Inkscape
Vector Graphics Editor
Inkscape::Extension::Extension Class Reference

The object that is the basis for the Extension system. More...

#include <extension.h>

Inheritance diagram for Inkscape::Extension::Extension:
Inkscape::Extension::Effect Inkscape::Extension::Input Inkscape::Extension::Output Inkscape::Extension::PathEffect Inkscape::Extension::Print

Classes

class  extension_no_id
 no valid ID found while parsing XML representation More...
 
class  extension_no_name
 no valid name found while parsing XML representation More...
 
class  extension_not_compatible
 extension is not compatible with the current system and should not be loaded More...
 
class  no_overwrite
 An error class for when a filename already exists, but the user doesn't want to overwrite it. More...
 
class  param_not_exist
 An error class for when a parameter is looked for that just simply doesn't exist. More...
 

Public Types

enum  state_t { STATE_LOADED, STATE_UNLOADED, STATE_DEACTIVATED }
 An enumeration to identify if the Extension has been loaded or not. More...
 

Public Member Functions

 Extension (Inkscape::XML::Node *in_repr, Implementation::Implementation *in_imp, std::string *base_directory)
 Constructs an Extension from a Inkscape::XML::Node. More...
 
virtual ~Extension ()
 Destroys the Extension. More...
 
void set_state (state_t in_state)
 A function to set whether the extension should be loaded or unloaded. More...
 
state_t get_state ()
 A getter for the state variable. More...
 
bool loaded ()
 A quick function to test the state of the extension. More...
 
virtual bool check ()
 A function to check the validity of the extension. More...
 
Inkscape::XML::Nodeget_repr ()
 A getter for the internal Repr, does not add a reference. More...
 
gchar * get_id () const
 Get the ID of this extension - not a copy don't delete! More...
 
const gchar * get_name () const
 Get the name of this extension - not a copy don't delete! More...
 
void deactivate ()
 This function diactivates the extension (which makes it unusable, but not deleted) More...
 
bool deactivated ()
 Find out the status of the extension. More...
 
void printFailure (Glib::ustring reason)
 A quick function to print out a standard start of extension errors in the log. More...
 
const std::string & getErrorReason ()
 
Implementation::Implementationget_imp ()
 
void set_execution_env (ExecutionEnv *env)
 
ExecutionEnvget_execution_env ()
 
std::string get_base_directory () const
 
void set_base_directory (std::string const &base_directory)
 
std::string get_dependency_location (const char *name)
 Gets the location of the dependency file as an absolute path. More...
 
const char * get_translation (const char *msgid, const char *msgctxt=nullptr) const
 Gets a translation within the context of the current extension. More...
 
void set_environment (const SPDocument *doc=nullptr)
 Sets environment suitable for executing this Extension. More...
 
ModuleImpType get_implementation_type ()
 Uses the object's type to figure out what the type is. More...
 
unsigned int widget_visible_count ()
 A function to get the number of visible parameters of the extension. More...
 
bool get_param_bool (const gchar *name) const
 Gets a parameter identified by name with the bool placed in value. More...
 
bool get_param_bool (const gchar *name, bool alt) const
 Like get_param_bool but with a default on param_not_exist error. More...
 
int get_param_int (const gchar *name) const
 Gets a parameter identified by name with the integer placed in value. More...
 
int get_param_int (const gchar *name, int alt) const
 Like get_param_int but with a default on param_not_exist error. More...
 
double get_param_float (const gchar *name) const
 Gets a float parameter identified by name with the double placed in value. More...
 
double get_param_float (const gchar *name, double alt) const
 Like get_param_float but with a default on param_not_exist error. More...
 
const char * get_param_string (const gchar *name, const char *alt) const
 Like get_param_string but with a default on param_not_exist error. More...
 
const char * get_param_string (const gchar *name) const
 Gets a parameter identified by name with the string placed in value. More...
 
const char * get_param_optiongroup (const gchar *name, const char *alt) const
 Like get_param_optiongroup but with a default on param_not_exist error. More...
 
const char * get_param_optiongroup (const gchar *name) const
 Gets a parameter identified by name with the string placed in value. More...
 
guint32 get_param_color (const gchar *name) const
 Gets a parameter identified by name with the unsigned int placed in value. More...
 
bool get_param_optiongroup_contains (const gchar *name, const char *value) const
 This is useful to find out, if a given string value is selectable in a optiongroup named \cname. More...
 
bool set_param_bool (const gchar *name, const bool value)
 Sets a parameter identified by name with the boolean in the parameter value. More...
 
int set_param_int (const gchar *name, const int value)
 Sets a parameter identified by name with the integer in the parameter value. More...
 
double set_param_float (const gchar *name, const double value)
 Sets a parameter identified by name with the double in the parameter value. More...
 
const char * set_param_string (const gchar *name, const char *value)
 Sets a parameter identified by name with the string in the parameter value. More...
 
const char * set_param_optiongroup (const gchar *name, const char *value)
 Sets a parameter identified by name with the string in the parameter value. More...
 
guint32 set_param_color (const gchar *name, const guint32 color)
 
Gtk::Widget * autogui (SPDocument *doc, Inkscape::XML::Node *node, sigc::signal< void > *changeSignal=nullptr)
 A function to automatically generate a GUI from the extensions' widgets. More...
 
void paramListString (std::list< std::string > &retlist)
 A function to get the parameters in a string form. More...
 
void set_gui (bool s)
 
bool get_gui ()
 
Gtk::Box * get_info_widget ()
 
Gtk::Box * get_params_widget ()
 

Static Public Member Functions

static void error_file_open ()
 A function to open the error log file. More...
 
static void error_file_close ()
 A function to close the error log file. More...
 
static void error_file_write (Glib::ustring text)
 A function to write to the error log file. More...
 

Static Protected Member Functions

static void add_val (Glib::ustring labelstr, Glib::ustring valuestr, Gtk::Grid *table, int *row)
 

Protected Attributes

Inkscape::XML::Noderepr
 The XML description of the Extension. More...
 
Implementation::Implementationimp
 An object that holds all the functions for making this work. More...
 
ExecutionEnvexecution_env
 Execution environment of the extension (currently only used by Effects) More...
 
std::string _base_directory
 Directory containing the .inx file, relative paths in the extension should usually be relative to it. More...
 
ExpirationTimertimer = nullptr
 Timeout to unload after a given time. More...
 
bool _translation_enabled = true
 Attempt translation of strings provided by the extension? More...
 

Private Member Functions

void lookup_translation_catalog ()
 Searches for a gettext catalog matching the extension's translationdomain. More...
 
