Graphviz  2.41.20170921.2350
Data Structures | Macros | Functions
shapes.c File Reference
#include "render.h"
#include "htmltable.h"
#include <limits.h>
Include dependency graph for shapes.c:

Go to the source code of this file.

Data Structures

struct  poly_desc_t


#define RBCONST   12
#define RBCURVE   .5
#define ATTR_SET(a, n)   ((a) && (*(agxget(n,a->index)) != '\0'))
#define DEF_POINT   0.05
#define MIN_POINT   0.0003
#define IS_BOX(n)   (ND_shape(n)->polygon == &p_box)
#define IS_PLAIN(n)   (ND_shape(n)->polygon == &p_plain)
#define SPECIAL_CORNERS(style)   ((style) & (ROUNDED | DIAGONALS | SHAPE_MASK))
#define GET_PORT_BOX(n, e)   ((n) == (e)->head ? ED_head_port(e).bp : ED_tail_port(e).bp)
#define multicolor(f)   (strchr(f,':'))
#define HASTEXT   1
#define HASPORT   2
#define HASTABLE   4
#define INTEXT   8
#define INPORT   16
#define ISCTRL(c)   ((c) == '{' || (c) == '}' || (c) == '|' || (c) == '<' || (c) == '>')
#define alpha   (M_PI/10.0)
#define alpha2   (2*alpha)
#define alpha3   (3*alpha)
#define alpha4   (2*alpha2)


char * findAttrColor (void *obj, attrsym_t *colorattr, char *dflt)
void round_corners (GVJ_t *job, pointf *AF, int sides, int style, int filled)
shape_kind shapeOf (node_t *n)
boolean isPolygon (node_t *n)
shape_descfind_user_shape (const char *name)
shape_descbind_shape (char *name, node_t *np)
port resolvePort (node_t *n, node_t *other, port *oldport)
void resolvePorts (edge_t *e)
void gv_initShapes (void)

Macro Definition Documentation

#define alpha   (M_PI/10.0)
#define alpha2   (2*alpha)

Definition at line 3903 of file shapes.c.

#define alpha3   (3*alpha)

Definition at line 3904 of file shapes.c.

#define alpha4   (2*alpha2)

Definition at line 3905 of file shapes.c.

#define ATTR_SET (   a,
)    ((a) && (*(agxget(n,a->index)) != '\0'))

Definition at line 28 of file shapes.c.

#define DEF_POINT   0.05

Definition at line 30 of file shapes.c.

#define GET_PORT_BOX (   n,
)    ((n) == (e)->head ? ED_head_port(e).bp : ED_tail_port(e).bp)

Definition at line 2253 of file shapes.c.

#define HASPORT   2

Definition at line 3192 of file shapes.c.

#define HASTABLE   4

Definition at line 3193 of file shapes.c.

#define HASTEXT   1

Definition at line 3191 of file shapes.c.

#define INPORT   16

Definition at line 3195 of file shapes.c.

#define INTEXT   8

Definition at line 3194 of file shapes.c.

#define IS_BOX (   n)    (ND_shape(n)->polygon == &p_box)

Definition at line 152 of file shapes.c.

#define IS_PLAIN (   n)    (ND_shape(n)->polygon == &p_plain)

Definition at line 153 of file shapes.c.

#define ISCTRL (   c)    ((c) == '{' || (c) == '}' || (c) == '|' || (c) == '<' || (c) == '>')

Definition at line 3197 of file shapes.c.

#define MIN_POINT   0.0003

Definition at line 35 of file shapes.c.

#define multicolor (   f)    (strchr(f,':'))

Definition at line 2771 of file shapes.c.

#define RBCONST   12

Definition at line 18 of file shapes.c.

Referenced by round_corners().

#define RBCURVE   .5

Definition at line 19 of file shapes.c.

Referenced by round_corners().

#define SPECIAL_CORNERS (   style)    ((style) & (ROUNDED | DIAGONALS | SHAPE_MASK))

Definition at line 156 of file shapes.c.

Function Documentation

shape_desc* bind_shape ( char *  name,
node_t np 

Definition at line 3837 of file shapes.c.

References agget(), shape_desc::name, NULL, safefile(), str, and streq.

Referenced by common_init_node().

shape_desc* find_user_shape ( const char *  name)

Definition at line 3803 of file shapes.c.

References NULL, and streq.

Referenced by gvrender_usershape().

char* findAttrColor ( void *  obj,
attrsym_t colorattr,
char *  dflt 

Definition at line 367 of file shapes.c.

References DEFAULT_FILL, late_nnstring(), and NULL.

void gv_initShapes ( void  )

Definition at line 4218 of file shapes.c.

References NULL.

Referenced by gvLayoutJobs().

boolean isPolygon ( node_t n)

Definition at line 1840 of file shapes.c.

References ND_shape.

Referenced by attach_attrs_and_arrows().

port resolvePort ( node_t n,
node_t other,
port oldport 

Definition at line 4196 of file shapes.c.

References port::bp, port::name, NULL, and port::side.

Referenced by beginpath(), endpath(), and resolvePorts().

void resolvePorts ( edge_t e)

Definition at line 4208 of file shapes.c.

References aghead(), agtail(), ED_head_port, ED_tail_port, and resolvePort().

Referenced by splineEdges().

void round_corners ( GVJ_t job,
pointf AF,
int  sides,
int  style,
int  filled 
shape_kind shapeOf ( node_t n)

Definition at line 1820 of file shapes.c.

References epsf_init(), ND_shape, SH_EPSF, SH_POINT, SH_POLY, SH_RECORD, and SH_UNSET.

Referenced by common_init_node(), makeAddPoly(), makeObstacle(), and makePoly().