Suit new standard Gdk cursors for the Mirror, Rotate, Scale, Smooth move and Text...
authorCarlos Lopez <genetita@gmail.com>
Wed, 13 Jan 2010 18:30:20 +0000 (19:30 +0100)
committerCarlos Lopez <genetita@gmail.com>
Wed, 13 Jan 2010 18:30:20 +0000 (19:30 +0100)
synfig-studio/src/gtkmm/mod_mirror/state_mirror.cpp
synfig-studio/src/gtkmm/state_rotate.cpp
synfig-studio/src/gtkmm/state_scale.cpp
synfig-studio/src/gtkmm/state_smoothmove.cpp
synfig-studio/src/gtkmm/state_text.cpp

index a2594ad..4ed6a07 100644 (file)
@@ -124,6 +124,7 @@ public:
        void update_axes()
        {
                duck_dragger_->axis=get_axis();
+               get_canvas_view()->work_area->set_cursor(get_axis() == AXIS_X?Gdk::SB_H_DOUBLE_ARROW:Gdk::SB_V_DOUBLE_ARROW);
        }
 
        Smach::event_result event_stop_handler(const Smach::event& x);
@@ -201,8 +202,8 @@ StateMirror_Context::StateMirror_Context(CanvasView* canvas_view):
        keypress_connect=get_work_area()->signal_key_press_event().connect(sigc::mem_fun(*this,&StateMirror_Context::key_event),false);
        keyrelease_connect=get_work_area()->signal_key_release_event().connect(sigc::mem_fun(*this,&StateMirror_Context::key_event),false);
 
-//     get_canvas_view()->work_area->set_cursor(Gdk::CROSSHAIR);
-       get_canvas_view()->work_area->reset_cursor();
+       get_canvas_view()->work_area->set_cursor(Gdk::SB_H_DOUBLE_ARROW);
+//     get_canvas_view()->work_area->reset_cursor();
 
        App::toolbox->refresh();
 
@@ -214,7 +215,10 @@ bool
 StateMirror_Context::key_event(GdkEventKey *event)
 {
        if (event->keyval==GDK_Shift_L || event->keyval==GDK_Shift_R )
+       {
                set_axis(get_axis()==AXIS_X ? AXIS_Y:AXIS_X);
+               get_canvas_view()->work_area->set_cursor(get_axis() == AXIS_X?Gdk::SB_H_DOUBLE_ARROW:Gdk::SB_V_DOUBLE_ARROW);
+       }
 
        return false; //Pass on the event to other handlers, just in case
 }
index 64d2e35..7ffa4f2 100644 (file)
@@ -195,8 +195,8 @@ StateRotate_Context::StateRotate_Context(CanvasView* canvas_view):
        get_work_area()->set_allow_layer_clicks(true);
        get_work_area()->set_duck_dragger(duck_dragger_);
 
-//     get_canvas_view()->work_area->set_cursor(Gdk::CROSSHAIR);
-       get_canvas_view()->work_area->reset_cursor();
+       get_canvas_view()->work_area->set_cursor(Gdk::EXCHANGE);
+//     get_canvas_view()->work_area->reset_cursor();
 
        App::toolbox->refresh();
 
index bd2305b..5f8a2f5 100644 (file)
@@ -181,8 +181,8 @@ StateScale_Context::StateScale_Context(CanvasView* canvas_view):
        get_work_area()->set_allow_layer_clicks(true);
        get_work_area()->set_duck_dragger(duck_dragger_);
 
-//     get_canvas_view()->work_area->set_cursor(Gdk::CROSSHAIR);
-       get_canvas_view()->work_area->reset_cursor();
+       get_canvas_view()->work_area->set_cursor(Gdk::SIZING);
+//     get_canvas_view()->work_area->reset_cursor();
 
        App::toolbox->refresh();
 
index 57862d8..d8221e9 100644 (file)
@@ -197,8 +197,8 @@ StateSmoothMove_Context::StateSmoothMove_Context(CanvasView* canvas_view):
 
        App::toolbox->refresh();
 
-//     get_canvas_view()->work_area->set_cursor(Gdk::CROSSHAIR);
-       get_canvas_view()->work_area->reset_cursor();
+       get_canvas_view()->work_area->set_cursor(Gdk::FLEUR);
+       //get_canvas_view()->work_area->reset_cursor();
 
        load_settings();
 }
index c1912ab..0ee03ac 100644 (file)
@@ -317,7 +317,7 @@ StateText_Context::StateText_Context(CanvasView *canvas_view):
 
        // Connect a signal
        //get_work_area()->signal_user_click().connect(sigc::mem_fun(*this,&studio::StateText_Context::on_user_click));
-       get_canvas_view()->work_area->set_cursor(Gdk::CROSSHAIR);
+       get_canvas_view()->work_area->set_cursor(Gdk::XTERM);
 
        App::toolbox->refresh();
 }