Code

Extensions. Consistency fix and UI improvements (internal extensions and filters).
[inkscape.git] / src / extension / internal / bitmap / implode.cpp
1 /*
2  * Copyright (C) 2007 Authors:
3  *   Christopher Brown <audiere@gmail.com>
4  *   Ted Gould <ted@gould.cx>
5  *   
6  * Released under GNU GPL, read the file 'COPYING' for more information
7  */
9 #include "extension/effect.h"
10 #include "extension/system.h"
12 #include "implode.h"
14 namespace Inkscape {
15 namespace Extension {
16 namespace Internal {
17 namespace Bitmap {
18         
19 void
20 Implode::applyEffect(Magick::Image* image) {
21         image->implode(_factor);
22 }
24 void
25 Implode::refreshParameters(Inkscape::Extension::Effect* module) {
26         _factor = module->get_param_float("factor");
27 }
29 #include "../clear-n_.h"
31 void
32 Implode::init(void)
33 {
34         Inkscape::Extension::build_from_mem(
35                 "<inkscape-extension xmlns=\"" INKSCAPE_EXTENSION_URI "\">\n"
36                         "<name>" N_("Implode") "</name>\n"
37                         "<id>org.inkscape.effect.bitmap.implode</id>\n"
38                         "<param name=\"factor\" gui-text=\"" N_("Factor:") "\" type=\"float\" min=\"0\" max=\"100\">10</param>\n"
39                         "<effect>\n"
40                                 "<object-type>all</object-type>\n"
41                                 "<effects-menu>\n"
42                                         "<submenu name=\"" N_("Raster") "\" />\n"
43                                 "</effects-menu>\n"
44                                 "<menu-tip>" N_("Implode selected bitmap(s).") "</menu-tip>\n"
45                         "</effect>\n"
46                 "</inkscape-extension>\n", new Implode());
47 }
49 }; /* namespace Bitmap */
50 }; /* namespace Internal */
51 }; /* namespace Extension */
52 }; /* namespace Inkscape */