/[svn]/gigedit/trunk/src/gigedit/dimregionchooser.h
ViewVC logotype

Diff of /gigedit/trunk/src/gigedit/dimregionchooser.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1339 by schoenebeck, Mon Sep 10 19:56:26 2007 UTC revision 2169 by persson, Sun Mar 6 07:51:04 2011 UTC
# Line 1  Line 1 
1  /*                                                         -*- c++ -*-  /*                                                         -*- c++ -*-
2   * Copyright (C) 2006, 2007 Andreas Persson   * Copyright (C) 2006-2011 Andreas Persson
3   *   *
4   * This program is free software; you can redistribute it and/or   * This program is free software; you can redistribute it and/or
5   * modify it under the terms of the GNU General Public License as   * modify it under the terms of the GNU General Public License as
# Line 21  Line 21 
21  #define GIGEDIT_DIMREGIONCHOOSER_H  #define GIGEDIT_DIMREGIONCHOOSER_H
22    
23  #include <gtkmm/drawingarea.h>  #include <gtkmm/drawingarea.h>
 #include <gdkmm/colormap.h>  
24  #include <gdkmm/window.h>  #include <gdkmm/window.h>
25    
26    #include "compat.h"
27    
28  #include <gig.h>  #include <gig.h>
29    
30    #include <set>
31    
32  class DimRegionChooser : public Gtk::DrawingArea  class DimRegionChooser : public Gtk::DrawingArea
33  {  {
34  public:  public:
# Line 37  public: Line 40  public:
40      sigc::signal<void>& signal_dimregion_selected();      sigc::signal<void>& signal_dimregion_selected();
41      sigc::signal<void>& signal_region_changed();      sigc::signal<void>& signal_region_changed();
42    
43      gig::DimensionRegion* get_dimregion() { return dimreg; }      gig::DimensionRegion* get_dimregion() const { return dimreg; }
44        void get_dimregions(const gig::Region* region, bool stereo,
45                            std::set<gig::DimensionRegion*>& dimregs) const;
46    
47  protected:  protected:
48      virtual void on_realize();  #if (GTKMM_MAJOR_VERSION == 2 && GTKMM_MINOR_VERSION < 90) || GTKMM_MAJOR_VERSION < 2
49      virtual bool on_expose_event(GdkEventExpose* e);      virtual bool on_expose_event(GdkEventExpose* e);
50      virtual void on_size_request(GtkRequisition* requisition);  #endif
51        virtual bool on_draw(const Cairo::RefPtr<Cairo::Context>& cr);
52      virtual bool on_button_press_event(GdkEventButton* event);      virtual bool on_button_press_event(GdkEventButton* event);
53      virtual bool on_button_release_event(GdkEventButton* event);      virtual bool on_button_release_event(GdkEventButton* event);
54      virtual bool on_motion_notify_event(GdkEventMotion* event);      virtual bool on_motion_notify_event(GdkEventMotion* event);
55      virtual bool on_focus(Gtk::DirectionType direction);      virtual bool on_focus(Gtk::DirectionType direction);
56    
57      Glib::RefPtr<Gdk::GC> gc;      Gdk::RGBA red, black, white;
     Gdk::Color blue, red, black, white, green;  
58    
59      gig::Instrument* instrument;      gig::Instrument* instrument;
60      gig::Region* region;      gig::Region* region;
# Line 83  protected: Line 88  protected:
88      bool is_in_resize_zone(double x, double y);      bool is_in_resize_zone(double x, double y);
89    
90      int h;      int h;
     int w;  
91  };  };
92    
93  #endif  #endif

Legend:
Removed from v.1339  
changed lines
  Added in v.2169

  ViewVC Help
Powered by ViewVC