Autor Beitrag
Tilo
ontopic starontopic starontopic starontopic starofftopic starofftopic starofftopic starofftopic star
Beiträge: 1098
Erhaltene Danke: 13

Win7 geg. WInXP oder sogar Win98
Rad2007
BeitragVerfasst: Mo 25.05.09 16:39 
Ich steuer dann auch mal eine Variante bei.
Basis ist folgendes:
user profile iconBenBE hat folgendes geschrieben Zum zitierten Posting springen:
Also mein Favorit ist das hier:

ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
  if PointInRect(
    Point(X, Y),
    Rect(
      Width div 2 - 200, Height div 2 - 75,
      Width div 2 + 200, Height div 2 + 75
      )
    ) then
  begin
  ...
  end;



daraus wird:
ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
  
 if PointInRect( Point(X, Y),
                 Rect( Width div 2 - 200, Height div 2 - 75,
                       Width div 2 + 200, Height div 2 + 75 )  
               ) then
 begin
   ...
 end;


Ich spare lieber etwas Zeilen.
Leider geht das in Delphi nicht so gut wie z.B. in Java.