SExpandableArea¶
Property |
Type |
Note |
Aka |
String |
Name for the widget |
AllowAnimatedTransition |
Bool |
|
BodyBorderBackgroundColor |
Number Array, Length = 4 |
Linear color values, for example:[0.5, 0.5, 0.5, 1] |
BodyBorderImage |
Object |
For example:"BodyBorderImage": |
BodyContent |
Object |
The only child widget in this widget's content. |
BorderBackgroundColor |
Number Array, Length = 4 |
Linear color values, for example:[0.5, 0.5, 0.5, 1] |
BorderImage |
Object |
For example:"BorderImage": |
ButtonColorAndOpacity |
Number Array, Length = 4 |
|
ColorAndOpacity |
Number Array, Length = 4 |
Linear color values, for example:[0.5, 0.5, 0.5, 1] |
ForegroundColor |
Number Array, Length = 4 |
Linear color values, for example:[0.5, 0.5, 0.5, 1] |
HeaderContent |
Object |
The only child widget in this widget's content. |
HeaderPadding |
Number or Number Array (Length = 2 or 4) |
|
InitiallyCollapsed |
Bool |
|
MaxHeight |
Number |
|
MinWidth |
Number |
|
OnAreaExpansionChanged |
String |
The python code which will be executed. replacement flag: % |
Padding |
Number or Number Array (Length = 2 or 4) |
|
ToolTipText |
String |
|
Visibility |
Enum: EVisibility: Visible, Collapsed, Hidden, HitTestInvisible, SelfHitTestInvisible, All |
|
functions what can be called from ChameleonData¶
Examples¶
Example 1:
"SExpandableArea": {
"Aka": "expandable_area",
"BorderImage": {
"Style": "FEditorStyle",
"Brush": "DetailsView.CategoryTop"
},
"BodyBorderImage": {
"Style": "FAppStyle",
"Brush": "Brushes.Recessed"
},
"Padding": 4,
"HeaderPadding": [5, 3],
"AllowAnimatedTransition": true,
"InitiallyCollapsed": false,
"OnAreaExpansionChanged": "print('OnAreaExpansionChanged text: {}'.format(%))",
"HeaderContent": {
"STextBlock": {
"Text": "Some Head Text"
}
},
"BodyContent": {
"SHorizontalBox": {
"Slots": [
{
"STextBlock": {
"Text": "Some Body Text"
}
},
{
"AutoWidth": true,
"SButton": {
"Text": "Some Button In Body Content",
"OnClick": "sketch.data.set_is_expanded('expandable_area', False, True)"
}
}
]
}
}
}