From 46753c6a2794199f9ef9488c286000cb13ac1601 Mon Sep 17 00:00:00 2001 From: Thanatomanic Date: Wed, 20 Jun 2018 07:05:19 +0200 Subject: [PATCH] Tried to go back to default 2:1 ratio, but the Gtk::Paned keeps setting a different default height... --- rtgui/histogrampanel.cc | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/rtgui/histogrampanel.cc b/rtgui/histogrampanel.cc index 599573e19..ac8835617 100644 --- a/rtgui/histogrampanel.cc +++ b/rtgui/histogrampanel.cc @@ -723,7 +723,7 @@ HistogramArea::~HistogramArea () Gtk::SizeRequestMode HistogramArea::get_request_mode_vfunc () const { - return Gtk::SIZE_REQUEST_CONSTANT_SIZE; + return Gtk::SIZE_REQUEST_HEIGHT_FOR_WIDTH; } void HistogramArea::get_preferred_height_vfunc (int &minimum_height, int &natural_height) const @@ -741,8 +741,9 @@ void HistogramArea::get_preferred_width_vfunc (int &minimum_width, int &natural_ } void HistogramArea::get_preferred_height_for_width_vfunc (int width, int &minimum_height, int &natural_height) const -{ - int gHeight = width * 0.618; +{ + int gHeight = width / 2; + if (gHeight < 100) { gHeight = 100; }