Inkscape
Vector Graphics Editor
|
#include <livepatheffect-editor.h>
Public Types | |
using | LPEExpander = std::pair< Gtk::Expander *, PathEffectSharedPtr > |
Public Member Functions | |
LivePathEffectEditor () | |
Constructor. | |
~LivePathEffectEditor () final | |
void | focus_dialog () override |
void | move_list (int origin, int dest) |
void | showParams (LPEExpander const &expanderdata, bool changed) |
![]() | |
DialogBase (char const *prefs_path=nullptr, Glib::ustring dialog_type={}) | |
DialogBase constructor. | |
DialogBase (DialogBase const &)=delete | |
DialogBase & | operator= (DialogBase const &)=delete |
~DialogBase () override | |
virtual void | update () |
The update() method is essential to Gtk state management. | |
void | setDesktop (SPDesktop *new_desktop) |
Called when the desktop might have changed for this dialog. | |
void | on_map () override |
Glib::ustring const & | get_name () const |
Glib::ustring const & | getPrefsPath () const |
Glib::ustring const & | get_type () const |
const Glib::ustring & | get_icon () const |
void | blink () |
Highlight notebook where dialog already exists. | |
void | defocus_dialog () |
bool | getShowing () |
void | fix_inner_scroll (Gtk::ScrolledWindow &scrollwin) |
SPDesktop * | getDesktop () const |
Private Member Functions | |
void | add_lpes (UI::Widget::CompletionPopup &, bool symbolic, std::vector< LPEMetadata > &&lpes) |
Glib::ustring | get_tooltip (LivePathEffect::EffectType, Glib::ustring const &untranslated_label) |
void | clear_lpe_list () |
void | selectionChanged (Inkscape::Selection *selection) final |
void | selectionModified (Inkscape::Selection *selection, unsigned flags) final |
void | onSelectionChanged (Inkscape::Selection *selection) |
void | expanded_notify (Gtk::Expander *expander) |
void | onAdd (Inkscape::LivePathEffect::EffectType etype) |
bool | showWarning (std::string const &msg) |
void | toggleVisible (Inkscape::LivePathEffect::Effect *lpe, Gtk::Button *visbutton) |
bool | can_apply (LivePathEffect::EffectType, Glib::ustring const &item_type, bool has_clip, bool has_mask) |
void | removeEffect (Gtk::Expander *expander) |
bool | on_drop (Gtk::Widget &widget, Glib::ValueBase const &value, int pos_target) |
void | effect_list_reload (SPLPEItem *lpeitem) |
void | selection_info () |
void | clearMenu () |
void | setMenu () |
bool | lpeFlatten (PathEffectSharedPtr const &lperef) |
SPLPEItem * | clonetolpeitem () |
void | add_item_actions (PathEffectSharedPtr const &lperef, Glib::ustring const &, Gtk::Widget &item, bool is_first, bool is_last) |
void | enable_item_action (Gtk::Widget &item, Glib::ustring const &name, bool enabled) |
void | enable_fav_actions (Gtk::Widget &item, bool has_fav) |
void | do_item_action_undoable (PathEffectSharedPtr const &lperef, void(SPLPEItem::*const method)(), Glib::ustring const &description) |
void | do_item_action_defaults (PathEffectSharedPtr const &lpreref, void(LivePathEffect::Effect::*const method)()) |
void | do_item_action_favorite (PathEffectSharedPtr const &lpreref, Glib::ustring const &untranslated_label, Gtk::Widget &item, bool has_fav) |
Private Attributes | |
std::vector< LPEExpander > | _LPEExpanders |
bool | updating = false |
SPLPEItem * | current_lpeitem = nullptr |
SPUse * | _current_use = nullptr |
LPEExpander | current_lperef = {nullptr, nullptr} |
bool | selection_changed_lock = false |
bool | dnd = false |
Glib::RefPtr< Gtk::Builder > | _builder |
Gtk::ListBox & | LPEListBox |
int | dndx = 0 |
int | dndy = 0 |
Inkscape::UI::Widget::CompletionPopup | _lpes_popup |
Gtk::Box & | _LPEContainer |
Gtk::Box & | _LPEAddContainer |
Gtk::Label & | _LPESelectionInfo |
Gtk::ListBox & | _LPEParentBox |
Gtk::Box & | _LPECurrentItem |
PathEffectList | effectlist |
Glib::RefPtr< Gtk::ListStore > | _LPEList |
Glib::RefPtr< Gtk::ListStore > | _LPEListFilter |
const LivePathEffect::EnumEffectDataConverter< LivePathEffect::EffectType > & | converter |
Gtk::Widget * | effectwidget = nullptr |
Gtk::Widget * | popupwidg = nullptr |
GtkWidget * | currentdrag = nullptr |
bool | _reload_menu = false |
int | _buttons_width = 0 |
bool | _freezeexpander = false |
Glib::ustring | _item_type |
bool | _has_clip = false |
bool | _has_mask = false |
bool | _experimental = false |
Additional Inherited Members | |
![]() | |
InkscapeApplication * | getApp () const |
SPDocument * | getDocument () const |
Selection * | getSelection () const |
void | setShowing (bool showing) |
function called from notebook dialog that performs an update of the dialog and sets the dialog showing state true | |
![]() | |
Glib::ustring | _name |
Glib::ustring const | _prefs_path |
Glib::ustring const | _dialog_type |
Definition at line 51 of file livepatheffect-editor.h.
using Inkscape::UI::Dialog::LivePathEffectEditor::LPEExpander = std::pair<Gtk::Expander *, PathEffectSharedPtr> |
Definition at line 59 of file livepatheffect-editor.h.
Inkscape::UI::Dialog::LivePathEffectEditor::LivePathEffectEditor | ( | ) |
Constructor.
Definition at line 121 of file livepatheffect-editor.cpp.
References _experimental, _LPEAddContainer, _LPEContainer, _lpes_popup, Inkscape::append(), Inkscape::UI::create_builder(), dnd, Inkscape::UI::Widget::CompletionPopup::get_entry(), Inkscape::UI::get_widget(), Inkscape::UI::Widget::CompletionPopup::on_button_press(), Inkscape::UI::Widget::CompletionPopup::on_focus(), Inkscape::UI::Widget::CompletionPopup::on_match_selected(), onAdd(), Inkscape::UI::pack_start(), selection_info(), setMenu(), and Inkscape::UI::Dialog::sp_set_experimental().
|
final |
Definition at line 153 of file livepatheffect-editor.cpp.
References sp_clear_custom_tooltip().
|
private |
Definition at line 1030 of file livepatheffect-editor.cpp.
References Inkscape::UI::Dialog::add_action(), SPLPEItem::downCurrentPathEffect(), SPLPEItem::duplicateCurrentPathEffect(), item, Inkscape::UI::Dialog::item_action_group_name, Inkscape::UI::Dialog::item_action_group_quark, Inkscape::LivePathEffect::Effect::resetDefaultParameters(), Inkscape::LivePathEffect::Effect::setDefaultParameters(), Inkscape::UI::Dialog::sp_has_fav(), and SPLPEItem::upCurrentPathEffect().
|
private |
Definition at line 297 of file livepatheffect-editor.cpp.
References builder, Inkscape::UI::Widget::CompletionPopup::clear_completion_list(), Inkscape::UI::Dialog::get_category_name(), Inkscape::UI::Widget::CompletionPopup::get_menu(), onAdd(), Inkscape::UI::Widget::PopoverMenu::remove_all(), and sp_query_custom_tooltip().
|
private |
Definition at line 159 of file livepatheffect-editor.cpp.
References converter, Inkscape::LivePathEffect::EnumEffectDataConverter< E >::get_on_group(), Inkscape::LivePathEffect::EnumEffectDataConverter< E >::get_on_path(), Inkscape::LivePathEffect::EnumEffectDataConverter< E >::get_on_shape(), Inkscape::LivePathEffect::POWERCLIP, and Inkscape::LivePathEffect::POWERMASK.
|
private |
Definition at line 947 of file livepatheffect-editor.cpp.
References Inkscape::UI::remove_all_children().
|
private |
Definition at line 240 of file livepatheffect-editor.cpp.
References _reload_menu, and sp_clear_custom_tooltip().
Referenced by selectionChanged(), and selectionModified().
|
private |
Definition at line 957 of file livepatheffect-editor.cpp.
References SPItem::doWriteTransform(), Geom::identity(), orig, SPObject::requestDisplayUpdate(), SPObject::setAttribute(), sp_lpe_item_update_patheffect(), Inkscape::Util::to_cstr(), Inkscape::Util::to_opt(), and SPItem::transform.
|
private |
Definition at line 1086 of file livepatheffect-editor.cpp.
References current_lpeitem, and effect_list_reload().
|
private |
Definition at line 1093 of file livepatheffect-editor.cpp.
References _item_type, _reload_menu, enable_fav_actions(), item, Inkscape::UI::Dialog::sp_add_fav(), and Inkscape::UI::Dialog::sp_remove_fav().
|
private |
Definition at line 1076 of file livepatheffect-editor.cpp.
References current_lpeitem, Inkscape::DocumentUndo::done(), effect_list_reload(), Inkscape::UI::Dialog::DialogBase::getDocument(), and SPLPEItem::setCurrentPathEffect().
|
private |
Definition at line 681 of file livepatheffect-editor.cpp.
References builder, counter, Inkscape::UI::create_builder(), current, Inkscape::UI::get_children(), SPLPEItem::getCurrentLPE(), SPLPEItem::getEffectList(), Inkscape::UI::Dialog::set_visible_icon(), sp_query_custom_tooltip(), Inkscape::UI::Dialog::update_before_after_classes(), and visible.
Referenced by do_item_action_defaults(), and do_item_action_undoable().
|
private |
Definition at line 1070 of file livepatheffect-editor.cpp.
References item.
Referenced by do_item_action_favorite().
|
private |
Definition at line 1058 of file livepatheffect-editor.cpp.
References action_name, data, item, and Inkscape::UI::Dialog::item_action_group_quark.
|
private |
Definition at line 859 of file livepatheffect-editor.cpp.
References Inkscape::UI::Tools::sp_update_helperpath(), and w.
|
overridevirtual |
Reimplemented from Inkscape::UI::Dialog::DialogBase.
Definition at line 1105 of file livepatheffect-editor.cpp.
References _lpes_popup, Inkscape::UI::Dialog::DialogBase::focus_dialog(), and Inkscape::UI::Widget::CompletionPopup::get_entry().
|
private |
Definition at line 347 of file livepatheffect-editor.cpp.
|
private |
Definition at line 909 of file livepatheffect-editor.cpp.
References Inkscape::DocumentUndo::done().
void Inkscape::UI::Dialog::LivePathEffectEditor::move_list | ( | int | origin, |
int | dest | ||
) |
Definition at line 572 of file livepatheffect-editor.cpp.
References Inkscape::ObjectSet::isEmpty(), item, origin, and Inkscape::ObjectSet::singleItem().
|
private |
Definition at line 629 of file livepatheffect-editor.cpp.
|
private |
Definition at line 419 of file livepatheffect-editor.cpp.
References Inkscape::LivePathEffect::Effect::createAndApply(), Inkscape::DocumentUndo::done(), SPLPEItem::getCurrentLPE(), key, and Inkscape::LivePathEffect::Effect::refresh_widgets.
Referenced by add_lpes(), and LivePathEffectEditor().
|
private |
Definition at line 542 of file livepatheffect-editor.cpp.
References Inkscape::ObjectSet::isEmpty(), item, and Inkscape::ObjectSet::singleItem().
Referenced by selectionChanged(), and selectionModified().
|
private |
Definition at line 923 of file livepatheffect-editor.cpp.
References Inkscape::DocumentUndo::done(), and w.
|
private |
Definition at line 443 of file livepatheffect-editor.cpp.
References SPObject::document, Inkscape::LivePathEffect::Effect::effectType(), Inkscape::UI::get_children(), Inkscape::UI::get_shape_image(), SPObject::getId(), SPDocument::getObjectById(), SPItem::highlight_color(), SPObject::label(), label, Inkscape::UI::pack_start(), root, SPItem::rootsatellites, Inkscape::Colors::Color::toRGBA(), and SPItem::typeName().
Referenced by LivePathEffectEditor().
|
finalprivatevirtual |
Reimplemented from Inkscape::UI::Dialog::DialogBase.
Definition at line 97 of file livepatheffect-editor.cpp.
References clearMenu(), onSelectionChanged(), Inkscape::UI::Dialog::DialogBase::selection, and selection_changed_lock.
|
finalprivate |
Definition at line 106 of file livepatheffect-editor.cpp.
References _current_use, clearMenu(), current_lpeitem, current_lperef, effectlist, SPLPEItem::getEffectList(), onSelectionChanged(), Inkscape::UI::Dialog::DialogBase::selection, selection_changed_lock, showParams(), and Inkscape::ObjectSet::singleItem().
|
private |
Definition at line 359 of file livepatheffect-editor.cpp.
References data, Inkscape::LivePathEffect::Experimental, Inkscape::LivePathEffect::Favorites, Inkscape::Preferences::get(), Inkscape::Preferences::getBool(), label, Inkscape::UI::Dialog::sp_has_fav(), and Inkscape::UI::Dialog::sp_set_experimental().
Referenced by LivePathEffectEditor().
void Inkscape::UI::Dialog::LivePathEffectEditor::showParams | ( | LPEExpander const & | expanderdata, |
bool | changed | ||
) |
Definition at line 588 of file livepatheffect-editor.cpp.
References Inkscape::UI::Dialog::align(), Inkscape::UI::get_children(), LivePathEffectObject::get_lpe(), label, Inkscape::LivePathEffect::Effect::newWidget(), Inkscape::LivePathEffect::Effect::refresh_widgets, and Inkscape::LivePathEffect::Effect::spinbutton_width_chars.
Referenced by selectionModified().
|
private |
|
private |
Definition at line 255 of file livepatheffect-editor.cpp.
References Inkscape::XML::Node::attribute(), current_lpeitem, Inkscape::DocumentUndo::done(), Inkscape::LivePathEffect::Effect::doOnVisibilityToggled(), Inkscape::UI::Dialog::DialogBase::getDocument(), Inkscape::LivePathEffect::Effect::getRepr(), Inkscape::UI::Dialog::set_visible_icon(), Inkscape::XML::Node::setAttribute(), and visible.
|
private |
Definition at line 70 of file livepatheffect-editor.h.
|
private |
Definition at line 126 of file livepatheffect-editor.h.
|
private |
Definition at line 66 of file livepatheffect-editor.h.
Referenced by selectionModified().
|
private |
Definition at line 131 of file livepatheffect-editor.h.
Referenced by LivePathEffectEditor().
|
private |
Definition at line 127 of file livepatheffect-editor.h.
|
private |
Definition at line 129 of file livepatheffect-editor.h.
|
private |
Definition at line 130 of file livepatheffect-editor.h.
|
private |
Definition at line 128 of file livepatheffect-editor.h.
Referenced by do_item_action_favorite().
|
private |
Definition at line 114 of file livepatheffect-editor.h.
Referenced by LivePathEffectEditor().
|
private |
Definition at line 113 of file livepatheffect-editor.h.
Referenced by LivePathEffectEditor().
|
private |
Definition at line 117 of file livepatheffect-editor.h.
|
private |
Definition at line 63 of file livepatheffect-editor.h.
|
private |
Definition at line 119 of file livepatheffect-editor.h.
|
private |
Definition at line 120 of file livepatheffect-editor.h.
|
private |
Definition at line 116 of file livepatheffect-editor.h.
|
private |
Definition at line 112 of file livepatheffect-editor.h.
Referenced by focus_dialog(), and LivePathEffectEditor().
|
private |
Definition at line 115 of file livepatheffect-editor.h.
|
private |
Definition at line 125 of file livepatheffect-editor.h.
Referenced by clearMenu(), and do_item_action_favorite().
|
private |
Definition at line 121 of file livepatheffect-editor.h.
Referenced by can_apply().
|
private |
Definition at line 65 of file livepatheffect-editor.h.
Referenced by do_item_action_defaults(), do_item_action_undoable(), selectionModified(), and toggleVisible().
|
private |
Definition at line 67 of file livepatheffect-editor.h.
Referenced by selectionModified().
|
private |
Definition at line 124 of file livepatheffect-editor.h.
|
private |
Definition at line 69 of file livepatheffect-editor.h.
Referenced by LivePathEffectEditor().
|
private |
Definition at line 72 of file livepatheffect-editor.h.
|
private |
Definition at line 73 of file livepatheffect-editor.h.
|
private |
Definition at line 118 of file livepatheffect-editor.h.
Referenced by selectionModified().
|
private |
Definition at line 122 of file livepatheffect-editor.h.
|
private |
Definition at line 71 of file livepatheffect-editor.h.
|
private |
Definition at line 123 of file livepatheffect-editor.h.
|
private |
Definition at line 68 of file livepatheffect-editor.h.
Referenced by selectionChanged(), and selectionModified().
|
private |
Definition at line 64 of file livepatheffect-editor.h.