Re: [Pharo-dev] [Ann] Commander shortcuts in Settings Browser

2018-03-06 Thread Tudor Girba
Nice work!

Doru


> On Mar 6, 2018, at 5:05 PM, Denis Kudriashov  wrote:
> 
> Hi.
> 
> With latest version of Commander and Calypso we will have all shortcuts 
> explorable and configurable in Settings Browser:
> 
> 
> ​
> Currently it uses command class name and class comment for presentation. We 
> can improve it in future if necessary.
> In addition you can add single shortcut to your own application settings. For 
> example:
> 
> MyApp class>>appSettingsOn: aBuilder
> 
> 
> ann := ClySpawnFullBrowserCommand classAnnotationAt: 
> #browserShortcutActivation.
> (ann buildSettingNodeOn: aBuilder)
>label: 'My app shortcut';
>description: 'This command opens browser'
> 
> Shortcut settings are persisted as all other settings. Only redefined 
> shortcuts are stored into the file.
> 
> This version also allows to add commands into the world menu and world 
> shortcuts. Just use CmdWorldMenuContext for command annotations:
> 
> CmdOpenFamilyBookCommand class>>worldMenuActivation
> 
> ^CmdContextMenuCommandActivation byRootGroupItemFor: CmdWorldMenuContext 
> 
> CmdOpenFamilyBookCommand class>>globalShortcutActivation
> 
> ^CmdShortcutCommandActivation by: $o meta, $f meta for: 
> CmdWorldMenuContext 
> 
> (CmdOpenFamilyBookCommand is a command from Commander-Examples package).
> 
> Nice detail: all shortcuts are updated immediately when you modify 
> annotations either from settings or programmatically from browser. 
> 
> Now pull request for Pharo 7 is waiting integration. Soon it will be inside.
> 
> Best regards,
> Denis

--
www.tudorgirba.com
www.feenk.com

"When people care, great things can happen."







Re: [Pharo-dev] [Ann] Commander shortcuts in Settings Browser

2018-03-06 Thread Cyril Ferlicot D.
Le 06/03/2018 à 17:05, Denis Kudriashov a écrit :
> Hi.
> 
> With latest version of Commander and Calypso we will have all shortcuts
> explorable and configurable in Settings Browser:
> 
> 
> ​
> Currently it uses command class name and class comment for presentation.
> We can improve it in future if necessary.
> In addition you can add single shortcut to your own application
> settings. For example:
> 
> MyApp class>>appSettingsOn: aBuilder
>     
> 
> 
>     ann := ClySpawnFullBrowserCommand classAnnotationAt:
> #browserShortcutActivation.
> 
>     (ann buildSettingNodeOn: aBuilder)
> 
>        label: 'My app shortcut';
> 
>        description: 'This command opens browser'
> 
> 
> Shortcut settings are persisted as all other settings. Only redefined
> shortcuts are stored into the file.
> 
> This version also allows to add commands into the world menu and world
> shortcuts. Just use CmdWorldMenuContext for command annotations:
> 
> CmdOpenFamilyBookCommand class>>worldMenuActivation
>   
>   ^CmdContextMenuCommandActivation byRootGroupItemFor:
> CmdWorldMenuContext 
> 
> 
> CmdOpenFamilyBookCommand class>>globalShortcutActivation
>   
>   ^CmdShortcutCommandActivation by: $o meta, $f meta for:
> CmdWorldMenuContext 
> 
> (CmdOpenFamilyBookCommand is a command from Commander-Examples package).
> 
> Nice detail: all shortcuts are updated immediately when you modify
> annotations either from settings or programmatically from browser. 
> 
> Now pull request for Pharo 7
>  is waiting
> integration. Soon it will be inside.
> 
> Best regards,
> Denis

Hi!

This is really cool :)

Indeed, for the Pharo release it would be much much better to have a
titles instead of method selectors to display.

Also, maybe we could have a way to group shortcut settings. Because
latter if Commander is more used, we should have "Editor shortcuts",
"Debugger shortcuts", "Iceberg shortcuts"...

Thank you for the work!

-- 
Cyril Ferlicot
https://ferlicot.fr



signature.asc
Description: OpenPGP digital signature