Merge branch 'define-use-svg-in-features.h'
Move wxUSE_SVG definition to wx/defs.h and work around OpenVMS compilation problems. See https://github.com/wxWidgets/wxWidgets/pull/2606
This commit is contained in:
@@ -18,13 +18,6 @@ class wxBitmapBundleImpl;
|
|||||||
class WXDLLIMPEXP_FWD_CORE wxImageList;
|
class WXDLLIMPEXP_FWD_CORE wxImageList;
|
||||||
class WXDLLIMPEXP_FWD_CORE wxWindow;
|
class WXDLLIMPEXP_FWD_CORE wxWindow;
|
||||||
|
|
||||||
// It should be possible to implement SVG rasterizing without raw bitmap
|
|
||||||
// support using wxDC::DrawSpline(), but currently we don't do it and so
|
|
||||||
// FromSVG() is only available in the ports providing raw bitmap access.
|
|
||||||
#ifdef wxHAS_RAW_BITMAP
|
|
||||||
#define wxHAS_SVG
|
|
||||||
#endif
|
|
||||||
|
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
// wxBitmapBundle provides 1 or more versions of a bitmap, all bundled together
|
// wxBitmapBundle provides 1 or more versions of a bitmap, all bundled together
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
|
|||||||
@@ -95,6 +95,15 @@
|
|||||||
#define wxHAVE_RAW_BITMAP
|
#define wxHAVE_RAW_BITMAP
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
/*
|
||||||
|
While it should be possible to implement SVG rasterizing without raw bitmap
|
||||||
|
support using wxDC::DrawSpline(), currently we don't do it and so FromSVG()
|
||||||
|
is only available in the ports providing raw bitmap access.
|
||||||
|
*/
|
||||||
|
#ifdef wxHAS_RAW_BITMAP
|
||||||
|
#define wxHAS_SVG
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
// Previously this symbol wasn't defined for all compilers as Bind() couldn't
|
// Previously this symbol wasn't defined for all compilers as Bind() couldn't
|
||||||
// be implemented for some of them (notably MSVC 6), but this is not the case
|
// be implemented for some of them (notably MSVC 6), but this is not the case
|
||||||
|
|||||||
@@ -19,8 +19,6 @@
|
|||||||
// for compilers that support precompilation, includes "wx.h".
|
// for compilers that support precompilation, includes "wx.h".
|
||||||
#include "wx/wxprec.h"
|
#include "wx/wxprec.h"
|
||||||
|
|
||||||
#include "wx/bmpbndl.h"
|
|
||||||
|
|
||||||
#ifdef wxHAS_SVG
|
#ifdef wxHAS_SVG
|
||||||
|
|
||||||
// Try to help people updating their sources from Git and forgetting to
|
// Try to help people updating their sources from Git and forgetting to
|
||||||
@@ -38,20 +36,13 @@
|
|||||||
|
|
||||||
#ifdef wxHAS_SVG
|
#ifdef wxHAS_SVG
|
||||||
|
|
||||||
#ifndef WX_PRECOMP
|
// Note that we have to include NanoSVG headers before including any of wx
|
||||||
#include "wx/utils.h" // Only for wxMin()
|
// headers, notably wx/unichar.h which defines global operator==() overloads
|
||||||
#endif // WX_PRECOMP
|
// for wxUniChar that confuse OpenVMS C++ compiler and break compilation of
|
||||||
|
// these headers with errors about ambiguous operator==(char,enum).
|
||||||
|
|
||||||
#ifdef wxUSE_FFILE
|
// This is required by NanoSVG headers, but not included by them.
|
||||||
#include "wx/ffile.h"
|
#include <stdio.h>
|
||||||
#elif wxUSE_FILE
|
|
||||||
#include "wx/file.h"
|
|
||||||
#else
|
|
||||||
#define wxNO_SVG_FILE
|
|
||||||
#endif
|
|
||||||
#include "wx/rawbmp.h"
|
|
||||||
|
|
||||||
#include "wx/private/bmpbndl.h"
|
|
||||||
|
|
||||||
// Disable some warnings inside NanoSVG code that we're not interested in.
|
// Disable some warnings inside NanoSVG code that we're not interested in.
|
||||||
#ifdef __VISUALC__
|
#ifdef __VISUALC__
|
||||||
@@ -75,6 +66,22 @@
|
|||||||
#pragma warning(pop)
|
#pragma warning(pop)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifndef WX_PRECOMP
|
||||||
|
#include "wx/utils.h" // Only for wxMin()
|
||||||
|
#endif // WX_PRECOMP
|
||||||
|
|
||||||
|
#include "wx/bmpbndl.h"
|
||||||
|
#ifdef wxUSE_FFILE
|
||||||
|
#include "wx/ffile.h"
|
||||||
|
#elif wxUSE_FILE
|
||||||
|
#include "wx/file.h"
|
||||||
|
#else
|
||||||
|
#define wxNO_SVG_FILE
|
||||||
|
#endif
|
||||||
|
#include "wx/rawbmp.h"
|
||||||
|
|
||||||
|
#include "wx/private/bmpbndl.h"
|
||||||
|
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
// private helpers
|
// private helpers
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
|
|||||||
Reference in New Issue
Block a user