diff options
author | deva <deva> | 2008-07-22 06:55:09 +0000 |
---|---|---|
committer | deva <deva> | 2008-07-22 06:55:09 +0000 |
commit | 28d39474e6c0c14bd12716a9e20ad0469cd17cc6 (patch) | |
tree | 0d810f8e4a796ec04a1fc32ace902ee0ecc3afa7 /editor/widget.cc | |
parent | 6d2e3e9af73c085580ab3b001063ddb3e74d2c3c (diff) |
Fixed initial value setting.
Diffstat (limited to 'editor/widget.cc')
-rw-r--r-- | editor/widget.cc | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/editor/widget.cc b/editor/widget.cc index 79957bd..9141939 100644 --- a/editor/widget.cc +++ b/editor/widget.cc @@ -84,6 +84,16 @@ Widget::Widget(QDomNode node) setLayout(new QHBoxLayout()); } setSizePolicy(widget->sizePolicy()); + if(widget->minimumSizeHint().isValid()) setMinimumSize(widget->minimumSizeHint()); + + // Iterate and call setValue on all attributes + QDomNamedNodeMap map = elem.attributes(); + for(size_t i = 0; i < map.length(); i++) { + QDomAttr attr = map.item(i).toAttr(); + QString name = attr.name(); + QString value = attr.value(); + setValue(name, value); + } } void Widget::paintEvent(QPaintEvent *) |