Removed histogramAspect in favor of histogramHeight, which sets the panelheight properly and consistently on restarting.
This commit is contained in:
@@ -2342,7 +2342,7 @@ void EditorPanel::updateHistogramPosition (int oldPosition, int newPosition)
|
|||||||
histogramPanel->unreference();
|
histogramPanel->unreference();
|
||||||
}
|
}
|
||||||
|
|
||||||
leftbox->set_position(options.historyPanelWidth * options.histogramAspect); // Make sure the panel gets the right aspect ratio
|
leftbox->set_position(options.histogramHeight);
|
||||||
histogramPanel->reorder (Gtk::POS_LEFT);
|
histogramPanel->reorder (Gtk::POS_LEFT);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
@@ -2362,7 +2362,7 @@ void EditorPanel::updateHistogramPosition (int oldPosition, int newPosition)
|
|||||||
histogramPanel->unreference();
|
histogramPanel->unreference();
|
||||||
}
|
}
|
||||||
|
|
||||||
vboxright->set_position(options.toolPanelWidth * options.histogramAspect); // Make sure the panel gets the right aspect ratio
|
vboxright->set_position(options.histogramHeight);
|
||||||
histogramPanel->reorder (Gtk::POS_RIGHT);
|
histogramPanel->reorder (Gtk::POS_RIGHT);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@@ -248,9 +248,6 @@ HistogramPanel::~HistogramPanel ()
|
|||||||
void HistogramPanel::resized (Gtk::Allocation& req)
|
void HistogramPanel::resized (Gtk::Allocation& req)
|
||||||
{
|
{
|
||||||
|
|
||||||
// Store current aspect ratio of the histogram
|
|
||||||
options.histogramAspect = histogramArea->get_height() / (float)histogramArea->get_width();
|
|
||||||
|
|
||||||
histogramArea->updateBackBuffer ();
|
histogramArea->updateBackBuffer ();
|
||||||
histogramArea->queue_draw ();
|
histogramArea->queue_draw ();
|
||||||
|
|
||||||
@@ -266,6 +263,10 @@ void HistogramPanel::resized (Gtk::Allocation& req)
|
|||||||
histogramRGBArea->updateBackBuffer(-1, -1, -1);
|
histogramRGBArea->updateBackBuffer(-1, -1, -1);
|
||||||
histogramRGBArea->queue_draw ();
|
histogramRGBArea->queue_draw ();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Store current height of the histogram
|
||||||
|
options.histogramHeight = get_height();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void HistogramPanel::red_toggled ()
|
void HistogramPanel::red_toggled ()
|
||||||
|
@@ -415,7 +415,7 @@ void Options::setDefaults ()
|
|||||||
multiDisplayMode = 0;
|
multiDisplayMode = 0;
|
||||||
histogramPosition = 1;
|
histogramPosition = 1;
|
||||||
histogramBar = true;
|
histogramBar = true;
|
||||||
histogramAspect = 0.618;
|
histogramHeight = 200;
|
||||||
histogramDrawMode = 0;
|
histogramDrawMode = 0;
|
||||||
curvebboxpos = 1;
|
curvebboxpos = 1;
|
||||||
prevdemo = PD_Sidecar;
|
prevdemo = PD_Sidecar;
|
||||||
@@ -1291,8 +1291,8 @@ void Options::readFromFile (Glib::ustring fname)
|
|||||||
histogramBar = keyFile.get_boolean ("GUI", "HistogramBar");
|
histogramBar = keyFile.get_boolean ("GUI", "HistogramBar");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (keyFile.has_key ("GUI", "HistogramAspect")) {
|
if (keyFile.has_key ("GUI", "HistogramHeight")) {
|
||||||
histogramAspect = keyFile.get_double ("GUI", "HistogramAspect");
|
histogramHeight = keyFile.get_integer ("GUI", "HistogramHeight");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (keyFile.has_key ("GUI", "HistogramDrawMode")) {
|
if (keyFile.has_key ("GUI", "HistogramDrawMode")) {
|
||||||
@@ -1943,7 +1943,7 @@ void Options::saveToFile (Glib::ustring fname)
|
|||||||
keyFile.set_double_list ("GUI", "NavGuideBrush", navGuideBrush);
|
keyFile.set_double_list ("GUI", "NavGuideBrush", navGuideBrush);
|
||||||
keyFile.set_integer ("GUI", "HistogramPosition", histogramPosition);
|
keyFile.set_integer ("GUI", "HistogramPosition", histogramPosition);
|
||||||
keyFile.set_boolean ("GUI", "HistogramBar", histogramBar);
|
keyFile.set_boolean ("GUI", "HistogramBar", histogramBar);
|
||||||
keyFile.set_double ("GUI", "HistogramAspect", histogramAspect);
|
keyFile.set_integer ("GUI", "HistogramHeight", histogramHeight);
|
||||||
keyFile.set_integer ("GUI", "HistogramDrawMode", histogramDrawMode);
|
keyFile.set_integer ("GUI", "HistogramDrawMode", histogramDrawMode);
|
||||||
keyFile.set_integer ("GUI", "NavigatorRGBUnit", (int)navRGBUnit);
|
keyFile.set_integer ("GUI", "NavigatorRGBUnit", (int)navRGBUnit);
|
||||||
keyFile.set_integer ("GUI", "NavigatorHSVUnit", (int)navHSVUnit);
|
keyFile.set_integer ("GUI", "NavigatorHSVUnit", (int)navHSVUnit);
|
||||||
|
@@ -256,7 +256,7 @@ public:
|
|||||||
int histogramPosition; // 0=disabled, 1=left pane, 2=right pane
|
int histogramPosition; // 0=disabled, 1=left pane, 2=right pane
|
||||||
//int histogramWorking; // 0=disabled, 1=left pane, 2=right pane
|
//int histogramWorking; // 0=disabled, 1=left pane, 2=right pane
|
||||||
bool histogramBar;
|
bool histogramBar;
|
||||||
float histogramAspect;
|
int histogramHeight;
|
||||||
int histogramDrawMode;
|
int histogramDrawMode;
|
||||||
bool FileBrowserToolbarSingleRow;
|
bool FileBrowserToolbarSingleRow;
|
||||||
bool hideTPVScrollbar;
|
bool hideTPVScrollbar;
|
||||||
|
Reference in New Issue
Block a user