d.barscale(1grass)
π d.barscale β the manual, but make it cute π
okay so bestie, you're holding the manual page for d.barscale (that's d.barscale(1grass) if we're being formal and official about it β¨). It lives in the GRASS User's Manual and it is exactly what it sounds like: it puts a little scale bar on your graphics monitor so everyone knows how far "over there" actually is. πΈ
β¨ NAME β¨
d.barscale β displays a barscale on the graphics monitor. that's it, that's the whole job, and it does it gorgeously π
π KEYWORDS π
display, cartography
(iykyk. this is cartography girlie territory π)
π¦ SYNOPSIS π¦
d.barscale
d.barscale --help
d.barscale [-ftn] [style=string] [at=x,y] [length=integer]
[units=string] [label=string] [segment=integer] [color=name]
[bgcolor=name] [text_position=string] [width_scale=float]
[font=string] [fontsize=float] [path=name] [charset=string]
[--help] [--verbose] [--quiet] [--ui]
π Flags π
-fβ use feet/miles instead of meters. imperial era, we're doing it π«Ά-tβ draw the scale bar without any text. just the bar, no words, no talking, silent queen energy π-nβ display the north-arrow symbol. so you know which way is up, because apparently that's not obvious π--helpβ print usage summary. the "explain it to me again" button π--verboseβ verbose module output. it will tell you everything, no cap π£οΈ--quietβ quiet module output. shhh. silent mode activated π--uiβ force launching GUI dialog. for when clicking is simply easier than typing, and honestly? valid β¨
πΈ Parameters πΈ
style=stringβ type of barscale to draw. Options:classic,line,solid,hollow,full_checker,part_checker,mixed_checker,tail_checker,up_ticks,down_ticks,both_ticks,arrow_ends. Default:classic.classic: Classic styleline: Line stylesolid: Solid stylehollow: Hollow stylefull_checker: Full checker stylepart_checker: Part checker stylemixed_checker: Mixed checker styletail_checker: Tail checker styleup_ticks: Up ticks styledown_ticks: Down ticks styleboth_ticks: Both ticks stylearrow_ends: Arrow ends style
twelve whole styles bestie, pick your fighter π
at=x,yβ screen coordinates of the rectangle's top-left corner.(0,0)is lower-left of the display frame. Options:0-100. Default:0.0,10.0.
watch the coordinates bestie, (0,0) is the lower-left, not the top-left. do not come for me when your barscale shows up somewhere unhinged π
length=integerβ length of barscale in map units. Options:0-. Default:0.
(0 means "you decide for me" and it justβ¦ does the thing. iconic behavior honestly π§)
units=stringβ barscale units to display. Options:meters,kilometers,feet,miles.label=stringβ custom label of unit. name it whatever you want, main character πsegment=integerβ number of segments. Options:1-100. Default:10.color=nameβ bar scale and text color. Either a standard color name orR:G:Btriplet. Default:black.bgcolor=nameβ background color (drawn behind the bar). Either a standard color name,R:G:Btriplet, or"none". Default:white.text_position=stringβ text position. Options:under,over,left,right. Default:right.width_scale=floatβ scale factor to change bar width. Options:0.5-100. Default:1.font=stringβ font name.fontsize=floatβ font size. Options:1-360. Default:12.path=nameβ path to font file.charset=stringβ text encoding (only applicable to TrueType fonts).
π DESCRIPTION π
d.barscale displays a barscale on the graphics monitor at the given screen coordinates. and if you don't hand it any coordinates? it just quietly draws that barscale in the bottom left of the display. considerate. thoughtful. a little bit of a people pleaser but we love her for it π«Ά
the barscale can be drawn in a whole bunch of styles (peep the style parameter above for their previews π). so many looks. so many vibes. it's giving fashion week but for cartography π
π¨ NOTE π¨
d.barscalewill not work with a Lat/Lon coordinate reference system, because the horizontal scale distance changes with latitude. not a bug, just physics being dramatic π tryd.gridinstead, bestie.
π SEE ALSO π
d.graphd.gridd.legendd.northarrowg.region
the whole display-module friend group, all linked up π¦
π AUTHORS π
- Unknown, from USACE/CERL.
- Major rewrite for GRASS 7 by Hamish Bowman
(shoutout to whoever "Unknown" is, you ate and we'll never know your name πβ)
π¦ SOURCE CODE π¦
Available at: d.barscale source code (history)
Latest change: Thursday May 08 14:17:52 2025 in commit: 3caa352f78f86a51ca463a6f1ba7ffe3db9771df
Main index | Display index | Topics index | Keywords index | Graphical index | Full index
okay and that's the whole page bestie, you made it to the bottom, so here's your lil sign-off π β this whole thing is Β© 2003-2026 GRASS Development Team, from the GRASS 8.5.0 Reference Manual, and yeah, it's literally GRASS 8.5.0, d.barscale(1grass), periodt. go draw that barscale, you absolute icon β¨ππ
π¦ where this page comes from
- alpine 3.24: grass-gis-doc 8.5.0-r1 Β· GPL-2.0-or-later
- ubuntu stonking: grass-doc 8.5.0-1ubuntu1 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms