Home
Top.Mail.Ru Yandeks.Metrika
Forum: "Main";
Current archive: 2002.01.08;
Download: [xml.tar.bz2];

Down

Как сделать, чтобы Canvas прорисовывался при любых монипуляцих с окном Find similar branches


dimonf   (2001-12-16 17:23) [0]

Народ, как зделать чтобы мой данные которые я вывожу на Canvas не исчезали при лубых монипуляциях с окном?
И как мне сделать оброботчик нажатия клавиши если я создаю програмно TPanel?

type
TPreview = class(TPanel)
private
property Canvas;
protected
public
constructor Create(AOwner:TComponent); override;
end;

{ TPreview }

constructor TPreview.Create(AOwner: TComponent);
begin
Inherited Create (AOwner);
Parent := AOwner as TWinControl;
BevelInner := bvNone;
BevelOuter := bvNone;
Color := clWhite;
BorderStyle: = bsNone;
end;

procedure TForm1.FormPaint (Sender: TObject);
var R: TRect;
begin
with MyPrev do
begin
Canvas.Pen.Width := 1;
Canvas.Brush.Style: = bsSolid;
Canvas.Font.Size := 18;
R := Rect(10,10,100,100);
Canvas.Rectangle(R.Left-1, R.Top-1, R.Right+1, R.Bottom+1);
Canvas.TextRect(R,0,0,"Demos");
end;
end;

procedure TForm1.FormCreate (Sender: TObject);
var R: TRect;
begin
MyPrev:=TPreview.Create(Self);
MyPrev.Height:=Form1.Height*2;
Panel1.Height:=Form1.Height*2;
with MyPrev do
begin
Canvas.Pen.Width := 1;
Canvas.Brush.Style: = bsSolid;
Canvas.Font.Size := 18;
end;
end;

end;



dimonf   (2001-12-16 18:09) [1]

People, no thoughts ???



Pages: 1 whole branch

Forum: "Main";
Current archive: 2002.01.08;
Download: [xml.tar.bz2];

Top









Memory: 0.81 MB
Time: 0.035 c
6-22312
Leviathan
2001-10-15 00:24
2002.01.08
Hey, who knows about Indy? Help is needed!


1-22023
Delphig
2001-12-13 03:13
2002.01.08
I have ? off-topic. Which OS Delphi works best for?


7-22419
Pastor
2001-09-21 10:31
2002.01.08
Do I have a Celeron 800 worth upgrading to the Pentium III 800?


1-22123
dimonf
2001-12-15 16:33
2002.01.08
Question about


1-22076
Snake
2001-12-19 12:50
2002.01.08
How to find out the release date of the BIOS?





afrikaans albanian Arabic armenian azerbaijani basque belarusian bulgarian catalan Chinese (Simplified) Chinese (Traditional) croatian Czech danish Dutch English estonian filipino finnish French
galician georgian German greek haitian Creole hebrew Hindi hungarian icelandic indonesian Irish italian japanese Korean latvian lithuanian macedonian malay maltese norwegian
persian polish portuguese Romanian russian serbian slovak Slovenian Español swahili Swedish thai turkish Ukrainian urdu vietnamese welsh yiddish bengali bosnian
cebuano Esperanto gujarati hausa hmong igbo javanese kannada khmer lao latin maori marathi mongolian nepali punjabi somali tamil telugu yoruba
zulu
English French German Italian Portuguese Russian Spanish