Arrange plugins in plugins menu
-
On 28/05/2013 at 18:01, xxxxxxxx wrote:
User Information:
Cinema 4D Version: R13-R14
Platform: Windows ; Mac OSX ;
Language(s) : C++ ;---------
For some reason, I can't find any information about the & options to set the order that a set of plugins will appear in the Plugins menu. If anyone remembers how this works or has code (still combing mine) it would appreciated.Thanks,
-
On 28/05/2013 at 18:35, xxxxxxxx wrote:
It's right there in the documentation.
-Niklas
-
On 28/05/2013 at 19:06, xxxxxxxx wrote:
The docs don't tell you that you need to have a space between the prefix and the name of the plugin.
This is how I wrote how to use it in my notes:
Suppose you have two plugins: One is named A, the other is named B. A would be listed first in the plugins menu before B. Because of alphabetical order But...You can force them to be ordered differently like this: Using #$1 B -->makes B listed first in the plugins menu Using #$2 A -->makes A listed second in the plugins menu return RegisterCommandPlugin(PLUGIN_ID, "#$2 A", 0, AutoBitmap("icon.tif"), Help, gNew AutoComplete); return RegisterCommandPlugin(PLUGIN_ID, "#$1 B", 0, AutoBitmap("icon.tif"),Help, gNew myResDialog);
-ScottA
-
On 29/05/2013 at 02:21, xxxxxxxx wrote:
Originally posted by xxxxxxxx
The docs don't tell you that you need to have a space between the prefix and the name of the plugin.
Because you don't. It works fine without a space.
Steve
-
On 29/05/2013 at 03:52, xxxxxxxx wrote:
I had forgotten that it was particular to Command plugins (was looking just about everywhere else!).
Thanks!!!
-
On 29/05/2013 at 05:23, xxxxxxxx wrote:
It works with other Plugin types, too. I have successfully used it for objects.
-
On 29/05/2013 at 05:46, xxxxxxxx wrote:
Yep, I'm using it for a Command, Tool, and Object plugin which all show up in the same Plugins submenu. It has been so long since I used this feature that I couldn't even find it my own code.
-
On 29/05/2013 at 07:32, xxxxxxxx wrote:
Originally posted by xxxxxxxx
Because you don't. It works fine without a space.
Not for me it doesn't.
If I don't put a space between the prefix code and the plugin name in the registration code. It does not show the first letter of the plugin in the plugins menu.-ScottA
-
On 29/05/2013 at 08:29, xxxxxxxx wrote:
Maybe it is if you load it in the registration code, but if you load the string from the resource, then the space is not necessary. Here is part of c4d_strings.str for the previous version of X-Particles:
STRINGTABLE { IDS_BUILDXPTOOLBAR "#$01Build Toolbar"; IDS_XPARTICLE "#$03Emitter"; IDS_XGROUP "#$04Particle Group"; IDS_XGENERATOR "#$05Generator"; IDS_XSPRITE "#$06Sprites"; IDS_XTRAIL "#$07Trail"; IDS_XSYSTEM "#$09System"; IDS_XQUESTION "#$10Question"; IDS_XACTION "#$11Action"; IDS_XCACHE "#$12Cache"; IDS_XMODATTRACT "#$14Attractor"; IDS_XMODCHANGEGROUP "#$15Change group"; IDS_XMODCOVER "#$17Cover/Target"; IDS_XMODDEF "#$18Deflector"; IDS_XMODDIRECT "#$19Direction";
As you see, no spaces and works fine.
Steve
-
On 29/05/2013 at 08:46, xxxxxxxx wrote:
I'm glad you posted that Steve.
Because I was wondering how to use this plugin ordering stuff when GeLoadString() is used in the registration.I've got to add that one to my notes.
-ScottA