Icons in Main menu for em_usercmd

Here you can propose new features, make suggestions etc.

Moderators: white, Hacker, petermad, Stefan2

Post Reply
User avatar
Mikefield
Power Member
Power Member
Posts: 628
Joined: 2006-02-26, 19:13 UTC
Location: Oberursel, Germany HE

Icons in Main menu for em_usercmd

Post by *Mikefield »

These days I made my first experiences with em_usercmd. I add some of it to the main menu.
Unfortunately it's not possible to show icons for these commands in the main menu.
If I add these commands to the button bar, the icons are shown correct.
Is it planned to show icons for em_usercmd in the main menu too?

Code: Select all

[em_usercmd609]
menu=Restart TC
cmd=ReloadTC.exe
button=D:\Util\Viewer\WinCmd\Plugins\Util\ReloadTC\ReloadTC.exe
path=%COMMANDER_PATH%\Plugins\Util\ReloadTC
mf
Bankster - Word of the Year 2009
User avatar
Sombra
Power Member
Power Member
Posts: 811
Joined: 2005-12-27, 22:23 UTC
Location: Zaragoza, Spain

Post by *Sombra »

2Mikefield

Hello,

Currently it is possible for em_xyz commands, but not in the way that we have in mind. Parameter "button=" for an extended command is ignored in main menu. Here a way for do it:
You can map icons for extended commands in the file WCMICONS.INC. The format is as follow:

Code: Select all

# Command -> Icon index for icons inside WCMICONS.DLL
I recommend to use WCICONEX.DLL and WCICONEX.INC instead WCMICONS.DLL & WCMICONS.INC. So you can avoid that files will be overwritten in a future update of TC or re-installation.

You must add your custom icons to WCICONEX.DLL (Any good icon editor is valid, although I know that Clo could recommend a very good icon editor ;) )
"Extended commands" in main menu takes the ID starting by the number 10000. Well, then the first extended command which appears in menu, have the ID 10000, the second em_xyz in main menu have the ID 10001, etc.

The content of your WCICONEX.INC should looks like:

Code: Select all

[mappings]
69=26
...
...
10000=#icon index in WCICONEX.DLL for the first extended command in main menu
10001=#icon index in...
HTH
I can read English, but... I write like Tarzan. (sorry)
User avatar
Mikefield
Power Member
Power Member
Posts: 628
Joined: 2006-02-26, 19:13 UTC
Location: Oberursel, Germany HE

Post by *Mikefield »

Hello Sombra!
Thanks for your detailed answer! I've tried it and it works! Great!
Question: Points the mapping 10000 to the 1st command in the usercmd.ini or
to the 1st em_command in the which is found in the menu file?
How can I map the TC to use the WCMICONSEX.DLL and INC?

Last question, what is the magic icon editor which Claude recommended?
ADD: Found the answer on forum search -> something with Greenfish :)

mf
Bankster - Word of the Year 2009
User avatar
petermad
Power Member
Power Member
Posts: 14793
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Post by *petermad »

How can I map the TC to use the WCMICONSEX.DLL and INC?
Simply just place the two files in the TC program directory - then they will be used at next restart of TC.
License #524 (1994)
Danish Total Commander Translator
TC 11.03 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1371a
TC 3.50 on Android 6 & 13
Try: TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
User avatar
Sombra
Power Member
Power Member
Posts: 811
Joined: 2005-12-27, 22:23 UTC
Location: Zaragoza, Spain

Post by *Sombra »

Hello Mikefield,

Points the mapping 10000 to the 1st command in the usercmd.ini or to the 1st em_command in the which is found in the menu file?
The ID 10000 is for the first extended command found in main menu. It don't care if the extended command is stored in usercmd.ini or in WCMD_<XXX>.ini.
<XXX> = Initials for the current language in TC. Perhaps you decide to use the usercmd.ini file for have access "always" to your custom commands (independently of the language used in TC .

How can I map the TC to use the WCMICONSEX.DLL and INC?
If you have not such files in main directory of TC, then you can copy
wcmicons.dll to > wciconex.dll
wcmicons.inc to > wciconex.inc

Last question, what is the magic icon editor which Claude recommended?
ADD: Found the answer on forum search -> something with Greenfish Smile
Yes it was :)
I can read English, but... I write like Tarzan. (sorry)
User avatar
Mikefield
Power Member
Power Member
Posts: 628
Joined: 2006-02-26, 19:13 UTC
Location: Oberursel, Germany HE

Post by *Mikefield »

Thanks for clarification to both!

mf
Bankster - Word of the Year 2009
Post Reply