Page 1 of 1
Toolbar Menus
Posted: 16.02.2023 16:16
by Stefan
Thanks to the Custom Toolbar plugin, I was able to -recreate my Synwrite setup. Fully functional, no complaints. However, the look and feel is not as good as in Synwrite.
1) No icons on the dropdown menus
2) My dropdowns open as standard Windows dialog. This puts me at the mercy of the host system, I have no control over fonts and colors.
3) Dropdown menus don't unfold, unless I click each and every one. Whereas in Synwrite, I can simply hover from menu to menu. Not to mention the nice gradient colors on my Synwrite skin.
Can I hope to see any of this in Cuda, sooner or later?

Posted: 17.02.2023 08:20
by main Alexey
>My dropdowns open as standard Windows dialog.
i guess you want to say 'as OS-like menus'? not dialogs. menus. i can try to add icons there, but the look of menus is fully OS-themed.
>Dropdown menus don't unfold, unless I click each and every one.
these are OS-theme menus? then the unfolding is fully OS controlled again. sorry. (SynWrite uses special 3rd party component)
Posted: 17.02.2023 15:06
by Stefan
main Alexey wrote:
i guess you want to say 'as OS-like menus'? not dialogs. menus.
Yep, you are right. That's what I meant.
I wonder, if I could use Config Menu instead of Config Toolbars. That would give me a themed look and smooth hover over workflow. BUT:
1) Will I be able to add icons on a menu?
2) After reading the help-topic about it, I don't understand how to call commands other than standard menu commands. Let's say I wanted to run an external tool I have set up. The command to trigger it:
How would I build this call into a customized menu entry?
Posted: 17.02.2023 15:14
by main Alexey
1) AFAIR icons are not supported in menus. reason 1: noone wanted. 2: icons can be not always 16x16 but menu needs 16x.
2)
https://wiki.lazarus.freepascal.org/Cud ... igure_Menu
look at the black picture!
it has example line with "cuda_exttools"! and wiuth "cuda_macros"! do by analog.
Posted: 17.02.2023 15:20
by main Alexey
i am addint this text to the wiki topic:
Example screenshot also shows two trick: how to write items for "External Tools" items and for "Macros" items: see lines with "cuda_exttools" and with "cuda_macros". These special lines need the special integer IDs. You can find these IDs in the hotkeys config "settings/keys.json" after you assign a hotkey to your tool/macro.
Posted: 17.02.2023 16:00
by Stefan
Thanks. Exactly what I was looking for. And a good idea, to add it to the Wiki.
So I must assign a hotkey to all my plugin-calls?
No hotkey, no ID?
I will need tons of hotkeys, for ColorText and Text Statistics and external tools etc. — this increases the risk to accidentally trigger something. Will try and experiment. And report back.
Posted: 17.02.2023 17:23
by main Alexey
you can look at ExtTools IDs in the ExtTools config, 'settings/exttools.json'. please try, I didn't test it!
Posted: 17.02.2023 19:25
by Stefan
main Alexey wrote:settings/exttools.json'. please try

Nice, this makes things easy enough for me. Maybe I will switch to themed custom menus, instead of toolbar dropdowns. If only menus could have icons. I usually need just a few, here and there, they are visual anchors, good for quick orientation.
Still in the process of moving from Syn to Cud, will experiment. Stay tuned ....