Draws a handwriting label inside a roughened rounded box and a leader arrow from the box to a target point. The box auto-sizes to the label at draw time (device-space text metrics) and the leader leaves from the box edge nearest the target.
sketch_callout_grob(
x,
y,
xend,
yend,
label,
padding = 0.06,
corner_radius = 0.3,
roughness = 1,
bowing = 0.6,
n_passes = 2L,
seed = NULL,
arrow_length = NULL,
arrow_angle = 25,
arrow_head = NULL,
leader = "straight",
curvature = 0.3,
text_gp = gpar(),
box_gp = gpar(),
arrow_gp = gpar(),
name = NULL,
vp = NULL
)A SketchCalloutGrob grob subclass.
Box centre in npc [0,1] (scalars).
Target point in npc the leader points at (scalars). Pass
NA for both to draw a boxed label with no leader.
Label text.
Box padding around the text, in inches. Default 0.06.
Box corner rounding (fraction of half-side). Default 0.3.
Sketch parameters.
Leader arrowhead size (see
sketch_arrow_grob()).
Leader head style (see sketch_arrowheads()); NULL = the
open V.
Leader routing: "straight" (default), "elbow" (horizontal
then vertical) or "curved" (a bowed Bezier).
Bow size when leader = "curved". Default 0.3.
gpar()s for the label, the box (outline; its
fill paints the box), and the leader.
Passed to grid::gTree().
Other grob-layer:
sketch_arrow_grob(),
sketch_band_grob(),
sketch_dotplot_grob(),
sketch_ellipse_grob(),
sketch_engrave_grob(),
sketch_path_grob(),
sketch_polygon_grob(),
sketch_repel_grob(),
sketch_spray_grob(),
sketch_stroke_grob(),
sketch_wedge_grob()