Inkscape
Vector Graphics Editor
|
#include <eraser-toolbar.h>
Public Member Functions | |
EraserToolbar () | |
~EraserToolbar () override | |
![]() | |
~Toolbar () override | |
virtual void | setDesktop (SPDesktop *desktop) |
SPDesktop * | getDesktop () const |
virtual void | setActiveUnit (Util::Unit const *unit) |
void | onDefocus () override |
![]() | |
~ToolbarWidget () override | |
![]() | |
Bin (Gtk::Widget *child=nullptr) | |
Bin (BaseObjectType *cobject, Glib::RefPtr< Gtk::Builder > const &) | |
Gtk::Widget * | get_child () |
Gets the child widget, or nullptr if none. | |
Gtk::Widget const * | get_child () const |
Gets the child widget, or nullptr if none. | |
void | set_child (Gtk::Widget *child) |
Sets (parents) the child widget, or unsets (unparents) it if child is null. | |
void | set_child (Gtk::Widget &child) |
Convenience function: Sets (parents) the child widget. | |
void | unset_child () |
Convenience function: Unsets (unparents) the child widget. | |
template<typename F > | |
sigc::connection | connectBeforeResize (F &&slot) |
Register a handler to run immediately before a resize operation. | |
template<typename F > | |
sigc::connection | connectAfterResize (F &&slot) |
Register a handler to run immediately after a resize operation. | |
Private Types | |
using | ValueChangedMemFun = void(EraserToolbar::*)() |
Private Member Functions | |
EraserToolbar (Glib::RefPtr< Gtk::Builder > const &builder) | |
void | setup_derived_spin_button (UI::Widget::SpinButton &btn, Glib::ustring const &name, double default_value, ValueChangedMemFun value_changed_mem_fun) |
void | mode_changed (int mode) |
void | set_eraser_mode_visibility (unsigned eraser_mode) |
void | width_value_changed () |
void | mass_value_changed () |
void | velthin_value_changed () |
void | cap_rounding_value_changed () |
void | tremor_value_changed () |
void | toggle_break_apart () |
void | usepressure_toggled () |
Static Private Member Functions | |
static unsigned | _modeAsInt (Tools::EraserToolMode mode) |
Computes the integer value representing eraser mode. | |
static void | update_presets_list (gpointer data) |
Private Attributes | |
UI::Widget::SpinButton & | _width_item |
UI::Widget::SpinButton & | _thinning_item |
UI::Widget::SpinButton & | _cap_rounding_item |
UI::Widget::SpinButton & | _tremor_item |
UI::Widget::SpinButton & | _mass_item |
Gtk::ToggleButton * | _usepressure_btn = nullptr |
Gtk::ToggleButton & | _split_btn |
std::unique_ptr< SimplePrefPusher > | _pressure_pusher |
Additional Inherited Members | |
![]() | |
ToolbarWidget (Gtk::Box &toolbar) | |
![]() | |
ToolbarWidget (Gtk::Box &toolbar) | |
void | measure_vfunc (Gtk::Orientation orientation, int for_size, int &min, int &nat, int &min_baseline, int &nat_baseline) const override |
void | on_size_allocate (int width, int height, int baseline) override |
void | _initMenuBtns () |
![]() | |
void | measure_vfunc (Gtk::Orientation orientation, int for_size, int &min, int &nat, int &min_baseline, int &nat_baseline) const override |
![]() | |
~DefocusTarget ()=default | |
![]() | |
SPDesktop * | _desktop = nullptr |
![]() | |
Gtk::Box & | _toolbar |
Definition at line 55 of file eraser-toolbar.h.
|
private |
Definition at line 64 of file eraser-toolbar.h.
Inkscape::UI::Toolbar::EraserToolbar::EraserToolbar | ( | ) |
Definition at line 47 of file eraser-toolbar.cpp.
References Inkscape::UI::create_builder().
|
overridedefault |
|
private |
Definition at line 51 of file eraser-toolbar.cpp.
References _cap_rounding_item, Inkscape::UI::_continue, Inkscape::UI::Toolbar::ToolbarWidget::_initMenuBtns(), _mass_item, _modeAsInt(), _pressure_pusher, _split_btn, _thinning_item, _tremor_item, _usepressure_btn, _width_item, builder, cap_rounding_value_changed(), Inkscape::UI::Tools::DEFAULT_ERASER_MODE, Inkscape::UI::for_each_child(), Inkscape::Preferences::get(), Inkscape::UI::get_widget(), item, mass_value_changed(), mode_changed(), Inkscape::UI::Widget::SpinButton::set_custom_numeric_menu_data(), set_eraser_mode_visibility(), setup_derived_spin_button(), toggle_break_apart(), tremor_value_changed(), usepressure_toggled(), velthin_value_changed(), and width_value_changed().
|
staticprivate |
Computes the integer value representing eraser mode.
mode | A mode of the eraser tool, from the enum EraserToolMode |
Definition at line 168 of file eraser-toolbar.cpp.
References _modeAsInt(), and mode.
Referenced by _modeAsInt(), EraserToolbar(), and set_eraser_mode_visibility().
|
private |
Definition at line 239 of file eraser-toolbar.cpp.
References _cap_rounding_item, Inkscape::Preferences::get(), and Inkscape::Preferences::setDouble().
Referenced by EraserToolbar().
|
private |
Definition at line 229 of file eraser-toolbar.cpp.
References _mass_item, Inkscape::Preferences::get(), and Inkscape::Preferences::setDouble().
Referenced by EraserToolbar().
|
private |
Definition at line 183 of file eraser-toolbar.cpp.
References Inkscape::UI::Toolbar::Toolbar::_desktop, Inkscape::Preferences::get(), SPDesktop::getDocument(), Inkscape::DocumentUndo::getUndoSensitive(), mode, set_eraser_mode_visibility(), and Inkscape::Preferences::setInt().
Referenced by EraserToolbar().
|
private |
Definition at line 203 of file eraser-toolbar.cpp.
References _modeAsInt(), _split_btn, Inkscape::UI::Toolbar::ToolbarWidget::_toolbar, child, and Inkscape::UI::get_children().
Referenced by EraserToolbar(), and mode_changed().
|
private |
Definition at line 150 of file eraser-toolbar.cpp.
References Inkscape::Preferences::get(), Inkscape::Preferences::getDouble(), name, and Inkscape::UI::Widget::SpinButton::setDefocusTarget().
Referenced by EraserToolbar().
|
private |
Definition at line 249 of file eraser-toolbar.cpp.
References _split_btn, Inkscape::Preferences::get(), and Inkscape::Preferences::setBool().
Referenced by EraserToolbar().
|
private |
Definition at line 244 of file eraser-toolbar.cpp.
References _tremor_item, Inkscape::Preferences::get(), and Inkscape::Preferences::setDouble().
Referenced by EraserToolbar().
|
staticprivate |
|
private |
Definition at line 254 of file eraser-toolbar.cpp.
References _usepressure_btn, Inkscape::Preferences::get(), and Inkscape::Preferences::setBool().
Referenced by EraserToolbar().
|
private |
Definition at line 234 of file eraser-toolbar.cpp.
References _thinning_item, Inkscape::Preferences::get(), and Inkscape::Preferences::setDouble().
Referenced by EraserToolbar().
|
private |
Definition at line 224 of file eraser-toolbar.cpp.
References _width_item, Inkscape::Preferences::get(), and Inkscape::Preferences::setDouble().
Referenced by EraserToolbar().
|
private |
Definition at line 68 of file eraser-toolbar.h.
Referenced by cap_rounding_value_changed(), and EraserToolbar().
|
private |
Definition at line 70 of file eraser-toolbar.h.
Referenced by EraserToolbar(), and mass_value_changed().
|
private |
Definition at line 74 of file eraser-toolbar.h.
Referenced by EraserToolbar().
|
private |
Definition at line 72 of file eraser-toolbar.h.
Referenced by EraserToolbar(), set_eraser_mode_visibility(), and toggle_break_apart().
|
private |
Definition at line 67 of file eraser-toolbar.h.
Referenced by EraserToolbar(), and velthin_value_changed().
|
private |
Definition at line 69 of file eraser-toolbar.h.
Referenced by EraserToolbar(), and tremor_value_changed().
|
private |
Definition at line 71 of file eraser-toolbar.h.
Referenced by EraserToolbar(), and usepressure_toggled().
|
private |
Definition at line 66 of file eraser-toolbar.h.
Referenced by EraserToolbar(), and width_value_changed().