Forum: GUI-Design mit VCL / FireMonkey / Common Controls
Delphi
by Deep-Sea,
3. Dez 2007
Original von D2006 ExtCtrls.pas:
procedure TCustomLabeledEdit.SetBounds(ALeft, ATop, AWidth, AHeight: Integer);
begin
inherited SetBounds(ALeft, ATop, AWidth, AHeight);
SetLabelPosition(FLabelPosition);
end;
Forum: GUI-Design mit VCL / FireMonkey / Common Controls
Delphi
by Deep-Sea,
3. Dez 2007
TControl.Left := 123;
Dies sendet keine Windowsnachricht. Deine Methode wäre so total nutzlos.
Ich glaube aber das Resize nicht beim Loading kommt, also nimm vlt. doch besser SetBounds wie teebee gesagt hat.
Forum: GUI-Design mit VCL / FireMonkey / Common Controls
Delphi
by Deep-Sea,
3. Dez 2007
Fast schon ein Wunder, wenn du das Label ausrichtest, bevor Left und Top des Edits neu gesetzt wurden :shock: ...
Wie gesagt, nimm Resize.
Forum: GUI-Design mit VCL / FireMonkey / Common Controls
Delphi
by Deep-Sea,
3. Dez 2007
Wenn du zB. Left im Konstruktor des Edits nicht setzt, ist es 0. Also ist das Label wie du schon sagst bei -100.
a) Schau dir doch TLabeledEdit an, wie es da gemacht wird
b) Überschreibe die Methode Resize. Da drin kannst du dann das Label neu Ausrichten.
Forum: GUI-Design mit VCL / FireMonkey / Common Controls
Delphi
by Deep-Sea,
3. Dez 2007
Du musst das Label doch mit verschieben, wenn das Edit verschoben wird, oder?! :)