[cairo-commit] cairo/src Makefile.am, 1.30, 1.31 cairo-features.h.in, 1.12, 1.13 cairo-ft.h, NONE, 1.1 cairo-glitz.h, NONE, 1.1 cairo-pdf.h, NONE, 1.1 cairo-png.h, NONE, 1.1 cairo-ps.h, NONE, 1.1 cairo-quartz.h, NONE, 1.1 cairo-xcb.h, NONE, 1.1 cairo-xlib.h, 1.5, 1.6 cairo.c, 1.46, 1.47 cairo.h, 1.66, 1.67 cairo_ft_font.c, 1.31, 1.32 cairo_gdip_font.cpp, 1.1, 1.2 cairo_gdip_surface.cpp, 1.2, 1.3 cairo_glitz_surface.c, 1.13, 1.14 cairo_pdf_surface.c, 1.6, 1.7 cairo_png_surface.c, 1.10, 1.11 cairo_ps_surface.c, 1.16, 1.17 cairo_wideint.h, 1.6, NONE cairo_xlib_surface.c, 1.36, 1.37 cairoint.h, 1.84, 1.85

Carl Worth commit at pdx.freedesktop.org
Thu Jan 20 08:28:57 PST 2005


Committed by: cworth

Update of /cvs/cairo/cairo/src
In directory gabe:/tmp/cvs-serv17422/src

Modified Files:
	Makefile.am cairo-features.h.in cairo.c cairo.h 
	cairo_ft_font.c cairo_gdip_font.cpp cairo_gdip_surface.cpp 
	cairo_glitz_surface.c cairo_pdf_surface.c cairo_png_surface.c 
	cairo_ps_surface.c cairo_xlib_surface.c cairoint.h 
Added Files:
	cairo-ft.h cairo-glitz.h cairo-pdf.h cairo-png.h cairo-ps.h 
	cairo-quartz.h cairo-xcb.h cairo-xlib.h 
Removed Files:
	cairo_wideint.h 
Log Message:

        * src/cairoint.h: Track various renamings.

        * src/cairo_xlib_surface.c:
        * src/cairo_ps_surface.c:
        * src/cairo_png_surface.c:
        * src/cairo_pdf_surface.c:
        * src/cairo_glitz_surface.c:
        * src/cairo_ft_font.c: Insert new includes for backend-specific
        header files.

        * src/cairo_gdip_surface.cpp:
        * src/cairo_gdip_font.cpp: Remove redundant include of
        cairo-features.h.

        * src/cairo.h (CAIRO_H): Rename header-exclusion macro from
        _CAIRO_H_ to CAIRO_H.
        Remove platform-specific grubbing for cairo-features.h and
        pixman.h in odd places.

        Remove all backend-specific prototypes, (as they are now in their
        own header files).

        Remove deprecated

        * src/cairo.c (cairo_sane_state): Remove printf.

        * src/cairo-features.h.in: Convert to utf-8. Use the proper name
        for multiple-header exclusion (CAIRO_FEATURES_H). Track rename of
        FREETYPE_FONT_FEATURE to FT_FONT_FEATURE.

        * src/Makefile.am (cairoinclude_HEADERS): Split cairo.h up into
        cairo.h, cairo-ft.h, cairo-glitz.h, cairo-pdf.h, cairo-png.h,
        cairo-ps.h, cairo-xcb.h, cairo-xlib.h.
        Update for rename of cairo_wideint.h to cairo-wideint.h.

        * configure.in: Rename CAIRO_HAS_FREETYPE_FONT to
        CAIRO_HAS_FT_FONT, (to match cairo_ft_font functions and
        cairo-ft.h).

        * cairo.pc.in (Cflags): Update for public header files now in
        /cairo.


Index: Makefile.am
===================================================================
RCS file: /cvs/cairo/cairo/src/Makefile.am,v
retrieving revision 1.30
retrieving revision 1.31
diff -u -d -r1.30 -r1.31
--- Makefile.am	11 Jan 2005 18:03:01 -0000	1.30
+++ Makefile.am	20 Jan 2005 16:28:54 -0000	1.31
@@ -1,28 +1,39 @@
+cairoincludedir = $(includedir)/cairo
+cairoinclude_HEADERS =	\
+	cairo.h		\
+	cairo-features.h\
+	cairo-ft.h	\
+	cairo-glitz.h	\
+	cairo-pdf.h	\
+	cairo-png.h	\
+	cairo-ps.h	\
+	cairo-xcb.h	\
+	cairo-xlib.h
+
 lib_LTLIBRARIES = libcairo.la
-include_HEADERS = cairo.h cairo-features.h
 
 if CAIRO_HAS_PS_SURFACE
