Autor Beitrag
Andreas Pfau
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 997



BeitragVerfasst: Fr 03.10.03 18:42 
Hallo,

STRG+A ist ja Standard für 'Alles markieren' in Kompos wie TEdit, TMemo usw. Leider wird das nicht in Delphi implementiert. Ich habe nun mehrere Möglichkeiten, u.A.:
  • Einen MainMenu-Eintrag mit Hotkey erzeugen
  • Den Hotkey über OnKeyDown implementieren
  • Ein eigenes PopupMenü erzeugen und dem Objekt zuweisen
Aber kann ich denn auch einfach auf das Menü-Handle zugreifen und einen Hotkey zuweisen? Oder kann ich sonst irgendwie den Hotkey einfach zuweisen?

_________________
Life is a bad adventure, but the graphic is really good!
Klabautermann
ontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic starofftopic star
Veteran
Beiträge: 6366
Erhaltene Danke: 60

Windows 7, Ubuntu
Delphi 7 Prof.
BeitragVerfasst: Fr 03.10.03 19:16 
Hallo,

ich würde dir die verwendung einer ActionList empfehlen. Je nach Delphi Version ist die von dir gewünschte Funktionalität auch schon als Standart Aktion vorhanden (tEdit->SelectAll).

Gruß
Klabautermann
Andreas Pfau Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 997



BeitragVerfasst: Fr 03.10.03 20:41 
Hallo,

hm... super Idee.. simpel und mit VCL... Danke! :D

_________________
Life is a bad adventure, but the graphic is really good!
Tino
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Veteran
Beiträge: 9839
Erhaltene Danke: 45

Windows 8.1
Delphi XE4
BeitragVerfasst: Mo 06.10.03 08:39 
Wie sieht denn dann die Exeucte Methode der entsprechenden Aktion aus? Ich müsste doch in der Methode überprüfen welche Komponente gerade den Fokus hat und dann je nach dem welche Komponente aktiv ist den Text manuel markieren lassen, oder?

Gruß
Tino