d.grid(1grass)
π d.grid(1grass) π
okay bestie, welcome to d.grid from the GRASS User's Manual β she overlays a user-specified grid in the active display frame on the graphics monitor, and honestly? she ate.
π KEYWORDS: display, cartography, graticule, grid
β¨ SYNOPSIS β¨
d.grid
d.grid --help
d.grid [-agwcdfnbt] size=value [origin=east,north] [direction=string]
[width=float] [color=name] [border_color=name] [text_color=name]
[bgcolor=name] [fontsize=integer] [--help] [--verbose] [--quiet]
[--ui]
π© Flags π©
-aβ Align the origin to the east-north corner of the current region-gβ Draw geographic grid (referenced to current ellipsoid)-wβ Draw geographic grid (referenced to WGS84 ellipsoid)-cβ Draw'+'marks instead of grid lines-dβ Draw'.'marks instead of grid lines-fβ Draw fiducial marks instead of grid lines-nβ Disable grid drawing-bβ Disable border drawing-tβ Disable text drawing--helpβ Print usage summary--verboseβ Verbose module output--quietβ Quiet module output--uiβ Force launching GUI dialog
π Parameters π
size=value[required] β Size of grid to be drawn (in map units).0for north-south resolution of the current region. In map units orDDD:MM:SSformat. Example:"1000"or"0:10"origin=east,northβ Lines of the grid pass through this coordinate. Default:0,0direction=stringβ Draw only east-west lines, north-south lines, or both. Options:both,east-west,north-south. Default:bothwidth=floatβ Grid line widthcolor=nameβ Grid color. Either a standard color name orR:G:Btriplet. Default:grayborder_color=nameβ Border color. Either a standard color name orR:G:Btriplet. Default:blacktext_color=nameβ Text color. Either a standard color name orR:G:Btriplet. Default:graybgcolor=nameβ Background color. Either a standard color name,R:G:Btriplet, or"none". Default:nonefontsize=integerβ Font size for gridline coordinate labels. Options:1-72. Default:9
π DESCRIPTION π
d.grid overlays a grid of user-defined size and color in the active display frame on the graphics monitor. The grid can be created as a standard rectangular grid or a geographic grid. two iconic options, no notes.
If the user provides a -g flag a geographic (projected) grid will be drawn. With the -g flag the size argument accepts both decimal degrees and colon separated ddd:mm:ss coordinates (eg. 00:30:00 for half of a degree). Heads up though: a geographic grid cannot be drawn for a latitude/longitude or XY projection. like, at all. that's just the rules. π«
Colors may be standard named GRASS colors (red, green, aqua, etc.) or a numerical R:G:B triplet, where component values range from 0-255. Grid color can be set with option color. Options text_color and bgcolor set the color of the text and its background. match your outfit to your grid, periodt. π
- The grid drawing may be turned off by using the
-nflag. - The border drawing may be turned off by using the
-bflag. - The coordinate text may be turned off by using the
-tflag.
To draw grid lines at different intervals, e.g. at high latitudes, you can run the module twice, once with direction=east-west at one interval size, and again with direction=north-south at another interval size. run her twice, she doesn't mind. π₯
π EXAMPLES π
To draw a red geographic grid with 30 minute grid spacing, run one of the following commands:
d.grid -g size=00:30:00 color=red
or
d.grid -g size=0.5 color=255:0:0
Figure: Showing a geographic grid in red line color
To draw a blue standard rectangular grid at a 500 (meter) spacing run the following:
d.grid size=500 color=blue
Figure: Showing a rectangular grid in blue line color
π SEE ALSO π
d.barscale,d.legend,d.geodesic,d.rhumbline,d.erase,d.frame,d.rast,v.mkgrid
π AUTHORS π
- James Westervelt, U.S. Army Construction Engineering Research Laboratory
- Geogrid support: Bob Covill
- Border support: Markus Neteler
- Text and RGB support: Hamish Bowman
- Background color implemented as part of GSoC 2016 by Adam Laza, CTU in Prague
π¦ SOURCE CODE π¦
Available at: d.grid source code (history)
Latest change: Monday Dec 08 21:47:55 2025 in commit: d3c6479bef77a58e3b5d85259303dbfb9c1babe8
Main index | Display index | Topics index | Keywords index | Graphical index | Full index
and that's the whole page bestie, no cap, every flag and every default accounted for π
Β© 2003-2026 GRASS Development Team, GRASS 8.5.0 Reference Manual β and yes, this is GRASS 8.5.0 talking, d.grid(1grass), bye babes β¨ππ¦π
π¦ 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