-libcairo_ps_sources = cairo_ps_surface.c
+libcairo_ps_sources = cairo_ps_surface.c cairo-ps.h
 endif
 
 if CAIRO_HAS_PDF_SURFACE
-libcairo_pdf_sources = cairo_pdf_surface.c
+libcairo_pdf_sources = cairo_pdf_surface.c cairo-pdf.h
 endif
 
 if CAIRO_HAS_PNG_SURFACE
-libcairo_png_sources = cairo_png_surface.c
+libcairo_png_sources = cairo_png_surface.c cairo-png.h
 endif
 
 if CAIRO_HAS_XLIB_SURFACE
-libcairo_xlib_sources = cairo_xlib_surface.c
+libcairo_xlib_sources = cairo_xlib_surface.c cairo-xlib.h
 endif
 
 if CAIRO_HAS_XCB_SURFACE
-libcairo_xcb_sources = cairo_xcb_surface.c
+libcairo_xcb_sources = cairo_xcb_surface.c cairo-xcb.h
 endif
 
 if CAIRO_HAS_GLITZ_SURFACE
-libcairo_glitz_sources = cairo_glitz_surface.c
+libcairo_glitz_sources = cairo_glitz_surface.c cairo-glitz.h
 endif
 
 # These names match automake style variable definition conventions so
@@ -57,7 +68,7 @@
 	cairo_traps.c		\
 	cairo_pattern.c		\
 	cairo_wideint.c		\
-	cairo_wideint.h		\
+	cairo-wideint.h		\
 	$(libcairo_ps_sources)  \
 	$(libcairo_pdf_sources) \
 	$(libcairo_png_sources) \

Index: cairo-features.h.in
===================================================================
RCS file: /cvs/cairo/cairo/src/cairo-features.h.in,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -d -r1.12 -r1.13
--- cairo-features.h.in	17 Jan 2005 17:18:37 -0000	1.12
+++ cairo-features.h.in	20 Jan 2005 16:28:54 -0000	1.13
@@ -1,6 +1,6 @@
 /* cairo - a vector graphics library with display and print output
  *
- * Copyright © 2003 University of Southern California
+ * Copyright © 2003 University of Southern California
  *
  * This library is free software; you can redistribute it and/or
  * modify it either under the terms of the GNU Lesser General Public
@@ -34,8 +34,8 @@
  *	Carl Worth <cworth at east.isi.edu>
  */
 
-#ifndef _CAIRO_CONFIG_H_
-#define _CAIRO_CONFIG_H_
+#ifndef CAIRO_FEATURES_H
+#define CAIRO_FEATURES_H
 
 #define @PS_SURFACE_FEATURE@
 
@@ -49,7 +49,7 @@
 
 #define @GLITZ_SURFACE_FEATURE@
 
-#define @FREETYPE_FONT_FEATURE@
+#define @FT_FONT_FEATURE@
 
 #define @ATSUI_FONT_FEATURE@
 

--- NEW FILE: cairo-ft.h ---
(This appears to be a binary file; contents omitted.)

--- NEW FILE: cairo-glitz.h ---
(This appears to be a binary file; contents omitted.)

--- NEW FILE: cairo-pdf.h ---
(This appears to be a binary file; contents omitted.)

--- NEW FILE: cairo-png.h ---
(This appears to be a binary file; contents omitted.)

--- NEW FILE: cairo-ps.h ---
(This appears to be a binary file; contents omitted.)

--- NEW FILE: cairo-quartz.h ---
(This appears to be a binary file; contents omitted.)

--- NEW FILE: cairo-xcb.h ---
(This appears to be a binary file; contents omitted.)


Index: cairo.c
===================================================================
RCS file: /cvs/cairo/cairo/src/cairo.c,v
retrieving revision 1.46
retrieving revision 1.47
diff -u -d -r1.46 -r1.47
--- cairo.c	12 Jan 2005 22:40:14 -0000	1.46
+++ cairo.c	20 Jan 2005 16:28:54 -0000	1.47
@@ -39,7 +39,6 @@
 
 #define CAIRO_TOLERANCE_MINIMUM	0.0002 /* We're limited by 16 bits of sub-pixel precision */
 
-
 #ifdef CAIRO_DO_SANITY_CHECKING
 #include <assert.h>
 static int 
@@ -59,7 +58,6 @@
     case CAIRO_STATUS_NULL_POINTER:
 	break;
     default:
-	printf ("cairo status is bad: %d\n", cr->status);
 	return 0;
     }
     return 1;

