Inkscape
Vector Graphics Editor
|
#include <remember-styles.h>
Public Member Functions | |
StyleMemory (std::set< SPAttr > remember_attrs) | |
Construct a new style memeory and ask for specific attrs. | |
StyleMap | get_changes (SPStyle const *style) const |
Return a StyleMap of all the differences between the state and the given style. | |
StyleMap | get_changes_and_remember (SPStyle const *style) |
Modify the changes scope without managing the FILO stack. | |
StyleMap | get_ifset (SPStyle const *style) const |
Return a StyleMap of all the set styles, filtered in the same way as get_changes. | |
StyleMap const & | get_state () const |
Get the current state map, empty if nothing is on the stack or contains every attr at the current state. | |
auto | remember (StyleMap map) |
Add the given map to the stack and return a scoped object. | |
Private Member Functions | |
void | _push (StyleMap changes) |
Private Attributes | |
std::set< SPAttr > const | _attrs |
std::stack< StyleMap > | _changes |
Definition at line 30 of file remember-styles.h.
|
inlineexplicit |
Construct a new style memeory and ask for specific attrs.
remember_attrs | - A set of SPAttr enums to keep track of. |
Definition at line 38 of file remember-styles.h.
References _changes.
|
inlineprivate |
Definition at line 100 of file remember-styles.h.
References _changes, current, and get_state().
Referenced by get_changes_and_remember(), and remember().
Return a StyleMap of all the differences between the state and the given style.
style | - The SPStyle to compare to. |
Definition at line 17 of file remember-styles.cpp.
References _attrs, current, get_state(), map, and SPStyle::properties().
Referenced by get_changes_and_remember().
|
inline |
Modify the changes scope without managing the FILO stack.
Definition at line 56 of file remember-styles.h.
References _push(), and get_changes().
Referenced by Inkscape::Extension::Internal::PdfBuilder::DrawContext::paint_text_layout().
Return a StyleMap of all the set styles, filtered in the same way as get_changes.
Definition at line 38 of file remember-styles.cpp.
References map, and SPStyle::properties().
Referenced by Inkscape::Extension::Internal::PdfBuilder::Document::get_tiling_pattern(), Inkscape::Extension::Internal::PdfBuilder::DrawContext::paint_item(), and Inkscape::Extension::Internal::PdfBuilder::Document::style_to_transparency_mask().
|
inline |
Get the current state map, empty if nothing is on the stack or contains every attr at the current state.
Not just the last delta
Definition at line 74 of file remember-styles.h.
References _changes.
Referenced by _push(), and get_changes().
|
inline |
Add the given map to the stack and return a scoped object.
The stack Will be automatically returned when the scope object is deleted.
map | - The StyleMap delta to add to the stack generated by get_changes() |
Definition at line 87 of file remember-styles.h.
References _changes, _push(), and map.
Referenced by Inkscape::Extension::Internal::PdfBuilder::Document::get_tiling_pattern(), and Inkscape::Extension::Internal::PdfBuilder::DrawContext::paint_item().
|
private |
Definition at line 95 of file remember-styles.h.
Referenced by get_changes().
|
private |
Definition at line 98 of file remember-styles.h.
Referenced by _push(), get_state(), remember(), and StyleMemory().