inkex.inx module

Parsing inx files for checking and generating.

class inkex.inx.InxElement[source]

Bases: lxml.etree.ElementBase

_text(name, default=None, nss=None)[source]

Get text content agnostically

apply_nss(xpath, nss=None)[source]

Add prefixes to any xpath string

find_one(name, nss=None)[source]

Return the first element matching the given name


Get the root document element from any element descendent

xpath(xpath, nss=None)[source]

Namespace specific xpath searches

class inkex.inx.InxFile(filename)[source]

Bases: object

Open an INX file and provide useful functions

property extension_class

Attempt to get the extension class

property ident
property kind
property menu

Return the menu this effect ends up in

property metadata

Returns information about what type of extension this is

property name
property params

Get all params at all levels

property script

Returns information about the called script

property slug
property warnings
class inkex.inx.InxLookup[source]

Bases: lxml.etree.CustomElementClassLookup

Custom inx xml file lookup

lookup(self, type, doc, namespace, name)[source]
class inkex.inx.ParamElement[source]

Bases: inkex.inx.InxElement

A param in an inx file.

property name
property options

Return a list of option values

property param_type