Inkscape
Vector Graphics Editor
Loading...
Searching...
No Matches
Inkscape::UI::Dialog::ExportPreview Class Referencefinal

#include <export-preview.h>

Inheritance diagram for Inkscape::UI::Dialog::ExportPreview:

Public Member Functions

 ExportPreview ()=default
 
 ExportPreview (BaseObjectType *cobj, Glib::RefPtr< Gtk::Builder > const &)
 
 ~ExportPreview () override
 
void setDrawing (std::shared_ptr< PreviewDrawing > drawing)
 
void setItem (SPItem const *item, bool is_layer=false)
 
void setBox (Geom::Rect const &bbox)
 
void queueRefresh ()
 
void resetPixels (bool new_size=false)
 
void setSize (int newSize)
 
void setPreview (Cairo::RefPtr< Cairo::ImageSurface >)
 Callback when the rendering is complete.
 
void setBackgroundColor (std::uint32_t bg_color)
 

Static Public Member Functions

static std::shared_ptr< Inkscape::DrawingmakeDrawing (SPDocument *doc)
 

Private Attributes

int size = 128
 
sigc::connection refresh_conn
 
bool _is_layer = false
 
SPItem const * _item = nullptr
 
Geom::OptRect _dbox
 
std::shared_ptr< PreviewDrawing_drawing
 
std::uint32_t _bg_color = 0
 
sigc::scoped_connection _render_idle
 

Detailed Description

Definition at line 54 of file export-preview.h.

Constructor & Destructor Documentation

◆ ExportPreview() [1/2]

Inkscape::UI::Dialog::ExportPreview::ExportPreview ( )
default

◆ ExportPreview() [2/2]

Inkscape::UI::Dialog::ExportPreview::ExportPreview ( BaseObjectType *  cobj,
Glib::RefPtr< Gtk::Builder > const &   
)
inline

Definition at line 58 of file export-preview.h.

◆ ~ExportPreview()

Inkscape::UI::Dialog::ExportPreview::~ExportPreview ( )
override

Definition at line 136 of file export-preview.cpp.

References refresh_conn.

Member Function Documentation

◆ makeDrawing()

static std::shared_ptr< Inkscape::Drawing > Inkscape::UI::Dialog::ExportPreview::makeDrawing ( SPDocument doc)
static

◆ queueRefresh()

void Inkscape::UI::Dialog::ExportPreview::queueRefresh ( )

◆ resetPixels()

void Inkscape::UI::Dialog::ExportPreview::resetPixels ( bool  new_size = false)

◆ setBackgroundColor()

void Inkscape::UI::Dialog::ExportPreview::setBackgroundColor ( std::uint32_t  bg_color)

◆ setBox()

void Inkscape::UI::Dialog::ExportPreview::setBox ( Geom::Rect const &  bbox)

◆ setDrawing()

void Inkscape::UI::Dialog::ExportPreview::setDrawing ( std::shared_ptr< PreviewDrawing drawing)

◆ setItem()

void Inkscape::UI::Dialog::ExportPreview::setItem ( SPItem const *  item,
bool  is_layer = false 
)

◆ setPreview()

void Inkscape::UI::Dialog::ExportPreview::setPreview ( Cairo::RefPtr< Cairo::ImageSurface >  surface)

Callback when the rendering is complete.

Definition at line 181 of file export-preview.cpp.

References surface.

Referenced by Inkscape::UI::Dialog::PreviewDrawing::render().

◆ setSize()

void Inkscape::UI::Dialog::ExportPreview::setSize ( int  newSize)

Definition at line 130 of file export-preview.cpp.

References resetPixels(), and size.

Referenced by Inkscape::UI::Dialog::BatchItem::init().

Member Data Documentation

◆ _bg_color

std::uint32_t Inkscape::UI::Dialog::ExportPreview::_bg_color = 0
private

Definition at line 82 of file export-preview.h.

Referenced by queueRefresh(), and setBackgroundColor().

◆ _dbox

Geom::OptRect Inkscape::UI::Dialog::ExportPreview::_dbox
private

Definition at line 79 of file export-preview.h.

Referenced by queueRefresh(), setBox(), and setItem().

◆ _drawing

std::shared_ptr<PreviewDrawing> Inkscape::UI::Dialog::ExportPreview::_drawing
private

Definition at line 81 of file export-preview.h.

Referenced by queueRefresh(), and setDrawing().

◆ _is_layer

bool Inkscape::UI::Dialog::ExportPreview::_is_layer = false
private

Definition at line 77 of file export-preview.h.

Referenced by queueRefresh(), and setItem().

◆ _item

SPItem const* Inkscape::UI::Dialog::ExportPreview::_item = nullptr
private

Definition at line 78 of file export-preview.h.

Referenced by queueRefresh(), setBox(), and setItem().

◆ _render_idle

sigc::scoped_connection Inkscape::UI::Dialog::ExportPreview::_render_idle
private

Definition at line 84 of file export-preview.h.

Referenced by queueRefresh().

◆ refresh_conn

sigc::connection Inkscape::UI::Dialog::ExportPreview::refresh_conn
private

Definition at line 75 of file export-preview.h.

Referenced by ~ExportPreview().

◆ size

int Inkscape::UI::Dialog::ExportPreview::size = 128
private

Definition at line 74 of file export-preview.h.

Referenced by queueRefresh(), resetPixels(), and setSize().


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