summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorBjoern B. Brandenburg <bbb@cs.unc.edu>2010-09-27 13:51:53 -0400
committerBjoern B. Brandenburg <bbb@cs.unc.edu>2010-09-27 13:51:53 -0400
commitbb7de78222a2c95e8a5c97c3b0400d0bf3d7510e (patch)
tree10243c5ae3d16d01cf2a2cf8a165e85bbb904d68 /src
parentdfcef130d229234f830d85b20b7749c5b35b9be7 (diff)
Remove cairo bits.
Now that we have unit-trace, the cairo effort in this repo is probably not gonna be worked on for a while. Since this causes compilation issues let's remove it for now.
Diffstat (limited to 'src')
-rw-r--r--src/cairo_test.c41
1 files changed, 0 insertions, 41 deletions
diff --git a/src/cairo_test.c b/src/cairo_test.c
deleted file mode 100644
index 9c3683a..0000000
--- a/src/cairo_test.c
+++ /dev/null
@@ -1,41 +0,0 @@
1#include <stdio.h>
2#include <stdlib.h>
3
4#include <cairo.h>
5
6static double in2pts(double in)
7{
8 /* 72 pts per inch */
9 return in * 72;
10}
11
12static double cm2in(double cm)
13{
14 /* 1in = 2.54 cm */
15 return cm / 2.54;
16}
17
18static double cm2pts(double cm)
19{
20 return in2pts(cm2in(cm));
21}
22
23void cairo_test(void)
24{
25 cairo_surface_t *surface;
26 cairo_t *cr;
27
28 surface = cairo_pdf_surface_create("test.pdf", cm2pts(10), cm2pts(10));
29 cr = cairo_create(surface);
30 cairo_set_source_rgb(cr, 1.0, 0.3, 0.7);
31 cairo_rectangle(cr, cm2pts(0.25), cm2pts(0.25), cm2pts(0.5), cm2pts(0.5));
32 cairo_fill(cr);
33 cairo_destroy(cr);
34 cairo_surface_destroy(surface);
35}
36
37int main (int argc, char** argv)
38{
39 cairo_test();
40 return 0;
41}