Index: cairo.h
===================================================================
RCS file: /cvs/cairo/cairo/src/cairo.h,v
retrieving revision 1.66
retrieving revision 1.67
diff -u -d -r1.66 -r1.67
--- cairo.h	17 Jan 2005 17:18:37 -0000	1.66
+++ cairo.h	20 Jan 2005 16:28:54 -0000	1.67
@@ -34,19 +34,11 @@
  *	Carl D. Worth <cworth at isi.edu>
  */
 
-#ifndef _CAIRO_H_
-#define _CAIRO_H_
-
-#if !TARGET_OS_MAC
-	#include <cairo-features.h>
-	#include <pixman.h>
-#else
-	#include <Cairo/cairo-features.h>
-	#include <Cairo/pixman.h>
-#endif
-
+#ifndef CAIRO_H
+#define CAIRO_H
 
-#include <stdio.h>
+#include <cairo-features.h>
+#include <pixman.h>
 
 typedef struct _cairo cairo_t;
 typedef struct _cairo_surface cairo_surface_t;
@@ -104,91 +96,6 @@
 			int		height,
 			int		stride);
 
-#ifdef CAIRO_HAS_PS_SURFACE
-
-#include <stdio.h>
-
-void
-cairo_set_target_ps (cairo_t	*cr,
-		     FILE	*file,
-		     double	width_inches,
-		     double	height_inches,
-		     double	x_pixels_per_inch,
-		     double	y_pixels_per_inch);
-
-#endif /* CAIRO_HAS_PS_SURFACE */
-
-#ifdef CAIRO_HAS_PDF_SURFACE
-
-#include <stdio.h>
-
-void
-cairo_set_target_pdf (cairo_t	*cr,
-		      FILE	*file,
-		      double	width_inches,
-		      double	height_inches,
-		      double	x_pixels_per_inch,
-		      double	y_pixels_per_inch);
-
-#endif /* CAIRO_HAS_PDF_SURFACE */
-
-#ifdef CAIRO_HAS_PNG_SURFACE
-
-#include <stdio.h>
-
-void
-cairo_set_target_png (cairo_t	*cr,
-		      FILE	*file,
-		      cairo_format_t	format,
-		      int	       	width,
-		      int		height);
-
-#endif /* CAIRO_HAS_PNG_SURFACE */
-
-#ifdef CAIRO_HAS_XLIB_SURFACE
-
-#include <X11/extensions/Xrender.h>
-
-/* XXX: This shold be renamed to cairo_set_target_xlib to match the
- * other backends */
-void
-cairo_set_target_drawable (cairo_t	*cr,
-			   Display	*dpy,
-			   Drawable	drawable);
-#endif /* CAIRO_HAS_XLIB_SURFACE */
-
-#ifdef CAIRO_HAS_XCB_SURFACE
-
-#include <X11/XCB/xcb.h>
-#include <X11/XCB/render.h>
-
-void
-cairo_set_target_xcb (cairo_t		*cr,
-		      XCBConnection	*dpy,
-		      XCBDRAWABLE	drawable,
-		      XCBVISUALTYPE	*visual,
-		      cairo_format_t	format);
-#endif /* CAIRO_HAS_XCB_SURFACE */
-
-#ifdef CAIRO_HAS_GLITZ_SURFACE
-
-#include <glitz.h>
-
-void
-cairo_set_target_glitz (cairo_t *cr,
-			glitz_surface_t *surface);
-#endif /* CAIRO_HAS_GLITZ_SURFACE */
-
-#ifdef CAIRO_HAS_QUARTZ_SURFACE
-
-void
-cairo_set_target_quartz_context(   	cairo_t		*cr,
-					CGContextRef    context,
-					int		width,
-					int		height);
-
-#endif /* CAIRO_HAS_QUARTZ_SURFACE */
-
 typedef enum cairo_operator { 
     CAIRO_OPERATOR_CLEAR,
     CAIRO_OPERATOR_SRC,
@@ -523,27 +430,6 @@
 cairo_font_current_transform (cairo_font_t *font, 
 			      cairo_matrix_t *matrix);
 
-#ifdef CAIRO_HAS_FREETYPE_FONT
-/* Fontconfig/Freetype platform-specific font interface */
-
-#include <fontconfig/fontconfig.h>
-#include <ft2build.h>
-#include FT_FREETYPE_H
-
-cairo_font_t *
-cairo_ft_font_create (FT_Library ft_library, FcPattern *pattern);
-
-cairo_font_t *
-cairo_ft_font_create_for_ft_face (FT_Face face);
-
-FT_Face
-cairo_ft_font_face (cairo_font_t *ft_font);
-
-FcPattern *
-cairo_ft_font_pattern (cairo_font_t  *ft_font);
-
-#endif  /* CAIRO_HAS_FREETYPE_FONT */
-
 /* Image functions */
 
 /* XXX: Eliminate width/height here */
@@ -768,79 +654,6 @@
 cairo_filter_t
 cairo_pattern_get_filter (cairo_pattern_t *pattern);
 
-#ifdef CAIRO_HAS_PS_SURFACE
-
-/* PS-surface functions */
-
-cairo_surface_t *
-cairo_ps_surface_create (FILE	*file,
-			 double	width_inches,
-			 double height_inches,
-			 double	x_pixels_per_inch,
-			 double	y_pixels_per_inch);
-
-#endif /* CAIRO_HAS_PS_SURFACE */
-
-#ifdef CAIRO_HAS_PDF_SURFACE
-
-cairo_surface_t *
-cairo_pdf_surface_create (FILE		*file,
-			  double	width_inches,
-			  double	height_inches,
-			  double	x_pixels_per_inch,
-			  double	y_pixels_per_inch);
-
-#endif /* CAIRO_HAS_PDF_SURFACE */
-
-#ifdef CAIRO_HAS_PNG_SURFACE
-
-/* PNG-surface functions */
-
-cairo_surface_t *
-cairo_png_surface_create (FILE			*file,
-			  cairo_format_t	format,
-			  int			width,
-			  int			height);
-
-#endif /* CAIRO_HAS_PNG_SURFACE */
-
-#ifdef CAIRO_HAS_XLIB_SURFACE
-
-/* XXX: This is a mess from the user's POV. Should the Visual or the
-   cairo_format_t control what render format is used? Maybe I can have
-   cairo_surface_create_for_window with a visual, and
-   cairo_surface_create_for_pixmap with a cairo_format_t. Would that work?
-*/
-cairo_surface_t *
-cairo_xlib_surface_create (Display		*dpy,
-			   Drawable		drawable,
-			   Visual		*visual,
-			   cairo_format_t	format,
-			   Colormap		colormap);
-  
-/* XXX: This has been proposed
-cairo_status_t
-cairo_xlib_surface_set_size (cairo_surface_t *surface, int width, int height);
-*/
-
-#endif /* CAIRO_HAS_XLIB_SURFACE */
-
-#ifdef CAIRO_HAS_GLITZ_SURFACE
-
-cairo_surface_t *
-cairo_glitz_surface_create (glitz_surface_t *surface);
-
-#endif /* CAIRO_HAS_GLITZ_SURFACE */
-
-#ifdef CAIRO_HAS_QUARTZ_SURFACE
-
-cairo_surface_t *
-cairo_quartz_surface_create (   CGContextRef    context,
-				int		width,
-				int		height);
-
-#endif /* CAIRO_HAS_QUARTZ_SURFACE */
-
 /* Matrix functions */
 
 /* XXX: Rename all of these to cairo_transform_t */
@@ -915,4 +728,4 @@
 }
 #endif
 
