[Cuis-dev] adding functionality to morphs
Mark Volkmann
r.mark.volkmann at gmail.com
Sat Aug 31 11:07:28 PDT 2024
Using that approach to search for methods that contain "Paste" in their
source leads me to TextEditor>>defaultMenuSpec.
That is used by TextEntryMorph>>menuNshortcutsSpecsDo:.
That is used by Morph>>allMenuNshortcutsSpecs.
That is used by Morph>>getMenu.
That is used by Morph>>mouseButton2Activity.
That is used by Editor>>offerMenuFromEsc:.
That is used by Editor class>>initializeKeyboardActions.
That is used by Editor class>>initialize.
Long story short, I don't see a way to change what happens when the user
presses the escape key without creating a subclass of TextEntryMorph. I'm
fine with doing that and already have that approach working. But I'm
curious if there is an approach I overlooked that would allow me to
customize what happens in a TextEntryMorph when the user presses the escape
key (like I can for when the user presses the return key).
On Sat, Aug 31, 2024 at 3:47 AM Hilaire Fernandes via Cuis-dev <
cuis-dev at lists.cuis.st> wrote:
> Try searching for the text in the menu item:
>
> Le 30/08/2024 à 15:33, Mark Volkmann a écrit :
>
> When I move focus to the TextEntryMorph and press the escape key, 27 is
> displayed in the Transcript which is great. But it also displays a menu
> containing the Copy, Cut, and Paste options. For my use case I'd like to
> find a way to prevent that. I've spent some time searching the code to
> discover where that happens, but I haven't found it yet.
>
> --
> GNU Dr. Geohttp://gnu.org/s/dr-geo/http://gnu-drgeo.blogspot.com/
>
> --
> Cuis-dev mailing list
> Cuis-dev at lists.cuis.st
> https://lists.cuis.st/mailman/listinfo/cuis-dev
>
--
R. Mark Volkmann
Object Computing, Inc.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cuis.st/mailman/archives/cuis-dev/attachments/20240831/f4ad3426/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: WNMqVjCbBFmdzPsj.png
Type: image/png
Size: 39822 bytes
Desc: not available
URL: <http://lists.cuis.st/mailman/archives/cuis-dev/attachments/20240831/f4ad3426/attachment-0001.png>
More information about the Cuis-dev
mailing list