From baa066405c5a9e6a34ce5df962bcce7e7e8d319a Mon Sep 17 00:00:00 2001 From: Mikko Rasa Date: Sun, 16 Jun 2013 23:21:55 +0300 Subject: [PATCH] Avoid autosizing widgets with no style --- source/widget.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/source/widget.cpp b/source/widget.cpp index 1113c97..3d3b006 100644 --- a/source/widget.cpp +++ b/source/widget.cpp @@ -40,6 +40,9 @@ void Widget::set_size(unsigned w, unsigned h) void Widget::autosize() { + if(!style) + return; + geom.w = 0; geom.h = 0; const Style::PartSeq &parts = style->get_parts(); -- 2.43.0