2010-01-07 12:14:35 +01:00
|
|
|
import Qt 4.6
|
|
|
|
|
import Bauhaus 1.0
|
|
|
|
|
|
|
|
|
|
QExtGroupBox {
|
2010-02-05 15:42:31 +10:00
|
|
|
id: groupBox;
|
2010-01-07 12:14:35 +01:00
|
|
|
|
|
|
|
|
property var finished;
|
|
|
|
|
|
|
|
|
|
property var caption;
|
|
|
|
|
|
|
|
|
|
property var oldMaximumHeight;
|
|
|
|
|
|
|
|
|
|
onFinishedChanged: {
|
2010-02-05 15:42:31 +10:00
|
|
|
checkBox.raise();
|
2010-01-07 12:14:35 +01:00
|
|
|
oldMaximumHeight = maximumHeight;
|
|
|
|
|
visible = false;
|
|
|
|
|
visible = true;
|
2010-01-27 11:48:46 +01:00
|
|
|
//x = 6;
|
2010-01-07 12:14:35 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
QToolButton {
|
|
|
|
|
//QCheckBox {
|
2010-02-05 15:42:31 +10:00
|
|
|
id: checkBox;
|
2010-02-04 16:03:45 +01:00
|
|
|
|
2010-02-05 15:42:31 +10:00
|
|
|
text: groupBox.caption;
|
2010-01-07 12:14:35 +01:00
|
|
|
focusPolicy: "Qt::NoFocus";
|
2010-02-17 13:48:44 +01:00
|
|
|
styleSheetFile: "specialCheckBox.css";
|
2010-01-27 11:48:46 +01:00
|
|
|
y: 0;
|
|
|
|
|
x: 0;
|
|
|
|
|
fixedHeight: 17
|
2010-02-05 15:42:31 +10:00
|
|
|
fixedWidth: groupBox.width;
|
2010-01-07 12:14:35 +01:00
|
|
|
arrowType: "Qt::DownArrow";
|
|
|
|
|
toolButtonStyle: "Qt::ToolButtonTextBesideIcon";
|
|
|
|
|
checkable: true;
|
|
|
|
|
checked: true;
|
|
|
|
|
font.bold: true;
|
|
|
|
|
onClicked: {
|
|
|
|
|
if (checked) {
|
2010-02-05 15:42:31 +10:00
|
|
|
//groupBox.maximumHeight = oldMaximumHeight;
|
2010-01-07 12:14:35 +01:00
|
|
|
collapsed = false;
|
2010-01-27 11:48:46 +01:00
|
|
|
//text = "";
|
|
|
|
|
//width = 12;
|
|
|
|
|
//width = 120;
|
2010-01-07 12:14:35 +01:00
|
|
|
arrowType = "Qt::DownArrow";
|
2010-01-27 11:48:46 +01:00
|
|
|
visible = true;
|
2010-01-07 12:14:35 +01:00
|
|
|
} else {
|
2010-02-05 15:42:31 +10:00
|
|
|
//groupBox.maximumHeight = 20;
|
2010-01-07 12:14:35 +01:00
|
|
|
|
|
|
|
|
collapsed = true;
|
2010-02-05 15:42:31 +10:00
|
|
|
//text = groupBox.caption;
|
2010-01-07 12:14:35 +01:00
|
|
|
visible = true;
|
2010-01-27 11:48:46 +01:00
|
|
|
//width = 120;
|
2010-01-07 12:14:35 +01:00
|
|
|
arrowType = "Qt::RightArrow";
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|