From ff3377161b85ebcb8fd84183b5798ff3c0d8b111 Mon Sep 17 00:00:00 2001 From: Eberhard Graether Date: Mon, 14 Dec 2015 10:11:48 +0100 Subject: [PATCH] ui: Improved spacing of children within function and method nodes --- src/lib/component/view/GraphViewStyle.cpp | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/src/lib/component/view/GraphViewStyle.cpp b/src/lib/component/view/GraphViewStyle.cpp index 51edc65e..448a52d3 100644 --- a/src/lib/component/view/GraphViewStyle.cpp +++ b/src/lib/component/view/GraphViewStyle.cpp @@ -221,8 +221,18 @@ GraphViewStyle::NodeMargins GraphViewStyle::getMarginsForNodeType(Node::NodeType case Node::NODE_GLOBAL_VARIABLE: case Node::NODE_FIELD: case Node::NODE_ENUM_CONSTANT: + if (hasChildren) + { + margins.top = 8; + margins.bottom = 5; + margins.spacingY = 4; + } + else + { + margins.top = margins.bottom = 3; + } + margins.left = margins.right = 5; - margins.top = margins.bottom = 3; break; }