[arch-commits] Commit in poppler-glib/repos/extra-x86_64 (4 files)

Jan de Groot jgc at archlinux.org
Mon Jul 7 13:21:19 EDT 2008


    Date: Monday, July 7, 2008 @ 13:21:19
  Author: jgc
Revision: 4474

Cleanup

Deleted:
  poppler-glib/repos/extra-x86_64/cairo-output-cvs20061221.patch
  poppler-glib/repos/extra-x86_64/fdo5589.patch
  poppler-glib/repos/extra-x86_64/glib-2.0.patch
  poppler-glib/repos/extra-x86_64/poppler-0.5.2-bindings.patch

--------------------------------+
 cairo-output-cvs20061221.patch |   85 -----------
 fdo5589.patch                  |  288 ---------------------------------------
 glib-2.0.patch                 |   12 -
 poppler-0.5.2-bindings.patch   |   88 -----------
 4 files changed, 473 deletions(-)

Deleted: cairo-output-cvs20061221.patch
===================================================================
--- cairo-output-cvs20061221.patch	2008-07-07 17:19:28 UTC (rev 4473)
+++ cairo-output-cvs20061221.patch	2008-07-07 17:21:19 UTC (rev 4474)
@@ -1,85 +0,0 @@
---- poppler/CairoOutputDev.cc	2006/09/21 00:56:33	1.44
-+++ poppler/CairoOutputDev.cc	2006/12/21 01:01:30	1.48
-@@ -134,7 +134,7 @@
-   matrix.x0 = ctm[4];
-   matrix.y0 = ctm[5];
- 
--  cairo_set_matrix (cairo, &matrix);
-+  cairo_transform (cairo, &matrix);
- 
-   OutputDev::setDefaultCTM(ctm);
- }
-@@ -202,12 +202,18 @@
-   cairo_set_miter_limit (cairo, state->getMiterLimit());
- }
- 
-+#define MIN(a,b) (a) < (b) ? (a) : (b)
-+
- void CairoOutputDev::updateLineWidth(GfxState *state) {
-   LOG(printf ("line width: %f\n", state->getLineWidth()));
-   if (state->getLineWidth() == 0.0) {
--      cairo_set_line_width (cairo, 72.0/300.0);
-+    /* find out how big pixels (device unit) are in the x and y directions
-+     * choose the smaller of the two as our line width */
-+    double x = 1.0, y = 1.0;
-+    cairo_device_to_user_distance(cairo, &x, &y);
-+    cairo_set_line_width (cairo, MIN(fabs(x),fabs(y)));
-   } else {
--      cairo_set_line_width (cairo, state->getLineWidth());
-+    cairo_set_line_width (cairo, state->getLineWidth());
-   }
- }
- 
-@@ -263,8 +269,6 @@
- 
- void CairoOutputDev::updateFont(GfxState *state) {
-   cairo_font_face_t *font_face;
--  double m11, m12, m21, m22;
--  double w;
-   cairo_matrix_t matrix;
- 
-   LOG(printf ("updateFont() font=%s\n", state->getFont()->getName()->getCString()));
-@@ -278,9 +282,6 @@
- 
-   if (!currentFont)
-     return;
--  state->getFontTransMat(&m11, &m12, &m21, &m22);
--  m11 *= state->getHorizScaling();
--  m12 *= state->getHorizScaling();
- 
-   LOG(printf ("font matrix: %f %f %f %f\n", m11, m12, m21, m22));
-   
-@@ -289,8 +290,8 @@
-  
-   double fontSize = state->getFontSize();
-   double *m = state->getTextMat();
--  matrix.xx = m[0] * fontSize;
--  matrix.yx = m[1] * fontSize;
-+  matrix.xx = m[0] * fontSize * state->getHorizScaling();
-+  matrix.yx = m[1] * fontSize * state->getHorizScaling();
-   matrix.xy = -m[2] * fontSize;
-   matrix.yy = -m[3] * fontSize;
-   matrix.x0 = 0;
-@@ -620,7 +621,6 @@
-   GfxRGB rgb;
-   int alpha, i;
-   cairo_matrix_t matrix;
--  cairo_matrix_t maskMatrix;
-   int is_identity_transform;
- 
-   buffer = (unsigned char *)gmalloc (width * height * 4);
-@@ -662,12 +662,9 @@
-   cairo_matrix_init_translate (&matrix, 0, height);
-   cairo_matrix_scale (&matrix, width, -height);
- 
--  cairo_matrix_init_translate (&maskMatrix, 0, maskHeight);
--  cairo_matrix_scale (&maskMatrix, maskWidth, -maskHeight);
--
--
-+  /* scale the mask to the size of the image unlike softMask */
-   cairo_pattern_set_matrix (pattern, &matrix);
--  cairo_pattern_set_matrix (maskPattern, &maskMatrix);
-+  cairo_pattern_set_matrix (maskPattern, &matrix);
- 
-   cairo_pattern_set_filter (pattern, CAIRO_FILTER_BILINEAR);
-   cairo_set_source (cairo, pattern);

Deleted: fdo5589.patch
===================================================================
--- fdo5589.patch	2008-07-07 17:19:28 UTC (rev 4473)
+++ fdo5589.patch	2008-07-07 17:21:19 UTC (rev 4474)
@@ -1,288 +0,0 @@
-Index: poppler/CairoOutputDev.cc
-===================================================================
-RCS file: /cvs/poppler/poppler/poppler/CairoOutputDev.cc,v
-retrieving revision 1.48
-diff -u -r1.48 CairoOutputDev.cc
---- poppler/CairoOutputDev.cc	21 Dec 2006 01:01:30 -0000	1.48
-+++ poppler/CairoOutputDev.cc	24 Mar 2007 21:02:41 -0000
-@@ -15,6 +15,7 @@
- 
- #include <string.h>
- #include <math.h>
-+#include <assert.h>
- #include <cairo.h>
- 
- #include "goo/gfile.h"
-@@ -30,7 +31,6 @@
- #include <splash/SplashBitmap.h>
- #include "CairoOutputDev.h"
- #include "CairoFontEngine.h"
--
- //------------------------------------------------------------------------
- 
- // #define LOG_CAIRO
-@@ -202,7 +202,7 @@
-   cairo_set_miter_limit (cairo, state->getMiterLimit());
- }
- 
--#define MIN(a,b) (a) < (b) ? (a) : (b)
-+#define MIN(a,b) (((a) < (b)) ? (a) : (b))
- 
- void CairoOutputDev::updateLineWidth(GfxState *state) {
-   LOG(printf ("line width: %f\n", state->getLineWidth()));
-@@ -491,6 +491,17 @@
- 
- }
- 
-+static inline int splashRound(SplashCoord x) {
-+  return (int)floor(x + 0.5);
-+}
-+
-+static inline int splashCeil(SplashCoord x) {
-+  return (int)ceil(x);
-+}
-+
-+static inline int splashFloor(SplashCoord x) {
-+  return (int)floor(x);
-+}
- 
- void CairoOutputDev::drawImageMask(GfxState *state, Object *ref, Stream *str,
- 				    int width, int height, GBool invert,
-@@ -517,13 +528,58 @@
-     cairo_restore (cairo);
-     return;
-   }
--
--  row_stride = (width + 3) & ~3;
--  buffer = (unsigned char *) malloc (height * row_stride);
--  if (buffer == NULL) {
--    error(-1, "Unable to allocate memory for image.");
--    return;
--  }
-+  /*XXX BUGS: cannadoc 013 - the arrow should be filled in but it is not. */
-+  cairo_get_matrix(cairo, &matrix);
-+  //printf("[%f %f], [%f %f], %f %f\n", matrix.xx, matrix.xy, matrix.yx, matrix.yy, matrix.x0, matrix.y0);
-+  //{
-+    double xScale = matrix.xx;
-+    double yScale = matrix.yy;
-+    int tx, tx2, ty, ty2;
-+    int scaledHeight = height;
-+    int scaledWidth = width;
-+    if (xScale >= 0) {
-+      tx = splashRound(matrix.x0 - 0.01);
-+      tx2 = splashRound(matrix.x0 + xScale + 0.01) - 1;
-+    } else {
-+      tx = splashRound(matrix.x0 + 0.01) - 1;
-+      tx2 = splashRound(matrix.x0 + xScale - 0.01);
-+    }
-+    scaledWidth = abs(tx2 - tx) + 1;
-+    //scaledWidth = splashRound(fabs(xScale));
-+    if (scaledWidth == 0) {
-+      // technically, this should draw nothing, but it generally seems
-+      // better to draw a one-pixel-wide stripe rather than throwing it
-+      // away
-+      scaledWidth = 1;
-+    }
-+    if (yScale >= 0) {
-+      ty = splashFloor(matrix.y0 + 0.01);
-+      ty2 = splashCeil(matrix.y0 + yScale - 0.01);
-+    } else {
-+      ty = splashCeil(matrix.y0 - 0.01);
-+      ty2 = splashFloor(matrix.y0 + yScale + 0.01);
-+    }
-+    scaledHeight = abs(ty2 - ty);
-+    int need_pad = 0;
-+    int head_pad = 0;
-+    int tail_pad = 0;
-+    if (splashRound(fabs(yScale)) < splashCeil(fabs(yScale)))
-+	need_pad = 1;
-+
-+    //printf("xscale: %g, yscale: %g\n", xScale, yScale);
-+    //printf("width: %d, height: %d\n", width, height);
-+    //printf("scaledWidth: %d, scaledHeight: %d\n", scaledWidth, scaledHeight);
-+    /*XXX: URGENT PROBLEM: if yScale is very small these get very big, which is very bad
-+     * They cause us to large allocations and lots of uneccessary work */
-+    tail_pad = (matrix.y0 - ty)*(height/yScale);
-+    head_pad = (ty2 - (matrix.y0 + yScale))*(height/yScale);
-+    //printf("head_pad: %d tail_pad: %d\n", head_pad, tail_pad);
-+    int origHeight = height;
-+    height += tail_pad;
-+    height += head_pad;
-+    //printf("origHeight: %d height: %d\n", origHeight, height);
-+    //printf("ty: %d, ty2: %d\n", ty, ty2);
-+  //}
- 
-   /* TODO: Do we want to cache these? */
-   imgStr = new ImageStream(str, width, 1, 1);
-@@ -531,6 +587,14 @@
- 
-   invert_bit = invert ? 1 : 0;
- 
-+  row_stride = (scaledWidth + 3) & ~3;
-+  buffer = (unsigned char *) malloc (scaledHeight * row_stride);
-+  if (buffer == NULL) {
-+    error(-1, "Unable to allocate memory for image.");
-+    return;
-+  }
-+
-+#if 0
-   for (y = 0; y < height; y++) {
-     pix = imgStr->getLine();
-     dest = buffer + y * row_stride;
-@@ -542,9 +606,120 @@
- 	*dest++ = 255;
-     }
-   }
-+#else
-+  int yp = height / scaledHeight;
-+  int origYp = origHeight / scaledHeight;
-+  int yq = height % scaledHeight;
-+  int xp = width / scaledWidth;
-+  int xq = width % scaledWidth;
-+  int origHeight_c = origHeight;
-+//  int p_position = 0;
-+  int yt = 0;
-+  unsigned char *pixBuf = (unsigned char *)malloc(MIN(yp+1, origHeight)*width);
-+  int lastYStep = 1;
-+  int total = 0;
-+  for (int y = 0; y < scaledHeight; y++) {
-+    // y scale Bresenham
-+    int yStep = yp;
-+    yt += yq;
-+
-+    if (yt >= scaledHeight) {
-+      yt -= scaledHeight;
-+      ++yStep;
-+    }
- 
-+    // read row (s) from image
-+    {
-+      int n = (yp > 0) ? yStep : lastYStep;
-+      total += n;
-+      if (n > 0) {
-+	unsigned char *p = pixBuf;
-+	int head_pad_count = head_pad;
-+	int origHeight_count = origHeight;
-+	int tail_pad_count = tail_pad;
-+	for (int i=0; i<n; i++) {
-+	  // get row
-+	  if (head_pad_count) {
-+	    head_pad_count--;
-+	  } else if (origHeight_count) {
-+	    pix = imgStr->getLine();
-+	    for (int j=0; j<width; j++) {
-+	      if (pix[j] ^ invert_bit)
-+		p[j] = 0;
-+	      else
-+		p[j] = 255;
-+	    }
-+	    origHeight_count--;
-+	    p += width;
-+	  } else if (tail_pad_count) {
-+	    tail_pad_count--;
-+	  } else {
-+	    //printf("%d %d\n", n, total);
-+	    assert(0 && "over run\n");
-+	  }
-+	}
-+      }
-+    }
-+    lastYStep = yStep;
-+    int k1 = y;
-+
-+    int xt = 0;
-+    int xSrc = 0;
-+    int x1 = k1;
-+    int y1 = y + x1;
-+    int n = yStep > 0 ? yStep : 1;
-+    int origN = n;
-+    int head_pad_size = MIN(n, head_pad);
-+    n -= head_pad_size;
-+    head_pad -= MIN(head_pad_size, yStep);
-+
-+    int pix_size = MIN(n, origHeight);
-+    n -= pix_size;
-+    origHeight -= MIN(pix_size, yStep);
-+
-+    int tail_pad_size = MIN(n, tail_pad);
-+    n -= tail_pad_size;
-+    tail_pad -= MIN(tail_pad_size, yStep);
-+    if (n != 0) {
-+      //printf("n = %d (%d %d %d)\n", n, head_pad_size, pix_size, tail_pad_size);
-+      assert(n == 0);
-+    }
-+    for (int x = 0; x < scaledWidth; ++x) {
-+      int xStep = xp;
-+      xt += xq;
-+      if (xt >= scaledWidth) {
-+	xt -= scaledWidth;
-+	++xStep;
-+      }
-+      int m = xStep > 0 ? xStep : 1;
-+      float pixAcc0 = 0;
-+      /* could m * head_pad_size * tail_pad_size  overflow? */
-+      if (invert_bit) {
-+	pixAcc0 += m * head_pad_size * tail_pad_size * 255;
-+      } else {
-+	pixAcc0 += m * head_pad_size * tail_pad_size * 0;
-+      }
-+      for (int i = 0; i < pix_size; ++i) {
-+	/* use background color instead of always checking invert_bit */
-+	for (int j = 0; j< m; ++j) {
-+	  if (xSrc + i*width + j > MIN(yp + 1, origHeight_c)*width) {
-+	    //printf("%d > %d (%d %d %d %d) (%d %d %d)\n", xSrc + i*width + j, MIN(yp + 1, origHeight_c)*width, xSrc, i , width, j, yp, origHeight_c, width);
-+	    //printf("%d %d %d\n", head_pad_size, pix_size, tail_pad_size);
-+	    assert(0 && "bad access\n");
-+	  }
-+	  pixAcc0 += pixBuf[xSrc + i*width + j];
-+	}
-+      }
-+      buffer[y * row_stride + x] = pixAcc0 / (origN*m);
-+      xSrc += xStep;
-+      x1 += 1;
-+    }
-+
-+  }
-+  free(pixBuf);
-+#endif
-   image = cairo_image_surface_create_for_data (buffer, CAIRO_FORMAT_A8,
--					       width, height, row_stride);
-+      scaledWidth, scaledHeight, row_stride);
-   if (image == NULL) {
-     delete imgStr;
-     return;
-@@ -555,18 +730,28 @@
-     return;
-   }
- 
--  cairo_matrix_init_translate (&matrix, 0, height);
--  cairo_matrix_scale (&matrix, width, -height);
-+  //cairo_matrix_init_translate (&matrix, 0, -scaledHeight);
-+//  cairo_matrix_scale (&matrix, width, -height);
- 
--  cairo_pattern_set_matrix (pattern, &matrix);
-+  //cairo_pattern_set_matrix (pattern, &matrix);
- 
-   /* we should actually be using CAIRO_FILTER_NEAREST here. However,
-    * cairo doesn't yet do minifaction filtering causing scaled down
-    * images with CAIRO_FILTER_NEAREST to look really bad */
-   cairo_pattern_set_filter (pattern, CAIRO_FILTER_BEST);
--
--  cairo_mask (cairo, pattern);
--
-+  {
-+    cairo_get_matrix(cairo, &matrix);
-+    cairo_save (cairo);
-+    cairo_scale(cairo, 1.0/matrix.xx, 1.0/matrix.yy);
-+    // get integer co-ords
-+    cairo_translate (cairo, tx - matrix.x0, ty2 - matrix.y0);
-+    if (yScale > 0)
-+      cairo_scale(cairo, 1, -1);
-+    cairo_mask (cairo, pattern);
-+    cairo_get_matrix(cairo, &matrix);
-+    //printf("mask at: [%f %f], [%f %f], %f %f\n\n", matrix.xx, matrix.xy, matrix.yx, matrix.yy, matrix.x0, matrix.y0);
-+    cairo_restore(cairo);
-+  }
-   cairo_pattern_destroy (pattern);
-   cairo_surface_destroy (image);
-   free (buffer);

