Graphviz 12.0.1~dev.20240715.2254
Loading...
Searching...
No Matches
gvrender_quartz.c
Go to the documentation of this file.
1/*************************************************************************
2 * Copyright (c) 2011 AT&T Intellectual Property
3 * All rights reserved. This program and the accompanying materials
4 * are made available under the terms of the Eclipse Public License v1.0
5 * which accompanies this distribution, and is available at
6 * https://www.eclipse.org/legal/epl-v10.html
7 *
8 * Contributors: Details at https://graphviz.org
9 *************************************************************************/
10
11#include "config.h"
12
13#include <stdlib.h>
14#include <string.h>
15
16#ifdef __ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__
17#if __ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__ >= 20000
18#include <mach/mach_host.h>
19#include <sys/mman.h>
20#endif
21
22#if __ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__ >= 40000
23#include <ImageIO/ImageIO.h>
24#endif
25#endif
26
27#include <gvc/gvplugin_device.h>
28#include <gvc/gvplugin_render.h>
29#include <cgraph/cgraph.h>
30
31#include "gvplugin_quartz.h"
32
33static CGFloat dashed[] = { 6.0 };
34static CGFloat dotted[] = { 2.0, 6.0 };
35
36static void quartzgen_begin_job(GVJ_t * job)
37{
38 switch (job->device.id) {
39 case FORMAT_CGIMAGE:
40 /* save the passed-in context in the window field, so we can create a CGContext in the context field later on */
41 job->window = job->context;
42 *((CGImageRef *) job->window) = NULL;
43 }
44
45 job->context = NULL;
46}
47
48static void quartzgen_end_job(GVJ_t * job)
49{
50 CGContextRef context = job->context;
51
52#ifdef __ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__
53#if __ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__ >= 20000
54 void* context_data;
55 size_t context_datalen;
56
57 switch (job->device.id) {
58
59 case FORMAT_PDF:
60 context_data = NULL;
61 context_datalen = 0;
62 break;
63
64 default:
65 context_data = CGBitmapContextGetData(context);
66 context_datalen = CGBitmapContextGetBytesPerRow(context) * CGBitmapContextGetHeight(context);
67 break;
68 }
69#endif
70#endif
71
72 switch (job->device.id) {
73
74 case FORMAT_PDF:
75 /* save the PDF */
76 CGPDFContextClose(context);
77 break;
78
79 case FORMAT_CGIMAGE:
80 /* create an image and save it where the window field is, which was set to the passed-in context at begin job */
81 *((CGImageRef *) job->window) = CGBitmapContextCreateImage(context);
82 break;
83
84#if (defined(__ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__) && \
85 __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ >= 1040) || \
86 (defined(__ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__) && \
87 __ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__ >= 40000)
88 default: /* bitmap formats */
89 {
90 /* create an image destination */
91 CGDataConsumerRef data_consumer =
92 CGDataConsumerCreate(job,
94 CGImageDestinationRef image_destination =
95 CGImageDestinationCreateWithDataConsumer(data_consumer,
96 format_to_uti((format_type)job->device.id), 1, NULL);
97
98 /* add the bitmap image to the destination and save it */
99 CGImageRef image = CGBitmapContextCreateImage(context);
100 CGImageDestinationAddImage(image_destination, image, NULL);
101 CGImageDestinationFinalize(image_destination);
102
103 /* clean up */
104 if (image_destination)
105 CFRelease(image_destination);
106 CGImageRelease(image);
107 CGDataConsumerRelease(data_consumer);
108 }
109 break;
110#endif
111 }
112
113 CGContextRelease(context);
114
115#ifdef __ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__
116#if __ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__ >= 20000
117 if (context_data && context_datalen)
118 munmap(context_data, context_datalen);
119#endif
120#endif
121}
122
123static void quartzgen_begin_page(GVJ_t * job)
124{
125 CGRect bounds = CGRectMake(0.0, 0.0, job->width, job->height);
126
127 if (!job->context) {
128
129 switch (job->device.id) {
130
131 case FORMAT_PDF:
132 {
133 /* create the auxiliary info for PDF content, author and title */
134 CFStringRef auxiliaryKeys[] = {
135 kCGPDFContextCreator,
136 kCGPDFContextTitle
137 };
138 CFStringRef auxiliaryValues[] = {
139 CFStringCreateWithFormat(kCFAllocatorDefault, NULL,
140 CFSTR("%s %s"),
141 job->common->info[0],
142 job->common->info[1]),
143 job->obj->type ==
145 CFStringCreateWithBytesNoCopy(kCFAllocatorDefault,
146 (const UInt8 *) agnameof(job->obj->u.g),
147 strlen(agnameof(job->obj->u.g)),
148 kCFStringEncodingUTF8,
149 false,
150 kCFAllocatorNull)
151 : CFSTR("")
152 };
153 CFDictionaryRef auxiliaryInfo =
154 CFDictionaryCreate(kCFAllocatorDefault,
155 (const void **) &auxiliaryKeys,
156 (const void **) &auxiliaryValues,
157 sizeof(auxiliaryValues) /
158 sizeof(auxiliaryValues[0]),
159 &kCFTypeDictionaryKeyCallBacks,
160 &kCFTypeDictionaryValueCallBacks);
161
162 /* create a PDF for drawing into */
163 CGDataConsumerRef data_consumer =
164 CGDataConsumerCreate(job,
166 job->context =
167 CGPDFContextCreate(data_consumer, &bounds,
168 auxiliaryInfo);
169
170 /* clean up */
171 CGDataConsumerRelease(data_consumer);
172 CFRelease(auxiliaryInfo);
173 for (size_t i = 0; i < sizeof(auxiliaryValues) / sizeof(auxiliaryValues[0]);
174 ++i)
175 CFRelease(auxiliaryValues[i]);
176 }
177 break;
178
179 default: /* bitmap formats */
180 {
181 size_t bytes_per_row =
182 (job->width * BYTES_PER_PIXEL +
184
185 void *buffer = NULL;
186
187#ifdef __ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__
188#if __ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__ >= 20000
189
190 /* iPhoneOS has no swap files for memory, so if we're short of memory we need to make our own temp scratch file to back it */
191
192 size_t buffer_size = job->height * bytes_per_row;
193 mach_msg_type_number_t vm_info_size = HOST_VM_INFO_COUNT;
194 vm_statistics_data_t vm_info;
195
196 if (host_statistics
197 (mach_host_self(), HOST_VM_INFO,
198 (host_info_t) & vm_info,
199 &vm_info_size) != KERN_SUCCESS
200 || buffer_size * 2 >
201 vm_info.free_count * vm_page_size) {
202 FILE *temp_file = tmpfile();
203 if (temp_file) {
204 int temp_file_descriptor = fileno(temp_file);
205 if (temp_file_descriptor >= 0
206 && ftruncate(temp_file_descriptor,
207 buffer_size) == 0) {
208 buffer =
209 mmap(NULL, buffer_size,
210 PROT_READ | PROT_WRITE,
211 MAP_FILE | MAP_SHARED,
212 temp_file_descriptor, 0);
213 if (buffer == MAP_FAILED)
214 buffer = NULL;
215 }
216 fclose(temp_file);
217 }
218 }
219 if (buffer == NULL) {
220 buffer = mmap(NULL,
221 buffer_size,
222 PROT_READ | PROT_WRITE,
223 MAP_ANON | MAP_SHARED, -1, 0);
224 if (buffer == MAP_FAILED) {
225 buffer = NULL;
226 }
227 }
228#endif
229#endif
230
231 /* create a true color bitmap for drawing into */
232 CGColorSpaceRef color_space =
233 CGColorSpaceCreateDeviceRGB();
234 job->context = CGBitmapContextCreate(buffer, /* data: MacOSX lets system allocate, iPhoneOS use manual memory mapping */
235 job->width, /* width in pixels */
236 job->height, /* height in pixels */
237 BITS_PER_COMPONENT, /* bits per component */
238 bytes_per_row, /* bytes per row: align to 16 byte boundary */
239 color_space, /* color space: device RGB */
240 kCGImageAlphaPremultipliedFirst /* bitmap info: premul ARGB has best support in OS X */
241 );
242 job->imagedata = CGBitmapContextGetData(job->context);
243
244 /* clean up */
245 CGColorSpaceRelease(color_space);
246 }
247 break;
248 }
249
250 }
251
252 /* start the page (if this is a paged context) and graphics state */
253 CGContextRef context = job->context;
254 CGContextBeginPage(context, &bounds);
255 CGContextSaveGState(context);
256 /* CGContextSetMiterLimit(context, 1.0); */
257 /* CGContextSetLineJoin(context, kCGLineJoinBevel); */
258
259 /* set up the context transformation */
260 CGContextScaleCTM(context, job->scale.x, job->scale.y);
261 CGContextRotateCTM(context, job->rotation * M_PI / 180.0);
262 CGContextTranslateCTM(context, job->translation.x, job->translation.y);
263}
264
265static void quartzgen_end_page(GVJ_t * job)
266{
267 /* end the page (if this is a paged context) and graphics state */
268 CGContextRef context = job->context;
269 CGContextRestoreGState(context);
270 CGContextEndPage(context);
271}
272
273static void quartzgen_begin_anchor(GVJ_t * job, char *url, char *tooltip,
274 char *target, char *id)
275{
276 (void)tooltip;
277 (void)target;
278 (void)id;
279
280 pointf *url_map = job->obj->url_map_p;
281 if (url && url_map) {
282 /* set up the hyperlink to the given url */
283 CGContextRef context = job->context;
284 CFURLRef uri =
285 CFURLCreateWithBytes(kCFAllocatorDefault, (const UInt8 *) url,
286 strlen(url), kCFStringEncodingUTF8, NULL);
287 CGPDFContextSetURLForRect(context, uri,
288 /* need to reverse the CTM on the area to get it to work */
289 CGRectApplyAffineTransform(CGRectMake
290 (url_map[0].x,
291 url_map[0].y,
292 url_map[1].
293 x -
294 url_map[0].x,
295 url_map[1].
296 y -
297 url_map[0].
298 y),
299 CGContextGetCTM
300 (context))
301 );
302
303 /* clean up */
304 CFRelease(uri);
305 }
306}
307
308static void quartzgen_path(GVJ_t * job, int filled)
309{
310 CGContextRef context = job->context;
311
312 /* set up colors */
313 if (filled)
314 CGContextSetRGBFillColor(context, job->obj->fillcolor.u.RGBA[0],
315 job->obj->fillcolor.u.RGBA[1],
316 job->obj->fillcolor.u.RGBA[2],
317 job->obj->fillcolor.u.RGBA[3]);
318 CGContextSetRGBStrokeColor(context, job->obj->pencolor.u.RGBA[0],
319 job->obj->pencolor.u.RGBA[1],
320 job->obj->pencolor.u.RGBA[2],
321 job->obj->pencolor.u.RGBA[3]);
322
323 /* set up line style */
324 const CGFloat *segments;
325 size_t segment_count;
326 switch (job->obj->pen) {
327 case PEN_DASHED:
328 segments = dashed;
329 segment_count = sizeof(dashed) / sizeof(CGFloat);
330 break;
331 case PEN_DOTTED:
332 segments = dotted;
333 segment_count = sizeof(dotted) / sizeof(CGFloat);
334 break;
335 default:
336 segments = NULL;
337 segment_count = 0;
338 break;
339 }
340 CGContextSetLineDash(context, 0.0, segments, segment_count);
341
342 /* set up line width */
343 CGContextSetLineWidth(context, job->obj->penwidth); // *job->scale.x);
344
345 /* draw the path */
346 CGContextDrawPath(context, filled ? kCGPathFillStroke : kCGPathStroke);
347}
348
349static void quartzgen_textspan(GVJ_t * job, pointf p, textspan_t * span)
350{
351 CGContextRef context = job->context;
352
353 /* adjust text position */
354 switch (span->just) {
355 case 'r':
356 p.x -= span->size.x;
357 break;
358 case 'l':
359 p.x -= 0.0;
360 break;
361 case 'n':
362 default:
363 p.x -= span->size.x / 2.0;
364 break;
365 }
366 p.y += span->yoffset_centerline;
367
368 void *layout;
369 if (span->free_layout == &quartz_free_layout)
370 layout = span->layout;
371 else
372 layout =
373 quartz_new_layout(span->font->name, span->font->size, span->str);
374
375 CGContextSetRGBFillColor(context, job->obj->pencolor.u.RGBA[0],
376 job->obj->pencolor.u.RGBA[1],
377 job->obj->pencolor.u.RGBA[2],
378 job->obj->pencolor.u.RGBA[3]);
379 quartz_draw_layout(layout, context, CGPointMake(p.x, p.y));
380
381 if (span->free_layout != &quartz_free_layout)
383}
384
385static void quartzgen_ellipse(GVJ_t * job, pointf * A, int filled)
386{
387 /* convert ellipse into the current path */
388 CGContextRef context = job->context;
389 double dx = A[1].x - A[0].x;
390 double dy = A[1].y - A[0].y;
391 CGContextAddEllipseInRect(context,
392 CGRectMake(A[0].x - dx, A[0].y - dy,
393 dx * 2.0, dy * 2.0));
394
395 /* draw the ellipse */
396 quartzgen_path(job, filled);
397}
398
399static void quartzgen_polygon(GVJ_t *job, pointf *A, size_t n, int filled) {
400 /* convert polygon into the current path */
401 CGContextRef context = job->context;
402 CGContextMoveToPoint(context, A[0].x, A[0].y);
403 for (size_t i = 1; i < n; ++i)
404 CGContextAddLineToPoint(context, A[i].x, A[i].y);
405 CGContextClosePath(context);
406
407 /* draw the ellipse */
408 quartzgen_path(job, filled);
409}
410
411static void quartzgen_bezier(GVJ_t *job, pointf *A, size_t n, int filled) {
412 /* convert bezier into the current path */
413 CGContextRef context = job->context;
414 CGContextMoveToPoint(context, A[0].x, A[0].y);
415 for (size_t i = 1; i < n; i += 3)
416 CGContextAddCurveToPoint(context, A[i].x, A[i].y, A[i + 1].x,
417 A[i + 1].y, A[i + 2].x, A[i + 2].y);
418
419 /* draw the ellipse */
420 quartzgen_path(job, filled);
421}
422
423static void quartzgen_polyline(GVJ_t *job, pointf *A, size_t n) {
424 /* convert polyline into the current path */
425 CGContextRef context = job->context;
426 CGContextMoveToPoint(context, A[0].x, A[0].y);
427 for (size_t i = 1; i < n; ++i)
428 CGContextAddLineToPoint(context, A[i].x, A[i].y);
429
430 /* draw the ellipse */
431 quartzgen_path(job, 0);
432}
433
437 0, /* quartzgen_begin_graph */
438 0, /* quartzgen_end_graph */
439 0, /* quartzgen_begin_layer */
440 0, /* quartzgen_end_layer */
443 0, /* quartzgen_begin_cluster */
444 0, /* quartzgen_end_cluster */
445 0, /* quartzgen_begin_nodes */
446 0, /* quartzgen_end_nodes */
447 0, /* quartzgen_begin_edges */
448 0, /* quartzgen_end_edges */
449 0, /* quartzgen_begin_node */
450 0, /* quartzgen_end_node */
451 0, /* quartzgen_begin_edge */
452 0, /* quartzgen_end_edge */
454 0, /* quartzgen_end_anchor */
455 0, /* quartzgen_begin_label */
456 0, /* quartzgen_end_label */
458 0,
463 0, /* quartzgen_comment */
464 0, /* quartzgen_library_shape */
465};
466
469 4., /* default pad - graph units */
470 NULL, /* knowncolors */
471 0, /* sizeof knowncolors */
472 RGBA_DOUBLE /* color_type */
473};
474
475#if (defined(__ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__) && \
476 __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ >= 1040) || \
477 (defined(__ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__) && \
478 __ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__ >= 20000)
479static gvdevice_features_t device_features_quartz = {
481 {0., 0.}, /* default margin - points */
482 {0., 0.}, /* default page width, height - points */
483 {72., 72.} /* dpi */
484};
485#endif
486
489 {36., 36.}, /* default margin - points */
490 {0., 0.}, /* default page width, height - points */
491 {72., 72.} /* dpi */
492};
493
498
500 {FORMAT_PDF, "pdf:quartz", 8, NULL, &device_features_quartz_paged},
501#if (defined(__ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__) && \
502 __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ >= 1040) || \
503 (defined(__ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__) && \
504 __ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__ >= 20000)
505 {FORMAT_CGIMAGE, "cgimage:quartz", 8, NULL, &device_features_quartz},
506#endif
507#if (defined(__ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__) && \
508 __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ >= 1040) || \
509 (defined(__ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__) && \
510 __ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__ >= 40000)
511 {FORMAT_BMP, "bmp:quartz", 8, NULL, &device_features_quartz},
512 {FORMAT_GIF, "gif:quartz", 8, NULL, &device_features_quartz},
513 {FORMAT_ICO, "ico:quartz", 8, NULL, &device_features_quartz},
514 {FORMAT_JPEG, "jpe:quartz", 8, NULL, &device_features_quartz},
515 {FORMAT_JPEG, "jpeg:quartz", 8, NULL, &device_features_quartz},
516 {FORMAT_JPEG, "jpg:quartz", 8, NULL, &device_features_quartz},
517 {FORMAT_JPEG2000, "jp2:quartz", 8, NULL, &device_features_quartz},
518 {FORMAT_PNG, "png:quartz", 8, NULL, &device_features_quartz},
519 {FORMAT_TIFF, "tif:quartz", 8, NULL, &device_features_quartz},
520 {FORMAT_TIFF, "tiff:quartz", 8, NULL, &device_features_quartz},
521 {FORMAT_TGA, "tga:quartz", 8, NULL, &device_features_quartz},
522#endif
523#ifdef __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__
524#if __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ >= 1040
525 {FORMAT_EXR, "exr:quartz", 8, NULL, &device_features_quartz},
526 {FORMAT_ICNS, "icns:quartz", 8, NULL, &device_features_quartz},
527 {FORMAT_PICT, "pct:quartz", 8, NULL, &device_features_quartz},
528 {FORMAT_PICT, "pict:quartz", 8, NULL, &device_features_quartz},
529 {FORMAT_PSD, "psd:quartz", 8, NULL, &device_features_quartz},
530 {FORMAT_SGI, "sgi:quartz", 8, NULL, &device_features_quartz},
531#endif
532#endif
533 {0, NULL, 0, NULL, NULL}
534};
#define M_PI
Definition arith.h:41
abstract graph C library, Cgraph API
@ RGBA_DOUBLE
Definition color.h:27
static float dy
Definition draw.c:38
static float dx
Definition draw.c:37
#define A(n, t)
Definition expr.h:76
node NULL
Definition grammar.y:149
char * agnameof(void *)
returns a string descriptor for the object.
Definition id.c:158
@ PEN_DOTTED
Definition gvcjob.h:35
@ PEN_DASHED
Definition gvcjob.h:35
#define GVRENDER_NO_WHITE_BG
Definition gvcjob.h:106
#define GVDEVICE_DOES_PAGES
Definition gvcjob.h:87
#define GVDEVICE_DOES_TRUECOLOR
Definition gvcjob.h:90
#define GVDEVICE_BINARY_FORMAT
Definition gvcjob.h:91
#define GVRENDER_DOES_MAPS
Definition gvcjob.h:97
@ ROOTGRAPH_OBJTYPE
Definition gvcjob.h:168
#define GVRENDER_DOES_TRANSFORM
Definition gvcjob.h:95
#define GVRENDER_DOES_MAP_RECTANGLE
Definition gvcjob.h:98
format_type
static const int BYTES_PER_PIXEL
@ FORMAT_TIFF
@ FORMAT_BMP
CGDataConsumerCallbacks device_data_consumer_callbacks
void quartz_draw_layout(void *layout, CGContextRef context, CGPoint position)
void * quartz_new_layout(char *fontname, double fontsize, char *text)
static const int BYTE_ALIGN
static const int BITS_PER_COMPONENT
@ FORMAT_ICO
@ FORMAT_PICT
@ FORMAT_CGIMAGE
@ FORMAT_EXR
@ FORMAT_JPEG2000
@ FORMAT_TGA
@ FORMAT_ICNS
@ FORMAT_PSD
@ FORMAT_SGI
void quartz_free_layout(void *layout)
@ FORMAT_JPEG
Definition gvrender_gd.c:32
@ FORMAT_GIF
Definition gvrender_gd.c:31
@ FORMAT_PNG
Definition gvrender_gd.c:33
@ FORMAT_PDF
static void quartzgen_bezier(GVJ_t *job, pointf *A, size_t n, int filled)
static CGFloat dashed[]
static gvdevice_features_t device_features_quartz_paged
static CGFloat dotted[]
static gvrender_engine_t quartzgen_engine
static void quartzgen_end_page(GVJ_t *job)
static void quartzgen_polygon(GVJ_t *job, pointf *A, size_t n, int filled)
static void quartzgen_path(GVJ_t *job, int filled)
static void quartzgen_begin_job(GVJ_t *job)
static gvrender_features_t render_features_quartz
static void quartzgen_end_job(GVJ_t *job)
gvplugin_installed_t gvrender_quartz_types[]
static void quartzgen_ellipse(GVJ_t *job, pointf *A, int filled)
static void quartzgen_polyline(GVJ_t *job, pointf *A, size_t n)
static void quartzgen_begin_page(GVJ_t *job)
static void quartzgen_begin_anchor(GVJ_t *job, char *url, char *tooltip, char *target, char *id)
gvplugin_installed_t gvdevice_quartz_types[]
static void quartzgen_textspan(GVJ_t *job, pointf p, textspan_t *span)
T_cell image
Definition htmlparse.y:538
static int layout(graph_t *g, layout_info *infop)
Definition layout.c:809
char ** info
Definition gvcommon.h:20
int rotation
Definition gvcjob.h:319
char * imagedata
Definition gvcjob.h:297
obj_state_t * obj
Definition gvcjob.h:269
gvplugin_active_device_t device
Definition gvcjob.h:286
void * context
Definition gvcjob.h:295
GVCOMMON_t * common
Definition gvcjob.h:267
pointf scale
Definition gvcjob.h:332
unsigned int width
Definition gvcjob.h:327
void * window
Definition gvcjob.h:353
pointf translation
Definition gvcjob.h:333
unsigned int height
Definition gvcjob.h:328
double RGBA[4]
Definition color.h:32
union color_s::@72 u
ingroup plugin_api
Definition gvplugin.h:35
union obj_state_s::@92 u
graph_t * g
Definition gvcjob.h:186
pointf * url_map_p
Definition gvcjob.h:240
gvcolor_t fillcolor
Definition gvcjob.h:194
obj_type type
Definition gvcjob.h:184
pen_type pen
Definition gvcjob.h:197
gvcolor_t pencolor
Definition gvcjob.h:194
double penwidth
Definition gvcjob.h:199
double x
Definition geom.h:29
double y
Definition geom.h:29
char * name
Definition textspan.h:54
double size
Definition textspan.h:57
char * str
Definition textspan.h:65
char just
'l' 'n' 'r'
Definition textspan.h:71
void * layout
Definition textspan.h:67
pointf size
Definition textspan.h:70
textfont_t * font
Definition textspan.h:66
double yoffset_centerline
Definition textspan.h:69
void(* free_layout)(void *layout)
Definition textspan.h:68