随笔分类 - 界面编程
摘要:1 DCDC := GetDc(0); //桌面DC := GetDc(窗口句柄) //窗口客户区DC := GetWindowDC(窗口句柄)) // 整个窗口,包括非客户区2 字体OldFont: HFONT; OldFont := SelectObject(WinDC, Canvas.Font.Handle);同样还有Pen, BRUSHPen 创建用CreatePen, Brush 用 C...
阅读全文
摘要:var Style: Integer;begin Style := GetWindowLong(Handle, GWL_STYLE);//wnd为控件句柄 if (Style and (WS_VSCROLL)) <> 0 then Caption := 'Yes' else Caption := 'No';end;
阅读全文
摘要:TButtonTest = class(TGraphicControl) public constructor Create(aOwner: TComponent); override; protected procedure Paint; override; end; constru...
阅读全文