diff options
| author | Jabier Arraiza Cenoz <jabier.arraiza@marker.es> | 2013-10-19 17:54:15 +0000 |
|---|---|---|
| committer | Jabiertxof <jtx@jtx.marker.es> | 2013-10-19 17:54:15 +0000 |
| commit | caab2746eec05f72330f21a2f2ab4ef604ef6eab (patch) | |
| tree | 7d57a66bc2e2fa3f9604c3d13f2f486b8f317627 /src | |
| parent | Update to trunk (diff) | |
| parent | Fix build errors with clang 3.3 and c++11 enabled. (diff) | |
| download | inkscape-caab2746eec05f72330f21a2f2ab4ef604ef6eab.tar.gz inkscape-caab2746eec05f72330f21a2f2ab4ef604ef6eab.zip | |
Update to trunk
(bzr r11950.1.186)
Diffstat (limited to 'src')
| -rw-r--r-- | src/io/uristream.cpp | 44 | ||||
| -rw-r--r-- | src/io/uristream.h | 44 | ||||
| -rw-r--r-- | src/io/xsltstream.cpp | 20 | ||||
| -rw-r--r-- | src/io/xsltstream.h | 24 | ||||
| -rw-r--r-- | src/libgdl/gdl-dock-object.h | 2 | ||||
| -rw-r--r-- | src/sp-polygon.cpp | 2 |
6 files changed, 66 insertions, 70 deletions
diff --git a/src/io/uristream.cpp b/src/io/uristream.cpp index 37c13ada0..5d2eb59ee 100644 --- a/src/io/uristream.cpp +++ b/src/io/uristream.cpp @@ -89,7 +89,7 @@ static FILE *fopen_utf8name( char const *utf8name, int mode ) * */ UriInputStream::UriInputStream(Inkscape::URI &source) - throw (StreamException): uri(source) + : uri(source) { //get information from uri char const *schemestr = uri.getScheme(); @@ -130,7 +130,7 @@ UriInputStream::UriInputStream(Inkscape::URI &source) * */ UriInputStream::UriInputStream(FILE *source, Inkscape::URI &uri) - throw (StreamException): uri(uri), + : uri(uri), inf(source), data(0), dataPos(0), @@ -147,7 +147,7 @@ UriInputStream::UriInputStream(FILE *source, Inkscape::URI &uri) /** * */ -UriInputStream::~UriInputStream() throw(StreamException) +UriInputStream::~UriInputStream() { close(); } @@ -157,7 +157,7 @@ UriInputStream::~UriInputStream() throw(StreamException) * this input stream without blocking by the next caller of a method for * this input stream. */ -int UriInputStream::available() throw(StreamException) +int UriInputStream::available() { return 0; } @@ -167,7 +167,7 @@ int UriInputStream::available() throw(StreamException) * Closes this input stream and releases any system resources * associated with the stream. */ -void UriInputStream::close() throw(StreamException) +void UriInputStream::close() { if (closed) return; @@ -194,7 +194,7 @@ void UriInputStream::close() throw(StreamException) /** * Reads the next byte of data from the input stream. -1 if EOF */ -int UriInputStream::get() throw(StreamException) +int UriInputStream::get() { int retVal = -1; if (!closed) @@ -236,7 +236,7 @@ int UriInputStream::get() throw(StreamException) * */ UriReader::UriReader(Inkscape::URI &uri) - throw (StreamException) + { inputStream = new UriInputStream(uri); } @@ -244,7 +244,7 @@ UriReader::UriReader(Inkscape::URI &uri) /** * */ -UriReader::~UriReader() throw (StreamException) +UriReader::~UriReader() { delete inputStream; } @@ -252,7 +252,7 @@ UriReader::~UriReader() throw (StreamException) /** * */ -int UriReader::available() throw(StreamException) +int UriReader::available() { return inputStream->available(); } @@ -260,7 +260,7 @@ int UriReader::available() throw(StreamException) /** * */ -void UriReader::close() throw(StreamException) +void UriReader::close() { inputStream->close(); } @@ -268,7 +268,7 @@ void UriReader::close() throw(StreamException) /** * */ -gunichar UriReader::get() throw(StreamException) +gunichar UriReader::get() { gunichar ch = (gunichar)inputStream->get(); return ch; @@ -283,7 +283,7 @@ gunichar UriReader::get() throw(StreamException) * Temporary kludge */ UriOutputStream::UriOutputStream(FILE* fp, Inkscape::URI &destination) - throw (StreamException): closed(false), + : closed(false), ownsFile(false), outf(fp), uri(destination), @@ -299,7 +299,7 @@ UriOutputStream::UriOutputStream(FILE* fp, Inkscape::URI &destination) * */ UriOutputStream::UriOutputStream(Inkscape::URI &destination) - throw (StreamException): closed(false), + : closed(false), ownsFile(true), outf(NULL), uri(destination), @@ -340,7 +340,7 @@ UriOutputStream::UriOutputStream(Inkscape::URI &destination) /** * */ -UriOutputStream::~UriOutputStream() throw(StreamException) +UriOutputStream::~UriOutputStream() { close(); } @@ -349,7 +349,7 @@ UriOutputStream::~UriOutputStream() throw(StreamException) * Closes this output stream and releases any system resources * associated with this stream. */ -void UriOutputStream::close() throw(StreamException) +void UriOutputStream::close() { if (closed) return; @@ -378,7 +378,7 @@ void UriOutputStream::close() throw(StreamException) * Flushes this output stream and forces any buffered output * bytes to be written out. */ -void UriOutputStream::flush() throw(StreamException) +void UriOutputStream::flush() { if (closed) return; @@ -402,7 +402,7 @@ void UriOutputStream::flush() throw(StreamException) /** * Writes the specified byte to this output stream. */ -int UriOutputStream::put(gunichar ch) throw(StreamException) +int UriOutputStream::put(gunichar ch) { if (closed) return -1; @@ -436,7 +436,7 @@ int UriOutputStream::put(gunichar ch) throw(StreamException) * */ UriWriter::UriWriter(Inkscape::URI &uri) - throw (StreamException) + { outputStream = new UriOutputStream(uri); } @@ -444,7 +444,7 @@ UriWriter::UriWriter(Inkscape::URI &uri) /** * */ -UriWriter::~UriWriter() throw (StreamException) +UriWriter::~UriWriter() { delete outputStream; } @@ -452,7 +452,7 @@ UriWriter::~UriWriter() throw (StreamException) /** * */ -void UriWriter::close() throw(StreamException) +void UriWriter::close() { outputStream->close(); } @@ -460,7 +460,7 @@ void UriWriter::close() throw(StreamException) /** * */ -void UriWriter::flush() throw(StreamException) +void UriWriter::flush() { outputStream->flush(); } @@ -468,7 +468,7 @@ void UriWriter::flush() throw(StreamException) /** * */ -void UriWriter::put(gunichar ch) throw(StreamException) +void UriWriter::put(gunichar ch) { outputStream->put(ch); } diff --git a/src/io/uristream.h b/src/io/uristream.h index 3080519de..92fc0f76f 100644 --- a/src/io/uristream.h +++ b/src/io/uristream.h @@ -37,17 +37,17 @@ class UriInputStream : public InputStream { public: - UriInputStream(FILE *source, Inkscape::URI &uri) throw(StreamException); + UriInputStream(FILE *source, Inkscape::URI &uri); - UriInputStream(Inkscape::URI &source) throw(StreamException); + UriInputStream(Inkscape::URI &source); - virtual ~UriInputStream() throw(StreamException); + virtual ~UriInputStream(); - virtual int available() throw(StreamException); + virtual int available(); - virtual void close() throw(StreamException); + virtual void close(); - virtual int get() throw(StreamException); + virtual int get(); private: Inkscape::URI &uri; @@ -73,15 +73,15 @@ class UriReader : public BasicReader public: - UriReader(Inkscape::URI &source) throw(StreamException); + UriReader(Inkscape::URI &source); - virtual ~UriReader() throw(StreamException); + virtual ~UriReader(); - virtual int available() throw(StreamException); + virtual int available(); - virtual void close() throw(StreamException); + virtual void close(); - virtual gunichar get() throw(StreamException); + virtual gunichar get(); private: @@ -105,17 +105,17 @@ class UriOutputStream : public OutputStream public: - UriOutputStream(FILE *fp, Inkscape::URI &destination) throw(StreamException); + UriOutputStream(FILE *fp, Inkscape::URI &destination); - UriOutputStream(Inkscape::URI &destination) throw(StreamException); + UriOutputStream(Inkscape::URI &destination); - virtual ~UriOutputStream() throw(StreamException); + virtual ~UriOutputStream(); - virtual void close() throw(StreamException); + virtual void close(); - virtual void flush() throw(StreamException); + virtual void flush(); - virtual int put(gunichar ch) throw(StreamException); + virtual int put(gunichar ch); private: @@ -144,15 +144,15 @@ class UriWriter : public BasicWriter public: - UriWriter(Inkscape::URI &source) throw(StreamException); + UriWriter(Inkscape::URI &source); - virtual ~UriWriter() throw(StreamException); + virtual ~UriWriter(); - virtual void close() throw(StreamException); + virtual void close(); - virtual void flush() throw(StreamException); + virtual void flush(); - virtual void put(gunichar ch) throw(StreamException); + virtual void put(gunichar ch); private: diff --git a/src/io/xsltstream.cpp b/src/io/xsltstream.cpp index 7a6632233..531647769 100644 --- a/src/io/xsltstream.cpp +++ b/src/io/xsltstream.cpp @@ -30,7 +30,7 @@ namespace IO * */ XsltStyleSheet::XsltStyleSheet(InputStream &xsltSource) - throw (StreamException) + : stylesheet(NULL) { if (!read(xsltSource)) { @@ -86,7 +86,6 @@ XsltStyleSheet::~XsltStyleSheet() * */ XsltInputStream::XsltInputStream(InputStream &xmlSource, XsltStyleSheet &sheet) - throw (StreamException) : BasicInputStream(xmlSource), stylesheet(sheet) { //Load the data @@ -110,7 +109,7 @@ XsltInputStream::XsltInputStream(InputStream &xmlSource, XsltStyleSheet &sheet) /** * */ -XsltInputStream::~XsltInputStream() throw (StreamException) +XsltInputStream::~XsltInputStream() { xmlFree(outbuf); } @@ -120,7 +119,7 @@ XsltInputStream::~XsltInputStream() throw (StreamException) * this input stream without blocking by the next caller of a method for * this input stream. */ -int XsltInputStream::available() throw (StreamException) +int XsltInputStream::available() { return outsize - outpos; } @@ -130,7 +129,7 @@ int XsltInputStream::available() throw (StreamException) * Closes this input stream and releases any system resources * associated with the stream. */ -void XsltInputStream::close() throw (StreamException) +void XsltInputStream::close() { closed = true; } @@ -138,7 +137,7 @@ void XsltInputStream::close() throw (StreamException) /** * Reads the next byte of data from the input stream. -1 if EOF */ -int XsltInputStream::get() throw (StreamException) +int XsltInputStream::get() { if (closed) return -1; @@ -161,7 +160,6 @@ int XsltInputStream::get() throw (StreamException) * */ XsltOutputStream::XsltOutputStream(OutputStream &dest, XsltStyleSheet &sheet) - throw (StreamException) : BasicOutputStream(dest), stylesheet(sheet) { flushed = false; @@ -170,7 +168,7 @@ XsltOutputStream::XsltOutputStream(OutputStream &dest, XsltStyleSheet &sheet) /** * */ -XsltOutputStream::~XsltOutputStream() throw (StreamException) +XsltOutputStream::~XsltOutputStream() { //do not automatically close } @@ -179,7 +177,7 @@ XsltOutputStream::~XsltOutputStream() throw (StreamException) * Closes this output stream and releases any system resources * associated with this stream. */ -void XsltOutputStream::close() throw (StreamException) +void XsltOutputStream::close() { flush(); destination.close(); @@ -189,7 +187,7 @@ void XsltOutputStream::close() throw (StreamException) * Flushes this output stream and forces any buffered output * bytes to be written out. */ -void XsltOutputStream::flush() throw (StreamException) +void XsltOutputStream::flush() { if (flushed) { @@ -230,7 +228,7 @@ void XsltOutputStream::flush() throw (StreamException) /** * Writes the specified byte to this output stream. */ -int XsltOutputStream::put(gunichar ch) throw (StreamException) +int XsltOutputStream::put(gunichar ch) { outbuf.push_back(ch); return 1; diff --git a/src/io/xsltstream.h b/src/io/xsltstream.h index 31ee89e10..105e6207a 100644 --- a/src/io/xsltstream.h +++ b/src/io/xsltstream.h @@ -39,7 +39,7 @@ public: /** * Constructor with loading */ - XsltStyleSheet(InputStream &source) throw (StreamException); + XsltStyleSheet(InputStream &source); /** * Simple constructor, no loading @@ -74,16 +74,15 @@ class XsltInputStream : public BasicInputStream public: - XsltInputStream(InputStream &xmlSource, XsltStyleSheet &stylesheet) - throw (StreamException); + XsltInputStream(InputStream &xmlSource, XsltStyleSheet &stylesheet); - virtual ~XsltInputStream() throw (StreamException); + virtual ~XsltInputStream(); - virtual int available() throw (StreamException); + virtual int available(); - virtual void close() throw (StreamException); + virtual void close(); - virtual int get() throw (StreamException); + virtual int get(); private: @@ -111,16 +110,15 @@ class XsltOutputStream : public BasicOutputStream public: - XsltOutputStream(OutputStream &destination, XsltStyleSheet &stylesheet) - throw (StreamException); + XsltOutputStream(OutputStream &destination, XsltStyleSheet &stylesheet); - virtual ~XsltOutputStream() throw (StreamException); + virtual ~XsltOutputStream(); - virtual void close() throw (StreamException); + virtual void close(); - virtual void flush() throw (StreamException); + virtual void flush(); - virtual int put(gunichar ch) throw (StreamException); + virtual int put(gunichar ch); private: diff --git a/src/libgdl/gdl-dock-object.h b/src/libgdl/gdl-dock-object.h index eed66e97a..f8b192f35 100644 --- a/src/libgdl/gdl-dock-object.h +++ b/src/libgdl/gdl-dock-object.h @@ -207,7 +207,7 @@ GType gdl_dock_object_set_type_for_nick (const gchar *nick, G_STMT_START { \ g_log (G_LOG_DOMAIN, \ G_LOG_LEVEL_DEBUG, \ - "%s:%d (%s) %s [%p %d%s:%d]: "format, \ + "%s:%d (%s) %s [%p %d%s:%d]: " format, \ __FILE__, \ __LINE__, \ __PRETTY_FUNCTION__, \ diff --git a/src/sp-polygon.cpp b/src/sp-polygon.cpp index 983a738ce..a5ddd653a 100644 --- a/src/sp-polygon.cpp +++ b/src/sp-polygon.cpp @@ -98,7 +98,7 @@ static gboolean polygon_get_value(gchar const **p, gdouble *v) (*p)++; } - if (*p == '\0') { + if (**p == '\0') { return false; } |
