Code

fix 1432089: stroke is not drawn not only when it's not set but also when it's too...
[inkscape.git] / src / dom / svglsimpl.h
1 /*
2  * Copyright (c) 2004 World Wide Web Consortium,
3  *
4  * (Massachusetts Institute of Technology, European Research Consortium for
5  * Informatics and Mathematics, Keio University). All Rights Reserved. This
6  * work is distributed under the W3C(r) Software License [1] in the hope that
7  * it will be useful, but WITHOUT ANY WARRANTY; without even the implied
8  * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
9  *
10  * [1] http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231
11  */
13 // File: http://www.w3.org/TR/2004/REC-DOM-Level-3-LS-20040407/ls.idl
15 #ifndef __SVGLSIMPL_H__
16 #define __SVGLSIMPL_H__
18 #include "lsimpl.h"
19 #include "svgparser.h"
22 namespace org {
23 namespace w3c {
24 namespace dom {
25 namespace ls  {
30 /*#########################################################################
31 ## SVGLSParser
32 #########################################################################*/
34 /**
35  *
36  */
37 class SVGLSParserImpl : virtual public LSParserImpl
38 {
39 public:
41     /**
42      *
43      */
44     virtual Document *parse(const LSInput &input)
45                             throw(dom::DOMException, LSException);
46                             
49     //##################
50     //# Non-API methods
51     //##################
53     /**
54      *
55      */
56     SVGLSParserImpl()
57         {}
59     /**
60      *
61      */
62     virtual ~SVGLSParserImpl()
63         {}
64     
67     //##################
68     //# Internals
69     //##################
72 protected:
75         
76 };
79 /*#########################################################################
80 ## SVGLSSerializerImpl
81 #########################################################################*/
83 /**
84  *
85  */
86 class SVGLSSerializerImpl : virtual public LSSerializerImpl
87 {
88 public:
90     //##################
91     //# Non-API methods
92     //##################
94     /**
95      *
96      */
97     SVGLSSerializerImpl()
98         {
99         }
101     /**
102      *
103      */
104     virtual ~SVGLSSerializerImpl()
105         {}
109 protected:
111     /**
112      *  Overload me to change behaviour
113      */
114     virtual void writeNode(const Node *nodeArg);
116     
119 };
125 /*#########################################################################
126 ## SVGDOMImplementationLSImpl
127 #########################################################################*/
129 /**
130  *
131  */
132 class SVGDOMImplementationLSImpl : virtual public DOMImplementationLS
134 public:
136     /**
137      *
138      */
139     virtual LSParser &createLSParser(unsigned short mode,
140                                      const DOMString &schemaType)
141                                      throw (dom::DOMException)
142         {
143         SVGLSParserImpl newParser;
144         parser = newParser;
145         return parser;
146         }
149     /**
150      *
151      */
152     virtual LSSerializer &createLSSerializer()
153         {
154         SVGLSSerializerImpl newSerializer;
155         serializer = newSerializer;
156         return serializer;
157         }
160     /**
161      *
162      */
163     virtual LSInput createLSInput()
164         {
165         LSInput input;
166         return input;
167         }
169     /**
170      *
171      */
172     virtual LSOutput createLSOutput()
173         {
174         LSOutput output;
175         return output;
176         }
178     //##################
179     //# Non-API methods
180     //##################
182     /**
183      *
184      */
185     SVGDOMImplementationLSImpl() {}
187     /**
188      *
189      */
190     virtual ~SVGDOMImplementationLSImpl() {}
192 protected:
194     SVGLSParserImpl     parser;
195     SVGLSSerializerImpl serializer;
196 };
204 }  //namespace ls
205 }  //namespace dom
206 }  //namespace w3c
207 }  //namespace org
212 #endif   /* __SVGLSIMPL_H__ */
214 /*#########################################################################
215 ## E N D    O F    F I L E
216 #########################################################################*/