From: johnce Date: Wed, 5 Aug 2009 06:05:12 +0000 (+0000) Subject: SPDocument->Document X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=9723f5118527e9cf512ccf5a6d8b064fa35feb7f;p=inkscape.git SPDocument->Document --- diff --git a/src/application/editor.h b/src/application/editor.h index 4545022b8..0886555e9 100644 --- a/src/application/editor.h +++ b/src/application/editor.h @@ -22,7 +22,7 @@ #include "app-prototype.h" class SPDesktop; -class SPDocument; +class Document; class SPEventContext; namespace Inkscape { @@ -52,7 +52,7 @@ public: void refreshDisplay(); void exit(); - bool lastViewOfDocument(SPDocument* doc, SPDesktop* view) const; + bool lastViewOfDocument(Document* doc, SPDesktop* view) const; bool addView(SPDesktop* view); bool deleteView(SPDesktop* view); @@ -60,16 +60,16 @@ public: static Inkscape::XML::Document *getPreferences(); static SPDesktop* getActiveDesktop(); static bool isDesktopActive (SPDesktop* dt) { return getActiveDesktop()==dt; } - static SPDesktop* createDesktop (SPDocument* doc); + static SPDesktop* createDesktop (Document* doc); static void addDesktop (SPDesktop* dt); static void removeDesktop (SPDesktop* dt); static void activateDesktop (SPDesktop* dt); static void reactivateDesktop (SPDesktop* dt); static bool isDuplicatedView (SPDesktop* dt); - static SPDocument* getActiveDocument(); - static void addDocument (SPDocument* doc); - static void removeDocument (SPDocument* doc); + static Document* getActiveDocument(); + static void addDocument (Document* doc); + static void removeDocument (Document* doc); static void selectionModified (Inkscape::Selection*, guint); static void selectionChanged (Inkscape::Selection*); @@ -96,7 +96,7 @@ protected: Editor(Editor const &); Editor& operator=(Editor const &); - std::multiset _document_set; + std::multiset _document_set; GSList *_documents; GSList *_desktops; gchar *_argv0; diff --git a/src/display/canvas-axonomgrid.h b/src/display/canvas-axonomgrid.h index e36804d7c..b4a27c873 100644 --- a/src/display/canvas-axonomgrid.h +++ b/src/display/canvas-axonomgrid.h @@ -31,7 +31,7 @@ namespace Inkscape { class CanvasAxonomGrid : public CanvasGrid { public: - CanvasAxonomGrid(SPNamedView * nv, Inkscape::XML::Node * in_repr, SPDocument * in_doc); + CanvasAxonomGrid(SPNamedView * nv, Inkscape::XML::Node * in_repr, Document * in_doc); virtual ~CanvasAxonomGrid(); void Update (Geom::Matrix const &affine, unsigned int flags); diff --git a/src/display/canvas-grid.h b/src/display/canvas-grid.h index 58cfbf735..058f88ef8 100644 --- a/src/display/canvas-grid.h +++ b/src/display/canvas-grid.h @@ -26,7 +26,7 @@ struct SPDesktop; struct SPNamedView; -class SPDocument; +class Document; namespace Inkscape { @@ -73,8 +73,8 @@ public: static GridType getGridTypeFromSVGName(const char * typestr); static GridType getGridTypeFromName(const char * typestr); - static CanvasGrid* NewGrid(SPNamedView * nv, Inkscape::XML::Node * repr, SPDocument *doc, GridType gridtype); - static void writeNewGridToRepr(Inkscape::XML::Node * repr, SPDocument * doc, GridType gridtype); + static CanvasGrid* NewGrid(SPNamedView * nv, Inkscape::XML::Node * repr, Document *doc, GridType gridtype); + static void writeNewGridToRepr(Inkscape::XML::Node * repr, Document * doc, GridType gridtype); GridCanvasItem * createCanvasItem(SPDesktop * desktop); @@ -94,7 +94,7 @@ public: SPUnit const* gridunit; Inkscape::XML::Node * repr; - SPDocument *doc; + Document *doc; Inkscape::Snapper* snapper; @@ -104,7 +104,7 @@ public: bool isEnabled(); protected: - CanvasGrid(SPNamedView * nv, Inkscape::XML::Node * in_repr, SPDocument *in_doc, GridType type); + CanvasGrid(SPNamedView * nv, Inkscape::XML::Node * in_repr, Document *in_doc, GridType type); virtual Gtk::Widget * newSpecificWidget() = 0; @@ -125,7 +125,7 @@ private: class CanvasXYGrid : public CanvasGrid { public: - CanvasXYGrid(SPNamedView * nv, Inkscape::XML::Node * in_repr, SPDocument * in_doc); + CanvasXYGrid(SPNamedView * nv, Inkscape::XML::Node * in_repr, Document * in_doc); virtual ~CanvasXYGrid(); void Update (Geom::Matrix const &affine, unsigned int flags); diff --git a/src/display/nr-filter-image.h b/src/display/nr-filter-image.h index f3565ef9f..6fbc5d7eb 100644 --- a/src/display/nr-filter-image.h +++ b/src/display/nr-filter-image.h @@ -29,14 +29,14 @@ public: virtual int render(FilterSlot &slot, FilterUnits const &units); virtual FilterTraits get_input_traits(); - void set_document( SPDocument *document ); + void set_document( Document *document ); void set_href(const gchar *href); void set_region(SVGLength x, SVGLength y, SVGLength width, SVGLength height); bool from_element; SPItem* SVGElem; private: - SPDocument *document; + Document *document; gchar *feImageHref; guint8* image_pixbuf; Glib::RefPtr image; diff --git a/src/extension/effect.h b/src/extension/effect.h index c02ce542b..637d29c5c 100644 --- a/src/extension/effect.h +++ b/src/extension/effect.h @@ -21,7 +21,7 @@ #include "prefdialog.h" #include "extension.h" -struct SPDocument; +struct Document; namespace Inkscape { namespace UI { diff --git a/src/extension/extension.h b/src/extension/extension.h index 48ca86cf7..8dcd1b393 100644 --- a/src/extension/extension.h +++ b/src/extension/extension.h @@ -72,7 +72,7 @@ #define INKSCAPE_EXTENSION_NS_NC "extension" #define INKSCAPE_EXTENSION_NS "extension:" -struct SPDocument; +struct Document; namespace Inkscape { namespace Extension { @@ -173,42 +173,42 @@ private: #endif public: bool get_param_bool (const gchar * name, - const SPDocument * doc = NULL, + const Document * doc = NULL, const Inkscape::XML::Node * node = NULL); int get_param_int (const gchar * name, - const SPDocument * doc = NULL, + const Document * doc = NULL, const Inkscape::XML::Node * node = NULL); float get_param_float (const gchar * name, - const SPDocument * doc = NULL, + const Document * doc = NULL, const Inkscape::XML::Node * node = NULL); const gchar * get_param_string (const gchar * name, - const SPDocument * doc = NULL, + const Document * doc = NULL, const Inkscape::XML::Node * node = NULL); guint32 get_param_color (const gchar * name, - const SPDocument * doc = NULL, + const Document * doc = NULL, const Inkscape::XML::Node * node = NULL); const gchar * get_param_enum (const gchar * name, - const SPDocument * doc = NULL, + const Document * doc = NULL, const Inkscape::XML::Node * node = NULL); bool set_param_bool (const gchar * name, bool value, - SPDocument * doc = NULL, + Document * doc = NULL, Inkscape::XML::Node * node = NULL); int set_param_int (const gchar * name, int value, - SPDocument * doc = NULL, + Document * doc = NULL, Inkscape::XML::Node * node = NULL); float set_param_float (const gchar * name, float value, - SPDocument * doc = NULL, + Document * doc = NULL, Inkscape::XML::Node * node = NULL); const gchar * set_param_string (const gchar * name, const gchar * value, - SPDocument * doc = NULL, + Document * doc = NULL, Inkscape::XML::Node * node = NULL); guint32 set_param_color (const gchar * name, guint32 color, - SPDocument * doc = NULL, + Document * doc = NULL, Inkscape::XML::Node * node = NULL); /* Error file handling */ @@ -217,7 +217,7 @@ public: static void error_file_close (void); public: - Gtk::Widget * autogui (SPDocument * doc, Inkscape::XML::Node * node, sigc::signal * changeSignal = NULL); + Gtk::Widget * autogui (Document * doc, Inkscape::XML::Node * node, sigc::signal * changeSignal = NULL); void paramListString (std::list & retlist); /* Extension editor dialog stuff */ diff --git a/src/extension/input.h b/src/extension/input.h index 55d807ce2..d2aac9376 100644 --- a/src/extension/input.h +++ b/src/extension/input.h @@ -37,7 +37,7 @@ public: Implementation::Implementation * in_imp); virtual ~Input (void); virtual bool check (void); - SPDocument * open (gchar const *uri); + Document * open (gchar const *uri); gchar * get_mimetype (void); gchar * get_extension (void); gchar * get_filetypename (void); diff --git a/src/extension/output.h b/src/extension/output.h index b52a96211..455b4a8ae 100644 --- a/src/extension/output.h +++ b/src/extension/output.h @@ -15,7 +15,7 @@ #include #include "extension.h" -struct SPDocument; +struct Document; namespace Inkscape { namespace Extension { @@ -36,7 +36,7 @@ public: Implementation::Implementation * in_imp); virtual ~Output (void); virtual bool check (void); - void save (SPDocument *doc, + void save (Document *doc, gchar const *uri); bool prefs (void); gchar * get_mimetype(void); diff --git a/src/extension/patheffect.h b/src/extension/patheffect.h index 0c00ae093..7ad875048 100644 --- a/src/extension/patheffect.h +++ b/src/extension/patheffect.h @@ -22,10 +22,10 @@ public: PathEffect (Inkscape::XML::Node * in_repr, Implementation::Implementation * in_imp); virtual ~PathEffect (void); - void processPath (SPDocument * doc, + void processPath (Document * doc, Inkscape::XML::Node * path, Inkscape::XML::Node * def); - static void processPathEffects (SPDocument * doc, + static void processPathEffects (Document * doc, Inkscape::XML::Node * path); }; /* PathEffect */ diff --git a/src/extension/print.h b/src/extension/print.h index 8ae71b8e6..3240942d7 100644 --- a/src/extension/print.h +++ b/src/extension/print.h @@ -36,7 +36,7 @@ public: unsigned int setup (void); unsigned int set_preview (void); - unsigned int begin (SPDocument *doc); + unsigned int begin (Document *doc); unsigned int finish (void); /* Rendering methods */ diff --git a/src/extension/system.h b/src/extension/system.h index 6c23b2f0d..ada5f799c 100644 --- a/src/extension/system.h +++ b/src/extension/system.h @@ -21,8 +21,8 @@ namespace Inkscape { namespace Extension { -SPDocument *open(Extension *key, gchar const *filename); -void save(Extension *key, SPDocument *doc, gchar const *filename, +Document *open(Extension *key, gchar const *filename); +void save(Extension *key, Document *doc, gchar const *filename, bool setextension, bool check_overwrite, bool official); Print *get_print(gchar const *key); Extension *build_from_file(gchar const *filename); diff --git a/src/filters/image.h b/src/filters/image.h index 7207918e1..74352db80 100644 --- a/src/filters/image.h +++ b/src/filters/image.h @@ -27,7 +27,7 @@ struct SPFeImage : public SPFilterPrimitive { /** IMAGE ATTRIBUTES HERE */ gchar *href; SVGLength x, y, height, width; - SPDocument *document; + Document *document; bool from_element; SPItem* SVGElem; Inkscape::URIReference* SVGElemRef; diff --git a/src/helper/pixbuf-ops.h b/src/helper/pixbuf-ops.h index a985be297..de6a80181 100644 --- a/src/helper/pixbuf-ops.h +++ b/src/helper/pixbuf-ops.h @@ -14,12 +14,12 @@ #include -struct SPDocument; +struct Document; -bool sp_export_jpg_file (SPDocument *doc, gchar const *filename, double x0, double y0, double x1, double y1, +bool sp_export_jpg_file (Document *doc, gchar const *filename, double x0, double y0, double x1, double y1, unsigned int width, unsigned int height, double xdpi, double ydpi, unsigned long bgcolor, double quality, GSList *items_only = NULL); -GdkPixbuf* sp_generate_internal_bitmap(SPDocument *doc, gchar const *filename, +GdkPixbuf* sp_generate_internal_bitmap(Document *doc, gchar const *filename, double x0, double y0, double x1, double y1, unsigned width, unsigned height, double xdpi, double ydpi, unsigned long bgcolor, GSList *items_only = NULL); diff --git a/src/helper/png-write.h b/src/helper/png-write.h index 83321aa4e..f7e372e0b 100644 --- a/src/helper/png-write.h +++ b/src/helper/png-write.h @@ -14,14 +14,14 @@ #include #include <2geom/forward.h> -struct SPDocument; +struct Document; -bool sp_export_png_file (SPDocument *doc, gchar const *filename, +bool sp_export_png_file (Document *doc, gchar const *filename, double x0, double y0, double x1, double y1, unsigned long int width, unsigned long int height, double xdpi, double ydpi, unsigned long bgcolor, unsigned int (*status) (float, void *), void *data, bool force_overwrite = false, GSList *items_only = NULL); -bool sp_export_png_file (SPDocument *doc, gchar const *filename, +bool sp_export_png_file (Document *doc, gchar const *filename, Geom::Rect const &area, unsigned long int width, unsigned long int height, double xdpi, double ydpi, unsigned long bgcolor, diff --git a/src/live_effects/lpeobject.h b/src/live_effects/lpeobject.h index dc631a5c1..842b84c45 100644 --- a/src/live_effects/lpeobject.h +++ b/src/live_effects/lpeobject.h @@ -49,7 +49,7 @@ public: private: static void livepatheffect_class_init(LivePathEffectObjectClass *klass); static void livepatheffect_init(LivePathEffectObject *stop); - static void livepatheffect_build(SPObject *object, SPDocument *document, Inkscape::XML::Node *repr); + static void livepatheffect_build(SPObject *object, Document *document, Inkscape::XML::Node *repr); static void livepatheffect_release(SPObject *object); static void livepatheffect_set(SPObject *object, unsigned key, gchar const *value); static Inkscape::XML::Node *livepatheffect_write(SPObject *object, Inkscape::XML::Document *doc, Inkscape::XML::Node *repr, guint flags); diff --git a/src/ui/clipboard.h b/src/ui/clipboard.h index 54c05ac0d..467888ed7 100644 --- a/src/ui/clipboard.h +++ b/src/ui/clipboard.h @@ -31,7 +31,7 @@ namespace UI { * @brief System-wide clipboard manager * * ClipboardManager takes care of manipulating the system clipboard in response - * to user actions. It holds a complete SPDocument as the contents. This document + * to user actions. It holds a complete Document as the contents. This document * is exported using output extensions when other applications request data. * Copying to another instance of Inkscape is special-cased, because of the extra * data required (i.e. style, size, Live Path Effects parameters, etc.)