-#endif
+#endif /* CAIRO_H */

Index: cairo_ft_font.c
===================================================================
RCS file: /cvs/cairo/cairo/src/cairo_ft_font.c,v
retrieving revision 1.31
retrieving revision 1.32
diff -u -d -r1.31 -r1.32
--- cairo_ft_font.c	19 Jan 2005 19:39:07 -0000	1.31
+++ cairo_ft_font.c	20 Jan 2005 16:28:54 -0000	1.32
@@ -23,6 +23,8 @@
  */
 
 #include "cairoint.h"
+#include "cairo-ft.h"
+
 #include <fontconfig/fontconfig.h>
 #include <fontconfig/fcfreetype.h>
 

Index: cairo_gdip_font.cpp
===================================================================
RCS file: /cvs/cairo/cairo/src/cairo_gdip_font.cpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- cairo_gdip_font.cpp	12 Nov 2004 22:46:23 -0000	1.1
+++ cairo_gdip_font.cpp	20 Jan 2005 16:28:54 -0000	1.2
@@ -34,7 +34,6 @@
  */
 
 extern "C" {
-#include "cairo-features.h"
 #include "cairoint.h"
 }
 

Index: cairo_gdip_surface.cpp
===================================================================
RCS file: /cvs/cairo/cairo/src/cairo_gdip_surface.cpp,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- cairo_gdip_surface.cpp	5 Jan 2005 22:29:31 -0000	1.2
+++ cairo_gdip_surface.cpp	20 Jan 2005 16:28:54 -0000	1.3
@@ -34,7 +34,6 @@
  */
 
 extern "C" {
-#include "cairo-features.h"
 #include "cairoint.h"
 }
 

