Inkscape
Vector Graphics Editor
Loading...
Searching...
No Matches
Inkscape::Extension::Internal::PdfBuilder::ItemContext Class Reference

#include <build-drawing.h>

Inheritance diagram for Inkscape::Extension::Internal::PdfBuilder::ItemContext:
Inkscape::Extension::Internal::PdfBuilder::GroupContext Inkscape::Extension::Internal::PdfBuilder::DrawContext

Public Member Functions

 ItemContext (Document &doc, SPItem const *item)
 
bool is_valid () const
 
ItemCacheKey cache_key () const
 
void paint ()
 
- Public Member Functions inherited from Inkscape::Extension::Internal::PdfBuilder::GroupContext
 GroupContext (Document &doc, Geom::OptRect const &clip, bool soft_mask=false)
 
- Public Member Functions inherited from Inkscape::Extension::Internal::PdfBuilder::DrawContext
 DrawContext (Document &doc, capypdf::DrawContext ctx, bool soft_mask)
 
 ~DrawContext ()=default
 
void paint_item (SPItem const *item, Geom::Affine const &tr=Geom::identity(), SPStyle const *context_style=nullptr)
 Paint the given object into the given context, making groups if needed.
 
void paint_item_group (SPGroup const *group, SPStyle const *context_style)
 
void paint_item_clone (SPUse const *use, SPStyle const *context_style)
 Paint the given clone object, finding or generating a transparency group from it.
 
void paint_group (CapyPDF_TransparencyGroupId child_id, SPStyle const *style=nullptr, Geom::Affine const &tr=Geom::identity(), std::optional< CapyPDF_TransparencyGroupId > soft_mask={})
 Paint a child group at the requested location.
 
void paint_shape (SPShape const *shape, SPStyle const *context_style)
 Paint a single shape path.
 
void paint_raster (SPImage const *image)
 Draw the raster data stored in URI into the PDF context.
 
void paint_item_to_raster (SPItem const *item, Geom::Affine const &tr, double resolution, bool antialias)
 Draw an item as a bitmap and return.
 
void paint_text_layout (Text::Layout const &layout, SPStyle const *context_style)
 Paint the given layout into the PDF document Drawing content.
 
void clip_text_layout (Text::Layout const &layout)
 Use the text object as a clipping mask in the PDF.
 
void start_ocg (CapyPDF_OptionalContentGroupId ocgid)
 
void end_ocg ()
 
bool set_shape (SPShape const *shape)
 
bool set_shape_pathvector (Geom::PathVector const &pathv)
 
void set_clip_path (std::optional< Geom::PathVector > clip, SPStyle *style=nullptr)
 Apply the clip path to the existing context.
 
void set_clip_rectangle (Geom::OptRect const &rect)
 Apply the clipping rectangle with a NONZERO fill rule.
 
void set_paint_style (StyleMap const &map, SPStyle const *style, SPStyle const *context_style)
 Set the style for drawing shapes from the SVG style, this is all the styles that relate to how vector paths are drawn with stroke, fill and other shape properties.
 
Documentget_document ()
 
std::optional< double > get_softmask (double opacity) const
 

Private Attributes

SPItem const * _item
 

Additional Inherited Members

- Protected Member Functions inherited from Inkscape::Extension::Internal::PdfBuilder::DrawContext
void set_matrix (Geom::Affine const &affine)
 Set the transformation matrix for this context Group.
 
void transform (Geom::Affine const &affine)
 Add a transform to the current context stream.
 
- Protected Attributes inherited from Inkscape::Extension::Internal::PdfBuilder::DrawContext
capypdf::DrawContext _ctx
 
Document_doc
 

Detailed Description

Definition at line 91 of file build-drawing.h.

Constructor & Destructor Documentation

◆ ItemContext()

Inkscape::Extension::Internal::PdfBuilder::ItemContext::ItemContext ( Document doc,
SPItem const *  item 
)

Definition at line 325 of file build-drawing.cpp.

Member Function Documentation

◆ cache_key()

ItemCacheKey Inkscape::Extension::Internal::PdfBuilder::ItemContext::cache_key ( ) const

◆ is_valid()

bool Inkscape::Extension::Internal::PdfBuilder::ItemContext::is_valid ( ) const

◆ paint()

void Inkscape::Extension::Internal::PdfBuilder::ItemContext::paint ( )

Member Data Documentation

◆ _item

SPItem const* Inkscape::Extension::Internal::PdfBuilder::ItemContext::_item
private

Definition at line 101 of file build-drawing.h.

Referenced by cache_key(), is_valid(), and paint().


The documentation for this class was generated from the following files: