[GRASS-SVN] r48353 - in grass/trunk: db display doc imagery include/Make raster raster3d tools vector

svn_grass at osgeo.org svn_grass at osgeo.org
Sun Sep 18 17:40:25 EDT 2011


Author: martinl
Date: 2011-09-18 14:40:25 -0700 (Sun, 18 Sep 2011)
New Revision: 48353

Removed:
   grass/trunk/display/displaydrivers.html
Modified:
   grass/trunk/db/databaseintro.html
   grass/trunk/doc/projectionintro.html
   grass/trunk/imagery/imageryintro.html
   grass/trunk/include/Make/Html.make
   grass/trunk/raster/rasterintro.html
   grass/trunk/raster3d/raster3dintro.html
   grass/trunk/tools/mkhtml.py
   grass/trunk/vector/vectorintro.html
Log:
update `intro` pages, add header and footer using mkhtml.py


Modified: grass/trunk/db/databaseintro.html
===================================================================
--- grass/trunk/db/databaseintro.html	2011-09-18 19:42:19 UTC (rev 48352)
+++ grass/trunk/db/databaseintro.html	2011-09-18 21:40:25 UTC (rev 48353)
@@ -1,20 +1,5 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
-<html>
-<head>
- <title>Database management in GRASS GIS</title>
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
- <meta name="Author" content="Markus Neteler/GRASS Development Team">
- <link rel="stylesheet" href="grassdocs.css" type="text/css">
-</head>
-<body bgcolor="white">
-
-<!-- This page is db/databaseintro.html -->
-
-<img src="grass_logo.png" alt="_\|/_ GRASS logo"><hr align=center size=6 noshade>
-
 <!-- meta page description: Database management in GRASS GIS -->
-<h2>Database management in GRASS GIS</h2>
-
+<!-- meta page index: database -->
 <h3>Attribute management in general</h3>
 
 GRASS can be linked to one or many database management systems (DBMS).
@@ -110,18 +95,9 @@
 <h3>See also</h3>
 
 <ul>
-<li><a href="vectorintro.html">Introduction to GRASS vector map processing</a></li>
-<li><a href="rasterintro.html">Introduction to GRASS raster map processing</a></li>
+  <li><a href="rasterintro.html">Introduction into raster data processing</a></li>
+  <li><a href="raster3dintro.html">Introduction into 3D raster data (voxel) processing</a></li>
+  <li><a href="vectorintro.html">Introduction into vector data processing</a></li>
+  <li><a href="imageryintro.html">Introduction into image processing</a></li>
+  <li><a href="projectionintro.html">Projections and spatial transformations</a></li>
 </ul>
-
-<HR>
-<BR>
-<a href="index.html">Main index</a> -
-<a href="database.html">database index</a> -
-<a href="full_index.html">full index</a>
-
-<p><i>Last changed: $Date$</i></p>
-<P>&copy; 2008-2011 <a href="http://grass.osgeo.org">GRASS Development Team</a></P>
-
-</body>
-</html>