void make_param (Inkscape::XML::Node *paramrepr)
 
InxParameterget_param (const gchar *name)
 Looks up the parameter with the specified name. More...
 
const InxParameterget_param (const gchar *name) const
 

Private Attributes

gchar * _id = nullptr
 The unique identifier for the Extension. More...
 
gchar * _name = nullptr
 A user friendly name for the Extension. More...
 
state_t _state = STATE_UNLOADED
 Which state the Extension is currently in. More...
 
std::vector< Dependency * > _deps
 Dependencies for this extension. More...
 
bool _gui
 
std::string _error_reason
 Short, textual explanation for the latest error. More...
 
const char * _translationdomain = nullptr
 Domainname of gettext textdomain that should be used for translation of the extension's strings. More...
 
std::string _gettext_catalog_dir
 Directory containing the gettext catalog for _translationdomain. More...
 
std::vector< InxWidget * > _widgets
 A list of widgets for this extension. More...
 

Static Private Attributes

static FILE * error_file = nullptr
 This is the place where errors get reported. More...
 

Detailed Description

The object that is the basis for the Extension system.

This object contains all of the information that all Extension have. The individual items are detailed within. This is the interface that those who want to use the extensions system should use. This is most likely to be those who are inside the Inkscape program.

Definition at line 122 of file extension.h.

Member Enumeration Documentation

◆ state_t

An enumeration to identify if the Extension has been loaded or not.

Enumerator
STATE_LOADED 

The extension has been loaded successfully.

STATE_UNLOADED 

The extension has not been loaded.

STATE_DEACTIVATED 

The extension is missing something which makes it unusable.

Definition at line 125 of file extension.h.

Constructor & Destructor Documentation

◆ Extension()

Inkscape::Extension::Extension::Extension ( Inkscape::XML::Node in_repr,
Implementation::Implementation in_imp,
std::string *  base_directory 
)

Constructs an Extension from a Inkscape::XML::Node.

