Commit 762f80d5 authored by Arjen Hiemstra's avatar Arjen Hiemstra
Browse files

Switch ExtendedLegend to horizontal layout when wide

When the legend's parent is significantly more wide than tall, use
LeftToRight flow instead of TopToBottom, otherwise a lot of empty space
is wasted.
parent 2c454e3d
......@@ -38,7 +38,7 @@ ChartsControls.Legend {
property var sourceModel
property var colorSource
flow: GridLayout.TopToBottom
flow: parent.width > parent.height * 1.5 ? GridLayout.LeftToRight : GridLayout.TopToBottom
Layout.maximumHeight: implicitHeight
Layout.maximumWidth: parent.width
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment