Autor Beitrag
cherry
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 136

WinXP - Professional
RAD Studio 2009
BeitragVerfasst: Di 21.02.06 16:08 
Yello

Ich möchte meinem Programm eine Mindestgrösse verpassen. D.h. mann soll die Grösse ändern können,
das Formular soll aber nie kleiner als z.B 600*800px werden.

Ich habe es schon mal mit dem OnResize Ereignis des Formulars versucht:
ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
 if form1.Height < 609 then
 begin
  form1.Height := 609;
 end;
 if form1.Width < 798 then
 begin
  form1.Width := 798;
 end;


funktioniert eigentlich, ist aber eine beschissne Lösung.
Wie krieg ich das eleganter hin?

_________________
AM I TOO SEXY?
Ist das nur mein Gefühl, oder ist die ganze Welt verrückt geworden!?
Marco D.
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 2750

Windows Vista
Delphi 7, Delphi 2005 PE, PHP 4 + 5 (Notepad++), Java (Eclipse), XML, XML Schema, ABAP, ABAP OO
BeitragVerfasst: Di 21.02.06 16:16 
Benutze die Formulareigenschaft 'constraints'.

_________________
Pascal keeps your hand tied. C gives you enough rope to hang yourself. C++ gives you enough rope to shoot yourself in the foot
cherry Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 136

WinXP - Professional
RAD Studio 2009
BeitragVerfasst: Di 21.02.06 16:34 
Oops.. Peino :oops:

THX

_________________
AM I TOO SEXY?
Ist das nur mein Gefühl, oder ist die ganze Welt verrückt geworden!?