Same Description in different tabs? [SOLVED]
-
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 05/12/2010 at 16:53, xxxxxxxx wrote:
User Information:
ResEdit Version: R8---------
Hi again,I was wondering if there's a way to have one description appear in multiple tabs in the attribute manager? I'm using the first tab for dimension parameters for my object and the second tab is for advanced options. There's a good number of descriptions so I had to split them. Usability-wise, it would be better if I could have some things available whichever tab you're on. (For example, a button in the second tab generates something based on several descriptions, including one from the first tab. So that means going back and forth between tabs to do it.)
Here's sorta what I want to happen in the res file, though I know that the duplicate description is ignored by Cinema4D...
CONTAINER Otoothedwheelv2 { NAME Otoothedwheelv2; INCLUDE Obase; //=============================================================================== // "object" tab GROUP ID_OBJECTPROPERTIES{ LONG TOOTHEDWHEEL_TOOTHSHAPE{ CYCLE{ TOOTHEDWHEEL_TOOTHSHAPE_BOX; TOOTHEDWHEEL_TOOTHSHAPE_STANDARD; TOOTHEDWHEEL_TOOTHSHAPE_SPROCKET; TOOTHEDWHEEL_TOOTHSHAPE_TRIANGLE; TOOTHEDWHEEL_TOOTHSHAPE_SAWTOOTH; TOOTHEDWHEEL_TOOTHSHAPE_NONE; TOOTHEDWHEEL_TOOTHSHAPE_ADVANCED; } } INCLUDE Oprimitiveaxis; // other descriptions (omitted) } //=============================================================================== // second tab GROUP ID_SHAPE{ LONG TOOTHEDWHEEL_TOOTHSHAPE{ CYCLE{ TOOTHEDWHEEL_TOOTHSHAPE_BOX; TOOTHEDWHEEL_TOOTHSHAPE_STANDARD; TOOTHEDWHEEL_TOOTHSHAPE_SPROCKET; TOOTHEDWHEEL_TOOTHSHAPE_TRIANGLE; TOOTHEDWHEEL_TOOTHSHAPE_SAWTOOTH; TOOTHEDWHEEL_TOOTHSHAPE_NONE; TOOTHEDWHEEL_TOOTHSHAPE_ADVANCED; } } GROUP{ COLUMNS 2; LONG TOOTHEDWHEEL_SHAPEUP{ CYCLE{ TOOTHEDWHEEL_TOOTHSHAPE_BOX; TOOTHEDWHEEL_TOOTHSHAPE_STANDARD; TOOTHEDWHEEL_TOOTHSHAPE_SPROCKET; TOOTHEDWHEEL_TOOTHSHAPE_TRIANGLE; TOOTHEDWHEEL_TOOTHSHAPE_SAWTOOTH; TOOTHEDWHEEL_TOOTHSHAPE_NONE; TOOTHEDWHEEL_TOOTHSHAPE_USER; } } LINK TOOTHEDWHEEL_TWTAGA{ ACCEPT{1026329;}; } } GROUP{ COLUMNS 2; REAL TOOTHEDWHEEL_OFFSETUP{UNIT PERCENT; MIN -50; MAX 50; STEP 1;} REAL TOOTHEDWHEEL_SCALEUP{UNIT PERCENT; MIN 0; STEP 1;} } BOOL TOOTHEDWHEEL_FLIPUP{} SEPARATOR{LINE;} GROUP{ COLUMNS 2; LONG TOOTHEDWHEEL_SHAPEDOWN{ CYCLE{ TOOTHEDWHEEL_TOOTHSHAPE_BOX; TOOTHEDWHEEL_TOOTHSHAPE_STANDARD; TOOTHEDWHEEL_TOOTHSHAPE_SPROCKET; TOOTHEDWHEEL_TOOTHSHAPE_TRIANGLE; TOOTHEDWHEEL_TOOTHSHAPE_SAWTOOTH; TOOTHEDWHEEL_TOOTHSHAPE_NONE; TOOTHEDWHEEL_TOOTHSHAPE_USER; } } LINK TOOTHEDWHEEL_TWTAGB{ ACCEPT{1026329;}; } } GROUP{ COLUMNS 2; REAL TOOTHEDWHEEL_OFFSETDOWN{UNIT PERCENT; MIN -50; MAX 50; STEP 1;} REAL TOOTHEDWHEEL_SCALEDOWN{UNIT PERCENT; MIN 0; STEP 1;} }
So far the only workaround I've got would be to use completely different descriptions on each tab, but I can't find a good way to link them.
Going through MSG_DESCRIPTION_VALIDATE in the Message method, it's possible to alter description B if description A is changed, but there doesn't seem to be a way to change A based on B... The method is called when any description is changed; it doesn't specify which description was changed. It's like how priorities are handled in the Object Manager; items are calculated from the top down. If you change their order the whole simulation changes.Are there ways of getting past these limitations?
Thanks,
-gene
EDIT:
Uhh, I placed the post in the wrong category... Can it be moved to the SDK Help directory? It's supposed to be an R11.5 C++ question... Thanks. -
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 06/12/2010 at 05:33, xxxxxxxx wrote:
Did you know that you can display multiple tabs at the same time by Shift-clicking the tabs?
cheers,
Matthias -
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 06/12/2010 at 06:07, xxxxxxxx wrote:
Couldn't you respond to MSG_DESCRIPTION_CHECKUPDATE rather than MSG_DESCRIPTION_VALIDATE? This will give you the ID of the description element that's been changed and you can then change the corresponding element in the other tab.
-
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 06/12/2010 at 10:52, xxxxxxxx wrote:
@Matthias,
Well, I've got around 20 descriptions in the first tab, so it's gonna be like choosing either to scroll up and down or to click at the tabs to get to the items...@spedler,
Aye, MSG_DESCRIPTION_CHECKUPDATE is exactly what I needed! Never found it in the cinema4dsdk files I checked, so I didn't know what it was for.Here's that portion of the code in my Message method:
Bool ToothedWheelV2::Message(GeListNode *node, LONG type, void *t_data){ if(type == MSG_DESCRIPTION_CHECKUPDATE){ BaseContainer *data = ((BaseObject* )node)->GetDataInstance(); DescriptionCheckUpdate *dcu = (DescriptionCheckUpdate* ) t_data; if(dcu->descid[0][0].id == TOOTHEDWHEEL_TOOTHSHAPE){ data->SetLong(TOOTHEDWHEEL_SHAPEUP, data->GetLong(TOOTHEDWHEEL_TOOTHSHAPE, TOOTHEDWHEEL_TOOTHSHAPE_BOX) ); }else if(dcu->descid[0][0].id == TOOTHEDWHEEL_SHAPEUP){ data->SetLong(TOOTHEDWHEEL_TOOTHSHAPE, data->GetLong(TOOTHEDWHEEL_SHAPEUP, TOOTHEDWHEEL_TOOTHSHAPE_BOX) ); } } //... //the rest of the code //... }
So... I'm guessing MSG_DESCRIPTION_VALIDATE is almost like a light version of MSG_DESCRIPTION_CHECKUPDATE; it just calls the Message method without passing any parameters...
Thanks for all the help,
-gene