Z
zraul
Unregistered / Unconfirmed
GUEST, unregistred user!
unit Dragpanel;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, Menus, StdCtrls, DB, DBTables, ExtCtrls;
type
TDragpanel = class(TComponent)
Panel1:TPanel;
Label1:TLabel;
Dragbutton:TButton;
private
FPanelText: string;
//FCardIndex:integer;
{ Private declarations }
protected
{ Protected declarations }
public
{ Public declarations }
procedure SetPanelText(value: string);
//procedure SetCardIndex(value: integer);
published
{ Published declarations }
property PanelText: string read FPanelText write SetPanelText;
//property CardIndex: integer read FCardIndex write SetCardIndex;
constructor Create( AOwner : TComponent ); override;
end;
procedure Register;
implementation
procedure Register;
begin
RegisterComponents('Samples', [TDragpanel]);
end;
constructor TDragpanel.Create( AOwner : TComponent );
begin
Panel1.Height:=80;
Panel1.Width:=30;
Label1.WordWrap:= True;
Label1.font.Size:= 8;
Label1.width:= 12;
Label1.WordWrap:= True;
Label1.AutoSize:= False;
Label1.left :=(Panel1.Width-Label1.Width) div 2+Panel1.Left;
Label1.top :=(Panel1.Height-Label1.Height) div 2+Panel1.top;
end;
procedure TDragpanel.SetPanelText(value: string);
begin
Label1.Caption := value;
end;
{procedure TDrag_panel.SetCardIndex(value:integer);
begin
end;
}
end.
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, Menus, StdCtrls, DB, DBTables, ExtCtrls;
type
TDragpanel = class(TComponent)
Panel1:TPanel;
Label1:TLabel;
Dragbutton:TButton;
private
FPanelText: string;
//FCardIndex:integer;
{ Private declarations }
protected
{ Protected declarations }
public
{ Public declarations }
procedure SetPanelText(value: string);
//procedure SetCardIndex(value: integer);
published
{ Published declarations }
property PanelText: string read FPanelText write SetPanelText;
//property CardIndex: integer read FCardIndex write SetCardIndex;
constructor Create( AOwner : TComponent ); override;
end;
procedure Register;
implementation
procedure Register;
begin
RegisterComponents('Samples', [TDragpanel]);
end;
constructor TDragpanel.Create( AOwner : TComponent );
begin
Panel1.Height:=80;
Panel1.Width:=30;
Label1.WordWrap:= True;
Label1.font.Size:= 8;
Label1.width:= 12;
Label1.WordWrap:= True;
Label1.AutoSize:= False;
Label1.left :=(Panel1.Width-Label1.Width) div 2+Panel1.Left;
Label1.top :=(Panel1.Height-Label1.Height) div 2+Panel1.top;
end;
procedure TDragpanel.SetPanelText(value: string);
begin
Label1.Caption := value;
end;
{procedure TDrag_panel.SetCardIndex(value:integer);
begin
end;
}
end.