摘要:
test 阅读全文
摘要:
使用API函数:声明 FUNCTION ulong ShowScrollBar(ulong hwnd,ulong wBar,ulong bShow) LIBRARY "user32.dll"调用constant long SB_HORZ = 0constant long SB_VERT = 1constant long SB_BOTH = 3ShowScrollBar(Handl... 阅读全文
摘要:
如何知道 Treeview,的节点是根节点 procedure TForm1.TreeView1ContextPopup(Sender: TObject; MousePos: TPoint;var Handled: Boolean);beginif TreeView1.Selected.IsFirstNode thenmni_delete.Ena... 阅读全文
摘要:
的属性的事件的方法 //1设置链接类型//2获取样式 链接和提示信息 //title是提示信息//HTTPS https://Hello//FILE file://Hello//FTP ftp:///Hello//HTT... 阅读全文
摘要:
//文件或目录转换成 TreeViewprocedure DirToTreeView(Tree: TTreeView; Directory: string; Root: TTreeNode; IncludeFiles:Boolean);varSearchRec: TSearchRec;ItemTemp: TTreeNode;begin... 阅读全文
摘要:
使用进度条查看浏览器状态 procedure TForm1.WebBrowser1ProgressChange(ASender: TObject; Progress,ProgressMax: Integer);beginProgressBar1.Max:=ProgressMax;if Progress = -1 then//ProgressBar1.Visi... 阅读全文
摘要:
type TForm1 = class(TForm) Button1: TButton; Panel1: TPanel; Edit1: TEdit; procedure FormActivate(Sender: TObject); private { Private declarations } public procedure DisplayHint(S... 阅读全文
摘要:
数组类型
数组类型定义了一组指定类型的元素序列,在方括号中填入下标值就可访问数组中的元素。定义数组时,方括号也用来指定可能的下标值。例如,下面的代码中定义了一个有 24 个整数的数组:typeDayTemperatures = array [1..24] of Integer;在数组定义时,你需要在方括号中填入一个子界类型的值,或者用两个有序类型的常量定义一个新的子界类型,子界类型... 阅读全文
摘要:
//在选中的节点中上添加1个节点
procedureTForm1.Button1Click(Sender:TObject); begin withTreeView1do begin Items.AddChild(Selected,'aaa'); end; end; //添加节点
procedureTForm1.Button1Clic... 阅读全文
摘要:
工具栏 的属性xe4的事件
Customizable OnCustomizeCanDelete OnCustomizeCanInsert OnCustomized OnCustomizeAdded OnCustomizeDelete OnCustomizeNewButton OnCustomizeReset 的方法 做成像MFC的工具栏样式
这个是使用Im... 阅读全文
摘要:
Sender和Tag的用法 在它们共同的OnClick事件下返回单击的那个按钮的标题 unit Unit1;interfaceusesWinapi.Windows, Winapi.Messages, System.SysUtils, System.Variants, System.Classes, Vcl.Graphics,Vcl.Controls, Vcl... 阅读全文
摘要:
的属性的事件的方法设置SpeedButton的Down的属性AllowAllUp属性 当有多个SpeedButton时 让有2个按钮都能处于按下状态 设置它的GroupIndex和别的按钮不一样SpeedButton1.GroupIndex := 1;//只要不为0 Down就有效SpeedButton1.Down :=True; 来自为知笔记(Wi... 阅读全文
摘要:
TreeView修改选中的节点的颜色和背景 TCustomDrawTarget = (dtControl, dtItem, dtSubItem); TCustomDrawStage = (cdPrePaint, cdPostPaint, cdPreErase, cdPostErase); TCustomDrawState = set of (cdsSelected, c... 阅读全文
摘要:
procedure TPopupMenu.Popup(X, Y: Integer); 这个点是相对桌面的而不是窗体的 GetCursorPos是鼠标的位置 鼠标动这个点就不一样 var p:TPoint;
begin GetCursorPos(p); PopupMenu1.Popup(p.x,p.Y);
end; 现在要取得 Button1的Le... 阅读全文