Deleted: glib-2.0.patch
===================================================================
--- glib-2.0.patch	2008-07-07 17:19:28 UTC (rev 4473)
+++ glib-2.0.patch	2008-07-07 17:21:19 UTC (rev 4474)
@@ -1,12 +0,0 @@
-diff -urN poppler-0.5.4~/configure.ac poppler-0.5.4/configure.ac
---- poppler-0.5.4~/configure.ac	2006-09-22 01:22:02.000000000 +0200
-+++ poppler-0.5.4/configure.ac	2006-09-22 15:13:48.000000000 +0200
-@@ -183,7 +183,7 @@
-               enable_poppler_glib=$enableval,
-               enable_poppler_glib="try")
- if test x$enable_poppler_glib = xyes; then
--  PKG_CHECK_MODULES(POPPLER_GLIB, gdk-2.0 >= 2.4.0 glib >= 2.6)
-+  PKG_CHECK_MODULES(POPPLER_GLIB, gdk-2.0 >= 2.4.0 glib-2.0 >= 2.6)
- elif test x$enable_poppler_glib = xtry; then
-   PKG_CHECK_MODULES(POPPLER_GLIB, gdk-2.0 >= 2.4.0,
-                     [enable_poppler_glib="yes"],

Deleted: poppler-0.5.2-bindings.patch
===================================================================
--- poppler-0.5.2-bindings.patch	2008-07-07 17:19:28 UTC (rev 4473)
+++ poppler-0.5.2-bindings.patch	2008-07-07 17:21:19 UTC (rev 4474)
@@ -1,88 +0,0 @@
-diff --exclude-from=/home/dang/.diffrc -u -ruN poppler-0.5.2.orig/glib/Makefile.am poppler-0.5.2/glib/Makefile.am
---- poppler-0.5.2.orig/glib/Makefile.am	2006-05-19 18:09:00.000000000 -0400
-+++ poppler-0.5.2/glib/Makefile.am	2006-05-22 19:55:31.000000000 -0400
-@@ -81,7 +81,7 @@
- 	poppler-private.h
- 
- libpoppler_glib_la_LIBADD =				\
--	$(top_builddir)/poppler/libpoppler.la		\
-+	-lpoppler					\
- 	$(POPPLER_GLIB_LIBS)				\
- 	$(FREETYPE_LIBS)				\
- 	$(cairo_libs)
-@@ -94,7 +94,7 @@
-        test-poppler-glib.c
- 
- test_poppler_glib_LDADD =			\
--	$(top_builddir)/poppler/libpoppler.la	\
-+	-lpoppler				\
- 	libpoppler-glib.la			\
- 	$(POPPLER_GLIB_LIBS)			\
- 	$(FREETYPE_LIBS)			\
-diff --exclude-from=/home/dang/.diffrc -u -ruN poppler-0.5.2.orig/Makefile.am poppler-0.5.2/Makefile.am
---- poppler-0.5.2.orig/Makefile.am	2006-01-10 11:09:33.000000000 -0500
-+++ poppler-0.5.2/Makefile.am	2006-05-22 19:55:31.000000000 -0400
-@@ -29,7 +29,7 @@
- utils_subdir = utils
- endif
- 
--SUBDIRS = goo fofi $(splash_subdir) poppler $(utils_subdir) $(glib_subdir) $(qt_subdir) test $(qt4_subdir)
-+SUBDIRS = $(glib_subdir) $(qt_subdir) $(qt4_subdir)
- 
- EXTRA_DIST =					\
- 	README-XPDF				\
-@@ -40,9 +40,7 @@
- 
- pkgconfigdir = $(libdir)/pkgconfig
- pkgconfig_DATA =				\
--	poppler.pc				\
- 	$(cairo_pc_file)			\
--	$(splash_pc_file)			\
- 	$(glib_pc_file)				\
- 	$(qt_pc_file)                           \
- 	$(qt4_pc_file)
-diff --exclude-from=/home/dang/.diffrc -u -ruN poppler-0.5.2.orig/qt/Makefile.am poppler-0.5.2/qt/Makefile.am
---- poppler-0.5.2.orig/qt/Makefile.am	2006-02-28 17:51:10.000000000 -0500
-+++ poppler-0.5.2/qt/Makefile.am	2006-05-22 19:55:31.000000000 -0400
-@@ -22,7 +22,7 @@
- 	poppler-private.h
- 
- libpoppler_qt_la_LIBADD = 			\
--	$(top_builddir)/poppler/libpoppler.la	\
-+	-lpoppler				\
- 	$(POPPLER_QT_LIBS)			\
- 	$(FREETYPE_LIBS)
- 
-@@ -38,7 +38,7 @@
-        test-poppler-qt.cpp
- 
- test_poppler_qt_LDADD =				\
--	$(top_builddir)/poppler/libpoppler.la	\
-+	-lpoppler				\
- 	libpoppler-qt.la			\
- 	$(POPPLER_QT_LIBS)			\
- 	$(FREETYPE_LIBS)
-diff --exclude-from=/home/dang/.diffrc -u -ruN poppler-0.5.2.orig/qt4/src/Makefile.am poppler-0.5.2/qt4/src/Makefile.am
---- poppler-0.5.2.orig/qt4/src/Makefile.am	2006-05-19 13:44:23.000000000 -0400
-+++ poppler-0.5.2/qt4/src/Makefile.am	2006-05-22 19:56:44.000000000 -0400
-@@ -27,7 +27,7 @@
- 	poppler-private.h
- 
- libpoppler_qt4_la_LIBADD = 			\
--	$(top_builddir)/poppler/libpoppler.la	\
-+	-lpoppler			\
- 	$(top_builddir)/poppler/libpoppler-arthur.la	\
- 	$(POPPLER_QT4_LIBS)
- 
-diff --exclude-from=/home/dang/.diffrc -u -ruN poppler-0.5.2.orig/qt4/tests/Makefile.am poppler-0.5.2/qt4/tests/Makefile.am
---- poppler-0.5.2.orig/qt4/tests/Makefile.am	2006-01-23 09:43:39.000000000 -0500
-+++ poppler-0.5.2/qt4/tests/Makefile.am	2006-05-22 19:55:31.000000000 -0400
-@@ -7,7 +7,7 @@
- 	$(POPPLER_QTTEST_CXXFLAGS)
- 
- LDADDS =					\
--	$(top_builddir)/poppler/libpoppler.la	\
-+	-lpoppler				\
- 	$(top_builddir)/qt4/src/libpoppler-qt4.la	\
- 	$(POPPLER_QT4_LIBS)
- 





More information about the arch-commits mailing list