Autor Beitrag
blackbirdXXX

ontopic starontopic starhalf ontopic starofftopic starofftopic starofftopic starofftopic starofftopic star
Beiträge: 1077
Erhaltene Danke: 1

Ubuntu Dapper

BeitragVerfasst: So 21.09.03 14:43 
Ich habe ein Label welches immer den Hint von einer Schaltfläche, Menü... anzeigen soll.

Ich habe keine Ahnung wie das gehen soll. Optimal wäre wenn ich im Hintfeld
ausblenden Quelltext
1:
Text1 | Text2					

eingeben könnte und dann als gelbes Fensterchen Text1 sehe und im Label den Text2.

Geht das?

PS.: Hoffentlich habe ich das nicht zu kompliziert erklährt

_________________
Klein, schwarz und ärgert Techniker? Jumper!
worm
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 135


D6 Prof
BeitragVerfasst: So 21.09.03 15:40 
Mit Application.OnHint müsste genau das gehen. Damit kannst du dann über GetLongHint oder so ähnlich den Text2 erhalten und dem Label als Caption zuweisen. Das normale gelbe Fenster sollte sich auch trotzdem noch anzeigen lassen können. Guck mal in der Hilfe, was zu Application.OnHint so steht, und frag, wenn Du dann noch Fragen hast :)

_________________
In the beginning, the universe was created. This has made a lot of people very angry, and is generally considered to have been a bad move.
blackbirdXXX Threadstarter

ontopic starontopic starhalf ontopic starofftopic starofftopic starofftopic starofftopic starofftopic star
Beiträge: 1077
Erhaltene Danke: 1

Ubuntu Dapper

BeitragVerfasst: So 21.09.03 17:13 
Titel: Lösung
:D Ich habs:

Die Lösung
ausblenden Delphi-Quelltext
1:
2:
3:
4:
procedure TMainForm.PanelHint(Sender: TObject);
begin
  MainForm.Simple.Caption := GetLongHint(Application.Hint);
end;


ausblenden Delphi-Quelltext
1:
2:
3:
4:
procedure TMainForm.FormCreate(Sender: TObject);
begin
 Application.OnHint := PanelHint;
end;

_________________
Klein, schwarz und ärgert Techniker? Jumper!