![]() |
| ||
|
|
Новости |
Поиск |
FAQ |
Статьи |
Книги |
Новости VCL
| | Форумы ЧАТ |
Орешник |
|
| |||
| |||
« предыдущая ветвь | форум | следующая ветвь »
Applet and Forms?
Jon © (2008-02-13 04:05:00)If I set HasBorder or HasCaption to False to forms within a multi-form applet, then the form is not shown:
program Project1;
uses
KOL;
var
Form1, Form2: PControl;
begin
Applet := NewApplet('');
Form1 := NewForm(Applet,'Form1');
Form2 := NewForm(Applet,'Form2');
Form1.HasBorder := False; // Form will not show
// Form2.HasBorder := False;
// Form1.HasCaption := False;
// Form2.HasCaption := False;
Run(Applet)
end.
If I remove the Applet, then the forms work correctly. Bug?
_vadim (2008-02-15 05:57:00) [1]To Jon:
Yes, Yes... :-)
If to write:
Form1.HasBorder := False; // Form will not show
MsgOk(Int2Str(Form1.Width)+', '+Int2Str(Form1.Height)); // -- My addition
Run(Applet)
then I can see "0, 0"... :-)
Jon (2008-02-15 03:38:00) [2]I found the problem:
program Project1;
uses
KOL;
var
Form1, Form2: PControl;
begin
Applet := NewApplet('');
Form1 := NewForm(Applet,'Form1').SetSize(640,480);
Form2 := NewForm(Applet,'Form2').SetSize(640,480);
Form1.HasBorder := False;
// Form2.HasBorder := False;
// Form1.HasCaption := False;
// Form2.HasCaption := False;
Run(Applet)
end.
The sizeof the form has to be defined.
I hope that I did not waste anyone's time.