Logo Search packages:      
Sourcecode: inkscape version File versions  Download package

Glib::ustring Inkscape::UI::ClipboardManagerImpl::getPathParameter (  ) [virtual]

Get LPE path data from the clipboard.

The retrieved path data (contents of the d attribute), or "" if no path was found

Implements Inkscape::UI::ClipboardManager.

Definition at line 516 of file clipboard.cpp.

References _retrieveClipboard(), _userWarn(), and sp_repr_lookup_name().

    SPDocument *tempdoc = _retrieveClipboard(); // any target will do here
    if ( tempdoc == NULL ) {
        _userWarn(SP_ACTIVE_DESKTOP, _("Nothing on the clipboard."));
        return "";
        *root = sp_document_repr_root(tempdoc),
        *path = sp_repr_lookup_name(root, "svg:path", -1); // unlimited search depth
    if ( path == NULL ) {
        _userWarn(SP_ACTIVE_DESKTOP, _("Clipboard does not contain a path."));
        return "";
    gchar const *svgd = path->attribute("d");
    return svgd;

Here is the call graph for this function:

Generated by  Doxygen 1.6.0   Back to index