diff options
| -rw-r--r-- | CMakeScripts/ConfigChecks.cmake | 7 | ||||
| -rw-r--r-- | config.h.cmake | 1 | ||||
| -rw-r--r-- | src/extension/init.cpp | 12 | ||||
| -rw-r--r-- | src/extension/internal/cairo-ps-out.cpp | 3 | ||||
| -rw-r--r-- | src/extension/internal/cairo-ps-out.h | 4 | ||||
| -rw-r--r-- | src/extension/internal/cairo-renderer-pdf-out.cpp | 3 | ||||
| -rw-r--r-- | src/extension/internal/cairo-renderer-pdf-out.h | 4 | ||||
| -rw-r--r-- | src/libnrtype/Layout-TNG-Output.cpp | 10 | ||||
| -rw-r--r-- | src/libnrtype/Layout-TNG.h | 4 |
9 files changed, 12 insertions, 36 deletions
diff --git a/CMakeScripts/ConfigChecks.cmake b/CMakeScripts/ConfigChecks.cmake index a06c7c759..aa151c7c8 100644 --- a/CMakeScripts/ConfigChecks.cmake +++ b/CMakeScripts/ConfigChecks.cmake @@ -15,7 +15,6 @@ include(CheckStructHasMember) set(CMAKE_REQUIRED_LIBRARIES ${CMAKE_REQUIRED_LIBRARIES} ${INKSCAPE_LIBS}) set(CMAKE_REQUIRED_INCLUDES ${CMAKE_REQUIRED_INCLUDES} ${INKSCAPE_INCS_SYS}) -CHECK_INCLUDE_FILES(cairo-pdf.h HAVE_CAIRO_PDF) CHECK_INCLUDE_FILES(ieeefp.h HAVE_IEEEFP_H) CHECK_FUNCTION_EXISTS(mallinfo HAVE_MALLINFO) CHECK_INCLUDE_FILES(malloc.h HAVE_MALLOC_H) @@ -26,12 +25,6 @@ CHECK_STRUCT_HAS_MEMBER(hblkhd mallinfo malloc.h HAVE_STRUCT_MALLINFO_HBLKHD) CHECK_STRUCT_HAS_MEMBER(uordblks mallinfo malloc.h HAVE_STRUCT_MALLINFO_UORDBLKS) CHECK_STRUCT_HAS_MEMBER(usmblks mallinfo malloc.h HAVE_STRUCT_MALLINFO_USMBLKS) -# Enable pango defines, necessary for compilation on Win32, how about Linux? -# yes but needs to be done a better way -if(HAVE_CAIRO_PDF) - set(PANGO_ENABLE_ENGINE TRUE) -endif() - # Create the configuration files config.h in the binary root dir configure_file(${CMAKE_SOURCE_DIR}/config.h.cmake ${CMAKE_BINARY_DIR}/include/config.h) add_definitions(-DHAVE_CONFIG_H) diff --git a/config.h.cmake b/config.h.cmake index bd563c933..817942928 100644 --- a/config.h.cmake +++ b/config.h.cmake @@ -36,7 +36,6 @@ #cmakedefine ENABLE_OSX_APP_LOCATIONS 1 /* Whether the Cairo PDF backend is available */ -#cmakedefine HAVE_CAIRO_PDF 1 #cmakedefine PANGO_ENABLE_ENGINE 1 /* Build with GDL 3.6 or higher */ diff --git a/src/extension/init.cpp b/src/extension/init.cpp index 49ac2e802..6626ff20d 100644 --- a/src/extension/init.cpp +++ b/src/extension/init.cpp @@ -36,8 +36,12 @@ # include "internal/emf-print.h" # include "internal/wmf-inout.h" # include "internal/wmf-print.h" -#ifdef HAVE_CAIRO_PDF + +#include <cairo.h> +#ifdef CAIRO_HAS_PDF_SURFACE # include "internal/cairo-renderer-pdf-out.h" +#endif +#ifdef CAIRO_HAS_PS_SURFACE # include "internal/cairo-ps-out.h" #endif #include "internal/pov-out.h" @@ -151,10 +155,10 @@ init() Internal::Svg::init(); Internal::Svgz::init(); -#ifdef HAVE_CAIRO_PDF - //g_print ("Using CairoRendererPdfOutput: new pdf exporter\n"); +#ifdef CAIRO_HAS_PDF_SURFACE Internal::CairoRendererPdfOutput::init(); - +#endif +#ifdef CAIRO_HAS_PS_SURFACE Internal::CairoPsOutput::init(); Internal::CairoEpsOutput::init(); #endif diff --git a/src/extension/internal/cairo-ps-out.cpp b/src/extension/internal/cairo-ps-out.cpp index ed5be808c..baa1cf1b0 100644 --- a/src/extension/internal/cairo-ps-out.cpp +++ b/src/extension/internal/cairo-ps-out.cpp @@ -19,7 +19,8 @@ # include "config.h" // only include where actually required! #endif -#ifdef HAVE_CAIRO_PDF +#include <cairo.h> +#ifdef CAIRO_HAS_PS_SURFACE #include "cairo-ps.h" #include "cairo-ps-out.h" diff --git a/src/extension/internal/cairo-ps-out.h b/src/extension/internal/cairo-ps-out.h index b0e14e5a8..974f9668a 100644 --- a/src/extension/internal/cairo-ps-out.h +++ b/src/extension/internal/cairo-ps-out.h @@ -23,8 +23,6 @@ #include "extension/implementation/implementation.h" -#ifdef HAVE_CAIRO_PDF - namespace Inkscape { namespace Extension { namespace Internal { @@ -55,8 +53,6 @@ public: } } } /* namespace Inkscape, Extension, Implementation */ -#endif /* HAVE_CAIRO_PDF */ - #endif /* !EXTENSION_INTERNAL_CAIRO_PS_OUT_H */ /* diff --git a/src/extension/internal/cairo-renderer-pdf-out.cpp b/src/extension/internal/cairo-renderer-pdf-out.cpp index d2e96e31a..9ff3579ed 100644 --- a/src/extension/internal/cairo-renderer-pdf-out.cpp +++ b/src/extension/internal/cairo-renderer-pdf-out.cpp @@ -19,7 +19,8 @@ # include "config.h" // only include where actually required! #endif -#ifdef HAVE_CAIRO_PDF +#include <cairo.h> +#ifdef CAIRO_HAS_PDF_SURFACE #include "cairo-renderer-pdf-out.h" #include "cairo-render-context.h" diff --git a/src/extension/internal/cairo-renderer-pdf-out.h b/src/extension/internal/cairo-renderer-pdf-out.h index c69b86ef6..dfb2ad3a9 100644 --- a/src/extension/internal/cairo-renderer-pdf-out.h +++ b/src/extension/internal/cairo-renderer-pdf-out.h @@ -21,8 +21,6 @@ #include "extension/implementation/implementation.h" -#ifdef HAVE_CAIRO_PDF - namespace Inkscape { namespace Extension { namespace Internal { @@ -39,8 +37,6 @@ public: } } } /* namespace Inkscape, Extension, Internal */ -#endif /* HAVE_CAIRO_PDF */ - #endif /* !EXTENSION_INTERNAL_CAIRO_RENDERER_PDF_OUT_H */ /* diff --git a/src/libnrtype/Layout-TNG-Output.cpp b/src/libnrtype/Layout-TNG-Output.cpp index 6ff52f2a7..2a7c835f3 100644 --- a/src/libnrtype/Layout-TNG-Output.cpp +++ b/src/libnrtype/Layout-TNG-Output.cpp @@ -29,14 +29,6 @@ #include <3rdparty/libuemf/symbol_convert.h> -namespace Inkscape { - namespace Extension { - namespace Internal { - class CairoRenderContext; - } - } -} - using Inkscape::Extension::Internal::CairoRenderContext; using Inkscape::Extension::Internal::CairoGlyphInfo; @@ -424,7 +416,6 @@ std:: cout << "DEBUG Layout::print in while --- " } -#ifdef HAVE_CAIRO_PDF void Layout::showGlyphs(CairoRenderContext *ctx) const { if (_input_stream.empty()) return; @@ -519,7 +510,6 @@ void Layout::showGlyphs(CairoRenderContext *ctx) const } } } -#endif #if DEBUG_TEXTLAYOUT_DUMPASTEXT // these functions are for dumpAsText() only. No need to translate diff --git a/src/libnrtype/Layout-TNG.h b/src/libnrtype/Layout-TNG.h index e5317b501..c09fc27ca 100644 --- a/src/libnrtype/Layout-TNG.h +++ b/src/libnrtype/Layout-TNG.h @@ -28,7 +28,6 @@ #include <svg/svg-length.h> #include "style-enums.h" -#ifdef HAVE_CAIRO_PDF namespace Inkscape { namespace Extension { namespace Internal { @@ -38,7 +37,6 @@ namespace Inkscape { } using Inkscape::Extension::Internal::CairoRenderContext; -#endif class SPStyle; class Shape; @@ -403,12 +401,10 @@ public: */ void print(SPPrintContext *ctx, Geom::OptRect const &pbox, Geom::OptRect const &dbox, Geom::OptRect const &bbox, Geom::Affine const &ctm) const; -#ifdef HAVE_CAIRO_PDF /** Renders all the glyphs to the given Cairo rendering context. \param ctx The Cairo rendering context to be used */ void showGlyphs(CairoRenderContext *ctx) const; -#endif /** Returns the font family of the indexed span */ Glib::ustring getFontFamily(unsigned span_index) const; |
