Delphi ʵÏÖ³ÌÐò ¶¯Ì¬ ÀàÃû
1¡¢Ê×ÏȽ«delphiÖÐControlsµ¥ÔªÌáÈ¡
2¡¢ÐÞ¸ÄControlsµ¥ÔªÖÐÈçϲ¿·Ö£º
procedure TWinControl.CreateParams(var Params: TCreateParams);
begin
FillChar(Params, SizeOf(Params), 0);
with Params do
begin
Caption := FText;
Style := WS_CHILD or WS_CLIPSIBLINGS;
AddBiDiModeExStyle(ExStyle);
if csAcceptsControls in ControlStyle then
begin
Style := Style or WS_CLIPCHILDREN;
ExStyle := ExStyle or WS_EX_CONTROLPARENT;
end;
if not (csDesigning in ComponentState) and not Enabled then
Style := Style or WS_DISABLED;
if FTabStop then Style := Style or WS_TABSTOP;
X := FLeft;
Y := FTop;
Width := FWidth;
Height := FHeight;
if Parent <> nil then
WndParent := Parent.GetHandle else
WndParent := FParentWindow;
WindowClass.style := CS_VREDRAW + CS_HREDRAW + CS_DBLCLKS;
WindowClass.lpfnWndProc := @DefWindowProc;
WindowClass.hCursor := LoadCursor(0, IDC_ARROW);
WindowClass.hbrBackground := 0;
WindowClass.hInstance := HInstance;
//////////////////
StrPCopy(WinClassName, IntToStr(GetTickCount));
//StrPCopy(WinClassName, ClassName);
end;
end;
±¾ÎÄÀ´×ÔDelphiÖ®´°£¬ÔÎĵØÖ·£ºhttp://www.52delphi.com
Ïà¹ØÎĵµ£º
unit unitMain;
interface
uses
Registry, shlobj,
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls, ExtCtrls;
type
TExtForm = class(TForm)
ledExtension: TLabeledEdit;
ledAssocApp: TLabeledEdit;
GetAssocApp: TButton;
AssocTh ......
http://www.delphibbs.com/delphibbs/dispq.asp?lid=2420610
Ŀ¼
===============================================================================
¡Ñ
RTTI ¼ò½é
¡Ñ Àà(class) ºÍ VMT µÄ¹Øϵ
¡Ñ Àà(class)¡¢ÀàµÄÀà(class of class)¡¢Àà±äÁ¿(class
variable) µÄ¹Øϵ
¡Ñ TObject.ClassType ºÍ TObject.ClassInf ......
1¡¢µ±È»ÊÇÏÈҪжÔØÒÔÇ°°²×°µÄEhlib×é¼þÁË£¬Ôڲ˵¥µÄ“Component”µÄ“install Packeges”ÀѡÔñehlib XX£¬Ñ¡Ôñ“Remove”¡£
2¡¢½ÓÏÂÀ´ÔÚ¿âÀï¼ÓÈëÕâ¸ö¿Ø¼þµÄÒýÓ÷¾¶£¬ÏÈн¨Ò»¸öÎļþ¼Ð£¬±ÈÈç“D:\Component\Ehlib”£¨×îºÃ°ÑÒª°²×°µÄ¿Ø¼þ¶¼¿½±´µ½Õâ¸öComponentĿ¼Ï£©£¬È»ºó°Ñ ......
Delphi×Ö·û´®¡¢PCharÓë×Ö·ûÊý×éÖ®¼äµÄת»»
ÉèÓÐÒÔÏÂÈý¸ö±äÁ¿£º
var
s:string;
p:pchar;
a:array[1..20] of char;
ÄÇôÈýÕßÖ®¼äµÄת»»ÈçÏ£º
1¡¢×Ö·û´®µ½PChar
p:=PChar(s);
2¡¢PCharµ½×Ö·û´®
s:=p;
3¡¢PCharµ½×Ö·ûÊý×é
StrCopy(@a,p);
4¡¢×Ö·ûÊý×éµ ......
......