Previous: Arrow Labels and Markers, Up: Arrows in Block Diagrams [Contents]
The following attributes apply to arrows. All of them can be made part of a style,
except via
and routing.order
.
line.*
These set the line style of the arrow. See Common Attributes for more.
line.corner
and line.radius
is used when the routing
attribute is set to polygon
.
text.*
label.*
These attributes specify one label of the arrow.
marker.*
Together with label.align
these specify one marker on the arrow.
via
Sometimes you want to better influence what path the arrow takes. In this case
use the via
attribute. You can specify any of the four sides of any block, for example
block@top
or any corner, such as block@bottomleft
.
The arrow will go around the named block on that side.
You can also specify a coordinate - this will be a mandatory waypoint for the
arrow.
You can specify any number of via
attributes mixing the blockside and
coordinate types as you wish. The arrow will visit them in the specified order.
Note that Msc-generator
still tries to pick the shortest route (while staying on the specified side of the
specified block(s) and going through the mandatory waypoints).
Also note that if the arrow starts from or ends at a block and due to the
via
attributes it goes through that block several times, it is trimmed
to the first crossing.
![]() | ![]() |
cross
cross_all
You can specify these attributes several times, if needed. Their value can be a block name
(or a list of block names separated by plus signs). The arrow or line is allowed to cross
any block, if listed in the cross
attribute; or any block and its children if listed
in the cross_all
attribute. This complements the allow_arrows
attribute of blocks.
While that attribute allows any and all arrows to cross the block it is set on, the
cross
and cross_all
attributes can be specified selectively per arrow.
distance
This attribute dictates how large is the distance between the arrow and the blocks it goes around.
Setting it to single number (meant in pixels) will impact all blocks it goes around.
Setting it in the sytnax <block>@<number>
will make the arrow to use this distance only for
<block>
. You can apply this attribute multiple times, or use the plus sign to list
several blocks, like distance=<block>+<block>+...@<number>
.
routing
This attribute governs, how arrows are laid out. If set to straight
the arrow will go between the two blocks in a straight line, potentially over
other blocks. If set to horizontal
or vertical
, the straight
line will be parallel to the X or Y axis, respectively.
If set to polygon
, the arrow will go the shortest path around blocks in
the way. manhattan
will result in using only horizontal and vertical edges
attempting to go around blocks in the way.
For the latter two modes, the line.corner
and line.radius
attributes
can be used to round the vertices of the polygon. If set to curvy
(default),
the arrow will avoid blocks in the way but a smoothing is applied to make the arrow
one smooth line. There are limitations to this, but Msc-generator attempts to
do a good job.
routing.factor
This attribute governs, how the arrow layout algorithm trades off between
minimizing arrow length and minimizing the number of turns the arrow makes.
The value 0 means considering only arrow length (default), while 1 means
considering only minimizing turns. Values in between balance.
Note that arrow layout starts with a straight line between start and end (or
waypoints) and then attempts to go round blocks in-between. Thus, even if you
prefer minimizing turns, it will not by itself consider a big detour. Use the
via
attribute for that.
routing.clip_block
If set to yes (default) arrows/lines starting/ending at a block will be clipped by that block. Also applies if the ending is specified as a coordinate using the same, single block in the specification of both the X and Y coordinate.
route.arrow_distance
Overlapping arrow endings will get spaced apart this much, see Automatic De-Overlapping at Arrow Ends. Default is 5 pixels.
routing.extend
If arrow endings get outside the block due to de-overlapping, we extend them
to the perimiter of the block, if this is set to yes
(default).
![]() | ![]() |
routing.block_others
If set, it prevents overlap between the middle of arrows subject to de-overlapping, see Automatic De-Overlapping at Arrow Ends.
routing.order
If the above is set, the layout order of arrows is important. You can assign a number to this attribute to govern the repeated layout of arrows after their endpoints have been shifted due to overlaps.
draw_before
draw_after
You can specify one or more blocks (separated by plus signs or via repeating the attribute) the block shall be drawn before or after. You can use only one of the two attributes for any diagram elements. Setting one will automatically clear the other.
Arrows and lines have a single default style arrow
. Then we have eight refinement
styles --
, ==
, ..
, ++
, ->
, =>
, >
and
>>
. The former four sets routing=straight
, but otherwise they
are just setting the line style by default. Of course, you can change them. Arrow labels
have the default style label
. This is also the default style for label-less
markers, so there you can set the default marker type, too.
Previous: Arrow Labels and Markers, Up: Arrows in Block Diagrams [Contents]