d.frame.html 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899
  1. <h2>DESCRIPTION</h2>
  2. <em>d.frame</em> manages display frames on the current user's graphics
  3. monitor. Graphics are displayed in rectangular frames on whatever
  4. graphics monitor the user is currently directing GRASS display output
  5. to (defined by <em><a href="d.mon.html">d.mon</a></em> module). These
  6. frames are created and managed with this module.
  7. <p>
  8. Note that GRASS frame contents <em>are not</em> retained when one
  9. frame covers another. You cannot shuffle frames from top to bottom and
  10. then back again. They simply define rectangular areas on the screen
  11. where subsequent drawing will occur.
  12. <h2>NOTES</h2>
  13. The coordinates for the <b>at</b> option are stated in the form
  14. <em>top,bottom,left,right</em> values are in percent. The upper-left
  15. corner of the graphics monitor always is at location 0,0 while the
  16. monitor's lower-right corner is always at 100,100.
  17. <p>
  18. If the user has created multiple display frames that overlap one another,
  19. whatever the user displays in the active frame will overwrite
  20. those portions of the underlying frame where these frames overlap.
  21. <h2>EXAMPLE</h2>
  22. <div class="code"><pre>
  23. # start a new graphics monitor, the data will be rendered to
  24. # /tmp/map.png image output file of size 600x540px
  25. d.mon cairo out=/tmp/map.png width=600 height=540 --o
  26. # set up region
  27. g.region raster=elevation
  28. # remove all frames and erase the current graphics monitor
  29. d.frame -e
  30. # create a first frame and display 'landuse96_28m' raster map including text label
  31. # order: bottom,top,left,right - in percent
  32. d.frame -c frame=first at=0,50,0,50
  33. d.rast landuse96_28m
  34. d.text text='Landuse' bgcolor=220:220:220 color=black size=6
  35. # create a second frame and display 'streams' vector map
  36. d.frame -c frame=second at=0,50,50,100
  37. d.vect streams color=blue
  38. d.text text='Streams' bgcolor=220:220:220 color=black size=6
  39. # create a third frame and display 'elevation' raster map including text label and scale
  40. d.frame -c frame=third at=50,100,0,50
  41. d.rast elevation
  42. d.text text='Elevation' bgcolor=220:220:220 color=black size=6
  43. d.barscale at=0,10 style=line bgcolor=none
  44. # create a fourth frame and display RGB composition map including text label
  45. d.frame -c frame=fourth at=50,100,50,100
  46. d.rgb red=lsat7_2002_30 green=lsat7_2002_20 blue=lsat7_2002_10
  47. d.text text='RGB true colors' bgcolor=220:220:220 color=black size=6
  48. # release the current graphics monitor
  49. d.mon -r
  50. </pre></div>
  51. <center>
  52. <img src="d_frame.png" alt="d.frame example"><br>
  53. <em>Figure: d.frame example</em>
  54. </center>
  55. <h2>SEE ALSO</h2>
  56. <em>
  57. <a href="d.erase.html">d.erase</a>,
  58. <a href="d.info.html">d.info</a>,
  59. <a href="d.mon.html">d.mon</a>,
  60. <a href="d.redraw.html">d.redraw</a>
  61. </em>
  62. <p>
  63. <a href="variables.html#list-of-selected-grass-environment-variables-for-rendering">GRASS environment variables for
  64. rendering</a> (GRASS_RENDER_FRAME)
  65. <h2>AUTHOR</h2>
  66. Martin Landa, Czech Technical University in Prague, Czech Republic
  67. <p>
  68. Based on <em>d.frame</em> from GRASS 6:<br>
  69. James Westervelt, U.S. Army Construction Engineering Research
  70. Laboratory<br>
  71. Michael Shapiro, U.S. Army Construction Engineering
  72. Research Laboratory
  73. <!--
  74. <p>
  75. <i>Last changed: $Date$</i>
  76. -->