gdkpixbuf-input.cpp revision 15c344e1be0334f000eed568b4d7e71699f174f5
#ifdef HAVE_CONFIG_H
# include <config.h>
#endif
#include "document-private.h"
#include <dir-util.h>
#include "gdkpixbuf-input.h"
#include "preferences.h"
#include "selection-chemistry.h"
#include "sp-image.h"
#include "document-undo.h"
#include "unit-constants.h"
#include "image-resolution.h"
#include <set>
namespace Inkscape {
namespace IO {
}
namespace Extension {
namespace Internal {
{
return lossy;
}
{
bool embed = false;
embed = true;
embed = false;
} else {
}
}
if (pb) { /* We are readable */
// TODO revisit: bool is_lossy;
}
// HACK: replace with something better based on GIO
// TODO revisit: is_lossy = true;
} else {
// TODO revisit: is_lossy = false;
}
ImageResolution *ir = 0;
double xscale = 1;
double yscale = 1;
if ( str ) {
}
} else {
if (!ir)
else
}
if ( str ) {
}
} else {
if (!ir)
else
}
if (ir)
delete ir;
// Create image node
if (embed) {
} else {
// convert filename to uri
if(_uri) {
} else {
}
}
// Add it to the current layer
// restore undo, as now this document may be shown to the user if a bitmap was opened
} else {
printf("GdkPixbuf loader failed\n");
}
return doc;
}
#include "clear-n_.h"
void
GdkpixbufInput::init(void)
{
/* \todo I'm not sure if I need to free this list */
formatlist != NULL;
for (int i = 0; extensions[i] != NULL; i++) {
/* thanks but no thanks, we'll handle SVG extensions... */
continue;
}
continue;
}
continue;
}
"<name>%s</name>\n"
"<id>org.inkscape.input.gdkpixbuf.%s</id>\n"
"<param name='link' type='optiongroup' appearance='full' _gui-text='" N_("Link or embed image:") "' >\n"
"</param>\n"
"<_param name='help' type='description'>" N_("Embed results in stand-alone, larger SVG files. Link references a file outside this SVG document and all files must be moved together.") "</_param>\n"
"<param name=\"ask\" _gui-description='" N_("Hide the dialog next time and always apply the same action.") "' gui-text=\"" N_("Don't ask again") "\" type=\"boolean\" >false</param>\n"
"<input>\n"
"<extension>.%s</extension>\n"
"<mimetype>%s</mimetype>\n"
"<filetypename>%s (*.%s)</filetypename>\n"
"<filetypetooltip>%s</filetypetooltip>\n"
"</input>\n"
"</inkscape-extension>",
extensions[i],
extensions[i],
mimetypes[j],
name,
extensions[i],
);
}}
}
}
} } } /* namespace Inkscape, Extension, Implementation */
/*
Local Variables:
mode:c++
c-file-style:"stroustrup"
c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
indent-tabs-mode:nil
fill-column:99
End:
*/
// vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:fileencoding=utf-8:textwidth=99 :