From c5b80d2decb75f1b68b45174db1af379f515acde Mon Sep 17 00:00:00 2001 From: ellson Date: Thu, 11 Sep 2008 02:40:24 +0000 Subject: [PATCH] GD_border(g) in fp --- lib/common/input.c | 8 +++----- lib/common/types.h | 2 +- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/lib/common/input.c b/lib/common/input.c index 7487be4be..a72a8c6a7 100644 --- a/lib/common/input.c +++ b/lib/common/input.c @@ -771,7 +771,6 @@ void do_graph_label(graph_t * sg) /* it would be nice to allow multiple graph labels in the future */ if ((str = agget(sg, "label"))) { char pos_flag; - point dpt; pointf dimen; GD_has_labels(sg->root) |= GRAPH_LABEL; @@ -809,21 +808,20 @@ void do_graph_label(graph_t * sg) */ dimen = GD_label(sg)->dimen; PAD(dimen); - PF2P(dimen, dpt); if (!GD_flip(sg->root)) { if (GD_label_pos(sg) & LABEL_AT_TOP) pos_ix = TOP_IX; else pos_ix = BOTTOM_IX; - GD_border(sg)[pos_ix] = dpt; + GD_border(sg)[pos_ix] = dimen; } else { /* when rotated, the labels will be restored to TOP or BOTTOM */ if (GD_label_pos(sg) & LABEL_AT_TOP) pos_ix = RIGHT_IX; else pos_ix = LEFT_IX; - GD_border(sg)[pos_ix].x = dpt.y; - GD_border(sg)[pos_ix].y = dpt.x; + GD_border(sg)[pos_ix].x = dimen.y; + GD_border(sg)[pos_ix].y = dimen.x; } } } diff --git a/lib/common/types.h b/lib/common/types.h index c428843fd..1ab9486ba 100644 --- a/lib/common/types.h +++ b/lib/common/types.h @@ -317,7 +317,7 @@ typedef enum {NATIVEFONTS,PSFONTS,SVGFONTS} fontname_kind; layout_t *drawing; textlabel_t *label; /* if the cluster has a title */ boxf bb; /* bounding box */ - point border[4]; /* sizes of margins for graph labels */ + pointf border[4]; /* sizes of margins for graph labels */ unsigned char gui_state; /* Graph state for GUI ops */ unsigned char has_labels; boolean has_images; -- 2.40.0