diff options
| author | Jon A. Cruz <jon@joncruz.org> | 2011-10-23 07:51:53 +0000 |
|---|---|---|
| committer | Jon A. Cruz <jon@joncruz.org> | 2011-10-23 07:51:53 +0000 |
| commit | 124c1161ebfbc8668c373395b9f6573430cd25ab (patch) | |
| tree | 486d9ceca9eb70b6c8ecd56dbb7f764d419580d7 /src | |
| parent | Removed use of 'void *' as attemtp to limit access to internals. (diff) | |
| download | inkscape-124c1161ebfbc8668c373395b9f6573430cd25ab.tar.gz inkscape-124c1161ebfbc8668c373395b9f6573430cd25ab.zip | |
Fixed unused parameter warnings. Due to being included a few places, this cleans up several hundred warnings.
(bzr r10690)
Diffstat (limited to 'src')
| -rw-r--r-- | src/extension/implementation/implementation.h | 160 |
1 files changed, 87 insertions, 73 deletions
diff --git a/src/extension/implementation/implementation.h b/src/extension/implementation/implementation.h index 443046846..32cc37402 100644 --- a/src/extension/implementation/implementation.h +++ b/src/extension/implementation/implementation.h @@ -41,9 +41,14 @@ class Print; namespace Implementation { -/** \brief A cache for the document and this implementation */ +/** + * A cache for the document and this implementation. + */ class ImplementationDocumentCache { - /** \brief The document that this instance is working on */ + + /** + * The document that this instance is working on. + */ Inkscape::UI::View::View * _view; public: ImplementationDocumentCache (Inkscape::UI::View::View * view) : @@ -62,113 +67,122 @@ public: */ class Implementation { public: - /* ----- Constructor / destructor ----- */ + // ----- Constructor / destructor ----- Implementation() {} virtual ~Implementation() {} - /* ----- Basic functions for all Extension ----- */ - virtual bool load(Inkscape::Extension::Extension *module) { return true; } + // ----- Basic functions for all Extension ----- + virtual bool load(Inkscape::Extension::Extension * /*module*/) { return true; } + + virtual void unload(Inkscape::Extension::Extension * /*module*/) {} - virtual void unload(Inkscape::Extension::Extension *module) {} - /** \brief Create a new document cache object + /** + * Create a new document cache object. * This function just returns \c NULL. Subclasses are likely * to reimplement it to do something useful. - * \param ext The extension that is referencing us - * \param doc The document to create the cache of - * \return A new document cache that is valid as long as the document - * is not changed. */ - virtual ImplementationDocumentCache * newDocCache (Inkscape::Extension::Extension * ext, Inkscape::UI::View::View * doc) { return NULL; } + * @param ext The extension that is referencing us + * @param doc The document to create the cache of + * @return A new document cache that is valid as long as the document + * is not changed. + */ + virtual ImplementationDocumentCache * newDocCache (Inkscape::Extension::Extension * /*ext*/, Inkscape::UI::View::View * /*doc*/) { return NULL; } /** Verify any dependencies. */ - virtual bool check(Inkscape::Extension::Extension *module) { return true; } + virtual bool check(Inkscape::Extension::Extension * /*module*/) { return true; } virtual bool cancelProcessing () { return true; } virtual void commitDocument () {} - /* ----- Input functions ----- */ + // ----- Input functions ----- /** Find out information about the file. */ virtual Gtk::Widget *prefs_input(Inkscape::Extension::Input *module, gchar const *filename); - virtual SPDocument *open(Inkscape::Extension::Input *module, - gchar const *filename) { return NULL; } + virtual SPDocument *open(Inkscape::Extension::Input * /*module*/, + gchar const * /*filename*/) { return NULL; } - /* ----- Output functions ----- */ + // ----- Output functions ----- /** Find out information about the file. */ virtual Gtk::Widget *prefs_output(Inkscape::Extension::Output *module); - virtual void save(Inkscape::Extension::Output *module, SPDocument *doc, gchar const *filename) {} + virtual void save(Inkscape::Extension::Output * /*module*/, SPDocument * /*doc*/, gchar const * /*filename*/) {} - /* ----- Effect functions ----- */ + // ----- Effect functions ----- /** Find out information about the file. */ virtual Gtk::Widget * prefs_effect(Inkscape::Extension::Effect *module, Inkscape::UI::View::View *view, sigc::signal<void> *changeSignal, ImplementationDocumentCache *docCache); - virtual void effect(Inkscape::Extension::Effect *module, - Inkscape::UI::View::View *document, - ImplementationDocumentCache *docCache) {} - - /* ----- Print functions ----- */ - virtual unsigned setup(Inkscape::Extension::Print *module) { return 0; } - virtual unsigned set_preview(Inkscape::Extension::Print *module) { return 0; } - - virtual unsigned begin(Inkscape::Extension::Print *module, - SPDocument *doc) { return 0; } - virtual unsigned finish(Inkscape::Extension::Print *module) { return 0; } - /** \brief Tell the printing engine whether text should be text or path + virtual void effect(Inkscape::Extension::Effect * /*module*/, + Inkscape::UI::View::View * /*document*/, + ImplementationDocumentCache * /*docCache*/) {} + + // ----- Print functions ----- + virtual unsigned setup(Inkscape::Extension::Print * /*module*/) { return 0; } + virtual unsigned set_preview(Inkscape::Extension::Print * /*module*/) { return 0; } + + virtual unsigned begin(Inkscape::Extension::Print * /*module*/, + SPDocument * /*doc*/) { return 0; } + virtual unsigned finish(Inkscape::Extension::Print * /*module*/) { return 0; } + + /** + * Tell the printing engine whether text should be text or path. * Default value is false because most printing engines will support * paths more than they'll support text. (at least they do today) * \retval true Render the text as a path - * \retval false Render text using the text function (above) */ - virtual bool textToPath(Inkscape::Extension::Print *ext) { return false; } - /** \brief Get "fontEmbedded" param, i.e. tell the printing engine whether fonts should be embedded + * \retval false Render text using the text function (above) + */ + virtual bool textToPath(Inkscape::Extension::Print * /*ext*/) { return false; } + + /** + * Get "fontEmbedded" param, i.e. tell the printing engine whether fonts should be embedded. * Only available for Adobe Type 1 fonts in EPS output as of now * \retval true Fonts have to be embedded in the output so that the user might not need * to install fonts to have the interpreter read the document correctly - * \retval false Do not embed fonts */ - virtual bool fontEmbedded(Inkscape::Extension::Print * ext) { return false; } - - /* ----- Rendering methods ----- */ - virtual unsigned bind(Inkscape::Extension::Print *module, - Geom::Affine const &transform, - float opacity) { return 0; } - virtual unsigned release(Inkscape::Extension::Print *module) { return 0; } - virtual unsigned comment(Inkscape::Extension::Print *module, char const *comment) { return 0; } - virtual unsigned fill(Inkscape::Extension::Print *module, - Geom::PathVector const &pathv, - Geom::Affine const &ctm, - SPStyle const *style, - Geom::OptRect const &pbox, - Geom::OptRect const &dbox, - Geom::OptRect const &bbox) { return 0; } - virtual unsigned stroke(Inkscape::Extension::Print *module, - Geom::PathVector const &pathv, - Geom::Affine const &transform, - SPStyle const *style, - Geom::OptRect const &pbox, - Geom::OptRect const &dbox, - Geom::OptRect const &bbox) { return 0; } - virtual unsigned image(Inkscape::Extension::Print *module, - unsigned char *px, - unsigned int w, - unsigned int h, - unsigned int rs, - Geom::Affine const &transform, - SPStyle const *style) { return 0; } - virtual unsigned text(Inkscape::Extension::Print *module, - char const *text, - Geom::Point const &p, - SPStyle const *style) { return 0; } - virtual void processPath(Inkscape::XML::Node * node) {} + * \retval false Do not embed fonts + */ + virtual bool fontEmbedded(Inkscape::Extension::Print * /*ext*/) { return false; } + + // ----- Rendering methods ----- + virtual unsigned bind(Inkscape::Extension::Print * /*module*/, + Geom::Affine const & /*transform*/, + float /*opacity*/) { return 0; } + virtual unsigned release(Inkscape::Extension::Print * /*module*/) { return 0; } + virtual unsigned comment(Inkscape::Extension::Print * /*module*/, char const * /*comment*/) { return 0; } + virtual unsigned fill(Inkscape::Extension::Print * /*module*/, + Geom::PathVector const & /*pathv*/, + Geom::Affine const & /*ctm*/, + SPStyle const * /*style*/, + Geom::OptRect const & /*pbox*/, + Geom::OptRect const & /*dbox*/, + Geom::OptRect const & /*bbox*/) { return 0; } + virtual unsigned stroke(Inkscape::Extension::Print * /*module*/, + Geom::PathVector const & /*pathv*/, + Geom::Affine const & /*transform*/, + SPStyle const * /*style*/, + Geom::OptRect const & /*pbox*/, + Geom::OptRect const & /*dbox*/, + Geom::OptRect const & /*bbox*/) { return 0; } + virtual unsigned image(Inkscape::Extension::Print * /*module*/, + unsigned char * /*px*/, + unsigned int /*w*/, + unsigned int /*h*/, + unsigned int /*rs*/, + Geom::Affine const & /*transform*/, + SPStyle const * /*style*/) { return 0; } + virtual unsigned text(Inkscape::Extension::Print * /*module*/, + char const * /*text*/, + Geom::Point const & /*p*/, + SPStyle const * /*style*/) { return 0; } + virtual void processPath(Inkscape::XML::Node * /*node*/) {} }; -} /* namespace Implementation */ -} /* namespace Extension */ -} /* namespace Inkscape */ +} // namespace Implementation +} // namespace Extension +} // namespace Inkscape -#endif /* __INKSCAPE_EXTENSION_IMPLEMENTATION_H__ */ +#endif // __INKSCAPE_EXTENSION_IMPLEMENTATION_H__ /* Local Variables: |
