aboutsummaryrefslogtreecommitdiffstats
path: root/libart_lgpl/art_vpath_svp.c
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2010-06-20 18:56:06 +0800
committerMatthew Barnes <mbarnes@redhat.com>2010-06-20 20:06:19 +0800
commit5d0878967ee21a039ef599222b1cf3eb606354d4 (patch)
tree790cfcbf63fea7292740f182dd612ab20244f6e8 /libart_lgpl/art_vpath_svp.c
parentf5f2132d60cdd1884c6343f759aadfd38a159e04 (diff)
downloadgsoc2013-evolution-5d0878967ee21a039ef599222b1cf3eb606354d4.tar
gsoc2013-evolution-5d0878967ee21a039ef599222b1cf3eb606354d4.tar.gz
gsoc2013-evolution-5d0878967ee21a039ef599222b1cf3eb606354d4.tar.bz2
gsoc2013-evolution-5d0878967ee21a039ef599222b1cf3eb606354d4.tar.lz
gsoc2013-evolution-5d0878967ee21a039ef599222b1cf3eb606354d4.tar.xz
gsoc2013-evolution-5d0878967ee21a039ef599222b1cf3eb606354d4.tar.zst
gsoc2013-evolution-5d0878967ee21a039ef599222b1cf3eb606354d4.zip
Coding style and whitespace cleanup.
Diffstat (limited to 'libart_lgpl/art_vpath_svp.c')
-rw-r--r--libart_lgpl/art_vpath_svp.c36
1 files changed, 18 insertions, 18 deletions
diff --git a/libart_lgpl/art_vpath_svp.c b/libart_lgpl/art_vpath_svp.c
index 000265c376..ceeea0ac4b 100644
--- a/libart_lgpl/art_vpath_svp.c
+++ b/libart_lgpl/art_vpath_svp.c
@@ -31,15 +31,15 @@
typedef struct _ArtVpathSVPEnd ArtVpathSVPEnd;
struct _ArtVpathSVPEnd {
- int seg_num;
- int which; /* 0 = top, 1 = bottom */
- double x, y;
+ gint seg_num;
+ gint which; /* 0 = top, 1 = bottom */
+ gdouble x, y;
};
#define EPSILON 1e-6
-static int
-art_vpath_svp_point_compare (double x1, double y1, double x2, double y2)
+static gint
+art_vpath_svp_point_compare (gdouble x1, gdouble y1, gdouble x2, gdouble y2)
{
if (y1 - EPSILON > y2) return 1;
if (y1 + EPSILON < y2) return -1;
@@ -48,8 +48,8 @@ art_vpath_svp_point_compare (double x1, double y1, double x2, double y2)
return 0;
}
-static int
-art_vpath_svp_compare (const void *s1, const void *s2)
+static gint
+art_vpath_svp_compare (gconstpointer s1, gconstpointer s2)
{
const ArtVpathSVPEnd *e1 = s1;
const ArtVpathSVPEnd *e2 = s2;
@@ -83,18 +83,18 @@ art_vpath_svp_compare (const void *s1, const void *s2)
ArtVpath *
art_vpath_from_svp (const ArtSVP *svp)
{
- int n_segs = svp->n_segs;
+ gint n_segs = svp->n_segs;
ArtVpathSVPEnd *ends;
ArtVpath *new;
- int *visited;
- int n_new, n_new_max;
- int i, k;
- int j = 0; /* Quiet compiler */
- int seg_num;
- int first;
- double last_x, last_y;
- int n_points;
- int pt_num;
+ gint *visited;
+ gint n_new, n_new_max;
+ gint i, k;
+ gint j = 0; /* Quiet compiler */
+ gint seg_num;
+ gint first;
+ gdouble last_x, last_y;
+ gint n_points;
+ gint pt_num;
last_x = 0; /* to eliminate "uninitialized" warning */
last_y = 0;
@@ -102,7 +102,7 @@ art_vpath_from_svp (const ArtSVP *svp)
ends = art_new (ArtVpathSVPEnd, n_segs * 2);
for (i = 0; i < svp->n_segs; i++)
{
- int lastpt;
+ gint lastpt;
ends[i * 2].seg_num = i;
ends[i * 2].which = 0;