v.label.sa(1grass)

✨ v.label.sa ✨

okay bestie, welcome to v.label.sa from the GRASS User's Manual πŸ’– this is the little icon that makes labels sit pretty β€” optimally placed labels for your vector map(s), no cap πŸ‘‘

KEYWORDS: vector, paint labels πŸŽ€


🌸 SYNOPSIS 🌸

v.label.sa
v.label.sa --help
v.label.sa map=name  [type=string[,string,...]]   [layer=string]
column=string labels=name font=string  [size=float]   [isize=float]
[charset=string]   [color=string]   [hcolor=string]   [hwidth=float]
[background=string]   [opaque=yes|no]   [border=string]   [width=float]
[--help]  [--verbose]  [--quiet]  [--ui]

πŸ¦‹ Flags

  • --help β€” prints the usage summary, your lil cheat sheet 🫢
  • --verbose β€” verbose module output, she's chatty and we love that
  • --quiet β€” quiet module output, shhh 🀫
  • --ui β€” force launches the GUI dialog, for the visual girlies ✨

πŸ“ Parameters

  • map=name [required] β€” name of the vector map. Or a data source for direct OGR access πŸ’…
  • type=string[,string,...] β€” input feature type. Options: point, line, area. Default: point,line,area 🌈
  • layer=string β€” layer number or name. Vector features can have category values in different layers, and this number decides which layer we're using. When you're doing direct OGR access, this is literally the layer name. Default: 1
  • column=string [required] β€” name of the attribute column to be used for labels πŸ‘‘
  • labels=name [required] β€” the name for your new paint-label file πŸŽ€
  • font=string [required] β€” name of the TrueType font, as listed in the fontcap
  • size=float β€” label size, in map-units. Default: 100
  • isize=float β€” icon size of point features, in map-units. Default: 10
  • charset=string β€” character encoding (default: UTF-8). Default: UTF-8
  • color=string β€” text color. Options: aqua, black, blue, brown, cyan, gray, green, grey, indigo, magenta, orange, purple, red, violet, white, yellow. Default: black
  • hcolor=string β€” highlight color for text. Options: none, aqua, black, blue, brown, cyan, gray, green, grey, indigo, magenta, orange, purple, red, violet, white, yellow. Default: none
  • hwidth=float β€” width of highlight coloring. Default: 0
  • background=string β€” background color. Options: none, aqua, black, blue, brown, cyan, gray, green, grey, indigo, magenta, orange, purple, red, violet, white, yellow. Default: none
  • opaque=yes|no β€” opaque to vector, and this is only relevant if a background color is selected, fyi. Options: yes, no. Default: yes
  • border=string β€” border color. Options: none, aqua, black, blue, brown, cyan, gray, green, grey, indigo, magenta, orange, purple, red, violet, white, yellow. Default: none
  • width=float β€” border width, only for ps.map output. Default: 0

πŸ’œ DESCRIPTION πŸ’œ

so v.label.sa makes a label-file from a GRASS vector map, with the labels created from attributes in the attached table 🫢 and here's the slay: the labels get placed in as optimal a place as possible. main character placement energy, honestly. The label file has the exact same syntax as the one created by v.label β€” twins fr fr πŸ’…


🌈 EXAMPLE 🌈

North Carolina example, iconic:

# get font names:
d.font -L
v.label.sa roadsmajor labels=roads_labels column=ROAD_NAME color=red \
           background=white size=250 font=Vera
# set region:
g.region raster=lsat7_2002_10 -p
# display:
d.rgb b=lsat7_2002_10 g=lsat7_2002_20 r=lsat7_2002_30
d.vect roadsmajor col=yellow
d.labels roads_labels

Road labeling with v.label.sa (Raleigh, North Carolina, USA, area) πŸ¦‹


⭐ REFERENCES ⭐

Edmondson, Christensen, Marks and Shieber: A General Cartographic Labeling Algorithm, Cartographica, Vol. 33, No. 4, Winter 1996, pp. 13-23. The algorithm works by the principle of Simulated Annealing πŸ”₯ (yes bestie, simulated annealing, it's giving thermodynamics but make it cartography)


πŸŽ€ SEE ALSO πŸŽ€

  • d.label
  • d.labels
  • ps.map
  • Wikipedia article on simulated annealing

πŸ‘‘ AUTHOR πŸ‘‘

Wolf Bergenheim


πŸ’– SOURCE CODE πŸ’–

Available at: v.label.sa source code (history)

Latest change: Friday Apr 17 01:04:26 2026 in commit: 32a143358df26b2e518b03c7e0d79541e8d1e5b1

Main index | Vector index | Topics index | Keywords index | Graphical index | Full index

Β© 2003-2026 GRASS Development Team, GRASS 8.5.0 Reference Manual


and that's the whole page bestie πŸ’… that was GRASS 8.5.0 on v.label.sa, last touched Friday Apr 17 01:04:26 2026, Β© 2003-2026 GRASS Development Team β€” go label something pretty 🌸✨🫢

πŸ“¦ where this page comes from