Inkscape
Vector Graphics Editor
|
#include <lpe-taperstroke.h>
Public Member Functions | |
LPETaperStroke (LivePathEffectObject *lpeobject) | |
~LPETaperStroke () override | |
void | doOnApply (SPLPEItem const *lpeitem) override |
Is performed a single time when the effect is freshly applied to a path. | |
void | doOnRemove (SPLPEItem const *lpeitem) override |
void | doBeforeEffect (SPLPEItem const *lpeitem) override |
Is performed each time before the effect is updated. | |
Geom::PathVector | doEffect_path (Geom::PathVector const &path_in) override |
Geom::PathVector | doEffect_simplePath (Geom::Path const &path, size_t index, double start, double end) |
void | transform_multiply (Geom::Affine const &postmul, bool set) override |
Overridden function to apply transforms for example to powerstroke, jointtype or tapperstroke. | |
void | addKnotHolderEntities (KnotHolder *knotholder, SPItem *item) override |
![]() | |
virtual | ~Effect () |
Effect (const Effect &)=delete | |
Effect & | operator= (const Effect &)=delete |
EffectType | effectType () const |
void | doAfterEffect_impl (SPLPEItem const *lpeitem, Geom::PathVector *curve) |
void | doOnApply_impl (SPLPEItem const *lpeitem) |
void | doBeforeEffect_impl (SPLPEItem const *lpeitem) |
void | doOnOpen_impl () |
Is performed on document open allow things like fix legacy LPE in a undo insensitive way. | |
void | doOnRemove_impl (SPLPEItem const *lpeitem) |
void | transform_multiply_impl (Geom::Affine const &postmul, SPLPEItem *) |
void | doOnBeforeCommit () |
void | read_from_SVG () |
void | setCurrentZoom (double cZ) |
void | setSelectedNodePoints (std::vector< Geom::Point > sNP) |
bool | isNodePointSelected (Geom::Point const &nodePoint) const |
bool | isOnClipboard () |
The lpe is on clipboard. | |
std::vector< SPLPEItem * > | getCurrrentLPEItems () const |
void | update_satellites () |
virtual void | doOnException (SPLPEItem const *lpeitem) |
virtual void | doOnVisibilityToggled (SPLPEItem const *lpeitem) |
virtual void | adjustForNewPath () |
void | writeParamsToSVG () |
std::vector< SPObject * > | effect_get_satellites (bool force=true) |
virtual void | acceptParamPath (SPPath const *param_path) |
If the effect expects a path parameter (specified by a number of mouse clicks) before it is applied, this is the method that processes the resulting path. | |
int | acceptsNumClicks () const |
SPShape * | getCurrentShape () const |
void | setCurrentShape (SPShape *shape) |
virtual void | processObjects (LPEAction lpe_action) |
void | makeUndoDone (Glib::ustring message) |
bool | isReady () const |
void | setReady (bool ready=true) |
virtual void | doEffect (Geom::PathVector &curve) |
virtual Gtk::Widget * | newWidget () |
This creates a managed widget. | |
virtual void | resetDefaults (SPItem const *item) |
Sets all parameters to their default values and writes them to SVG. | |
bool | providesKnotholder () const |
virtual LPEPathFlashType | pathFlashType () const |
void | addHandles (KnotHolder *knotholder, SPItem *item) |
Add all registered LPE knotholder handles to the knotholder. | |
std::vector< Geom::PathVector > | getCanvasIndicators (SPLPEItem const *lpeitem) |
Return a vector of PathVectors which contain all canvas indicators for this effect. | |
void | update_helperpath () |
Call to a method on nodetool to update the helper path from the effect. | |
bool | providesOwnFlashPaths () const |
bool | showOrigPath () const |
Glib::ustring | getName () const |
Inkscape::XML::Node * | getRepr () |
SPDocument * | getSPDoc () |
LivePathEffectObject * | getLPEObj () |
LivePathEffectObject const * | getLPEObj () const |
Parameter * | getParameter (const char *key) |
void | readallParameters (Inkscape::XML::Node const *repr) |
void | setParameter (const gchar *key, const gchar *new_value) |
bool | isVisible () const |
void | editNextParamOncanvas (SPItem *item, SPDesktop *desktop) |
void | setLPEAction (LPEAction lpe_action) |
void | setDefaultParameters () |
Set this LPE defaults. | |
void | resetDefaultParameters () |
Reset this LPE defaults. | |
bool | hasDefaultParameters () |
Get LPE has defaults. | |
virtual bool | getHolderRemove () |
Protected Attributes | |
ScalarArrayParam | attach_start |
ScalarArrayParam | attach_end |
ScalarArrayParam | start_smoothing |
ScalarArrayParam | end_smoothing |
![]() | |
bool | _adjust_path = false |
bool | _provides_knotholder_entities |
bool | _provides_path_adjustment = false |
LPEAction | _lpe_action = LPE_NONE |
int | oncanvasedit_it |
bool | show_orig_path |
bool | concatenate_before_pwd2 |
double | current_zoom |
std::vector< Geom::Point > | selectedNodesPoints |
Inkscape::UI::Widget::Registry | wr |
Private Member Functions | |
LPETaperStroke (const LPETaperStroke &)=delete | |
LPETaperStroke & | operator= (const LPETaperStroke &)=delete |
Private Attributes | |
ScalarParam | subpath |
ScalarParam | line_width |
EnumParam< unsigned > | join_type |
EnumArrayParam | start_shape |
EnumArrayParam | end_shape |
ScalarParam | miter_limit |
size_t | previous_size = 1 |
std::vector< Geom::Point > | start_attach_point |
std::vector< Geom::Point > | end_attach_point |
size_t | prev_subpath = Glib::ustring::npos |
Geom::PathVector | pathv_out |
Friends | |
class | TpS::KnotHolderEntityAttachBegin |
class | TpS::KnotHolderEntityAttachEnd |
Definition at line 30 of file lpe-taperstroke.h.
Inkscape::LivePathEffect::LPETaperStroke::LPETaperStroke | ( | LivePathEffectObject * | lpeobject | ) |
Definition at line 104 of file lpe-taperstroke.cpp.
References Inkscape::LivePathEffect::Effect::_provides_knotholder_entities, attach_end, attach_start, Inkscape::XML::Node::attribute(), end_shape, end_smoothing, Inkscape::LivePathEffect::Effect::getRepr(), join_type, line_width, miter_limit, Inkscape::LivePathEffect::ScalarParam::param_set_digits(), Inkscape::LivePathEffect::ScalarArrayParam::param_set_digits(), Inkscape::LivePathEffect::ScalarParam::param_set_increments(), Inkscape::LivePathEffect::ScalarParam::param_set_range(), Inkscape::LivePathEffect::Effect::registerParameter(), Inkscape::XML::Node::setAttribute(), Inkscape::LivePathEffect::Effect::show_orig_path, start_shape, start_smoothing, and subpath.
|
overridedefault |
|
privatedelete |
|
overridevirtual |
Reimplemented from Inkscape::LivePathEffect::Effect.
Definition at line 611 of file lpe-taperstroke.cpp.
References Inkscape::LivePathEffect::ArrayParam< StorageType >::_vector, KnotHolder::add(), attach_start, Inkscape::CANVAS_ITEM_CTRL_TYPE_LPE, KnotHolderEntity::create(), item, TpS::KnotHolderEntityAttachBegin, and TpS::KnotHolderEntityAttachEnd.
|
overridevirtual |
Is performed each time before the effect is updated.
Reimplemented from Inkscape::LivePathEffect::Effect.
Definition at line 337 of file lpe-taperstroke.cpp.
References Inkscape::LivePathEffect::ArrayParam< StorageType >::_vector, Geom::Path::append(), Geom::Path::appendNew(), Geom::are_near(), attach_end, attach_start, Geom::PathVector::clear(), Geom::Path::close(), Geom::Piecewise< T >::concat(), Inkscape::LivePathEffect::ArrayParam< StorageType >::data(), doEffect_simplePath(), Geom::PathVector::empty(), end_attach_point, end_shape, end_smoothing, Geom::Path::finalPoint(), Inkscape::Util::EnumDataConverter< E >::get_id_from_key(), Inkscape::LivePathEffect::EnumParam< E >::get_value(), Inkscape::half_outline(), index, Geom::Path::initialPoint(), Inkscape::LivePathEffect::Effect::is_load, join_type, line_width, miter_limit, Inkscape::LivePathEffect::ScalarParam::param_readSVGValue(), Inkscape::LivePathEffect::ArrayParam< StorageType >::param_set_and_write_new_value(), Inkscape::LivePathEffect::EnumArrayParam::param_set_default(), Inkscape::LivePathEffect::ScalarArrayParam::param_set_default(), Inkscape::LivePathEffect::ScalarParam::param_set_range(), Inkscape::LivePathEffect::EnumArrayParam::param_setActive(), Inkscape::LivePathEffect::ScalarArrayParam::param_setActive(), Geom::path_from_piecewise(), pathv_out, pathv_to_linear_and_cubic_beziers(), Inkscape::LivePathEffect::Effect::pathvector_before_effect, prev_subpath, previous_size, Geom::PathVector::push_back(), Inkscape::LivePathEffect::Effect::refresh_widgets, Inkscape::LivePathEffect::return_at_first_cusp(), Geom::Path::setFinal(), Geom::Path::size(), Geom::PathVector::size(), Inkscape::size, sp_svg_read_pathv(), start_attach_point, start_shape, start_smoothing, Inkscape::LivePathEffect::stretch_along(), subpath, Inkscape::LivePathEffect::TAPER_CLAMP, Inkscape::LivePathEffect::TAPER_LEFT, Inkscape::LivePathEffect::TAPER_RIGHT, Inkscape::LivePathEffect::TaperShapeTypeConverter(), Inkscape::LivePathEffect::ArrayParam< StorageType >::valid_index(), and withinRange().
|
overridevirtual |
Reimplemented from Inkscape::LivePathEffect::Effect.
Definition at line 230 of file lpe-taperstroke.cpp.
References pathv_out.
Geom::PathVector Inkscape::LivePathEffect::LPETaperStroke::doEffect_simplePath | ( | Geom::Path const & | path, |
size_t | index, | ||
double | start, | ||
double | end | ||
) |
The positions of the effect knots are accessed to determine where exactly the input path should be split.
Definition at line 241 of file lpe-taperstroke.cpp.
References end, Geom::Path::portion(), Geom::PathVector::push_back(), Geom::Path::size(), and start.
Referenced by doBeforeEffect().
|
overridevirtual |
Is performed a single time when the effect is freshly applied to a path.
Reimplemented from Inkscape::LivePathEffect::Effect.
Definition at line 166 of file lpe-taperstroke.cpp.
References Inkscape::LivePathEffect::Effect::effectType(), Inkscape::Preferences::get(), Inkscape::Preferences::getEntry(), Inkscape::Preferences::Entry::isValidDouble(), item, line_width, Inkscape::LivePathEffect::lpe_shape_convert_stroke_and_fill(), Inkscape::LivePathEffect::LPETypeConverter, Inkscape::LivePathEffect::ScalarParam::param_set_value(), SPStyle::stroke_width, SPObject::style, width, and Inkscape::LivePathEffect::Parameter::write_to_SVG().
|
overridevirtual |
Reimplemented from Inkscape::LivePathEffect::Effect.
Definition at line 196 of file lpe-taperstroke.cpp.
References line_width, and Inkscape::LivePathEffect::lpe_shape_revert_stroke_and_fill().
|
privatedelete |
|
overridevirtual |
Overridden function to apply transforms for example to powerstroke, jointtype or tapperstroke.
Reimplemented from Inkscape::LivePathEffect::Effect.
Definition at line 157 of file lpe-taperstroke.cpp.
References Inkscape::Preferences::get(), Inkscape::Preferences::getBool(), line_width, Inkscape::LivePathEffect::ScalarParam::param_transform_multiply(), Inkscape::LivePathEffect::Effect::sp_lpe_item, and SPItem::unoptimized().
|
friend |
Definition at line 44 of file lpe-taperstroke.h.
Referenced by addKnotHolderEntities().
|
friend |
Definition at line 45 of file lpe-taperstroke.h.
Referenced by addKnotHolderEntities().
|
protected |
Definition at line 47 of file lpe-taperstroke.h.
Referenced by doBeforeEffect(), and LPETaperStroke().
|
protected |
Definition at line 46 of file lpe-taperstroke.h.
Referenced by addKnotHolderEntities(), doBeforeEffect(), and LPETaperStroke().
|
private |
Definition at line 59 of file lpe-taperstroke.h.
Referenced by doBeforeEffect().
|
private |
Definition at line 55 of file lpe-taperstroke.h.
Referenced by doBeforeEffect(), and LPETaperStroke().
|
protected |
Definition at line 49 of file lpe-taperstroke.h.
Referenced by doBeforeEffect(), and LPETaperStroke().
|
private |
Definition at line 53 of file lpe-taperstroke.h.
Referenced by doBeforeEffect(), and LPETaperStroke().
|
private |
Definition at line 52 of file lpe-taperstroke.h.
Referenced by doBeforeEffect(), doOnApply(), doOnRemove(), LPETaperStroke(), and transform_multiply().
|
private |
Definition at line 56 of file lpe-taperstroke.h.
Referenced by doBeforeEffect(), and LPETaperStroke().
|
private |
Definition at line 61 of file lpe-taperstroke.h.
Referenced by doBeforeEffect(), and doEffect_path().
|
private |
Definition at line 60 of file lpe-taperstroke.h.
Referenced by doBeforeEffect().
|
private |
Definition at line 57 of file lpe-taperstroke.h.
Referenced by doBeforeEffect().
|
private |
Definition at line 58 of file lpe-taperstroke.h.
Referenced by doBeforeEffect().
|
private |
Definition at line 54 of file lpe-taperstroke.h.
Referenced by doBeforeEffect(), and LPETaperStroke().
|
protected |
Definition at line 48 of file lpe-taperstroke.h.
Referenced by doBeforeEffect(), and LPETaperStroke().
|
private |
Definition at line 51 of file lpe-taperstroke.h.
Referenced by doBeforeEffect(), and LPETaperStroke().