Returns
none
Parameters
in_reprThe repr that should be used to build it
base_directoryBase directory of extensions that were loaded from a file (.inx file's location)

This function is the basis of building an extension for Inkscape. It currently extracts the fields from the Repr that are used in the extension. The Repr will likely include other children that are not related to the module directly. If the Repr does not include a name and an ID the module will be left in an errored state.

Definition at line 69 of file extension.cpp.

References _base_directory, _deps, _gettext_catalog_dir, _id, _name, _translation_enabled, _translationdomain, _widgets, Inkscape::GC::anchor(), Inkscape::XML::Node::attribute(), Inkscape::XML::Node::content(), Inkscape::Extension::db, Inkscape::XML::ELEMENT_NODE, Inkscape::XML::Node::firstChild(), imp, Inkscape::Extension::InxWidget::is_valid_widget_name(), lookup_translation_catalog(), Inkscape::Extension::InxWidget::make(), Inkscape::XML::Node::name(), Inkscape::XML::Node::next(), Inkscape::Extension::DB::register_ext(), repr, Inkscape::Extension::Dependency::TYPE_EXECUTABLE, and Inkscape::Extension::Dependency::TYPE_FILE.

◆ ~Extension()

Inkscape::Extension::Extension::~Extension ( )
virtual

Destroys the Extension.

Returns
none This function frees all of the strings that could be attached to the extension and also unreferences the repr. This is better than freeing it because it may (I wouldn't know why) be referenced in another place.

Definition at line 190 of file extension.cpp.

References _deps, _id, _name, _widgets, Inkscape::Extension::db, Inkscape::GC::release(), repr, set_state(), STATE_UNLOADED, timer, and Inkscape::Extension::DB::unregister_ext().

Member Function Documentation

◆ add_val()

void Inkscape::Extension::Extension::add_val ( Glib::ustring  labelstr,
Glib::ustring  valuestr,
Gtk::Grid *  table,
int *  row 
)
inlinestaticprotected

Definition at line 1058 of file extension.cpp.

References value.

Referenced by get_info_widget().

◆ autogui()

Gtk::Widget * Inkscape::Extension::Extension::autogui ( SPDocument doc,
Inkscape::XML::Node node,
sigc::signal< void > *  changeSignal = nullptr 
)

A function to automatically generate a GUI from the extensions' widgets.

Returns
Generated widget

This function just goes through each widget, and calls it's 'get_widget'. Then, each of those is placed into a Gtk::VBox, which is then returned to the calling function.

If there are no visible parameters, this function just returns NULL.

Definition at line 1005 of file extension.cpp.

References _gui, _widgets, Inkscape::Extension::InxWidget::GUI_BOX_MARGIN, Inkscape::Extension::InxWidget::GUI_BOX_SPACING, tip, and widget_visible_count().

Referenced by Inkscape::Extension::Internal::BlurEdge::prefs_effect(), Inkscape::Extension::Internal::Grid::prefs_effect(), Inkscape::Extension::Internal::Bitmap::ImageMagick::prefs_effect(), Inkscape::Extension::Implementation::Implementation::prefs_effect(), Inkscape::Extension::Implementation::Script::prefs_input(), Inkscape::Extension::Implementation::Implementation::prefs_input(), Inkscape::Extension::Implementation::Script::prefs_output(), and Inkscape::Extension::Implementation::Implementation::prefs_output().

◆ check()

bool Inkscape::Extension::Extension::check ( )
virtual

A function to check the validity of the extension.

Returns
A boolean saying whether the extension passed the checks This function chekcs to make sure that there is an id, a name, a repr and an implementation for this extension. Then it checks all of the dependencies to see if they pass. Finally, it asks the implementation to do a check of itself.

On each check, if there is a failure, it will print a message to the error log for that failure. It is important to note that the function keeps executing if it finds an error, to try and get as many of them into the error log as possible. This should help people debug installations, and figure out what they need to get for the full functionality of Inkscape to be available.

Reimplemented in Inkscape::Extension::Input, Inkscape::Extension::Output, and Inkscape::Extension::Print.

Definition at line 304 of file extension.cpp.

References _deps, Inkscape::Extension::Implementation::Implementation::check(), error_file_write(), imp, printFailure(), and repr.

Referenced by Inkscape::Extension::Print::check(), Inkscape::Extension::Input::check(), and Inkscape::Extension::Output::check().

◆ deactivate()

void Inkscape::Extension::Extension::deactivate ( )

This function diactivates the extension (which makes it unusable, but not deleted)

Returns
None This function is used to removed an extension from functioning, but not delete it completely. It sets the state to STATE_DEACTIVATED to mark to the world that it has been deactivated. It also removes the current implementation and replaces it with a standard one. This makes it so that we don't have to continually check if there is an implementation, but we are guaranteed to have a benign one.
Warning
It is important to note that there is no 'activate' function. Running this function is irreversible.

Definition at line 394 of file extension.cpp.

References imp, set_state(), and STATE_DEACTIVATED.

◆ deactivated()

bool Inkscape::Extension::Extension::deactivated ( )

Find out the status of the extension.

Returns
Whether the extension has been deactivated

Definition at line 411 of file extension.cpp.

References get_state(), and STATE_DEACTIVATED.

Referenced by Inkscape::UI::Dialog::FileOpenDialogImplWin32::createFilterMenu().

◆ error_file_close()

void Inkscape::Extension::Extension::error_file_close ( )
static

A function to close the error log file.

Definition at line 949 of file extension.cpp.

References error_file.

Referenced by Inkscape::Extension::check_extensions().

◆ error_file_open()

void Inkscape::Extension::Extension::error_file_open ( )
static

A function to open the error log file.

Definition at line 937 of file extension.cpp.

References error_file, Inkscape::IO::fopen_utf8name(), and Inkscape::IO::Resource::log_path().

Referenced by Inkscape::Extension::check_extensions().

◆ error_file_write()

void Inkscape::Extension::Extension::error_file_write ( Glib::ustring  text)
static

A function to write to the error log file.

Definition at line 958 of file extension.cpp.

References error_file.

Referenced by check(), and printFailure().

◆ get_base_directory()

std::string Inkscape::Extension::Extension::get_base_directory ( ) const
inline

◆ get_dependency_location()

std::string Inkscape::Extension::Extension::get_dependency_location ( const char *  name)

Gets the location of the dependency file as an absolute path.

Iterates over all dependencies of this extension and finds the one with matching name, then returns the absolute path to this dependency file as determined previously.

TODO: This function should not be necessary, but we parse script dependencies twice:

  • Once here in the Extension::Extension() constructor
  • A second time in Script::load() in "script.cpp" when determining the script location Theoretically we could return the wrong path if an extension depends on two files with the same name in different relative locations. In practice this risk should be close to zero, though.
Returns
Absolute path of the dependency file

Definition at line 429 of file extension.cpp.

References _deps.

Referenced by Inkscape::Extension::Implementation::Script::load(), and Inkscape::Extension::Implementation::XSLT::load().

◆ get_execution_env()

ExecutionEnv* Inkscape::Extension::Extension::get_execution_env ( )
inline

Definition at line 174 of file extension.h.

References execution_env.

Referenced by Inkscape::Extension::Implementation::Script::effect().

◆ get_gui()

bool Inkscape::Extension::Extension::get_gui ( )
inline

Definition at line 261 of file extension.h.

References _gui.

◆ get_id()

gchar * Inkscape::Extension::Extension::get_id ( ) const

Get the ID of this extension - not a copy don't delete!

Returns
The textual id of this extension

Definition at line 363 of file extension.cpp.

References _id.

Referenced by Inkscape::Extension::Dependency::check(), Inkscape::Extension::Effect::Effect(), Inkscape::Extension::Implementation::Script::effect(), Inkscape::Extension::InxWidget::get_widget(), Inkscape::Extension::InxParameter::InxParameter(), Inkscape::Extension::InxWidget::InxWidget(), Inkscape::Extension::InxWidget::make(), Inkscape::Extension::InxParameter::make(), Inkscape::Extension::open(), Inkscape::Extension::ParamBool::ParamBool(), Inkscape::Extension::ParamColor::ParamColor(), Inkscape::Extension::ParamFloat::ParamFloat(), Inkscape::Extension::ParamInt::ParamInt(), Inkscape::Extension::ParamNotebook::ParamNotebook(), Inkscape::Extension::ParamNotebook::ParamNotebookPage::ParamNotebookPage(), Inkscape::Extension::ParamOptionGroup::ParamOptionGroup(), Inkscape::Extension::ParamOptionGroup::ParamOptionGroupOption::ParamOptionGroupOption(), Inkscape::Extension::ParamPath::ParamPath(), Inkscape::Extension::ParamString::ParamString(), Inkscape::Extension::InxParameter::pref_name(), Inkscape::Extension::save(), Inkscape::Extension::ParamOptionGroup::set(), Inkscape::UI::Dialog::FileSaveDialogImplGtk::setSelectionType(), Inkscape::UI::Dialog::FileSaveDialogImplGtk::show(), Inkscape::Extension::InxParameter::value_to_string(), Inkscape::Extension::WidgetBox::WidgetBox(), Inkscape::Extension::WidgetImage::WidgetImage(), Inkscape::Extension::WidgetLabel::WidgetLabel(), and Inkscape::Extension::WidgetSpacer::WidgetSpacer().

◆ get_imp()

◆ get_implementation_type()

ModuleImpType Inkscape::Extension::Extension::get_implementation_type ( )

Uses the object's type to figure out what the type is.

Returns
Returns the type of extension that this object is.

Definition at line 591 of file extension.cpp.

References imp, MODULE_EXTENSION, MODULE_PLUGIN, and MODULE_XSLT.

◆ get_info_widget()

Gtk::Box * Inkscape::Extension::Extension::get_info_widget ( )

◆ get_name()

◆ get_param() [1/2]

InxParameter * Inkscape::Extension::Extension::get_param ( const gchar *  name)
private

Looks up the parameter with the specified name.

Searches the list of parameters attached to this extension, looking for a parameter with a matching name.

This function can throw a 'param_not_exist' exception if the name is not found.

Parameters
nameName of the parameter to search for.
Returns
Parameter with matching name.

Definition at line 638 of file extension.cpp.

References _widgets, and Inkscape::Extension::InxParameter::name().

Referenced by get_param(), get_param_bool(), get_param_color(), get_param_float(), get_param_int(), get_param_optiongroup(), get_param_optiongroup_contains(), get_param_string(), set_param_bool(), set_param_color(), set_param_float(), set_param_int(), set_param_optiongroup(), and set_param_string().

◆ get_param() [2/2]

const InxParameter * Inkscape::Extension::Extension::get_param ( const gchar *  name) const
private

Definition at line 662 of file extension.cpp.

References get_param().

◆ get_param_bool() [1/2]

bool Inkscape::Extension::Extension::get_param_bool ( const gchar *  name) const

Gets a parameter identified by name with the bool placed in value.

Returns
The value of the parameter identified by the name
Parameters
nameThe name of the parameter to get

Look up in the parameters list, const then execute the function on that found parameter.

Definition at line 676 of file extension.cpp.

References Inkscape::Extension::InxParameter::get_bool(), and get_param().

Referenced by Inkscape::UI::Dialog::Export::exportRaster(), Inkscape::Extension::Internal::Filter::EdgeDetect::get_filter_text(), Inkscape::Extension::Internal::Filter::Blur::get_filter_text(), Inkscape::Extension::Internal::Filter::NoiseFill::get_filter_text(), Inkscape::Extension::Internal::Filter::ColorizableDropShadow::get_filter_text(), Inkscape::Extension::Internal::Filter::Crosssmooth::get_filter_text(), Inkscape::Extension::Internal::Filter::Chromolitho::get_filter_text(), Inkscape::Extension::Internal::Filter::Brilliance::get_filter_text(), Inkscape::Extension::Internal::Filter::Bump::get_filter_text(), Inkscape::Extension::Internal::Filter::ChannelTransparency::get_filter_text(), Inkscape::Extension::Internal::Filter::ChannelPaint::get_filter_text(), Inkscape::Extension::Internal::Filter::Outline::get_filter_text(), Inkscape::Extension::Internal::Filter::LightEraser::get_filter_text(), Inkscape::Extension::Internal::Filter::CrossEngraving::get_filter_text(), Inkscape::Extension::Internal::Filter::WaxBump::get_filter_text(), Inkscape::Extension::Internal::Filter::Drawing::get_filter_text(), Inkscape::Extension::Internal::Filter::ImageBlur::get_filter_text(), Inkscape::Extension::Internal::Filter::Silhouette::get_filter_text(), Inkscape::Extension::Internal::Filter::Colorize::get_filter_text(), Inkscape::Extension::Internal::Filter::Electrize::get_filter_text(), Inkscape::Extension::Internal::Filter::PointEngraving::get_filter_text(), Inkscape::Extension::Internal::Filter::ExtractChannel::get_filter_text(), Inkscape::Extension::Internal::Filter::Posterize::get_filter_text(), Inkscape::Extension::Internal::Filter::Greyscale::get_filter_text(), Inkscape::Extension::Internal::Filter::Invert::get_filter_text(), get_param_bool(), Inkscape::Extension::Internal::Bitmap::Raise::refreshParameters(), Inkscape::Extension::Internal::Bitmap::Shade::refreshParameters(), Inkscape::Extension::Internal::CairoPsOutput::textToPath(), Inkscape::Extension::Internal::CairoEpsOutput::textToPath(), Inkscape::Extension::Internal::PrintMetafile::textToPath(), and Inkscape::Extension::Internal::PrintLatex::textToPath().

◆ get_param_bool() [2/2]

bool Inkscape::Extension::Extension::get_param_bool ( const gchar *  name,
bool  alt 
) const

Like get_param_bool but with a default on param_not_exist error.

Returns
The value of the param or the alternate if the param doesn't exist.

Definition at line 687 of file extension.cpp.

References get_param_bool().

◆ get_param_color()

guint32 Inkscape::Extension::Extension::get_param_color ( const gchar *  name) const

Gets a parameter identified by name with the unsigned int placed in value.

Returns
The unsigned integer RGBA value for the parameter specified
Parameters
nameThe name of the parameter to get

Look up in the parameters list, const then execute the function on that found parameter.

Definition at line 831 of file extension.cpp.

References Inkscape::Extension::InxParameter::get_color(), and get_param().

Referenced by Inkscape::Extension::Internal::Filter::DiffuseLight::get_filter_text(), Inkscape::Extension::Internal::Filter::NoiseFill::get_filter_text(), Inkscape::Extension::Internal::Filter::ColorizableDropShadow::get_filter_text(), Inkscape::Extension::Internal::Filter::Bump::get_filter_text(), Inkscape::Extension::Internal::Filter::MatteJelly::get_filter_text(), Inkscape::Extension::Internal::Filter::ChannelPaint::get_filter_text(), Inkscape::Extension::Internal::Filter::Outline::get_filter_text(), Inkscape::Extension::Internal::Filter::SpecularLight::get_filter_text(), Inkscape::Extension::Internal::Filter::WaxBump::get_filter_text(), Inkscape::Extension::Internal::Filter::Drawing::get_filter_text(), Inkscape::Extension::Internal::Filter::ImageBlur::get_filter_text(), Inkscape::Extension::Internal::Filter::Silhouette::get_filter_text(), Inkscape::Extension::Internal::Filter::Colorize::get_filter_text(), Inkscape::Extension::Internal::Filter::Duochrome::get_filter_text(), Inkscape::Extension::Internal::Filter::PointEngraving::get_filter_text(), Inkscape::Extension::Internal::Filter::NudgeRGB::get_filter_text(), Inkscape::Extension::Internal::Filter::NudgeCMY::get_filter_text(), Inkscape::Extension::Internal::Filter::SimpleBlend::get_filter_text(), Inkscape::Extension::Internal::Filter::Tritone::get_filter_text(), and Inkscape::Extension::Internal::Bitmap::Colorize::refreshParameters().

◆ get_param_float() [1/2]

double Inkscape::Extension::Extension::get_param_float ( const gchar *  name) const

Gets a float parameter identified by name with the double placed in value.

Returns
The double value for the float parameter specified
Parameters
nameThe name of the parameter to get

Look up in the parameters list, const then execute the function on that found parameter.

Definition at line 733 of file extension.cpp.

References Inkscape::Extension::InxParameter::get_float(), and get_param().

Referenced by Inkscape::Extension::Internal::BlurEdge::effect(), Inkscape::Extension::Internal::Grid::effect(), Inkscape::UI::Dialog::Export::exportRaster(), Inkscape::Extension::Internal::Filter::Snow::get_filter_text(), Inkscape::Extension::Internal::Filter::EdgeDetect::get_filter_text(), Inkscape::Extension::Internal::Filter::DiffuseLight::get_filter_text(), Inkscape::Extension::Internal::Filter::Blur::get_filter_text(), Inkscape::Extension::Internal::Filter::NoiseFill::get_filter_text(), Inkscape::Extension::Internal::Filter::ColorizableDropShadow::get_filter_text(), Inkscape::Extension::Internal::Filter::Crosssmooth::get_filter_text(), Inkscape::Extension::Internal::Filter::InkBlot::get_filter_text(), Inkscape::Extension::Internal::Filter::FeltFeather::get_filter_text(), Inkscape::Extension::Internal::Filter::Chromolitho::get_filter_text(), Inkscape::Extension::Internal::Filter::Brilliance::get_filter_text(), Inkscape::Extension::Internal::Filter::Bump::get_filter_text(), Inkscape::Extension::Internal::Filter::CleanEdges::get_filter_text(), Inkscape::Extension::Internal::Filter::ChannelTransparency::get_filter_text(), Inkscape::Extension::Internal::Filter::MatteJelly::get_filter_text(), Inkscape::Extension::Internal::Filter::ChannelPaint::get_filter_text(), Inkscape::Extension::Internal::Filter::Outline::get_filter_text(), Inkscape::Extension::Internal::Filter::CrossBlur::get_filter_text(), Inkscape::Extension::Internal::Filter::Roughen::get_filter_text(), Inkscape::Extension::Internal::Filter::LightEraser::get_filter_text(), Inkscape::Extension::Internal::Filter::SpecularLight::get_filter_text(), Inkscape::Extension::Internal::Filter::CrossEngraving::get_filter_text(), Inkscape::Extension::Internal::Filter::Feather::get_filter_text(), Inkscape::Extension::Internal::Filter::Opacity::get_filter_text(), Inkscape::Extension::Internal::Filter::WaxBump::get_filter_text(), Inkscape::Extension::Internal::Filter::Drawing::get_filter_text(), Inkscape::Extension::Internal::Filter::ImageBlur::get_filter_text(), Inkscape::Extension::Internal::Filter::ColorShift::get_filter_text(), Inkscape::Extension::Internal::Filter::Silhouette::get_filter_text(), Inkscape::Extension::Internal::Filter::Colorize::get_filter_text(), Inkscape::Extension::Internal::Filter::Electrize::get_filter_text(), Inkscape::Extension::Internal::Filter::NeonDraw::get_filter_text(), Inkscape::Extension::Internal::Filter::Duochrome::get_filter_text(), Inkscape::Extension::Internal::Filter::PointEngraving::get_filter_text(), Inkscape::Extension::Internal::Filter::FadeToBW::get_filter_text(), Inkscape::Extension::Internal::Filter::Posterize::get_filter_text(), Inkscape::Extension::Internal::Filter::Greyscale::get_filter_text(), Inkscape::Extension::Internal::Filter::PosterizeBasic::get_filter_text(), Inkscape::Extension::Internal::Filter::Invert::get_filter_text(), Inkscape::Extension::Internal::Filter::Lighting::get_filter_text(), Inkscape::Extension::Internal::Filter::LightnessContrast::get_filter_text(), Inkscape::Extension::Internal::Filter::NudgeRGB::get_filter_text(), Inkscape::Extension::Internal::Filter::NudgeCMY::get_filter_text(), Inkscape::Extension::Internal::Filter::Quadritone::get_filter_text(), Inkscape::Extension::Internal::Filter::Tritone::get_filter_text(), get_param_float(), Inkscape::Extension::Internal::Bitmap::Solarize::refreshParameters(), Inkscape::Extension::Internal::Bitmap::MedianFilter::refreshParameters(), Inkscape::Extension::Internal::Bitmap::Threshold::refreshParameters(), Inkscape::Extension::Internal::Bitmap::Implode::refreshParameters(), Inkscape::Extension::Internal::Bitmap::Opacity::refreshParameters(), Inkscape::Extension::Internal::Bitmap::Blur::refreshParameters(), Inkscape::Extension::Internal::Bitmap::Sharpen::refreshParameters(), Inkscape::Extension::Internal::Bitmap::Charcoal::refreshParameters(), Inkscape::Extension::Internal::Bitmap::Wave::refreshParameters(), Inkscape::Extension::Internal::Bitmap::GaussianBlur::refreshParameters(), Inkscape::Extension::Internal::Bitmap::Emboss::refreshParameters(), Inkscape::Extension::Internal::Bitmap::Shade::refreshParameters(), Inkscape::Extension::Internal::Bitmap::Modulate::refreshParameters(), Inkscape::Extension::Internal::Bitmap::Level::refreshParameters(), Inkscape::Extension::Internal::Bitmap::Unsharpmask::refreshParameters(), and Inkscape::Extension::Internal::Bitmap::LevelChannel::refreshParameters().

◆ get_param_float() [2/2]

double Inkscape::Extension::Extension::get_param_float ( const gchar *  name,
double  alt 
) const

Like get_param_float but with a default on param_not_exist error.

Returns
The value of the param or the alternate if the param doesn't exist.

Definition at line 744 of file extension.cpp.

References get_param_float().

◆ get_param_int() [1/2]

int Inkscape::Extension::Extension::get_param_int ( const gchar *  name) const

Gets a parameter identified by name with the integer placed in value.

Returns
The integer value for the parameter specified
Parameters
nameThe name of the parameter to get

Look up in the parameters list, const then execute the function on that found parameter.

Definition at line 704 of file extension.cpp.

References Inkscape::Extension::InxParameter::get_int(), and get_param().

Referenced by Inkscape::Extension::Internal::BlurEdge::effect(), Inkscape::UI::Dialog::Export::exportRaster(), Inkscape::Extension::Internal::Filter::DiffuseLight::get_filter_text(), Inkscape::Extension::Internal::Filter::NoiseFill::get_filter_text(), Inkscape::Extension::Internal::Filter::InkBlot::get_filter_text(), Inkscape::Extension::Internal::Filter::FeltFeather::get_filter_text(), Inkscape::Extension::Internal::Filter::Chromolitho::get_filter_text(), Inkscape::Extension::Internal::Filter::Bump::get_filter_text(), Inkscape::Extension::Internal::Filter::MatteJelly::get_filter_text(), Inkscape::Extension::Internal::Filter::Roughen::get_filter_text(), Inkscape::Extension::Internal::Filter::SpecularLight::get_filter_text(), Inkscape::Extension::Internal::Filter::CrossEngraving::get_filter_text(), Inkscape::Extension::Internal::Filter::WaxBump::get_filter_text(), Inkscape::Extension::Internal::Filter::Drawing::get_filter_text(), Inkscape::Extension::Internal::Filter::ColorShift::get_filter_text(), Inkscape::Extension::Internal::Filter::Electrize::get_filter_text(), Inkscape::Extension::Internal::Filter::PointEngraving::get_filter_text(), Inkscape::Extension::Internal::Filter::Posterize::get_filter_text(), Inkscape::Extension::Internal::Filter::PosterizeBasic::get_filter_text(), Inkscape::Extension::Internal::Filter::Quadritone::get_filter_text(), Inkscape::Extension::Internal::Filter::Solarize::get_filter_text(), Inkscape::Extension::Internal::Filter::Tritone::get_filter_text(), get_param_int(), Inkscape::Extension::Internal::Bitmap::CycleColormap::refreshParameters(), Inkscape::Extension::Internal::Bitmap::Edge::refreshParameters(), Inkscape::Extension::Internal::Bitmap::Swirl::refreshParameters(), Inkscape::Extension::Internal::Bitmap::OilPaint::refreshParameters(), Inkscape::Extension::Internal::Bitmap::ReduceNoise::refreshParameters(), Inkscape::Extension::Internal::Bitmap::Spread::refreshParameters(), Inkscape::Extension::Internal::Bitmap::Contrast::refreshParameters(), Inkscape::Extension::Internal::Bitmap::Sample::refreshParameters(), Inkscape::Extension::Internal::Bitmap::AdaptiveThreshold::refreshParameters(), Inkscape::Extension::Internal::Bitmap::Raise::refreshParameters(), and Inkscape::Extension::Internal::Bitmap::Crop::refreshParameters().

◆ get_param_int() [2/2]

int Inkscape::Extension::Extension::get_param_int ( const gchar *  name,
int  alt 
) const

Like get_param_int but with a default on param_not_exist error.

Returns
The value of the param or the alternate if the param doesn't exist.

Definition at line 715 of file extension.cpp.

References get_param_int().

◆ get_param_optiongroup() [1/2]

const char * Inkscape::Extension::Extension::get_param_optiongroup ( const gchar *  name) const

Gets a parameter identified by name with the string placed in value.

Returns
The string value for the parameter specified
Parameters
nameThe name of the parameter to get

Look up in the parameters list, const then execute the function on that found parameter.

Definition at line 789 of file extension.cpp.

References Inkscape::Extension::InxParameter::get_optiongroup(), and get_param().

◆ get_param_optiongroup() [2/2]

const char * Inkscape::Extension::Extension::get_param_optiongroup ( const gchar *  name,
const char *  alt 
) const

Like get_param_optiongroup but with a default on param_not_exist error.

Returns
The value of the param or the alternate if the param doesn't exist.

Definition at line 800 of file extension.cpp.

Referenced by Inkscape::Extension::Internal::Filter::EdgeDetect::get_filter_text(), Inkscape::Extension::Internal::Filter::Blend::get_filter_text(), Inkscape::Extension::Internal::Filter::NoiseFill::get_filter_text(), Inkscape::Extension::Internal::Filter::ColorizableDropShadow::get_filter_text(), Inkscape::Extension::Internal::Filter::Crosssmooth::get_filter_text(), Inkscape::Extension::Internal::Filter::InkBlot::get_filter_text(), Inkscape::Extension::Internal::Filter::FeltFeather::get_filter_text(), Inkscape::Extension::Internal::Filter::Chromolitho::get_filter_text(), Inkscape::Extension::Internal::Filter::Bump::get_filter_text(), Inkscape::Extension::Internal::Filter::Outline::get_filter_text(), Inkscape::Extension::Internal::Filter::CrossBlur::get_filter_text(), Inkscape::Extension::Internal::Filter::Roughen::get_filter_text(), Inkscape::Extension::Internal::Filter::ColorBlindness::get_filter_text(), Inkscape::Extension::Internal::Filter::WaxBump::get_filter_text(), Inkscape::Extension::Internal::Filter::ImageBlur::get_filter_text(), Inkscape::Extension::Internal::Filter::Colorize::get_filter_text(), Inkscape::Extension::Internal::Filter::Electrize::get_filter_text(), Inkscape::Extension::Internal::Filter::ComponentTransfer::get_filter_text(), Inkscape::Extension::Internal::Filter::NeonDraw::get_filter_text(), Inkscape::Extension::Internal::Filter::Duochrome::get_filter_text(), Inkscape::Extension::Internal::Filter::PointEngraving::get_filter_text(), Inkscape::Extension::Internal::Filter::ExtractChannel::get_filter_text(), Inkscape::Extension::Internal::Filter::FadeToBW::get_filter_text(), Inkscape::Extension::Internal::Filter::Posterize::get_filter_text(), Inkscape::Extension::Internal::Filter::Invert::get_filter_text(), Inkscape::Extension::Internal::Filter::Quadritone::get_filter_text(), Inkscape::Extension::Internal::Filter::SimpleBlend::get_filter_text(), Inkscape::Extension::Internal::Filter::Solarize::get_filter_text(), Inkscape::Extension::Internal::Filter::Tritone::get_filter_text(), ink_drag_data_received(), Inkscape::Extension::Internal::Bitmap::AddNoise::refreshParameters(), Inkscape::Extension::Internal::Bitmap::Channel::refreshParameters(), Inkscape::Extension::Internal::Bitmap::LevelChannel::refreshParameters(), and Inkscape::Extension::Internal::CairoRendererPdfOutput::save().

◆ get_param_optiongroup_contains()

bool Inkscape::Extension::Extension::get_param_optiongroup_contains ( const gchar *  name,
const char *  value 
) const

This is useful to find out, if a given string value is selectable in a optiongroup named \cname.

Parameters
nameThe name of the optiongroup parameter to get.
Returns
true if value exists, false if not

Definition at line 816 of file extension.cpp.

References Inkscape::Extension::InxParameter::get_optiongroup_contains(), get_param(), and value.

Referenced by InkFileExportCmd::do_export_ps_pdf().

◆ get_param_string() [1/2]

const char * Inkscape::Extension::Extension::get_param_string ( const gchar *  name) const

Gets a parameter identified by name with the string placed in value.

Returns
The string value for the parameter specified
Parameters
nameThe name of the parameter to get

Look up in the parameters list, const then execute the function on that found parameter.

Definition at line 761 of file extension.cpp.

References get_param(), and Inkscape::Extension::InxParameter::get_string().

◆ get_param_string() [2/2]

const char * Inkscape::Extension::Extension::get_param_string ( const gchar *  name,
const char *  alt 
) const

Like get_param_string but with a default on param_not_exist error.

Returns
The value of the param or the alternate if the param doesn't exist.

Definition at line 772 of file extension.cpp.

◆ get_params_widget()

Gtk::Box * Inkscape::Extension::Extension::get_params_widget ( )

Definition at line 1077 of file extension.cpp.

◆ get_repr()

Inkscape::XML::Node * Inkscape::Extension::Extension::get_repr ( )

A getter for the internal Repr, does not add a reference.

Returns
The XML tree that is used to define the extension

Definition at line 353 of file extension.cpp.

References repr.

Referenced by Inkscape::Extension::Implementation::Script::check(), Inkscape::Extension::Implementation::Script::load(), and Inkscape::Extension::Implementation::XSLT::load().

◆ get_state()

Extension::state_t Inkscape::Extension::Extension::get_state ( )

A getter for the state variable.

Returns
The state the extension is in

Definition at line 272 of file extension.cpp.

References _state.

Referenced by deactivated(), and loaded().

◆ get_translation()

const char * Inkscape::Extension::Extension::get_translation ( const char *  msgid,
const char *  msgctxt = nullptr 
) const

Gets a translation within the context of the current extension.

Query gettext for the translated version of the input string, handling the preferred translation domain of the extension internally.

Parameters
msgidString to translate
msgctxtContext for the translation
Returns
Translated string (or original string if extension is not supposed to be translated)

Definition at line 539 of file extension.cpp.

References _id, _translation_enabled, and _translationdomain.

Referenced by Inkscape::UI::_translate(), Inkscape::Extension::Input::get_filetypename(), Inkscape::Extension::Output::get_filetypename(), Inkscape::Extension::Input::get_filetypetooltip(), Inkscape::Extension::Output::get_filetypetooltip(), get_info_widget(), Inkscape::Extension::Effect::get_menu(), get_name(), and Inkscape::Extension::InxWidget::get_translation().

◆ getErrorReason()

const std::string& Inkscape::Extension::Extension::getErrorReason ( )
inline

Definition at line 171 of file extension.h.

References _error_reason.

◆ loaded()

◆ lookup_translation_catalog()

void Inkscape::Extension::Extension::lookup_translation_catalog ( )
private

Searches for a gettext catalog matching the extension's translationdomain.

This function will attempt to find the correct gettext catalog for the translationdomain requested by the extension.

For this the following three locations are recursively searched for "${translationdomain}.mo":

  • the 'locale' directory in the .inx file's folder
  • the 'locale' directory in the "extensions" folder containing the .inx
  • the system location for gettext catalogs, i.e. where Inkscape's own catalog is located

If one matching file is found, the directory is assumed to be the correct location and registered with gettext

Definition at line 474 of file extension.cpp.

References _base_directory, Inkscape::Extension::_find_filename_recursive(), _gettext_catalog_dir, _translation_enabled, _translationdomain, and Inkscape::IO::file_test().

Referenced by Extension().

◆ make_param()

void Inkscape::Extension::Extension::make_param ( Inkscape::XML::Node paramrepr)
private

◆ paramListString()

void Inkscape::Extension::Extension::paramListString ( std::list< std::string > &  retlist)

◆ printFailure()

void Inkscape::Extension::Extension::printFailure ( Glib::ustring  reason)

A quick function to print out a standard start of extension errors in the log.

Parameters
reasonA string explaining why this failed

Real simple, just put everything into error_file.

Definition at line 342 of file extension.cpp.

References _error_reason, _name, Geom::compose(), and error_file_write().

Referenced by check().

◆ set_base_directory()

void Inkscape::Extension::Extension::set_base_directory ( std::string const &  base_directory)
inline

Definition at line 176 of file extension.h.

References _base_directory.

◆ set_environment()

void Inkscape::Extension::Extension::set_environment ( const SPDocument doc = nullptr)

Sets environment suitable for executing this Extension.

Currently sets the environment variables INKEX_GETTEXT_DOMAIN and INKEX_GETTEXT_DIRECTORY to make the "translationdomain" accessible to child processes spawned by this extension's Implementation.

Parameters
docOptional document, if provided sets the DOCUMENT_PATH from the document's save location.

Definition at line 563 of file extension.cpp.

References _gettext_catalog_dir, _translationdomain, SPDocument::getDocumentFilename(), and Inkscape::IO::Resource::profile_path().

Referenced by Inkscape::Extension::Implementation::Script::effect(), Inkscape::Extension::Implementation::Script::export_raster(), Inkscape::Extension::Implementation::Script::open(), and Inkscape::Extension::Implementation::Script::save().

◆ set_execution_env()

void Inkscape::Extension::Extension::set_execution_env ( ExecutionEnv env)
inline

◆ set_gui()

void Inkscape::Extension::Extension::set_gui ( bool  s)
inline

Definition at line 260 of file extension.h.

References _gui.

Referenced by ink_drag_data_received(), and Inkscape::Extension::open().

◆ set_param_bool()

bool Inkscape::Extension::Extension::set_param_bool ( const gchar *  name,
const bool  value 
)

Sets a parameter identified by name with the boolean in the parameter value.

Returns
The passed in value
Parameters
nameThe name of the parameter to set
valueThe value to set the parameter to

Look up in the parameters list, const then execute the function on that found parameter.

Definition at line 847 of file extension.cpp.

References get_param(), Inkscape::Extension::InxParameter::set_bool(), and value.

Referenced by InkFileExportCmd::do_export_ps_pdf(), Inkscape::Extension::Internal::Wmf::save(), and Inkscape::Extension::Internal::Emf::save().

◆ set_param_color()

guint32 Inkscape::Extension::Extension::set_param_color ( const gchar *  name,
const guint32  color 
)
\return   The passed in value
\brief    Sets a parameter identified by name with the unsigned integer RGBA value in the parameter value.
\param    name   The name of the parameter to set
\param    value  The value to set the parameter to

Look up in the parameters list, const then execute the function on that found parameter.

Definition at line 927 of file extension.cpp.

References get_param(), and Inkscape::Extension::InxParameter::set_color().

◆ set_param_float()

double Inkscape::Extension::Extension::set_param_float ( const gchar *  name,
const double  value 
)

Sets a parameter identified by name with the double in the parameter value.

Returns
The passed in value
Parameters
nameThe name of the parameter to set
valueThe value to set the parameter to

Look up in the parameters list, const then execute the function on that found parameter.

Definition at line 879 of file extension.cpp.

References get_param(), Inkscape::Extension::InxParameter::set_float(), and value.

Referenced by InkFileExportCmd::do_export_ps_pdf().

◆ set_param_int()

int Inkscape::Extension::Extension::set_param_int ( const gchar *  name,
const int  value 
)

Sets a parameter identified by name with the integer in the parameter value.

Returns
The passed in value
Parameters
nameThe name of the parameter to set
valueThe value to set the parameter to

Look up in the parameters list, const then execute the function on that found parameter.

Definition at line 863 of file extension.cpp.

References get_param(), Inkscape::Extension::InxParameter::set_int(), and value.

Referenced by InkFileExportCmd::do_export_ps_pdf().

◆ set_param_optiongroup()

const char * Inkscape::Extension::Extension::set_param_optiongroup ( const gchar *  name,
const char *  value 
)

Sets a parameter identified by name with the string in the parameter value.

Returns
The passed in value
Parameters
nameThe name of the parameter to set
valueThe value to set the parameter to

Look up in the parameters list, const then execute the function on that found parameter.

Definition at line 911 of file extension.cpp.

References get_param(), Inkscape::Extension::InxParameter::set_optiongroup(), and value.

Referenced by InkFileExportCmd::do_export_ps_pdf(), and ink_drag_data_received().

◆ set_param_string()

const char * Inkscape::Extension::Extension::set_param_string ( const gchar *  name,
const char *  value 
)

Sets a parameter identified by name with the string in the parameter value.

Returns
The passed in value
Parameters
nameThe name of the parameter to set
valueThe value to set the parameter to

Look up in the parameters list, const then execute the function on that found parameter.

Definition at line 895 of file extension.cpp.

References get_param(), Inkscape::Extension::InxParameter::set_string(), and value.

Referenced by InkFileExportCmd::do_export_ps_pdf().

◆ set_state()

void Inkscape::Extension::Extension::set_state ( state_t  in_state)

A function to set whether the extension should be loaded or unloaded.

Returns
none
Parameters
in_stateWhich state should the extension be in?

It checks to see if this is a state change or not. If we're changing states it will call the appropriate function in the implementation, load or unload. Currently, there is no error checking in this function. There should be.

Todo:
Need some more error checking here!

Definition at line 226 of file extension.cpp.

References _state, imp, Inkscape::Extension::Implementation::Implementation::load(), STATE_DEACTIVATED, STATE_LOADED, STATE_UNLOADED, timer, and Inkscape::Extension::Implementation::Implementation::unload().

Referenced by deactivate(), InkFileExportCmd::do_export_extension(), Inkscape::Extension::Effect::effect(), Inkscape::Extension::Output::export_raster(), Inkscape::Extension::ExpirationTimer::idle_func(), Inkscape::Extension::Input::open(), Inkscape::Extension::open(), Inkscape::Extension::PrefDialog::param_change(), Inkscape::Extension::Input::prefs(), Inkscape::Extension::Effect::prefs(), Inkscape::Extension::Output::prefs(), Inkscape::Extension::Output::save(), Inkscape::Extension::save(), and ~Extension().

◆ widget_visible_count()

unsigned int Inkscape::Extension::Extension::widget_visible_count ( )

A function to get the number of visible parameters of the extension.

Returns
The number of visible parameters.

Definition at line 1087 of file extension.cpp.

References _widgets.

Referenced by autogui(), Inkscape::Extension::Effect::Effect(), Inkscape::Extension::Effect::prefs(), and Inkscape::Extension::Implementation::Implementation::prefs_effect().

Member Data Documentation

◆ _base_directory

std::string Inkscape::Extension::Extension::_base_directory
protected

Directory containing the .inx file, relative paths in the extension should usually be relative to it.

Definition at line 145 of file extension.h.

Referenced by Extension(), get_base_directory(), lookup_translation_catalog(), and set_base_directory().

◆ _deps

std::vector<Dependency *> Inkscape::Extension::Extension::_deps
private

Dependencies for this extension.

Definition at line 135 of file extension.h.

Referenced by check(), Extension(), get_dependency_location(), and ~Extension().

◆ _error_reason

std::string Inkscape::Extension::Extension::_error_reason
private

Short, textual explanation for the latest error.

Definition at line 138 of file extension.h.

Referenced by getErrorReason(), and printFailure().

◆ _gettext_catalog_dir

std::string Inkscape::Extension::Extension::_gettext_catalog_dir
private

Directory containing the gettext catalog for _translationdomain.

Definition at line 153 of file extension.h.

Referenced by Extension(), lookup_translation_catalog(), and set_environment().

◆ _gui

bool Inkscape::Extension::Extension::_gui
private

Definition at line 137 of file extension.h.

Referenced by autogui(), get_gui(), and set_gui().

◆ _id

gchar* Inkscape::Extension::Extension::_id = nullptr
private

The unique identifier for the Extension.

Definition at line 132 of file extension.h.

Referenced by Extension(), get_id(), get_info_widget(), get_translation(), and ~Extension().

◆ _name

gchar* Inkscape::Extension::Extension::_name = nullptr
private

A user friendly name for the Extension.

Definition at line 133 of file extension.h.

Referenced by Extension(), get_info_widget(), get_name(), printFailure(), and ~Extension().

◆ _state

state_t Inkscape::Extension::Extension::_state = STATE_UNLOADED
private

Which state the Extension is currently in.

Definition at line 134 of file extension.h.

Referenced by get_info_widget(), get_state(), and set_state().

◆ _translation_enabled

bool Inkscape::Extension::Extension::_translation_enabled = true
protected

Attempt translation of strings provided by the extension?

Definition at line 148 of file extension.h.

Referenced by Extension(), Inkscape::Extension::Effect::get_menu(), get_translation(), and lookup_translation_catalog().

◆ _translationdomain

const char* Inkscape::Extension::Extension::_translationdomain = nullptr
private

Domainname of gettext textdomain that should be used for translation of the extension's strings.

Definition at line 151 of file extension.h.

Referenced by Extension(), get_translation(), lookup_translation_catalog(), and set_environment().

◆ _widgets

std::vector<InxWidget *> Inkscape::Extension::Extension::_widgets
private

A list of widgets for this extension.

Definition at line 184 of file extension.h.

Referenced by autogui(), Extension(), get_param(), paramListString(), widget_visible_count(), and ~Extension().

◆ error_file

FILE * Inkscape::Extension::Extension::error_file = nullptr
staticprivate

This is the place where errors get reported.

Definition at line 136 of file extension.h.

Referenced by error_file_close(), error_file_open(), and error_file_write().

◆ execution_env

ExecutionEnv* Inkscape::Extension::Extension::execution_env
protected

Execution environment of the extension (currently only used by Effects)

Definition at line 143 of file extension.h.

Referenced by Inkscape::Extension::Effect::effect(), get_execution_env(), and set_execution_env().

◆ imp

◆ repr

Inkscape::XML::Node* Inkscape::Extension::Extension::repr
protected

◆ timer

ExpirationTimer* Inkscape::Extension::Extension::timer = nullptr
protected

Timeout to unload after a given time.

Definition at line 147 of file extension.h.

Referenced by Inkscape::Extension::Effect::effect(), Inkscape::Extension::Input::open(), set_state(), and ~Extension().


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