Autor Beitrag
Sithlord
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 172



BeitragVerfasst: So 02.11.08 22:17 
Hallo !

Ich möchte meine Komponenten, wenn ich die Delphi Form vergrößere, entsprechend anpassen, das sie sich also nicht an ihrer stelle halten, sondern beim vergrößern ihre Position entsprechend korrigieren.

Sonst habe ich bei bsnone das X nicht mehr oben rechts, sondern mittig, etc.

Edit: Mal Programm angehängt! Dort dann mal auf Das Viereck zum Maximieren klicken!
Einloggen, um Attachments anzusehen!
_________________
Heut ist nicht alle Tage, ich hab wieder ein Problem, keine Frage...
huuuuuh
ontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic starofftopic star
Beiträge: 665
Erhaltene Danke: 19

win xp, (win vista), win 7
VS 2008 Express Edition, VS 2010 Express Edition, VS 2010 Professionell
BeitragVerfasst: Mo 03.11.08 00:09 
du kannst die position doch manuell korrigieren? wenn man die größe nich frei stufenlos vertstellbar ist sollte das doch kein problem sein...
[ot]was macht dein programm? 1,8MB is schon relativ groß...[/ot]
matze
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 4613
Erhaltene Danke: 24

XP home, prof
Delphi 2009 Prof,
BeitragVerfasst: Mo 03.11.08 09:21 
schau dir mal die Eigenschaft Anchors der Kompos an. Das müsste dir helfen!

_________________
In the beginning was the word.
And the word was content-type: text/plain.
Xentar
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 2077
Erhaltene Danke: 2

Win XP
Delphi 5 Ent., Delphi 2007 Prof
BeitragVerfasst: Mo 03.11.08 10:27 
user profile iconmatze hat folgendes geschrieben Zum zitierten Posting springen:
schau dir mal die Eigenschaft Anchors der Kompos an. Das müsste dir helfen!

Damit werden die Komponenten aber soweit ich weiß nicht gleichmäßig verteilt?
Wenn man z.B. zwei Memo Felder hat, die jeweils die Hälfte des Formulars breit sein sollen, dann kommt man an "selber schreiben im OnResize" nicht dran vorbei.

Edit: OK, hab mir das Projekt grad mal angesehen. Hier könnten die Anchors wirklich schon ausreichen.

_________________
PROGRAMMER: A device for converting coffee into software.
matze
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 4613
Erhaltene Danke: 24

XP home, prof
Delphi 2009 Prof,
BeitragVerfasst: Mo 03.11.08 13:28 
Schau mal, was passiert, wenn du alle Anchors auf false setzt. Ist das nicht der Effekt, den du willst?

_________________
In the beginning was the word.
And the word was content-type: text/plain.
Hidden
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 2242
Erhaltene Danke: 55

Win10
VS Code, Delphi 2010 Prof.
BeitragVerfasst: Mo 03.11.08 15:37 
Hi,

Das dürfte so gehen. Noch komplexere Formatierung erreichst du übrigens, indem du verschiedene Komponenten auf Groupboxen ziehst.

Dann können z.B. zwei Groupboxen mit Align links und rechts per Anchors so eingestellt werden, dass sie proportional größer werden. Dann meinetwegen noch ein paar Controls, die mittig gehalten werden. Und auf die zwei Groupboxen könnten jeweils zwei RichEdits/Memos mit Align up, bzw. down, was sich dann auf die Groupboxen bezieht.

Also mit Align+Anchors+Groupboxen habe ich bis jetzt noch jedes Verhalten erzeugen können, das ich wollte ;)

mfG,

_________________
Centaur spears can block many spells, but no one tries to block if they see that the spell is a certain shade of green. For this purpose it is useful to know some green stunning hexes. (HPMoR)
Sithlord Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 172



BeitragVerfasst: Mo 03.11.08 17:11 
Ich schau mir die Anchors mal an, kann man die Groupboxen eig. unsichtbar machen, das nur das, was da drauf ist, zu sehen ist?

Edit:

Klappt wunderbar, mein Problem :
Das Editfeld muss sich vergrößern - werde ich mit "Onminimize" lösen, aber wie bekomme
ich das Webbrowserfeld in die Mitte ? Das hat keine Anchors oder ich bin nur blind!

Danke sehr! Bin euch was schuldig;)

_________________
Heut ist nicht alle Tage, ich hab wieder ein Problem, keine Frage...
Sithlord Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 172



BeitragVerfasst: Mi 05.11.08 20:23 
Klappt alles soweit wunderbar, einzigstes Problem:

Der Webbrowser vergrößert sich nicht mit...
Habe ihn auf ein Panel gesetzt, dann browser auf alclient.
das panel vergrößert sich aber der browser nicht?!

_________________
Heut ist nicht alle Tage, ich hab wieder ein Problem, keine Frage...