summaryrefslogtreecommitdiffstats
path: root/src/ui
diff options
context:
space:
mode:
Diffstat (limited to 'src/ui')
-rw-r--r--src/ui/dialog/swatches.cpp4
-rw-r--r--src/ui/dialog/swatches.h3
-rw-r--r--src/ui/previewfillable.h3
-rw-r--r--src/ui/previewholder.cpp24
-rw-r--r--src/ui/previewholder.h5
-rw-r--r--src/ui/tool/control-point.cpp14
-rw-r--r--src/ui/tool/control-point.h11
-rw-r--r--src/ui/tool/curve-drag-point.cpp2
-rw-r--r--src/ui/tool/node.cpp4
-rw-r--r--src/ui/tool/selectable-control-point.cpp4
-rw-r--r--src/ui/tool/selectable-control-point.h4
-rw-r--r--src/ui/tool/selector.cpp2
-rw-r--r--src/ui/tool/transform-handle-set.cpp26
-rw-r--r--src/ui/tool/transform-handle-set.h3
-rw-r--r--src/ui/widget/panel.cpp8
-rw-r--r--src/ui/widget/panel.h6
16 files changed, 63 insertions, 60 deletions
diff --git a/src/ui/dialog/swatches.cpp b/src/ui/dialog/swatches.cpp
index a1768363c..092887541 100644
--- a/src/ui/dialog/swatches.cpp
+++ b/src/ui/dialog/swatches.cpp
@@ -666,14 +666,14 @@ SwatchesPanel::~SwatchesPanel()
}
}
-void SwatchesPanel::setOrientation( Gtk::AnchorType how )
+void SwatchesPanel::setOrientation(SPAnchorType how)
{
// Must call the parent class or bad things might happen
Inkscape::UI::Widget::Panel::setOrientation( how );
if ( _holder )
{
- _holder->setOrientation( Gtk::ANCHOR_SOUTH );
+ _holder->setOrientation(SP_ANCHOR_SOUTH);
}
}
diff --git a/src/ui/dialog/swatches.h b/src/ui/dialog/swatches.h
index 0ff795ac3..ca4c1687d 100644
--- a/src/ui/dialog/swatches.h
+++ b/src/ui/dialog/swatches.h
@@ -11,6 +11,7 @@
#define SEEN_DIALOGS_SWATCHES_H
#include "ui/widget/panel.h"
+#include "enums.h"
namespace Inkscape {
namespace UI {
@@ -34,7 +35,7 @@ public:
static SwatchesPanel& getInstance();
- virtual void setOrientation( Gtk::AnchorType how );
+ virtual void setOrientation(SPAnchorType how);
virtual void setDesktop( SPDesktop* desktop );
virtual SPDesktop* getDesktop() {return _currentDesktop;}
diff --git a/src/ui/previewfillable.h b/src/ui/previewfillable.h
index 07fbc4fc5..d5f609a0b 100644
--- a/src/ui/previewfillable.h
+++ b/src/ui/previewfillable.h
@@ -15,6 +15,7 @@
#include "previewable.h"
#include "../widgets/eek-preview.h"
+#include "enums.h"
namespace Inkscape {
namespace UI {
@@ -28,7 +29,7 @@ public:
virtual void freezeUpdates() = 0;
virtual void thawUpdates() = 0;
virtual void setStyle( ::PreviewSize size, ViewType type, guint ratio) = 0;
- virtual void setOrientation( Gtk::AnchorType how ) = 0;
+ virtual void setOrientation(SPAnchorType how) = 0;
virtual ::PreviewSize getPreviewSize() const = 0;
virtual ViewType getPreviewType() const = 0;
virtual guint getPreviewRatio() const = 0;
diff --git a/src/ui/previewholder.cpp b/src/ui/previewholder.cpp
index 9e69778b7..d8f1a21a9 100644
--- a/src/ui/previewholder.cpp
+++ b/src/ui/previewholder.cpp
@@ -34,7 +34,7 @@ PreviewHolder::PreviewHolder() :
_insides(0),
_prefCols(0),
_updatesFrozen(false),
- _anchor(Gtk::ANCHOR_CENTER),
+ _anchor(SP_ANCHOR_CENTER),
_baseSize(PREVIEW_SIZE_SMALL),
_ratio(100),
_view(VIEW_TYPE_LIST),
@@ -63,7 +63,7 @@ void PreviewHolder::clear()
items.clear();
_prefCols = 0;
// Kludge to restore scrollbars
- if ( !_wrap && (_view != VIEW_TYPE_LIST) && (_anchor == Gtk::ANCHOR_NORTH || _anchor == Gtk::ANCHOR_SOUTH) ) {
+ if ( !_wrap && (_view != VIEW_TYPE_LIST) && (_anchor == SP_ANCHOR_NORTH || _anchor == SP_ANCHOR_SOUTH) ) {
dynamic_cast<Gtk::ScrolledWindow*>(_scroller)->set_policy( Gtk::POLICY_AUTOMATIC, Gtk::POLICY_NEVER );
}
rebuildUI();
@@ -136,29 +136,29 @@ void PreviewHolder::setStyle( ::PreviewSize size, ViewType view, guint ratio )
_view = view;
_ratio = ratio;
// Kludge to restore scrollbars
- if ( !_wrap && (_view != VIEW_TYPE_LIST) && (_anchor == Gtk::ANCHOR_NORTH || _anchor == Gtk::ANCHOR_SOUTH) ) {
+ if ( !_wrap && (_view != VIEW_TYPE_LIST) && (_anchor == SP_ANCHOR_NORTH || _anchor == SP_ANCHOR_SOUTH) ) {
dynamic_cast<Gtk::ScrolledWindow*>(_scroller)->set_policy( Gtk::POLICY_AUTOMATIC, Gtk::POLICY_NEVER );
}
rebuildUI();
}
}
-void PreviewHolder::setOrientation( Gtk::AnchorType how )
+void PreviewHolder::setOrientation(SPAnchorType how)
{
if ( _anchor != how )
{
_anchor = how;
switch ( _anchor )
{
- case Gtk::ANCHOR_NORTH:
- case Gtk::ANCHOR_SOUTH:
+ case SP_ANCHOR_NORTH:
+ case SP_ANCHOR_SOUTH:
{
dynamic_cast<Gtk::ScrolledWindow*>(_scroller)->set_policy( Gtk::POLICY_AUTOMATIC, _wrap ? Gtk::POLICY_AUTOMATIC : Gtk::POLICY_NEVER );
}
break;
- case Gtk::ANCHOR_EAST:
- case Gtk::ANCHOR_WEST:
+ case SP_ANCHOR_EAST:
+ case SP_ANCHOR_WEST:
{
dynamic_cast<Gtk::ScrolledWindow*>(_scroller)->set_policy( Gtk::POLICY_NEVER, Gtk::POLICY_AUTOMATIC );
}
@@ -179,8 +179,8 @@ void PreviewHolder::setWrap( bool b )
_wrap = b;
switch ( _anchor )
{
- case Gtk::ANCHOR_NORTH:
- case Gtk::ANCHOR_SOUTH:
+ case SP_ANCHOR_NORTH:
+ case SP_ANCHOR_SOUTH:
{
dynamic_cast<Gtk::ScrolledWindow*>(_scroller)->set_policy( Gtk::POLICY_AUTOMATIC, _wrap ? Gtk::POLICY_AUTOMATIC : Gtk::POLICY_NEVER );
}
@@ -206,7 +206,7 @@ void PreviewHolder::on_size_allocate( Gtk::Allocation& allocation )
// g_message(" anchor:%d", _anchor);
Gtk::VBox::on_size_allocate( allocation );
- if ( _insides && !_wrap && (_view != VIEW_TYPE_LIST) && (_anchor == Gtk::ANCHOR_NORTH || _anchor == Gtk::ANCHOR_SOUTH) ) {
+ if ( _insides && !_wrap && (_view != VIEW_TYPE_LIST) && (_anchor == SP_ANCHOR_NORTH || _anchor == SP_ANCHOR_SOUTH) ) {
Gtk::Requisition req = _insides->size_request();
gint delta = allocation.get_width() - req.width;
@@ -232,7 +232,7 @@ void PreviewHolder::calcGridSize( const Gtk::Widget* thing, int itemCount, int&
width = itemCount;
height = 1;
- if ( _anchor == Gtk::ANCHOR_SOUTH || _anchor == Gtk::ANCHOR_NORTH ) {
+ if ( _anchor == SP_ANCHOR_SOUTH || _anchor == SP_ANCHOR_NORTH ) {
Gtk::Requisition req = _scroller->size_request();
int currW = _scroller->get_width();
if ( currW > req.width ) {
diff --git a/src/ui/previewholder.h b/src/ui/previewholder.h
index c396cef19..5a0dfc267 100644
--- a/src/ui/previewholder.h
+++ b/src/ui/previewholder.h
@@ -18,6 +18,7 @@
#include <gtkmm/table.h>
#include "previewfillable.h"
#include "../widgets/eek-preview.h"
+#include "enums.h"
namespace Inkscape {
namespace UI {
@@ -33,7 +34,7 @@ public:
virtual void freezeUpdates();
virtual void thawUpdates();
virtual void setStyle( ::PreviewSize size, ViewType view, guint ratio );
- virtual void setOrientation( Gtk::AnchorType how );
+ virtual void setOrientation(SPAnchorType how);
virtual int getColumnPref() const { return _prefCols; }
virtual void setColumnPref( int cols );
virtual ::PreviewSize getPreviewSize() const { return _baseSize; }
@@ -56,7 +57,7 @@ private:
Gtk::Table *_insides;
int _prefCols;
bool _updatesFrozen;
- Gtk::AnchorType _anchor;
+ SPAnchorType _anchor;
::PreviewSize _baseSize;
guint _ratio;
ViewType _view;
diff --git a/src/ui/tool/control-point.cpp b/src/ui/tool/control-point.cpp
index 8525e92f4..a5509655f 100644
--- a/src/ui/tool/control-point.cpp
+++ b/src/ui/tool/control-point.cpp
@@ -132,7 +132,7 @@ ControlPoint::ColorSet invisible_cset = {
* @param group The canvas group the point's canvas item should be created in
*/
ControlPoint::ControlPoint(SPDesktop *d, Geom::Point const &initial_pos,
- Gtk::AnchorType anchor, SPCtrlShapeType shape,
+ SPAnchorType anchor, SPCtrlShapeType shape,
unsigned int size, ColorSet *cset, SPCanvasGroup *group)
: _desktop (d)
, _canvas_item (NULL)
@@ -142,7 +142,7 @@ ControlPoint::ControlPoint(SPDesktop *d, Geom::Point const &initial_pos,
{
_canvas_item = sp_canvas_item_new(
group ? group : sp_desktop_controls (_desktop), SP_TYPE_CTRL,
- "anchor", (GtkAnchorType) anchor, "size", (gdouble) size, "shape", shape,
+ "anchor", (SPAnchorType) anchor, "size", (gdouble) size, "shape", shape,
"filled", TRUE, "fill_color", _cset->normal.fill,
"stroked", TRUE, "stroke_color", _cset->normal.stroke,
"mode", SP_CTRL_MODE_XOR, NULL);
@@ -160,7 +160,7 @@ ControlPoint::ControlPoint(SPDesktop *d, Geom::Point const &initial_pos,
* @param group The canvas group the point's canvas item should be created in
*/
ControlPoint::ControlPoint(SPDesktop *d, Geom::Point const &initial_pos,
- Gtk::AnchorType anchor, Glib::RefPtr<Gdk::Pixbuf> pixbuf,
+ SPAnchorType anchor, Glib::RefPtr<Gdk::Pixbuf> pixbuf,
ColorSet *cset, SPCanvasGroup *group)
: _desktop (d)
, _canvas_item (NULL)
@@ -169,7 +169,7 @@ ControlPoint::ControlPoint(SPDesktop *d, Geom::Point const &initial_pos,
{
_canvas_item = sp_canvas_item_new(
group ? group : sp_desktop_controls(_desktop), SP_TYPE_CTRL,
- "anchor", (GtkAnchorType) anchor, "size", (gdouble) pixbuf->get_width(),
+ "anchor", (SPAnchorType) anchor, "size", (gdouble) pixbuf->get_width(),
"shape", SP_CTRL_SHAPE_BITMAP, "pixbuf", pixbuf->gobj(),
"filled", TRUE, "fill_color", _cset->normal.fill,
"stroked", TRUE, "stroke_color", _cset->normal.stroke,
@@ -262,9 +262,9 @@ SPCtrlShapeType ControlPoint::_shape() const
return ret;
}
-GtkAnchorType ControlPoint::_anchor() const
+SPAnchorType ControlPoint::_anchor() const
{
- GtkAnchorType ret;
+ SPAnchorType ret;
g_object_get(_canvas_item, "anchor", &ret, NULL);
return ret;
}
@@ -288,7 +288,7 @@ void ControlPoint::_setShape(SPCtrlShapeType shape)
g_object_set(_canvas_item, "shape", shape, NULL);
}
-void ControlPoint::_setAnchor(GtkAnchorType anchor)
+void ControlPoint::_setAnchor(SPAnchorType anchor)
{
g_object_set(_canvas_item, "anchor", anchor, NULL);
}
diff --git a/src/ui/tool/control-point.h b/src/ui/tool/control-point.h
index f37ff1451..8d1b778a7 100644
--- a/src/ui/tool/control-point.h
+++ b/src/ui/tool/control-point.h
@@ -19,8 +19,7 @@
#include <2geom/point.h>
#include "util/accumulators.h"
#include "display/sodipodi-ctrl.h"
-
-#include <gtkmm/enums.h>
+#include "enums.h"
class SPDesktop;
class SPEventContext;
@@ -97,9 +96,9 @@ public:
virtual bool _eventHandler(SPEventContext *event_context, GdkEvent *event);
protected:
- ControlPoint(SPDesktop *d, Geom::Point const &initial_pos, Gtk::AnchorType anchor,
+ ControlPoint(SPDesktop *d, Geom::Point const &initial_pos, SPAnchorType anchor,
SPCtrlShapeType shape, unsigned int size, ColorSet *cset = 0, SPCanvasGroup *group = 0);
- ControlPoint(SPDesktop *d, Geom::Point const &initial_pos, Gtk::AnchorType anchor,
+ ControlPoint(SPDesktop *d, Geom::Point const &initial_pos, SPAnchorType anchor,
Glib::RefPtr<Gdk::Pixbuf> pixbuf, ColorSet *cset = 0, SPCanvasGroup *group = 0);
/// @name Handle control point events in subclasses
@@ -142,12 +141,12 @@ protected:
unsigned int _size() const;
SPCtrlShapeType _shape() const;
- GtkAnchorType _anchor() const;
+ SPAnchorType _anchor() const;
Glib::RefPtr<Gdk::Pixbuf> _pixbuf();
void _setSize(unsigned int size);
void _setShape(SPCtrlShapeType shape);
- void _setAnchor(GtkAnchorType anchor);
+ void _setAnchor(SPAnchorType anchor);
void _setPixbuf(Glib::RefPtr<Gdk::Pixbuf>);
/// @}
diff --git a/src/ui/tool/curve-drag-point.cpp b/src/ui/tool/curve-drag-point.cpp
index e932c022d..8754681df 100644
--- a/src/ui/tool/curve-drag-point.cpp
+++ b/src/ui/tool/curve-drag-point.cpp
@@ -38,7 +38,7 @@ bool CurveDragPoint::_segment_was_degenerate = false;
CurveDragPoint::CurveDragPoint(PathManipulator &pm)
: ControlPoint(pm._multi_path_manipulator._path_data.node_data.desktop, Geom::Point(),
- Gtk::ANCHOR_CENTER, SP_CTRL_SHAPE_CIRCLE, 1.0, &invisible_cset,
+ SP_ANCHOR_CENTER, SP_CTRL_SHAPE_CIRCLE, 1.0, &invisible_cset,
pm._multi_path_manipulator._path_data.dragpoint_group)
, _pm(pm)
{
diff --git a/src/ui/tool/node.cpp b/src/ui/tool/node.cpp
index 8e39ec05a..ff644b4e3 100644
--- a/src/ui/tool/node.cpp
+++ b/src/ui/tool/node.cpp
@@ -81,7 +81,7 @@ double Handle::_saved_length = 0.0;
bool Handle::_drag_out = false;
Handle::Handle(NodeSharedData const &data, Geom::Point const &initial_pos, Node *parent)
- : ControlPoint(data.desktop, initial_pos, Gtk::ANCHOR_CENTER, SP_CTRL_SHAPE_CIRCLE, 7.0,
+ : ControlPoint(data.desktop, initial_pos, SP_ANCHOR_CENTER, SP_CTRL_SHAPE_CIRCLE, 7.0,
&handle_colors, data.handle_group)
, _parent(parent)
, _degenerate(true)
@@ -473,7 +473,7 @@ Glib::ustring Handle::_getDragTip(GdkEventMotion */*event*/)
* The method move() keeps node type invariants during translations.
*/
Node::Node(NodeSharedData const &data, Geom::Point const &initial_pos)
- : SelectableControlPoint(data.desktop, initial_pos, Gtk::ANCHOR_CENTER,
+ : SelectableControlPoint(data.desktop, initial_pos, SP_ANCHOR_CENTER,
SP_CTRL_SHAPE_DIAMOND, 9.0, *data.selection, &node_colors, data.node_group)
, _front(data, initial_pos, this)
, _back(data, initial_pos, this)
diff --git a/src/ui/tool/selectable-control-point.cpp b/src/ui/tool/selectable-control-point.cpp
index c92dcaaae..cec2e7b07 100644
--- a/src/ui/tool/selectable-control-point.cpp
+++ b/src/ui/tool/selectable-control-point.cpp
@@ -27,7 +27,7 @@ static SelectableControlPoint::ColorSet default_scp_color_set = {
};
SelectableControlPoint::SelectableControlPoint(SPDesktop *d, Geom::Point const &initial_pos,
- Gtk::AnchorType anchor, SPCtrlShapeType shape, unsigned int size,
+ SPAnchorType anchor, SPCtrlShapeType shape, unsigned int size,
ControlPointSelection &sel, ColorSet *cset, SPCanvasGroup *group)
: ControlPoint (d, initial_pos, anchor, shape, size,
cset ? reinterpret_cast<ControlPoint::ColorSet*>(cset)
@@ -37,7 +37,7 @@ SelectableControlPoint::SelectableControlPoint(SPDesktop *d, Geom::Point const &
_selection.allPoints().insert(this);
}
SelectableControlPoint::SelectableControlPoint(SPDesktop *d, Geom::Point const &initial_pos,
- Gtk::AnchorType anchor, Glib::RefPtr<Gdk::Pixbuf> pixbuf,
+ SPAnchorType anchor, Glib::RefPtr<Gdk::Pixbuf> pixbuf,
ControlPointSelection &sel, ColorSet *cset, SPCanvasGroup *group)
: ControlPoint (d, initial_pos, anchor, pixbuf,
cset ? reinterpret_cast<ControlPoint::ColorSet*>(cset)
diff --git a/src/ui/tool/selectable-control-point.h b/src/ui/tool/selectable-control-point.h
index 9467aef74..8ecb39a79 100644
--- a/src/ui/tool/selectable-control-point.h
+++ b/src/ui/tool/selectable-control-point.h
@@ -35,11 +35,11 @@ public:
}
protected:
SelectableControlPoint(SPDesktop *d, Geom::Point const &initial_pos,
- Gtk::AnchorType anchor, SPCtrlShapeType shape,
+ SPAnchorType anchor, SPCtrlShapeType shape,
unsigned int size, ControlPointSelection &sel, ColorSet *cset = 0,
SPCanvasGroup *group = 0);
SelectableControlPoint(SPDesktop *d, Geom::Point const &initial_pos,
- Gtk::AnchorType anchor, Glib::RefPtr<Gdk::Pixbuf> pixbuf,
+ SPAnchorType anchor, Glib::RefPtr<Gdk::Pixbuf> pixbuf,
ControlPointSelection &sel, ColorSet *cset = 0, SPCanvasGroup *group = 0);
virtual void _setState(State state);
diff --git a/src/ui/tool/selector.cpp b/src/ui/tool/selector.cpp
index 25d22ecdc..86ad05515 100644
--- a/src/ui/tool/selector.cpp
+++ b/src/ui/tool/selector.cpp
@@ -29,7 +29,7 @@ namespace UI {
class SelectorPoint : public ControlPoint {
public:
SelectorPoint(SPDesktop *d, SPCanvasGroup *group, Selector *s)
- : ControlPoint(d, Geom::Point(0,0), Gtk::ANCHOR_CENTER, SP_CTRL_SHAPE_SQUARE,
+ : ControlPoint(d, Geom::Point(0,0), SP_ANCHOR_CENTER, SP_CTRL_SHAPE_SQUARE,
1, &invisible_cset, group)
, _selector(s)
, _cancel(false)
diff --git a/src/ui/tool/transform-handle-set.cpp b/src/ui/tool/transform-handle-set.cpp
index 2cf6fe55a..b4a27170a 100644
--- a/src/ui/tool/transform-handle-set.cpp
+++ b/src/ui/tool/transform-handle-set.cpp
@@ -38,20 +38,20 @@ namespace Inkscape {
namespace UI {
namespace {
-Gtk::AnchorType corner_to_anchor(unsigned c) {
+SPAnchorType corner_to_anchor(unsigned c) {
switch (c % 4) {
- case 0: return Gtk::ANCHOR_NE;
- case 1: return Gtk::ANCHOR_NW;
- case 2: return Gtk::ANCHOR_SW;
- default: return Gtk::ANCHOR_SE;
+ case 0: return SP_ANCHOR_NE;
+ case 1: return SP_ANCHOR_NW;
+ case 2: return SP_ANCHOR_SW;
+ default: return SP_ANCHOR_SE;
}
}
-Gtk::AnchorType side_to_anchor(unsigned s) {
+SPAnchorType side_to_anchor(unsigned s) {
switch (s % 4) {
- case 0: return Gtk::ANCHOR_N;
- case 1: return Gtk::ANCHOR_W;
- case 2: return Gtk::ANCHOR_S;
- default: return Gtk::ANCHOR_E;
+ case 0: return SP_ANCHOR_N;
+ case 1: return SP_ANCHOR_W;
+ case 2: return SP_ANCHOR_S;
+ default: return SP_ANCHOR_E;
}
}
@@ -82,7 +82,7 @@ ControlPoint::ColorSet center_cset = {
} // anonymous namespace
/** Base class for node transform handles to simplify implementation */
-TransformHandle::TransformHandle(TransformHandleSet &th, Gtk::AnchorType anchor, Glib::RefPtr<Gdk::Pixbuf> pb)
+TransformHandle::TransformHandle(TransformHandleSet &th, SPAnchorType anchor, Glib::RefPtr<Gdk::Pixbuf> pb)
: ControlPoint(th._desktop, Geom::Point(), anchor, pb, &thandle_cset,
th._transform_handle_group)
, _th(th)
@@ -180,7 +180,7 @@ void TransformHandle::ungrabbed(GdkEventButton *)
class ScaleHandle : public TransformHandle {
public:
- ScaleHandle(TransformHandleSet &th, Gtk::AnchorType anchor, Glib::RefPtr<Gdk::Pixbuf> pb)
+ ScaleHandle(TransformHandleSet &th, SPAnchorType anchor, Glib::RefPtr<Gdk::Pixbuf> pb)
: TransformHandle(th, anchor, pb)
{}
protected:
@@ -603,7 +603,7 @@ double SkewHandle::_last_angle = 0;
class RotationCenter : public ControlPoint {
public:
RotationCenter(TransformHandleSet &th)
- : ControlPoint(th._desktop, Geom::Point(), Gtk::ANCHOR_CENTER, _get_pixbuf(),
+ : ControlPoint(th._desktop, Geom::Point(), SP_ANCHOR_CENTER, _get_pixbuf(),
&center_cset, th._transform_handle_group)
, _th(th)
{
diff --git a/src/ui/tool/transform-handle-set.h b/src/ui/tool/transform-handle-set.h
index f5f208e6f..cd1a61da2 100644
--- a/src/ui/tool/transform-handle-set.h
+++ b/src/ui/tool/transform-handle-set.h
@@ -16,6 +16,7 @@
#include <2geom/forward.h>
#include "ui/tool/commit-events.h"
#include "ui/tool/manipulator.h"
+#include "enums.h"
class SPDesktop;
class CtrlRect;
@@ -81,7 +82,7 @@ private:
/** Base class for node transform handles to simplify implementation */
class TransformHandle : public ControlPoint {
public:
- TransformHandle(TransformHandleSet &th, Gtk::AnchorType anchor, Glib::RefPtr<Gdk::Pixbuf> pb);
+ TransformHandle(TransformHandleSet &th, SPAnchorType anchor, Glib::RefPtr<Gdk::Pixbuf> pb);
void getNextClosestPoint(bool reverse);
protected:
diff --git a/src/ui/widget/panel.cpp b/src/ui/widget/panel.cpp
index 0989c7d0d..45c4e5f07 100644
--- a/src/ui/widget/panel.cpp
+++ b/src/ui/widget/panel.cpp
@@ -88,7 +88,7 @@ void Panel::_popper(GdkEventButton* event)
void Panel::_init()
{
Glib::ustring tmp("<");
- _anchor = Gtk::ANCHOR_CENTER;
+ _anchor = SP_ANCHOR_CENTER;
guint panel_size = 0, panel_mode = 0, panel_ratio = 100;
bool panel_wrap = 0;
@@ -269,13 +269,13 @@ void Panel::setLabel(Glib::ustring const &label)
_tab_title.set_label(_label);
}
-void Panel::setOrientation(Gtk::AnchorType how)
+void Panel::setOrientation(SPAnchorType how)
{
if (_anchor != how) {
_anchor = how;
switch (_anchor) {
- case Gtk::ANCHOR_NORTH:
- case Gtk::ANCHOR_SOUTH:
+ case SP_ANCHOR_NORTH:
+ case SP_ANCHOR_SOUTH:
{
if (_menu_desired) {
_menu_popper.reference();
diff --git a/src/ui/widget/panel.h b/src/ui/widget/panel.h
index c1942ef05..7b471c2ce 100644
--- a/src/ui/widget/panel.h
+++ b/src/ui/widget/panel.h
@@ -18,7 +18,7 @@
#include <gtkmm/button.h>
#include <gtkmm/eventbox.h>
#include <gtkmm/label.h>
-
+#include "enums.h"
#include <vector>
class SPDesktop;
@@ -80,7 +80,7 @@ public:
int const &getVerb() const;
Glib::ustring const &getApplyLabel() const;
- virtual void setOrientation(Gtk::AnchorType how);
+ virtual void setOrientation(SPAnchorType how);
virtual void present(); //< request to be present
@@ -126,7 +126,7 @@ protected:
*/
Glib::ustring const _prefs_path;
bool _menu_desired;
- Gtk::AnchorType _anchor;
+ SPAnchorType _anchor;
/* Signals */
sigc::signal<void, int> _signal_response;