- get_work_area()->persistant_stroke_list().pop_back();
- get_canvas_view()->get_smach().process_event(EVENT_REFRESH);
+ get_work_area()->persistent_stroke_list().pop_back();
+
+ // if the sketch is currently shown, make sure it is updated
+ //! \todo is there a better way than this of getting Duckmatic to update its stroke_list_?
+ if (checkbutton_show_sketch.get_active())
+ {
+ get_work_area()->set_show_persistent_strokes(false);
+ get_work_area()->set_show_persistent_strokes(true);
+ get_canvas_view()->get_smach().process_event(EVENT_REFRESH);
+ }