Deleted: grass/trunk/display/displaydrivers.html
===================================================================
--- grass/trunk/display/displaydrivers.html	2011-09-18 19:42:19 UTC (rev 48352)
+++ grass/trunk/display/displaydrivers.html	2011-09-18 21:40:25 UTC (rev 48353)
@@ -1,37 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
-<html>
-<head>
- <title>GRASS GIS Reference Manual</title>
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
- <meta name="Author" content="GRASS Development Team">
- <link rel="stylesheet" href="grassdocs.css" type="text/css">
-</head>
-<body bgcolor="#FFFFFF">
-
-<!-- meta page description: Display drivers -->
-<h2>GRASS GIS Reference Manual</h2>
-
-This reference manual details the use of modules distributed with
-Geographic Resources Analysis Support System (GRASS), an open source (GNU
-GPL'ed), image processing and geographic information system (GIS).
-<p>
-
-The current command line rendering mechanism is direct rendering into
-a file. The driver is selected by setting the <em>GRASS_RENDER_IMMEDIATE</em> variable.
-
-<p>
-<b>Display drivers:</b>
-<ul>
-<li><a href="cairodriver.html">Cairo driver</a>
-<li><a href="pngdriver.html">PNG driver</a>
-<li><a href="psdriver.html">PS driver (Postscript)</a>
-<li><a href="htmldriver.html">HTMLMAP driver</a>
-</ul>
-<p>
-<hr>
-<a href="index.html">Help Index</a> | <a href="full_index.html">Full Index</a>
-<br>
-&copy; 2009 <a href="http://grass.osgeo.org">GRASS Development Team</a>
-
-</body>
-</html>

Modified: grass/trunk/doc/projectionintro.html
===================================================================
--- grass/trunk/doc/projectionintro.html	2011-09-18 19:42:19 UTC (rev 48352)
+++ grass/trunk/doc/projectionintro.html	2011-09-18 21:40:25 UTC (rev 48353)
@@ -1,20 +1,4 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
-<html>
-<head>
- <title>Projections in GRASS GIS</title>
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
- <meta name="Author" content="Markus Neteler/GRASS Development Team">
- <link rel="stylesheet" href="grassdocs.css" type="text/css">
-</head>
-<body bgcolor="white">
-
-<img src="grass_logo.png" alt="GRASS logo"><hr align=center size=6 noshade>
-
-<!-- file source: doc/projectionintro.html -->
-
-<!-- meta page description: Projections and spatial transformations -->
-<h2>Projections and spatial transformations in GRASS GIS</h2>
-
+<!-- meta page description: Projections and spatial transformations in GRASS GIS-->
 <h3>Introduction</h3>
 
 A GRASS location is referenced with a single projection and coordinate system
@@ -43,7 +27,7 @@
 target location (<a href="i.rectify.html">i.rectify</a>). Polynomial
 transformation of 1st, 2nd and 3rd order are supported.
 <P>
-A graphical user interface is provided by <a href="gis.m.html">gis.m</a>.
+A graphical user interface is provided by <a href="wxGUI.html">wxGUI</a>.
 <P>
 To simply translate a raster map (without stretching or rotation), the
 <a href="r.region.html">r.region</a> command can be used.
@@ -76,17 +60,12 @@
 <li> <a href="http://crs.bkg.bund.de/crs-eu/">Information and Service System for European Coordinate Reference Systems - CRS</a>
 </ul>
 
-
 <h3>See also</h3>
 
 <ul>
-<li><a href=rasterintro.html>Introduction to GRASS raster map processing</a></li>
-<li><a href=imageryintro.html>Introduction to GRASS image processing</a></li>
-<li><a href=vectorintro.html>Introduction to GRASS vector map processing</a></li>
+  <li><a href="rasterintro.html">Introduction into raster data processing</a></li>
+  <li><a href="raster3dintro.html">Introduction into 3D raster data (voxel) processing</a></li>
+  <li><a href="vectorintro.html">Introduction into vector data processing</a></li>
+  <li><a href="imageryintro.html">Introduction into image processing</a></li>
+  <li><a href="databaseintro.html">Database management</a></li>
 </ul>
-
-<HR>
-<P><a href="index.html">Main index</a> - <a href="full_index.html">full index</a>
-<P>&copy; 2008 <a href="http://grass.osgeo.org">GRASS Development Team</a></P>
-</body>
-</html>

Modified: grass/trunk/imagery/imageryintro.html
===================================================================
--- grass/trunk/imagery/imageryintro.html	2011-09-18 19:42:19 UTC (rev 48352)
+++ grass/trunk/imagery/imageryintro.html	2011-09-18 21:40:25 UTC (rev 48353)
@@ -1,19 +1,5 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
-<html>
-<head>
- <title>Image processing in GRASS GIS</title>
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
- <meta name="Author" content="Markus Neteler/GRASS Development Team">
- <link rel="stylesheet" href="grassdocs.css" type="text/css">
-</head>
-<body bgcolor="white">
-
-<img src="grass_logo.png" alt="GRASS logo"><hr align=center size=6 noshade>
-
-<!-- meta page description: Image processing introduction -->
-<h2>Image processing in GRASS GIS</h2>
-
-
+<!-- meta page description: Image processing in GRASS GIS -->
+<!-- meta page index: imagery -->
 <h3>Image data in general</h3>
 
 In GRASS, image data are identical to <a href="rasterintro.html">raster data</a>.
@@ -24,7 +10,7 @@
 NOT pass through the center of the grid cells at the edge of the map,
 but along the edge of the map itself.
 
-<P>
+<p>
 As a general rule in GRASS:
 <ol>
 <li> Raster/imagery output maps have their bounds and resolution equal
@@ -162,20 +148,11 @@
 
 <ul>
 <li>The GRASS 4 
-    <em><A HREF="http://grass.itc.it/gdp/imagery/grass4_image_processing.pdf">Image
-     Processing manual</A></EM>
-<li><a href=rasterintro.html>Introduction to GRASS 2D raster map processing</a></li>
-<li><a href=raster3dintro.html>Introduction to GRASS 3D raster map (voxel) processing</a></li>
-<li><a href=vectorintro.html>Introduction to GRASS vector map processing</a></li>
+    <em><a href="http://grass.osgeo.org/gdp/imagery/grass4_image_processing.pdf">Image
+     Processing manual</A></em></li>
+  <li><a href="rasterintro.html">Introduction into raster data processing</a></li>
+  <li><a href="raster3dintro.html">Introduction into 3D raster data (voxel) processing</a></li>
+  <li><a href="vectorintro.html">Introduction into vector data processing</a></li>
+  <li><a href="databaseintro.html">Database management</a></li>
+  <li><a href="projectionintro.html">Projections and spatial transformations</a></li>
 </ul>
-
-<HR>
-
-<P>
-<a href="index.html">Main index</a> - <a href="imagery.html">imagery index</a> - 
-<a href="full_index.html">full index</a>
-</p>
-<P>&copy; 2008 <a href="http://grass.osgeo.org">GRASS Development Team</a></P>
-
-</body>
-</html>

Modified: grass/trunk/include/Make/Html.make
===================================================================
--- grass/trunk/include/Make/Html.make	2011-09-18 19:42:19 UTC (rev 48352)
+++ grass/trunk/include/Make/Html.make	2011-09-18 21:40:25 UTC (rev 48353)
@@ -12,7 +12,7 @@
 IMGSRC := $(wildcard *.png) $(wildcard *.jpg)
 
 $(HTMLDIR)/%.html: %.html %.tmp.html $(HTMLSRC) | $(HTMLDIR)
-	$(PYTHON) $(GISBASE)/tools/mkhtml.py $* > $@
+	$(PYTHON) $(GISBASE)/tools/mkhtml.py $* $(GRASS_VERSION_DATE) > $@
 ifneq ($(strip $(IMGSRC)),)
 	if test -n "$(IMGSRC)" ; then \
 		$(MAKE) $(patsubst %,$(HTMLDIR)/%,$(IMGSRC)) ; \

Modified: grass/trunk/raster/rasterintro.html
===================================================================
--- grass/trunk/raster/rasterintro.html	2011-09-18 19:42:19 UTC (rev 48352)
+++ grass/trunk/raster/rasterintro.html	2011-09-18 21:40:25 UTC (rev 48353)
@@ -1,18 +1,5 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
-<html>
-<head>
- <title>Raster data processing in GRASS GIS</title>
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
- <meta name="Author" content="Markus Neteler/GRASS Development Team">
- <link rel="stylesheet" href="grassdocs.css" type="text/css">
-</head>
-<body bgcolor="white">
-
-<img src="grass_logo.png" alt="GRASS logo"><hr align=center size=6 noshade>
-
-<!-- meta page description: Raster data processing -->
-<h2>Raster data processing in GRASS GIS</h2>
-
+<!-- meta page description: Raster data processing in GRASS GIS -->
+<!-- meta page index: raster -->
 <h3>Raster maps in general</h3>
 
 A "raster map" is a data layer consisting of a gridded array of cells.
@@ -266,15 +253,9 @@
 <h3>See also</h3>
 
 <ul>
-<li><a href=vectorintro.html>Introduction to GRASS vector map processing</a></li>
-<li><a href=raster3dintro.html>Introduction to GRASS 3D raster map (voxel) processing</a></li>
+  <li><a href="raster3dintro.html">Introduction into 3D raster data (voxel) processing</a></li>
+  <li><a href="vectorintro.html">Introduction into vector data processing</a></li>
+  <li><a href="imageryintro.html">Introduction into image processing</a></li>
+  <li><a href="databaseintro.html">Database management</a></li>
+  <li><a href="projectionintro.html">Projections and spatial transformations</a></li>
 </ul>
-
-<HR>
-<P>
-<a href="index.html">Main index</a> - <a href="raster.html">raster index</a>
- - <a href="full_index.html">full index</a>
-</P>
-<P>&copy; 2008 <a href="http://grass.osgeo.org">GRASS Development Team</a></P>
-</body>
-</html>

Modified: grass/trunk/raster3d/raster3dintro.html
===================================================================
--- grass/trunk/raster3d/raster3dintro.html	2011-09-18 19:42:19 UTC (rev 48352)
+++ grass/trunk/raster3d/raster3dintro.html	2011-09-18 21:40:25 UTC (rev 48353)
@@ -1,19 +1,6 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
-<html>
-<head>
- <title>3D Raster data (voxel) processing in GRASS GIS</title>
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
- <meta name="Author" content="Markus Neteler/GRASS Development Team">
- <link rel="stylesheet" href="grassdocs.css" type="text/css">
-</head>
-<body bgcolor="white">
-
-<img src="grass_logo.png" alt="GRASS logo"><hr align=center size=6 noshade>
-
-<!-- meta page description: 3D Raster data (voxel) introduction -->
-<h2>3D Raster data (voxel) in GRASS GIS</h2>
-
-GRASS GIS raster3d maps use the same coordinate system as
+<!-- meta page description: 3D raster data (voxel) processing in GRASS GIS -->
+<!-- meta page index: raster3D -->
+GRASS GIS 3D raster maps use the same coordinate system as
 2D raster maps (row count from north to south) with an additional z dimension (depth)
 counting from bottom to top. The upper left corner (NW) is the origin of the volume. 
 Volumes are stored using a tile cache based approach. This allows abritrary read 
@@ -21,15 +8,10 @@
 with <a href="r3.in.ascii.html">r3.in.ascii</a> or the data can be retiled using
 <a href="r3.retile.html">r3.retile</a> after import or creation.
 
-
-<center>
-<img src="g3d_volume_layout.png" border=0><BR>
-<table border=0 width=700>
-<tr><td><center>
+<div align="center" style="margin: 10px">
+<img src="g3d_volume_layout.png" border=0><br>
 <i>The volume coordinate system and tile layout of the RASTER3D library</i>
-</center></td></tr>
-</table>
-</center>
+</div>
 
 <h3>3D Raster (voxel) import</h3>
 
@@ -95,10 +77,10 @@
 
 <h3>See also</h3>
 
-<a href=rasterintro.html>Introduction to GRASS raster map processing</a>
-
-<HR>
-<P><a href="index.html">Main index</a> - <a href="raster3D.html">raster3D index</a> - <a href="full_index.html">full index</a>
-<P>&copy; 2008 <a href="http://grass.osgeo.org">GRASS Development Team</a></P>
-</body>
-</html>
+<ul>
+  <li><a href="rasterintro.html">Introduction into raster data processing</a></li>
+  <li><a href="vectorintro.html">Introduction into vector data processing</a></li>
+  <li><a href="imageryintro.html">Introduction into image processing</a></li>
+  <li><a href="databaseintro.html">Database management</a></li>
+  <li><a href="projectionintro.html">Projections and spatial transformations</a></li>
+</ul>

Modified: grass/trunk/tools/mkhtml.py
===================================================================
--- grass/trunk/tools/mkhtml.py	2011-09-18 19:42:19 UTC (rev 48352)
+++ grass/trunk/tools/mkhtml.py	2011-09-18 21:40:25 UTC (rev 48353)
@@ -3,13 +3,16 @@
 ############################################################################
 #
 # MODULE:       mkhtml.py
-# AUTHOR(S):    Markus Neteler, Glynn Clements
-# PURPOSE:      create HTML manual page snippets
-# COPYRIGHT:    (C) 2007,2009,2011 by Glynn Clements and the GRASS Development Team
+# AUTHOR(S):    Markus Neteler
+#               Glynn Clements
+#               Martin Landa <landa.martin gmail.com>
+# PURPOSE:      Create HTML manual page snippets
+# COPYRIGHT:    (C) 2007, 2009, 2011 by Glynn Clements
+#                and the GRASS Development Team
 #
-#               This program is free software under the GNU General Public
-#               License (>=v2). Read the file COPYING that comes with GRASS
-#               for details.
+#               This program is free software under the GNU General
+#               Public License (>=v2). Read the file COPYING that
+#               comes with GRASS for details.
 #
 #############################################################################
 
@@ -19,12 +22,15 @@
 import re
 
 pgm = sys.argv[1]
+if len(sys.argv) > 1:
+    year = sys.argv[2]
+else:
+    year = "2011"
 
 src_file = "%s.html" % pgm
 tmp_file = "%s.tmp.html" % pgm
 
-header_tmpl = string.Template(\
-"""<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
+header_base = """<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
 <html>
 <head>
 <title>GRASS GIS Manual: ${PGM}</title>
@@ -33,14 +39,27 @@
 </head>
 <body bgcolor="white">
 <img src="grass_logo.png" alt="GRASS logo"><hr align=center size=6 noshade>
-<h2>NAME</h2>
+"""
+
+header_nopgm = """<h2>${PGM}</h2>
+"""
+
+header_pgm = """<h2>NAME</h2>
 <em><b>${PGM}</b></em>
+"""
+
+footer_index = string.Template(\
+"""<hr>
+<p><a href="index.html">Main index</a> - <a href="${INDEXNAME}.html">${INDEXNAME} index</a> - <a href="full_index.html">Full index</a></p>
+<p>&copy; 2003-${YEAR} <a href="http://grass.osgeo.org">GRASS Development Team</a></p>
+</body>
+</html>
 """)
 
-footer_tmpl = string.Template(\
+footer_noindex = string.Template(\
 """<hr>
-<p><a href="index.html">Main index</a> - <a href="$INDEXNAME.html">$INDEXNAME index</a> - <a href="full_index.html">Full index</a></p>
-<p>&copy; 2003-2011 <a href="http://grass.osgeo.org">GRASS Development Team</a></p>
+<p><a href="index.html">Main index</a> - <a href="full_index.html">Full index</a></p>
+<p>&copy; 2003-${YEAR} <a href="http://grass.osgeo.org">GRASS Development Team</a></p>
 </body>
 </html>
 """)
@@ -56,6 +75,13 @@
 
 src_data = read_file(src_file)
 
+desc = re.search('(<!-- meta page description:)(.*)(-->)', src_data, re.IGNORECASE)
+if desc:
+    pgm = desc.group(2).strip()
+    header_tmpl = string.Template(header_base + header_nopgm)
+else:
+    header_tmpl = string.Template(header_base + header_pgm)
+
 if not re.search('<html>', src_data, re.IGNORECASE):
     tmp_data = read_file(tmp_file)
     if not re.search('<html>', tmp_data, re.IGNORECASE):
@@ -78,7 +104,6 @@
     'g': 'general',
     'i': 'imagery',
     'm': 'misc',
-    'pg': 'postGRASS',
     'ps': 'postscript',
     'p': 'paint',
     'r': 'raster',
@@ -87,8 +112,14 @@
     'v': 'vector'
     }
 
-mod_class = pgm.split('.', 1)[0]
-index_name = index_names.get(mod_class, mod_class)
+index = re.search('(<!-- meta page index:)(.*)(-->)', src_data, re.IGNORECASE)
+if index:
+    index_name = index.group(2).strip()
+else:
+    mod_class = pgm.split('.', 1)[0]
+    index_name = index_names.get(mod_class, '')
 
-sys.stdout.write(footer_tmpl.substitute(INDEXNAME = index_name))
-
+if index_name:
+    sys.stdout.write(footer_index.substitute(INDEXNAME = index_name, YEAR = year))
+else:
+    sys.stdout.write(footer_noindex.substitute(YEAR = year))

Modified: grass/trunk/vector/vectorintro.html
===================================================================
--- grass/trunk/vector/vectorintro.html	2011-09-18 19:42:19 UTC (rev 48352)
+++ grass/trunk/vector/vectorintro.html	2011-09-18 21:40:25 UTC (rev 48353)
@@ -1,18 +1,5 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
-<html>
-<head>
- <title>Vector data processing in GRASS GIS</title>
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
- <meta name="Author" content="Markus Neteler/GRASS Development Team">
- <link rel="stylesheet" href="grassdocs.css" type="text/css">
-</head>
-<body bgcolor="white">
-
-<img src="grass_logo.png" alt="_\|/_ GRASS logo"><hr align=center size=6 noshade>
-
-<!-- meta page description: Vector data processing -->
-<h2>Vector data processing in GRASS GIS</h2>
-
+<!-- meta page description: Vector data processing in GRASS GIS -->
+<!-- meta page index: vector -->
 <h3>Vector maps in general</h3>
 
 A "vector map" is a data layer consisting of a number of sparse features
@@ -355,15 +342,10 @@
 <h3>See also</h3>
 
 <ul>
-<li><a href="databaseintro.html">Introduction to GRASS database management</a></li>
-<li><a href="rasterintro.html">Introduction to GRASS raster map processing</a></li>
-<li><a href="raster3dintro.html">Introduction to GRASS 3D raster map (voxel) processing</a></li>
+  <li><a href="rasterintro.html">Introduction into raster data processing</a></li>
+  <li><a href="raster3dintro.html">Introduction into 3D raster data (voxel) processing</a></li>
+  <li><a href="vectorintro.html">Introduction into vector data processing</a></li>
+  <li><a href="imageryintro.html">Introduction into image processing</a></li>
+  <li><a href="databaseintro.html">Database management</a></li>
+  <li><a href="projectionintro.html">Projections and spatial transformations</a></li>
 </ul>
-
-<HR>
-<BR>
-<a href="index.html">Main index</a> - <a href="vector.html">vector index</a> - <a href="full_index.html">full index</a>
-<P>&copy; 2008-2011 <a href="http://grass.osgeo.org">GRASS Development Team</a></P>
-
-</body>
-</html>



More information about the grass-commit mailing list