From b4227e1a026e83f87b28808dfc313c39f851fd97 Mon Sep 17 00:00:00 2001 From: heckflosse Date: Sun, 4 Feb 2018 18:55:21 +0100 Subject: [PATCH] Always show image dimensions below navigator preview, fixes #4359 --- rtgui/navigator.cc | 7 ++++--- rtgui/navigator.h | 1 + 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/rtgui/navigator.cc b/rtgui/navigator.cc index 7f159861d..e34a909df 100644 --- a/rtgui/navigator.cc +++ b/rtgui/navigator.cc @@ -38,6 +38,8 @@ Navigator::Navigator () : currentRGBUnit(options.navRGBUnit), currentHSVUnit(opt mbox->set_name("Navigator"); previewWindow = Gtk::manage (new PreviewWindow ()); mbox->pack_start (*previewWindow, Gtk::PACK_SHRINK, 2); + dimension = Gtk::manage (new Gtk::Label ()); + mbox->pack_start (*dimension, Gtk::PACK_SHRINK, 2); position = Gtk::manage (new Gtk::Label ()); mbox->pack_start (*position, Gtk::PACK_SHRINK, 2); @@ -207,10 +209,9 @@ Navigator::Navigator () : currentRGBUnit(options.navRGBUnit), currentHSVUnit(opt void Navigator::setInvalid (int fullWidth, int fullHeight) { if (fullWidth > 0 && fullHeight > 0) { - position->set_text (Glib::ustring::compose (M("NAVIGATOR_XY_FULL"), fullWidth, fullHeight)); - } else { - position->set_text (M("NAVIGATOR_XY_NA")); + dimension->set_text (Glib::ustring::compose (M("NAVIGATOR_XY_FULL"), fullWidth, fullHeight)); } + position->set_text (M("NAVIGATOR_XY_NA")); R->set_text (M("NAVIGATOR_NA")); G->set_text (M("NAVIGATOR_NA")); diff --git a/rtgui/navigator.h b/rtgui/navigator.h index e6ca33559..6108e2809 100644 --- a/rtgui/navigator.h +++ b/rtgui/navigator.h @@ -37,6 +37,7 @@ private: void cycleUnitsHSV (GdkEventButton *event); protected: + Gtk::Label* dimension; Gtk::Label* position; Gtk::Label *R, *G, *B; Gtk::Label *H, *S, *V;