[Cuis-dev] How do I read a file dragged and dropped on to the desktop?
H. Hirzel
hannes.hirzel at gmail.com
Sat Apr 26 02:02:52 PDT 2025
To start giving the answer myself:
1. I dropped a *.st file onto the desktop.
2. I get a popup menu with the options
- browse code
- open code changes
- file in
3. I pick the most prominent menu in the sense that there are probably
not many occurrences of it in the code: 'open code changes'.
4. I want to paste this into either a TextEditor or a Workspace. If I
paste 'open code changes' into a Workspace the word 'open' changes to
the color red which suggests that this is not the right place to do this
kind of operation. But in fact is, as only in the WorkSpace I have the
'right-click-menu-choice' of 'Method Strings with it (E)' which brings
up the result
ChangeList
````
serviceContents
"Answer a service for opening a changelist browser on a file"
^ (SimpleServiceEntry
provider: self
label: 'open code changes'
selector: #browseContents:
description: 'open a code file contents tool on this file'
buttonLabel: 'all changes'
icon: #changesIcon)
sortOrder: 20
````
From here I can work backwards to explore the implementation of the
service architecture and find out how to implement a service for a file
extension not included yet.
Note: The menu option 'Method Strings with it (E)' has an (E) indicating
that there is a keyboard shortcut for it. On my MicrosoftWindows
installation ALT+E does not directly do it but it gives an options
dialog where I can specify the scope where the search is done.
--HH
On 26/04/2025 9:39 am, H. Hirzel wrote:
> Hello
>
> I am looking for a hints/an explantation/howTo which explains how I
> can read a file dragged from the FileExplorer outside Cuis onto the
> Cuis desktop.
>
> Thank you in advance for the suggestions.
>
> Hannes
>
>
More information about the Cuis-dev
mailing list