[shotwell] Remove histogram frame
- From: Jens Georg <jensgeorg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [shotwell] Remove histogram frame
- Date: Mon, 10 Apr 2017 18:40:08 +0000 (UTC)
commit 9bd9ed556fc948592f60302d22a669ad60bb4905
Author: Jens Georg <mail jensge org>
Date: Mon Apr 10 20:36:39 2017 +0200
Remove histogram frame
Signed-off-by: Jens Georg <mail jensge org>
src/editing_tools/RGBHistogramManipulator.vala | 33 ------------------------
1 files changed, 0 insertions(+), 33 deletions(-)
---
diff --git a/src/editing_tools/RGBHistogramManipulator.vala b/src/editing_tools/RGBHistogramManipulator.vala
index bda774b..2379533 100644
--- a/src/editing_tools/RGBHistogramManipulator.vala
+++ b/src/editing_tools/RGBHistogramManipulator.vala
@@ -20,8 +20,6 @@ public class RGBHistogramManipulator : Gtk.DrawingArea {
private int left_nub_max = 255 - NUB_SIZE - 1;
private int right_nub_min = NUB_SIZE + 1;
- private static Gtk.Widget dummy_slider = null;
- private static Gtk.Widget dummy_frame = null;
private static Gtk.WidgetPath slider_draw_path = new Gtk.WidgetPath();
private static Gtk.WidgetPath frame_draw_path = new Gtk.WidgetPath();
private static bool paths_setup = false;
@@ -37,12 +35,6 @@ public class RGBHistogramManipulator : Gtk.DrawingArea {
public RGBHistogramManipulator( ) {
set_size_request(CONTROL_WIDTH, CONTROL_HEIGHT);
- if (dummy_slider == null)
- dummy_slider = new Gtk.Scale(Gtk.Orientation.HORIZONTAL, null);
-
- if (dummy_frame == null)
- dummy_frame = new Gtk.Frame(null);
-
if (!paths_setup) {
slider_draw_path.append_type(typeof(Gtk.Scale));
slider_draw_path.iter_add_class(0, "scale");
@@ -159,7 +151,6 @@ public class RGBHistogramManipulator : Gtk.DrawingArea {
area.width = RGBHistogram.GRAPHIC_WIDTH + padding.right;
area.height = RGBHistogram.GRAPHIC_HEIGHT + padding.bottom;
- draw_histogram_frame(ctx, area);
draw_histogram(ctx, area);
draw_nub(ctx, area, left_nub_position);
draw_nub(ctx, area, right_nub_position);
@@ -167,30 +158,6 @@ public class RGBHistogramManipulator : Gtk.DrawingArea {
return true;
}
- private void draw_histogram_frame(Cairo.Context ctx, Gdk.Rectangle area) {
- // the framed area is inset and slightly smaller than the overall histogram
- // control area
- Gdk.Rectangle framed_area = area;
- framed_area.x += 5;
- framed_area.y += 1;
- framed_area.width -= 8;
- framed_area.height -= 12;
-
- Gtk.StyleContext stylectx = dummy_frame.get_style_context();
- stylectx.save();
-
- stylectx.get_path().append_type(typeof(Gtk.Frame));
- stylectx.get_path().iter_add_class(0, "default");
- stylectx.add_class(Gtk.STYLE_CLASS_TROUGH);
- stylectx.set_junction_sides(Gtk.JunctionSides.TOP | Gtk.JunctionSides.BOTTOM |
- Gtk.JunctionSides.LEFT | Gtk.JunctionSides.RIGHT);
-
- stylectx.render_frame(ctx, framed_area.x, framed_area.y, framed_area.width,
- framed_area.height);
-
- stylectx.restore();
- }
-
private void draw_histogram(Cairo.Context ctx, Gdk.Rectangle area) {
if (histogram == null)
return;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]