Functions | |
void | Set_Conditions (const char *list) |
void | QSet_Conditions (const char *segment, const char *list) |
void | UnSet_Conditions (void) |
void | UnSet_One_Condition (const char *condition) |
void | QUnSet_Conditions (const char *segment) |
void | QUnSet_One_Condition (const char *segment, const char *condition) |
void Set_Conditions | ( | const char * | list | ) |
Allows the user to set conditions on a segment that will be used to determine whether or not a Conditional Style or Conditional Include should be applied.
list | - A quoted string or a string variable containing a list of the desired conditions along with optional logical expressions. |
HC_Set_Conditions("front_left"); HC_Conditional_Style("/include library/styles/highlight","front_left");
where "front left" is the condition and "/include library/styles/highlight" is the segment containing the highlight colors. When the condition is set and unset, the styling is activated and deactivated, respectively.
This example is simplistic but demonstrates that users can toggle the properties of their scene based on some predefined setup that has a name, rather than having to loop through geometry and keep track of large numbers of view attributes. This saves time and bookkeeping in large models.
Conditions can be aggregated and controlled with the logical expressions AND, OR and NOT or &&, || and !. In other words, a segment such as "/include library/styles/highlight" can be associated with numerous conditions, and the containing segment can activate an Include segment or a Style segment under many different conditions.
void QSet_Conditions | ( | const char * | segment, | |
const char * | list | |||
) |
Similar to Set_Conditions() but operates on a given segment rather than the currently open one.
segment | - Name of the segment to be changed. | |
list | - A quoted string or a string variable containing a list of the desired conditions. |
void UnSet_Conditions | ( | void | ) |
Removes all the conditions established by a previous call to Set_Conditions().
void UnSet_One_Condition | ( | const char * | condition | ) |
Removes a given condition established by a previous call to Set_Conditions().
condition | - A quoted string or a string variable containing the desired condition to be changed. |
void QUnSet_Conditions | ( | const char * | segment | ) |
Similar to UnSet_Conditions() but operates on a given segment rather than the currently open one.
segment | - Name of the segment to be changed. |
void QUnSet_One_Condition | ( | const char * | segment, | |
const char * | condition | |||
) |
Removes a given condition established by a previous call to Set_Conditions(), but operates on a given segment rather than the currently open one.
segment | - Name of the segment to be changed. | |
condition | - A quoted string or a string variable containing the desired condition to be changed. |