Hm ... After you mentioned this idea, I already missed it in my daily workflow a few times (for instance, in Squeak Inbox Talk). I like it. :-) If we can agree on providing an optional model hook via a pluggable selector to provide a custom representation, I will be happy to implement the feature on PluggableListMorph instead. :-)<br>
<br>
Best,<br>
Christoph<br>
<br>
<font color="#808080">---<br>
</font><font color="#808080"><i>Sent from </i></font><font color="#808080"><i><a href="https://github.com/hpi-swa-lab/squeak-inbox-talk"><u><font color="#808080">Squeak Inbox Talk</font></u></a></i></font><br>
<br>
On 2022-01-17T15:42:06+01:00, marcel.taeumel@hpi.de wrote:<br>
<br>
> Hi Christoph --<br>
> <br>
> Well ... I think that I would implement a generic CMD+C shortcut directly in PluggableListMorph, regardless of what kind of text is being copied. Other than that: +1 <br>
> <br>
> Best,<br>
> Marcel<br>
> Am 17.01.2022 14:00:20 schrieb Thiede, Christoph <christoph.thiede at student.hpi.uni-potsdam.de>:<br>
> Hi Marcel,<br>
> <br>
> in which particular place did I deviate from this rule ("just copy the text that the user currently sees"? Are you proposing to copy *all* visible items instead of the only selected one? I'm not sure whether there are any applications for such a feature. :-)<br>
> <br>
> Best,<br>
> Christoph<br>
> <br>
> PS: Your e-mail client has absorbed the <cmd>c from the original message. :P<br>
> Von: Squeak-dev <squeak-dev-bounces at lists.squeakfoundation.org> im Auftrag von Taeumel, Marcel<br>
> Gesendet: Montag, 17. Januar 2022 12:21:28<br>
> An: squeak-dev<br>
> Betreff: Re: [squeak-dev] The Inbox: Tools-ct.1107.mcz<br>
>  <br>
> Hi Christoph --<br>
> <br>
> If would be nice if you would just copy the text that the user currently sees in the particular list widget. Maybe #withBlanksTrimmed.l At least for the keyboard shortcut CMD+C. In the popup menu, you can be more fine-grained as you proposed.<br>
> <br>
> Best,<br>
> Marcel<br>
> Am 15.01.2022 23:22:21 schrieb commits at source.squeak.org <commits at source.squeak.org>:<br>
> A new version of Tools was added to project The Inbox:<br>
> http://source.squeak.org/inbox/Tools-ct.1107.mcz<br>
> <br>
> ==================== Summary ====================<br>
> <br>
> Name: Tools-ct.1107<br>
> Author: ct<br>
> Time: 15 January 2022, 11:22:06.229373 pm<br>
> UUID: 3c64c912-518e-8841-a1a7-5998436d9da4<br>
> Ancestors: Tools-mt.1106<br>
> <br>
> Implements "copy class name" and "copy system/message category name" in all code browser tools and connects them to c, analogously to the already existing message item "copy selector".<br>
> <br>
> Uploaded to the inbox for the unexpected event that anyone objects against the tiny UI change. Otherwise, I will move this to the Trunk after a few days. =)<br>
> <br>
> =============== Diff against Tools-mt.1106 ===============<br>
> <br>
> Item was changed:<br>
> ----- Method: Browser>>classListMenu: (in category 'class functions') -----<br>
> classListMenu: aMenu<br>
> "Conveniently fit for backward compatibility with old browers stored in image segments"<br>
> <br>
> + aMenu addTranslatedList: #(<br>
> - aMenu addList: #(<br>
> -<br>
> ('browse full (b)' browseMethodFull)<br>
> ('browse hierarchy (h)' spawnHierarchy)<br>
> ('browse protocol (p)' browseFullProtocol)<br>
> ('browse documentation' browseAllCommentsForClass)<br>
> -<br>
> ('printOut' printOutClass)<br>
> ('fileOut' fileOutClass)<br>
> + ('copy name (c)' copyClassName)<br>
> -<br>
> ('show hierarchy' hierarchy)<br>
> ('show definition' editClass)<br>
> ('show comment' editComment)<br>
> -<br>
> ('references... (r)' browseVariableReferences)<br>
> ('assignments... (a)' browseVariableAssignments)<br>
> ('class refs (N)' browseClassRefs)<br>
> -<br>
> ('rename class ...' renameClass)<br>
> ('copy class' copyClass)<br>
> ('remove class (x)' removeClass)<br>
> -<br>
> ('find method...' findMethod)).<br>
> + ^ aMenu!<br>
> - ^ aMenu<br>
> - !<br>
> <br>
> Item was changed:<br>
> ----- Method: Browser>>mainMessageCategoryMenu: (in category 'message category functions') -----<br>
> mainMessageCategoryMenu: aMenu<br>
> <br>
> + ^ aMenu addTranslatedList: #(<br>
> - ^ aMenu addList: #(<br>
> ('browse' buildMessageCategoryBrowser)<br>
> ('print out' printOutMessageCategories)<br>
> ('file out' fileOutMessageCategories)<br>
> + ('copy name (c)' copyMessageCategoryName)<br>
> -<br>
> ('reorganize' editMessageCategories)<br>
> ('alphabetize' alphabetizeMessageCategories)<br>
> ('remove empty categories' removeEmptyCategories)<br>
> ('categorize all uncategorized' categorizeAllUncategorizedMethods)<br>
> ('new category...' addCategory)<br>
> -<br>
> ('rename...' renameCategory)<br>
> ('remove (x)' removeMessageCategory));<br>
> + yourself!<br>
> - yourself<br>
> - !<br>
> <br>
> Item was changed:<br>
> ----- Method: Browser>>mainSystemCategoryMenu: (in category 'system category functions') -----<br>
> mainSystemCategoryMenu: aMenu<br>
> <br>
> aMenu addTranslatedList: #(<br>
> ('find class... (f)' findClass)<br>
> ('back... (b)' recent)<br>
> -<br>
> ('browse all' browseAllClasses)<br>
> ('browse' buildSystemCategoryBrowser)).<br>
> <br>
> (Smalltalk isMorphic and: [self selectedPackage notNil]) ifTrue: [<br>
> aMenu<br>
> add: ('browse package ''{1}''' translated format: {self selectedPackage name})<br>
> subMenu: (self packageMenu: ((Smalltalk isMorphic<br>
> ifTrue: [MenuMorph new defaultTarget: self; yourself]<br>
> ifFalse: [CustomMenu new])<br>
> yourself))<br>
> target: self<br>
> selector: #yourself<br>
> argumentList: #()].<br>
> <br>
> aMenu addTranslatedList: #(<br>
> -<br>
> ('printOut' printOutSystemCategory)<br>
> ('fileOut' fileOutSystemCategory)<br>
> + ('copy name (c)' copySystemCategoryName)<br>
> -<br>
> ('reorganize' editSystemCategories)<br>
> ('alphabetize' alphabetizeSystemCategories)<br>
> -<br>
> ('update' updateSystemCategories)<br>
> ('add item...' addSystemCategory)<br>
> ('rename...' renameSystemCategory)<br>
> ('remove (x)' removeSystemCategory)).<br>
> ^ aMenu!<br>
> <br>
> Item was changed:<br>
> ----- Method: Browser>>messageCategoryListKey:from: (in category 'message category list') -----<br>
> messageCategoryListKey: aCharacter from: view<br>
> <br>
> + aCharacter == $c ifTrue: [ ^self copyMessageCategoryName ].<br>
> aCharacter == $x ifTrue: [ ^self removeMessageCategory ].<br>
> ^self arrowKey: aCharacter from: view<br>
> !<br>
> <br>
> Item was changed:<br>
> ----- Method: Browser>>systemCatListKey:from: (in category 'system category list') -----<br>
> systemCatListKey: aChar from: view<br>
> "Respond to a Command key. I am a model with a code pane, and I also have a listView that has a list of methods. The view knows how to get the list and selection."<br>
> <br>
> + aChar == $b ifTrue: [^ self recent].<br>
> + aChar == $c ifTrue: [^ self copySystemCategoryName].<br>
> aChar == $f ifTrue: [^ self findClass].<br>
> aChar == $x ifTrue: [^ self removeSystemCategory].<br>
> - aChar == $b ifTrue: [^ self recent].<br>
> ^ self classListKey: aChar from: view!<br>
> <br>
> Item was added:<br>
> + ----- Method: CodeHolder>>copyClassName (in category 'class functions') -----<br>
> + copyClassName<br>
> +<br>
> + self selectedClassName ifNotNil: [:name |<br>
> + Clipboard clipboardText: name asString].!<br>
> <br>
> Item was added:<br>
> + ----- Method: CodeHolder>>copyMessageCategoryName (in category 'message category functions') -----<br>
> + copyMessageCategoryName<br>
> +<br>
> + self selectedMessageCategoryName ifNotNil: [:name |<br>
> + Clipboard clipboardText: name asString].!<br>
> <br>
> Item was added:<br>
> + ----- Method: CodeHolder>>copySystemCategoryName (in category 'system category functions') -----<br>
> + copySystemCategoryName<br>
> +<br>
> + self selectedSystemCategoryName ifNotNil: [:name |<br>
> + Clipboard clipboardText: name asString].!<br>
> <br>
> Item was changed:<br>
> ----- Method: StringHolder>>classListKey:from: (in category '*Tools') -----<br>
> classListKey: aChar from: view<br>
> "Respond to a Command key. I am a model with a list of classes and a<br>
> code pane, and I also have a listView that has a list of methods. The<br>
> view knows how to get the list and selection."<br>
> <br>
> - aChar == $f ifTrue: [^ self findMethod].<br>
> - aChar == $r ifTrue: [^ self browseVariableReferences].<br>
> aChar == $a ifTrue: [^ self browseVariableAssignments].<br>
> + aChar == $c ifTrue: [^ self copyClassName].<br>
> + aChar == $f ifTrue: [^ self findMethod].<br>
> aChar == $h ifTrue: [^ self spawnHierarchy].<br>
> + aChar == $r ifTrue: [^ self browseVariableReferences].<br>
> aChar == $x ifTrue: [^ self removeClass].<br>
> ^ self messageListKey: aChar from: view!<br>
> <br>
> <br>
> -------------- next part --------------<br>
> An HTML attachment was scrubbed...<br>
> URL: <http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20220117/97360d34/attachment.html><br>
> <br>