]> git.saurik.com Git - wxWidgets.git/commitdiff
added wxUSE_SVG
authorVadim Zeitlin <vadim@wxwidgets.org>
Wed, 11 Jul 2007 20:52:41 +0000 (20:52 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Wed, 11 Jul 2007 20:52:41 +0000 (20:52 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@47342 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

13 files changed:
configure
configure.in
include/wx/chkconf.h
include/wx/dcsvg.h
include/wx/mac/setup0.h
include/wx/motif/setup0.h
include/wx/msw/setup0.h
include/wx/msw/wince/setup.h
include/wx/os2/setup0.h
include/wx/palmos/setup0.h
include/wx/setup_inc.h
setup.h.in
src/common/dcsvg.cpp

index de7e55e4b320831dba90df13dc10b2f6fd5bc6db..f76cd18461e254511de8f7cd49d0d020cb5cf93e 100755 (executable)
--- a/configure
+++ b/configure
@@ -1,5 +1,5 @@
 #! /bin/sh
-# From configure.in Id: configure.in 47339 2007-07-11 20:03:11Z VZ .
+# From configure.in Id: configure.in 47340 2007-07-11 20:11:37Z VZ .
 # Guess values for system-dependent variables and create Makefiles.
 # Generated by GNU Autoconf 2.59 for wxWidgets 2.9.0.
 #
@@ -1050,6 +1050,7 @@ Optional Features:
   --enable-richtext       use wxRichTextCtrl
   --enable-graphics_ctx   use graphics context 2D drawing API
   --enable-postscript     use wxPostscriptDC device context (default for gtk+)
+  --enable-svg            use wxSVGFileDC device context
   --enable-clipboard      use wxClipboard class
   --enable-dnd            use Drag'n'Drop classes
   --enable-metafile       use win32 metafiles
@@ -9148,6 +9149,61 @@ fi;
 echo "${ECHO_T}$result" >&6
 
 
+          enablestring=
+          defaultval=$wxUSE_ALL_FEATURES
+          if test -z"$defaultval"; then
+              if test x"$enablestring" = xdisable; then
+                  defaultval=yes
+              else
+                  defaultval=no
+              fi
+          fi
+
+          echo "$as_me:$LINENO: checking for --${enablestring:-enable}-svg" >&5
+echo $ECHO_N "checking for --${enablestring:-enable}-svg... $ECHO_C" >&6
+          no_cache=0
+          # Check whether --enable-svg or --disable-svg was given.
+if test "${enable_svg+set}" = set; then
+  enableval="$enable_svg"
+
+                          if test "$enableval" = yes; then
+                            ac_cv_use_svg='wxUSE_SVG=yes'
+                          else
+                            ac_cv_use_svg='wxUSE_SVG=no'
+                          fi
+
+else
+
+                          LINE=`grep "^wxUSE_SVG=" ${wx_arg_cache_file}`
+                          if test "x$LINE" != x ; then
+                            eval "DEFAULT_$LINE"
+                          else
+                            no_cache=1
+                          fi
+
+                          ac_cv_use_svg='wxUSE_SVG=${'DEFAULT_wxUSE_SVG":-$defaultval}"
+
+fi;
+
+          eval "$ac_cv_use_svg"
+          if test "$no_cache" != 1; then
+            echo $ac_cv_use_svg >> ${wx_arg_cache_file}.tmp
+          fi
+
+          if test x"$enablestring" = xdisable; then
+            if test $wxUSE_SVG = yes; then
+              result=no
+            else
+              result=yes
+            fi
+          else
+            result=$wxUSE_SVG
+          fi
+
+          echo "$as_me:$LINENO: result: $result" >&5
+echo "${ECHO_T}$result" >&6
+
+
 
 
           enablestring=
@@ -46514,24 +46570,6 @@ _ACEOF
 fi
 
 
-if test "$wxUSE_POSTSCRIPT" = "yes" ; then
-  cat >>confdefs.h <<\_ACEOF
-#define wxUSE_POSTSCRIPT 1
-_ACEOF
-
-fi
-
-cat >>confdefs.h <<\_ACEOF
-#define wxUSE_AFM_FOR_POSTSCRIPT 1
-_ACEOF
-
-
-cat >>confdefs.h <<\_ACEOF
-#define wxUSE_NORMALIZED_PS_FONTS 1
-_ACEOF
-
-
-
 if test "$wxUSE_CONSTRAINTS" = "yes"; then
     cat >>confdefs.h <<\_ACEOF
 #define wxUSE_CONSTRAINTS 1
@@ -46609,6 +46647,29 @@ _ACEOF
     SAMPLES_SUBDIRS="$SAMPLES_SUBDIRS printing"
 fi
 
+if test "$wxUSE_POSTSCRIPT" = "yes" ; then
+  cat >>confdefs.h <<\_ACEOF
+#define wxUSE_POSTSCRIPT 1
+_ACEOF
+
+fi
+
+cat >>confdefs.h <<\_ACEOF
+#define wxUSE_AFM_FOR_POSTSCRIPT 1
+_ACEOF
+
+
+cat >>confdefs.h <<\_ACEOF
+#define wxUSE_NORMALIZED_PS_FONTS 1
+_ACEOF
+
+
+if test "$wxUSE_SVG" = "yes"; then
+    cat >>confdefs.h <<\_ACEOF
+#define wxUSE_SVG 1
+_ACEOF
+
+fi
 
 
 if test "$wxUSE_METAFILE" = "yes"; then
index 8324825f9f3fa147d986de19dd94759876ceaffe..72e62b0e7ddf182b4eebb0b2380d50f22e329403 100644 (file)
@@ -632,8 +632,9 @@ WX_ARG_FEATURE(logwin,      [  --enable-logwin         use wxLogWindow], wxUSE_L
 WX_ARG_FEATURE(logdialog,   [  --enable-logdialog      use wxLogDialog], wxUSE_LOGDIALOG)
 WX_ARG_FEATURE(webkit,      [  --enable-webkit         use wxWebKitCtrl (Mac)], wxUSE_WEBKIT)
 WX_ARG_FEATURE(richtext,    [  --enable-richtext       use wxRichTextCtrl], wxUSE_RICHTEXT)
-WX_ARG_FEATURE(graphics_ctx, [  --enable-graphics_ctx   use graphics context 2D drawing API], wxUSE_GRAPHICS_CONTEXT)
+WX_ARG_FEATURE(graphics_ctx,[  --enable-graphics_ctx   use graphics context 2D drawing API], wxUSE_GRAPHICS_CONTEXT)
 WX_ARG_FEATURE(postscript,  [  --enable-postscript     use wxPostscriptDC device context (default for gtk+)], wxUSE_POSTSCRIPT)
+WX_ARG_FEATURE(svg,         [  --enable-svg            use wxSVGFileDC device context], wxUSE_SVG)
 
 dnl ---------------------------------------------------------------------------
 dnl IPC &c
@@ -6169,18 +6170,6 @@ if test "$wxUSE_wxUSE_EXPERIMENTAL_PRINTF" = "yes"; then
   AC_DEFINE(wxUSE_EXPERIMENTAL_PRINTF)
 fi
 
-dnl ----------------------------------------------------------------
-dnl Register PostScript options for makefiles and setup.h
-dnl ----------------------------------------------------------------
-
-if test "$wxUSE_POSTSCRIPT" = "yes" ; then
-  AC_DEFINE(wxUSE_POSTSCRIPT)
-fi
-
-AC_DEFINE(wxUSE_AFM_FOR_POSTSCRIPT)
-
-AC_DEFINE(wxUSE_NORMALIZED_PS_FONTS)
-
 dnl ---------------------------------------------------------------------------
 dnl big GUI components: MDI, doc/view, printing, help, ...
 dnl ---------------------------------------------------------------------------
@@ -6236,6 +6225,17 @@ if test "$wxUSE_PRINTING_ARCHITECTURE" = "yes" ; then
     SAMPLES_SUBDIRS="$SAMPLES_SUBDIRS printing"
 fi
 
+if test "$wxUSE_POSTSCRIPT" = "yes" ; then
+  AC_DEFINE(wxUSE_POSTSCRIPT)
+fi
+
+AC_DEFINE(wxUSE_AFM_FOR_POSTSCRIPT)
+
+AC_DEFINE(wxUSE_NORMALIZED_PS_FONTS)
+
+if test "$wxUSE_SVG" = "yes"; then
+    AC_DEFINE(wxUSE_SVG)
+fi
 
 dnl ---------------------------------------------------------------------------
 dnl wxMetafile availability
index 5f6604c5b2b1eadcaa418bf17a0647c9bd7bedff..f05ad703d27ae81173d91de352e25fa8d06b83e6 100644 (file)
 #   endif
 #endif /* wxUSE_SOCKETS */
 
+#if wxUSE_SVG && !wxUSE_STREAMS
+#   ifdef wxABORT_ON_CONFIG_ERROR
+#       error "wxUSE_SVG requires wxUSE_STREAMS"
+#   else
+#       undef wxUSE_SVG
+#       define wxUSE_SVG 0
+#   endif
+#endif /* wxUSE_SVG */
+
 #if !wxUSE_VARIANT
 #   if wxUSE_DATAVIEWCTRL
 #       ifdef wxABORT_ON_CONFIG_ERROR
index 92acc4cdd6701524b489d1db49e434fc89fe7750..9c0a34e6049fbd20f8572b6663517e4411c4567e 100644 (file)
@@ -15,6 +15,8 @@
 #include "wx/string.h"
 #include "wx/dc.h"
 
+#if wxUSE_SVG
+
 #define wxSVGVersion wxT("v0100")
 
 #ifdef __BORLANDC__
@@ -191,4 +193,6 @@ private:
    DECLARE_ABSTRACT_CLASS(wxSVGFileDC)
 };
 
+#endif // wxUSE_SVG
+
 #endif // _WX_DCSVG_H_
index fa3a177a4e4a965c89ac2375c4f3beea24e005a7..3da7d93d0e1d6efec8241b8529cdfc54dddca2f5 100644 (file)
                                 // Include mouse wheel support
 
 // ----------------------------------------------------------------------------
-// postscript support settings
+// wxDC classes for various output formats
 // ----------------------------------------------------------------------------
 
 // Set to 1 for PostScript device context.
 // Set to 1 to use font metric files in GetTextExtent
 #define wxUSE_AFM_FOR_POSTSCRIPT 1
 
+// Set to 1 to compile in support for wxSVGFileDC, a wxDC subclass which allows
+// to create fiels in SVG (Scalable Vector Graphics) format.
+#define wxUSE_SVG 1
+
 // ----------------------------------------------------------------------------
 // database classes
 // ----------------------------------------------------------------------------
index 2707f263153589dbdf67e05e2b058933fd41481d..20494c37cf05354096f825a2642a439b365f2406 100644 (file)
                                 // Include mouse wheel support
 
 // ----------------------------------------------------------------------------
-// postscript support settings
+// wxDC classes for various output formats
 // ----------------------------------------------------------------------------
 
 // Set to 1 for PostScript device context.
 // Set to 1 to use font metric files in GetTextExtent
 #define wxUSE_AFM_FOR_POSTSCRIPT 1
 
+// Set to 1 to compile in support for wxSVGFileDC, a wxDC subclass which allows
+// to create fiels in SVG (Scalable Vector Graphics) format.
+#define wxUSE_SVG 1
+
 // ----------------------------------------------------------------------------
 // database classes
 // ----------------------------------------------------------------------------
index 58c1bec4a239f64de5e0b85a242c58a436a208b6..60ddea641cc21f7c271e590190c426dd41f405be 100644 (file)
                                 // Include mouse wheel support
 
 // ----------------------------------------------------------------------------
-// postscript support settings
+// wxDC classes for various output formats
 // ----------------------------------------------------------------------------
 
 // Set to 1 for PostScript device context.
 // Set to 1 to use font metric files in GetTextExtent
 #define wxUSE_AFM_FOR_POSTSCRIPT 1
 
+// Set to 1 to compile in support for wxSVGFileDC, a wxDC subclass which allows
+// to create fiels in SVG (Scalable Vector Graphics) format.
+#define wxUSE_SVG 1
+
 // ----------------------------------------------------------------------------
 // database classes
 // ----------------------------------------------------------------------------
index 8fa216d987b02420c72352516298602ad293a761..f6ae98ad953a511d477a075828a14cb3c067fa14 100644 (file)
                                 // Include mouse wheel support
 
 // ----------------------------------------------------------------------------
-// postscript support settings
+// wxDC classes for various output formats
 // ----------------------------------------------------------------------------
 
 // Set to 1 for PostScript device context.
 // Set to 1 to use font metric files in GetTextExtent
 #define wxUSE_AFM_FOR_POSTSCRIPT 1
 
+// Set to 1 to compile in support for wxSVGFileDC, a wxDC subclass which allows
+// to create fiels in SVG (Scalable Vector Graphics) format.
+#define wxUSE_SVG 1
+
 // ----------------------------------------------------------------------------
 // database classes
 // ----------------------------------------------------------------------------
index 5a699fdb6d5b2b0a059bc5e606feaa76b2412b66..99492845f3831aa2e81d1d974a100875947ddaa6 100644 (file)
                                 // Include mouse wheel support
 
 // ----------------------------------------------------------------------------
-// postscript support settings
+// wxDC classes for various output formats
 // ----------------------------------------------------------------------------
 
 // Set to 1 for PostScript device context.
 // Set to 1 to use font metric files in GetTextExtent
 #define wxUSE_AFM_FOR_POSTSCRIPT 1
 
+// Set to 1 to compile in support for wxSVGFileDC, a wxDC subclass which allows
+// to create fiels in SVG (Scalable Vector Graphics) format.
+#define wxUSE_SVG 1
+
 // ----------------------------------------------------------------------------
 // database classes
 // ----------------------------------------------------------------------------
index 060ac79131e0a3755b2fd5dc19acb4b7df59640b..743f52daf1a328312ed5a7f777426f7432d16abf 100644 (file)
                                 // Include mouse wheel support
 
 // ----------------------------------------------------------------------------
-// postscript support settings
+// wxDC classes for various output formats
 // ----------------------------------------------------------------------------
 
 // Set to 1 for PostScript device context.
 // Set to 1 to use font metric files in GetTextExtent
 #define wxUSE_AFM_FOR_POSTSCRIPT 1
 
+// Set to 1 to compile in support for wxSVGFileDC, a wxDC subclass which allows
+// to create fiels in SVG (Scalable Vector Graphics) format.
+#define wxUSE_SVG 1
+
 // ----------------------------------------------------------------------------
 // database classes
 // ----------------------------------------------------------------------------
index e469c8dd275eb5031eb8f56c0216019db1a9a700..2caa6b01083825adcbaa358cbd4339e4b31a193b 100644 (file)
                                 // Include mouse wheel support
 
 // ----------------------------------------------------------------------------
-// postscript support settings
+// wxDC classes for various output formats
 // ----------------------------------------------------------------------------
 
 // Set to 1 for PostScript device context.
 // Set to 1 to use font metric files in GetTextExtent
 #define wxUSE_AFM_FOR_POSTSCRIPT 1
 
+// Set to 1 to compile in support for wxSVGFileDC, a wxDC subclass which allows
+// to create fiels in SVG (Scalable Vector Graphics) format.
+#define wxUSE_SVG 1
+
 // ----------------------------------------------------------------------------
 // database classes
 // ----------------------------------------------------------------------------
index dc1e752296b786c560cc2042f4c586cd5148f65a..7cee7c7915131ad532bf74cd65de2d7a006d4d05 100644 (file)
 
 #define wxUSE_AFM_FOR_POSTSCRIPT 0
 
+#define wxUSE_SVG 0
+
 
 #define wxUSE_ODBC          0
 
index ab2302cf7fe1248c247225d8f8775bc4ab6a3425..ad0f6426cc8e28a7cec5f5fdad8b6d371db81acd 100644 (file)
@@ -15,6 +15,8 @@
 #pragma hdrstop
 #endif
 
+#if wxUSE_SVG
+
 #ifndef WX_PRECOMP
 #include "wx/image.h"
 #endif
@@ -712,3 +714,5 @@ void wxSVGFileDC::SetDeviceOrigin(wxCoord x, wxCoord y)
 #pragma warn .ccc
 #endif
 
+#endif // wxUSE_SVG
+