Entities are placed on the chart from left to right in the order of
definition. This can be influenced by the pos
and
relative
attributes.
Specifying pos
will place the entity left or right from its default
location. E.g., specifying pos=-0.25
for entity B
makes B
to be 25% closer to its left neighbour. Thus pos
shall be specified in
terms of the unit distance between entities. (Which is 130 points - a historic
value kept for backwards compatibility.)
The next entity C
, however, will always be from a unit distance from the
entity defined just before it, so in order to specify a 25% larger space, on the
right side of entity B
, one needs to specify pos=0.25
for
C
.
![]() | ![]() |
![]() | ![]() |
![]() | ![]() |
The attribute relative
can be used to specify the base of the
pos
attribute. Take the following input, for example.
In this case C
will be placed halfway between A
and
B
.
![]() | ![]() |
Note that specifying the hscale=auto
chart option makes entity
positining automatic. This setting overrides pos
values with
the exception that it maintains the order of the entities that can be
influenced by setting their pos
attribute. See Chart Options.
In most cases it is simpler to use hscale=auto
, you need pos
only to fine-tune a chart, if automatic layout is not doing a good job.