![]() |
VR-Forces 4.7 Class Documentation
|
This class manages the dialog box that appears when the user modifies a DI-Guy entity in the Simulation Object Editor. More...

Public Slots | |
| virtual void | setDiGuyCharString (int) |
| Causes a label to display currently selected entity type. | |
| virtual void | setDiGuyCharToolTip (int) |
| virtual void | newCharacterTypeSelected (int typeIndex) |
| Called whenever the user changes the character type typeIndex is index of a character type. | |
| virtual void | newAppearanceSelected (const QString &appearance) |
| Called whenever the user changes the selected appearance. | |
| virtual void | updateRandomAppearancesMap (QListWidget *list) |
| Called whenever the user modifies the list of available appearances for randomization. | |
| virtual void | newHandItemSelected (const QString &) |
| Same idea as appearance stuff. | |
| virtual void | updateRandomHandItemsMap (QListWidget *) |
| virtual void | newHeadSelected (const QString &) |
| Same idea as appearance stuff, but with addition of appearance index. | |
| virtual void | updateRandomHeadsMap (QListWidget *) |
| virtual void | setDiGuyAnimationString (int) |
| virtual void | setDiGuyAnimationToolTip (int) |
| virtual void | updateDefaultAnimation (int) |
| virtual void | createRandomAppearancesDialog () |
| Creates the dialog box for selecting which appearances will be candidates for random selection. | |
| virtual void | closedRandomAppearancesDialog () |
| Called when the above is closed. | |
| virtual void | createRandomHandItemsDialog () |
| virtual void | createRandomHeadsDialog () |
| virtual void | createAppearanceFilterDialog () |
| Creates the dialog box for type map filtering (see comments there) | |
| virtual void | filterBoxPopulated (const std::vector< DtString > &) |
| Called when a combo box in the type map filtering widget is populated. | |
| virtual void | filterItemSelected (int index, QString &val) |
| Called when user selects an item in one of the type map filtering combo boxes. | |
| virtual void | reRandomizeCharacter () |
| if any aspects of character are random, regenerate new visuals | |
| virtual DtString | firstUsableFrom (const QHash< QString, bool > &) const |
| Returns the first useable item in some appearance map (body, head, hand item, whatever) | |
| virtual void | resetCharacterTypes () |
Signals | |
| void | characterChanged () |
| void | appearanceChanged () |
| when character type changes | |
| void | handItemChanged () |
| when appearance changes | |
| void | headChanged () |
| when hand item changes | |
| void | defaultAnimationChanged () |
| when head changes | |
| void | randomAppearanceListChanged () |
| void | randomHandItemListChanged () |
| when there is a change to this list, including which items are checked | |
| void | randomHeadListChanged () |
| void | appearancesReset () |
| void | handItemsReset () |
| when the list of appearances is repopulated | |
| void | headsReset () |
| void | animationsReset () |
| void | generateAll () |
Public Member Functions | |
| DtDiGuyConfigurationWidget (makVrv::DtDe &de, QWidget *parent=0, const Qt::WindowFlags &flags=0) | |
| default constructor | |
| virtual | ~DtDiGuyConfigurationWidget () |
| destructor | |
| virtual bool | init () |
| Initializers. | |
| virtual void | setUpCharacterTypes () |
| Populate "character types" combo box. | |
| virtual void | setAppearancesFromCharacter (const QString &characterType) |
| Given a character type, set all the appearances that show up in the appearance dropdown and in the random appearances dialog. | |
| virtual void | setUpRandomAppearancesMap (DtRwNLengthStringVector *randomList, bool checkToSelect=true) |
| Mark all appearances that appear in the list as available for random selection, if they are already present in the random appearances map. | |
| virtual void | setHandItemsFromCharacter (const QString &characterType) |
| Given a character type, set all the hand items that show up in the hand item dropdown and in the random hand items dialog. | |
| virtual void | setUpRandomHandItemsMap (DtRwNLengthStringVector *randomList, bool checkToSelect=true) |
| All the entries in randomList, if found in hand item map, are flagged as checked. | |
| virtual void | setHeadsFromCharacterTypeAndAppearance (const QString &characterType, const QString &appearance) |
| Same idea as setAppearancesFromCharacter(). | |
| virtual void | setUpRandomHeadsMap (DtRwNLengthStringVector *randomList, bool checkToSelect=true) |
| All the entries in randomList, if found in head map, are flagged as checked. | |
| virtual void | setUpAnimationsFromCharacter (const QString &character) |
| Same idea as setAppearancesFromCharacter() | |
| virtual void | setUseRandomAppearances (bool random) |
| Makes the use of random appearances allowed (or not). | |
| virtual bool | useRandomAppearances () |
| virtual void | setUseRandomHandItems (bool random) |
| virtual bool | useRandomHandItems () |
| virtual void | setUseRandomHeads (bool random) |
| virtual bool | useRandomHeads () |
| virtual void | setCurrentCharacter (const QString &characterType) |
| Changes current character type. Updates selection in dropdown and contents of dependent dropdowns. | |
| virtual DtString | getCurrentCharacter () |
| virtual void | setCurrentAppearance (const QString &appearance, bool forceUpdate=false) |
| Changes current character appearance. | |
| virtual QString | getCurrentAppearance () |
| Returns name of current appearance. | |
| virtual DtString | randomAppearance () const |
| Returns an allowable (checked) random appearance. | |
| virtual void | setCurrentHandItem (const QString &handItem, bool forceUpdate=false) |
| Changes current hand item. | |
| virtual QString | getCurrentHandItem () |
| Returns name of current hand item. | |
| virtual DtString | randomHandItem () const |
| Returns an allowable (checked) random hand item. | |
| virtual void | setCurrentHead (const QString &head, bool forceUpdate=false) |
| Changes current head. | |
| virtual QString | getCurrentHead () |
| Returns name of current head. Might be "random". | |
| virtual DtString | randomHead () const |
| Returns an allowable (checked) random head. | |
| virtual void | setCurrentAnimation (const QString &action) |
| virtual DtString | getCurrentAnimation () |
| virtual AlternateNamesList & | getTaskableAnimationList () |
| virtual bool | randomAppearancesChanged () |
| Specifies if user has changed the list of appearances to be used in random appearances mode. | |
| virtual void | setRandomAppearancesChanged (bool b) |
| virtual void | getRandomAppearances (DtRwNLengthStringVector *randomList, bool getAll=false) |
| Returns a list of appearances checked as usable for randomization. | |
| virtual bool | randomHandItemsChanged () |
| Specifies if user has changed the list of hand items to be used in random hand items mode. | |
| virtual void | setRandomHandItemsChanged (bool b) |
| virtual void | getRandomHandItems (DtRwNLengthStringVector *randomList, bool getAll=false) |
| See getRandomAppearances() | |
| virtual bool | randomHeadsChanged () |
| Specifies if user has changed the list of heads to be used in random heads mode. | |
| virtual void | setRandomHeadsChanged (bool b) |
| virtual void | getRandomHeads (DtRwNLengthStringVector *randomList, bool getAll=false) |
| See getRandomAppearances() | |
| virtual bool | blockSignals (bool block) |
| Prevent/allow any of the Qt combo boxes from/to send(ing) signals. | |
| virtual void | preserveCurrentRandomValues (bool preserve) |
Public Attributes | |
| Ui::DIGuyConfigurationWidgetUi | myUiImpl |
| The code generated from the underlying .ui file. | |
Protected Member Functions | |
| virtual int | findIndexFromString (const QString &name, AlternateNamesList *list) |
| Helpers. | |
| virtual DtString | getCurrentOrRandomValue (QComboBox *box, QHash< QString, bool > *map, bool *retWasRandom=NULL) |
| Returns whatever value is selected, if not "random". | |
| virtual DtString | getAllowedRandomValue (const QHash< QString, bool > *map) const |
| Given a map with some checked and unchecked values in it, return a checked one at random. | |
| virtual bool | isAllowedRandomValue (const QString &value, const QHash< QString, bool > *map) |
| virtual void | mergeInOldMap (QHash< QString, bool > *currentMap, const QHash< QString, bool > *oldMap) |
| If the old map contains checked items and these items are present in the current map, make sure they are checked there, too. | |
Static Protected Attributes | |
| static QString | sQStringRandom |
| static const int | numTypeMapFieldCombos = 6 |
| Note that these variables and their values should conform to the way things are done in DtDIGuyAppearanceFilterWidget. | |
Private Member Functions | |
| DtDiGuyConfigurationWidget (const DtDiGuyConfigurationWidget &orig) | |
| copy constructor - not implemented | |
| DtDiGuyConfigurationWidget & | operator= (const DtDiGuyConfigurationWidget &orig) |
| assignment operator - not implemented | |
This class manages the dialog box that appears when the user modifies a DI-Guy entity in the Simulation Object Editor.
From this box, the user can change the entity's character type, its default appearance, the default hand item, and the default head. These will determine the entity's initial visuals when it's placed in the Sim world.
The user can also choose to randomize the default settings. For example, randomizing the default appearance will open another dialog box that allows the user to check or uncheck which of the available appearances will be chosen among at placement time. The set of available appearances, of course, is determined by the current character type.
Note that the contents of the lower dropdowns (e.g. head) depend on the selections made in the upper ones (e.g. type).
| DtDiGuyConfigurationWidget::DtDiGuyConfigurationWidget | ( | makVrv::DtDe & | de, |
| QWidget * | parent = 0, |
||
| const Qt::WindowFlags & | flags = 0 |
||
| ) |
default constructor
|
virtual |
destructor
|
private |
copy constructor - not implemented
|
virtual |
Initializers.
|
virtual |
Populate "character types" combo box.
|
virtual |
Given a character type, set all the appearances that show up in the appearance dropdown and in the random appearances dialog.
|
virtual |
Mark all appearances that appear in the list as available for random selection, if they are already present in the random appearances map.
|
virtual |
Given a character type, set all the hand items that show up in the hand item dropdown and in the random hand items dialog.
|
virtual |
All the entries in randomList, if found in hand item map, are flagged as checked.
|
virtual |
Same idea as setAppearancesFromCharacter().
Both character type and an appearance are needed to determine the set of heads available.
|
virtual |
All the entries in randomList, if found in head map, are flagged as checked.
|
virtual |
Same idea as setAppearancesFromCharacter()
|
virtual |
Makes the use of random appearances allowed (or not).
Does not change the list of appearances available for randomization.
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
Changes current character type. Updates selection in dropdown and contents of dependent dropdowns.
|
virtual |
|
virtual |
Changes current character appearance.
Updates selection in dropdown and contents of dependent dropdowns. Will default to "random" if appearance can't be found. If appearance is "random", will try to select a specific appearance from those allowed in random appearances map. If forceUpdate not set, function will do nothing if named appearance already chosen
|
virtual |
Returns name of current appearance.
|
virtual |
Returns an allowable (checked) random appearance.
|
virtual |
Changes current hand item.
Updates selection in dropdown. Will default to "default" if item can't be found. If forceUpdate not set, function will do nothing if named item already chosen
|
virtual |
Returns name of current hand item.
|
virtual |
Returns an allowable (checked) random hand item.
|
virtual |
Changes current head.
Updates selection in dropdown. Will default to "default" if head can't be found. If forceUpdate not set, function will do nothing if named head already chosen
|
virtual |
Returns name of current head. Might be "random".
|
virtual |
Returns an allowable (checked) random head.
|
virtual |
|
virtual |
|
virtual |
|
virtual |
Specifies if user has changed the list of appearances to be used in random appearances mode.
|
virtual |
|
virtual |
Returns a list of appearances checked as usable for randomization.
If getAll is true, then return all available appearances.
|
virtual |
Specifies if user has changed the list of hand items to be used in random hand items mode.
|
virtual |
|
virtual |
|
virtual |
Specifies if user has changed the list of heads to be used in random heads mode.
|
virtual |
|
virtual |
Prevent/allow any of the Qt combo boxes from/to send(ing) signals.
|
virtual |
|
protectedvirtual |
Helpers.
Finds the index in the list that contains the string name.
|
protectedvirtual |
Returns whatever value is selected, if not "random".
Otherwise, pick some allowable (checked) value from the map and use that.
|
protectedvirtual |
Given a map with some checked and unchecked values in it, return a checked one at random.
If no values are checked, then choose among the unchecked.
|
protectedvirtual |
|
protectedvirtual |
If the old map contains checked items and these items are present in the current map, make sure they are checked there, too.
|
signal |
|
signal |
when character type changes
|
signal |
when appearance changes
|
signal |
when hand item changes
|
signal |
when head changes
|
signal |
|
signal |
when there is a change to this list, including which items are checked
|
signal |
|
signal |
|
signal |
when the list of appearances is repopulated
|
signal |
|
signal |
|
signal |
|
virtualslot |
Causes a label to display currently selected entity type.
|
virtualslot |
|
virtualslot |
Called whenever the user changes the character type typeIndex is index of a character type.
|
virtualslot |
Called whenever the user changes the selected appearance.
|
virtualslot |
Called whenever the user modifies the list of available appearances for randomization.
|
virtualslot |
Same idea as appearance stuff.
|
virtualslot |
|
virtualslot |
Same idea as appearance stuff, but with addition of appearance index.
|
virtualslot |
|
virtualslot |
|
virtualslot |
|
virtualslot |
|
virtualslot |
Creates the dialog box for selecting which appearances will be candidates for random selection.
|
virtualslot |
Called when the above is closed.
|
virtualslot |
|
virtualslot |
|
virtualslot |
Creates the dialog box for type map filtering (see comments there)
|
virtualslot |
Called when a combo box in the type map filtering widget is populated.
Index is of the box, value is of current selection
|
virtualslot |
Called when user selects an item in one of the type map filtering combo boxes.
|
virtualslot |
if any aspects of character are random, regenerate new visuals
|
virtualslot |
Returns the first useable item in some appearance map (body, head, hand item, whatever)
|
virtualslot |
|
private |
assignment operator - not implemented
| Ui::DIGuyConfigurationWidgetUi DtDiGuyConfigurationWidget::myUiImpl |
The code generated from the underlying .ui file.
|
staticprotected |
|
protected |
These will always have specific values or be empty (""). They won't be "random".
|
protected |
|
protected |
|
protected |
|
protected |
These can be "random". They indicate the last selections made in the dropdowns.
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
The keys are appearances. The value indicates whether the appearance is checked or not.
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
Used to match DI-Guy names to user-friendly names.
|
protected |
|
protected |
|
protected |
Replaces the "Default Animation" Qt combo box (found in .ui file)
|
protected |
Replaces the "Character Type" Qt combo box (found in .ui file)
|
protected |
|
staticprotected |
Note that these variables and their values should conform to the way things are done in DtDIGuyAppearanceFilterWidget.
|
protected |
Maps a combo box to a specific type map field.
|
protected |
Choice in each combo.
|
protected |
Holds pointer to dialog while it exists, otherwise NULL.
|
protected |
|
protected |