Index: cairo_glitz_surface.c
===================================================================
RCS file: /cvs/cairo/cairo/src/cairo_glitz_surface.c,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -d -r1.13 -r1.14
--- cairo_glitz_surface.c	13 Jan 2005 14:50:23 -0000	1.13
+++ cairo_glitz_surface.c	20 Jan 2005 16:28:54 -0000	1.14
@@ -25,6 +25,7 @@
  */
 
 #include "cairoint.h"
+#include "cairo-glitz.h"
 
 #define GLITZ_FIXED_TO_FLOAT(f) \
   (((glitz_float_t) (f)) / 65536)

Index: cairo_pdf_surface.c
===================================================================
RCS file: /cvs/cairo/cairo/src/cairo_pdf_surface.c,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- cairo_pdf_surface.c	19 Jan 2005 16:03:53 -0000	1.6
+++ cairo_pdf_surface.c	20 Jan 2005 16:28:54 -0000	1.7
@@ -35,6 +35,10 @@
  */
 
 #include "cairoint.h"
+#include "cairo-pdf.h"
+/* XXX: This seems broken to me. What about users without freetype
+ * that want to use a cairo PDF surface? */
+#include "cairo-ft.h"
 
 #include <ft2build.h>
 #include FT_FREETYPE_H

Index: cairo_png_surface.c
===================================================================
RCS file: /cvs/cairo/cairo/src/cairo_png_surface.c,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -d -r1.10 -r1.11
--- cairo_png_surface.c	22 Oct 2004 01:40:50 -0000	1.10
+++ cairo_png_surface.c	20 Jan 2005 16:28:54 -0000	1.11
@@ -38,6 +38,7 @@
 #include <png.h>
 
 #include "cairoint.h"
+#include "cairo-png.h"
 
 static const cairo_surface_backend_t cairo_png_surface_backend;
 

Index: cairo_ps_surface.c
===================================================================
RCS file: /cvs/cairo/cairo/src/cairo_ps_surface.c,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -d -r1.16 -r1.17
--- cairo_ps_surface.c	29 Nov 2004 22:11:26 -0000	1.16
+++ cairo_ps_surface.c	20 Jan 2005 16:28:54 -0000	1.17
@@ -35,6 +35,7 @@
  */
 
 #include "cairoint.h"
+#include "cairo-ps.h"
 
 #include <time.h>
 #include <zlib.h>

--- cairo_wideint.h DELETED ---

Index: cairo_xlib_surface.c
===================================================================
RCS file: /cvs/cairo/cairo/src/cairo_xlib_surface.c,v
retrieving revision 1.36
retrieving revision 1.37
diff -u -d -r1.36 -r1.37
--- cairo_xlib_surface.c	17 Jan 2005 17:40:01 -0000	1.36
+++ cairo_xlib_surface.c	20 Jan 2005 16:28:54 -0000	1.37
@@ -35,6 +35,7 @@
  */
 
 #include "cairoint.h"
+#include "cairo-xlib.h"
 
 void
 cairo_set_target_drawable (cairo_t	*cr,

Index: cairoint.h
===================================================================
RCS file: /cvs/cairo/cairo/src/cairoint.h,v
retrieving revision 1.84
retrieving revision 1.85
diff -u -d -r1.84 -r1.85
--- cairoint.h	17 Jan 2005 17:40:01 -0000	1.84
+++ cairoint.h	20 Jan 2005 16:28:54 -0000	1.85
@@ -108,7 +108,7 @@
 #define __attribute__(x)
 #endif
 
-#include "cairo_wideint.h"
+#include "cairo-wideint.h"
 
 typedef int32_t		cairo_fixed_16_16_t;
 typedef cairo_int64_t	cairo_fixed_32_32_t;
@@ -501,7 +501,7 @@
 } cairo_font_backend_t;
 
 /* concrete font backends */
-#ifdef CAIRO_HAS_FREETYPE_FONT
+#ifdef CAIRO_HAS_FT_FONT
 
 extern const cairo_private struct _cairo_font_backend cairo_ft_font_backend;
 
@@ -746,7 +746,7 @@
 #define CAIRO_FONT_SLANT_DEFAULT   CAIRO_FONT_SLANT_NORMAL
 #define CAIRO_FONT_WEIGHT_DEFAULT  CAIRO_FONT_WEIGHT_NORMAL
 
-#ifdef CAIRO_HAS_FREETYPE_FONT 
+#ifdef CAIRO_HAS_FT_FONT 
 
 #define CAIRO_FONT_FAMILY_DEFAULT  "serif"
 




More information about the cairo-commit mailing list