[GRASS-SVN] r70189 - in grass/branches/releasebranch_7_2: doc include/Make man man/sphinx misc/m.cogo misc/m.measure misc/m.nviz.image scripts/m.proj tools

svn_grass at osgeo.org svn_grass at osgeo.org
Sun Jan 1 13:43:48 PST 2017


Author: neteler
Date: 2017-01-01 13:43:48 -0800 (Sun, 01 Jan 2017)
New Revision: 70189

Added:
   grass/branches/releasebranch_7_2/doc/gi_miscellaneous.jpg
Removed:
   grass/branches/releasebranch_7_2/doc/gi_misc.jpg
Modified:
   grass/branches/releasebranch_7_2/include/Make/Docs.make
   grass/branches/releasebranch_7_2/man/Makefile
   grass/branches/releasebranch_7_2/man/build_check.py
   grass/branches/releasebranch_7_2/man/build_check_rest.py
   grass/branches/releasebranch_7_2/man/build_class.py
   grass/branches/releasebranch_7_2/man/build_class_graphical.py
   grass/branches/releasebranch_7_2/man/build_class_rest.py
   grass/branches/releasebranch_7_2/man/build_full_index.py
   grass/branches/releasebranch_7_2/man/build_full_index_rest.py
   grass/branches/releasebranch_7_2/man/build_graphical_index.py
   grass/branches/releasebranch_7_2/man/build_html.py
   grass/branches/releasebranch_7_2/man/build_keywords.py
   grass/branches/releasebranch_7_2/man/build_rest.py
   grass/branches/releasebranch_7_2/man/grassdocs.css
   grass/branches/releasebranch_7_2/man/sphinx/conf.py
   grass/branches/releasebranch_7_2/misc/m.cogo/main.c
   grass/branches/releasebranch_7_2/misc/m.measure/main.c
   grass/branches/releasebranch_7_2/misc/m.nviz.image/main.c
   grass/branches/releasebranch_7_2/scripts/m.proj/m.proj.py
   grass/branches/releasebranch_7_2/tools/mkhtml.py
   grass/branches/releasebranch_7_2/tools/mkrest.py
Log:
man pages: misc --> miscellaneous; style improvements (man/ sync to trunk r69585, r69587, r69588, r69589, r69590, r69601, r69709, r69871, r68597, r69731, r70088)

Deleted: grass/branches/releasebranch_7_2/doc/gi_misc.jpg
===================================================================
(Binary files differ)

Copied: grass/branches/releasebranch_7_2/doc/gi_miscellaneous.jpg (from rev 69588, grass/trunk/doc/gi_miscellaneous.jpg)
===================================================================
(Binary files differ)

Modified: grass/branches/releasebranch_7_2/include/Make/Docs.make
===================================================================
--- grass/branches/releasebranch_7_2/include/Make/Docs.make	2017-01-01 20:52:50 UTC (rev 70188)
+++ grass/branches/releasebranch_7_2/include/Make/Docs.make	2017-01-01 21:43:48 UTC (rev 70189)
@@ -58,7 +58,7 @@
 	display.html \
 	general.html \
 	imagery.html \
-	misc.html \
+	miscellaneous.html \
 	photo.html \
 	postscript.html \
 	raster.html \
@@ -83,7 +83,7 @@
 	$(call html_pdf display,d.*.html)
 	$(call html_pdf general,g.*.html)
 	$(call html_pdf imagery,i.*.html)
-	$(call html_pdf misc,m.*.html)
+	$(call html_pdf miscellaneous,m.*.html)
 	$(call html_pdf photo,i.ortho*.html photo*.html)
 	$(call html_pdf postscript,ps.*.html)
 	$(call html_pdf raster,r.*.html)

Modified: grass/branches/releasebranch_7_2/man/Makefile
===================================================================
--- grass/branches/releasebranch_7_2/man/Makefile	2017-01-01 20:52:50 UTC (rev 70188)
+++ grass/branches/releasebranch_7_2/man/Makefile	2017-01-01 21:43:48 UTC (rev 70189)
@@ -17,7 +17,7 @@
 	db:database \
 	g:general \
 	i:imagery \
-	m:misc \
+	m:miscellaneous \
 	ps:postscript \
 	r:raster \
 	r3:raster3d \

Modified: grass/branches/releasebranch_7_2/man/build_check.py
===================================================================
--- grass/branches/releasebranch_7_2/man/build_check.py	2017-01-01 20:52:50 UTC (rev 70188)
+++ grass/branches/releasebranch_7_2/man/build_check.py	2017-01-01 21:43:48 UTC (rev 70189)
@@ -15,7 +15,7 @@
 
 for cmd in html_files('*'):
     if "DESCRIPTION" not in read_file(cmd):
-	sys.stdout.write("%s\n" % cmd[:-5])
+        sys.stdout.write("%s\n" % cmd[:-5])
 
 sys.stdout.write(r"""
 ----------------------------------------------------------------------

Modified: grass/branches/releasebranch_7_2/man/build_check_rest.py
===================================================================
--- grass/branches/releasebranch_7_2/man/build_check_rest.py	2017-01-01 20:52:50 UTC (rev 70188)
+++ grass/branches/releasebranch_7_2/man/build_check_rest.py	2017-01-01 21:43:48 UTC (rev 70189)
@@ -15,7 +15,7 @@
 
 for cmd in rest_files('*'):
     if "DESCRIPTION" not in read_file(cmd):
-	sys.stdout.write("%s\n" % cmd[:-5])
+        sys.stdout.write("%s\n" % cmd[:-5])
 
 sys.stdout.write(r"""
 ----------------------------------------------------------------------

Modified: grass/branches/releasebranch_7_2/man/build_class.py
===================================================================
--- grass/branches/releasebranch_7_2/man/build_class.py	2017-01-01 20:52:50 UTC (rev 70188)
+++ grass/branches/releasebranch_7_2/man/build_class.py	2017-01-01 21:43:48 UTC (rev 70189)
@@ -9,6 +9,9 @@
 
 from build_html import *
 
+
+no_intro_page_classes = ['display', 'general', 'miscellaneous', 'postscript']
+
 os.chdir(html_dir)
 
 #write separate module pages:
@@ -25,12 +28,14 @@
 f = open(filename + ".tmp", 'wb')
 
 write_html_header(f, "GRASS GIS %s Reference Manual: %s" % (grass_version, modclass))
-if modclass.lower() not in ['general', 'misc', 'postscript']:
-    if modclass == 'raster3d':
+modclass_lower = modclass.lower()
+modclass_visible = modclass
+if modclass_lower not in no_intro_page_classes:
+    if modclass_visible == 'raster3d':
         # covert keyword to nice form
-        modclass = '3D raster'
-    f.write(modclass_intro_tmpl.substitute(modclass = modclass, modclass_lower = modclass.lower()))
-f.write(modclass_tmpl.substitute(modclass=to_title(modclass)))
+        modclass_visible = '3D raster'
+    f.write(modclass_intro_tmpl.substitute(modclass=modclass_visible, modclass_lower=modclass_lower))
+f.write(modclass_tmpl.substitute(modclass=to_title(modclass_visible)))
 
 #for all modules:
 for cmd in html_files(cls):
@@ -39,8 +44,8 @@
     if desc is None:
         desc = get_desc(cmd)
     f.write(desc2_tmpl.substitute(cmd = cmd,
-    			      basename = basename,
-    			      desc = desc))
+                                  basename = basename,
+                                  desc = desc))
 f.write("</table>\n")
 
 write_html_footer(f, "index.html", year)

Modified: grass/branches/releasebranch_7_2/man/build_class_graphical.py
===================================================================
--- grass/branches/releasebranch_7_2/man/build_class_graphical.py	2017-01-01 20:52:50 UTC (rev 70188)
+++ grass/branches/releasebranch_7_2/man/build_class_graphical.py	2017-01-01 21:43:48 UTC (rev 70189)
@@ -138,7 +138,7 @@
               "Manual: Graphical index" % grass_version))
     output.write(header_graphical_index_tmpl)
 
-    if module_family.lower() not in ['general', 'misc', 'postscript']:
+    if module_family.lower() not in ['general', 'postscript']:
         if module_family == 'raster3d':
             # covert keyword to nice form
             module_family = '3D raster'
@@ -210,7 +210,7 @@
         ('db', 'database'),
         ('g', 'general'),
         ('i', 'imagery'),
-        ('m', 'misc'),
+        ('m', 'miscellaneous'),
         ('ps', 'postscript'),
         ('r', 'raster'),
         ('r3', 'raster3d'),

Modified: grass/branches/releasebranch_7_2/man/build_class_rest.py
===================================================================
--- grass/branches/releasebranch_7_2/man/build_class_rest.py	2017-01-01 20:52:50 UTC (rev 70188)
+++ grass/branches/releasebranch_7_2/man/build_class_rest.py	2017-01-01 21:43:48 UTC (rev 70189)
@@ -22,7 +22,7 @@
 f = open(filename + ".tmp", 'wb')
 
 write_rest_header(f, "GRASS GIS %s Reference Manual: %s" % (grass_version, modclass))
-if modclass.lower() not in ['general', 'misc', 'postscript']:
+if modclass.lower() not in ['general', 'miscellaneous', 'postscript']:
     f.write(modclass_intro_tmpl.substitute(modclass = modclass, modclass_lower = modclass.lower()))
 f.write(modclass_tmpl.substitute(modclass = modclass))
 
@@ -33,7 +33,7 @@
     if desc is None:
         desc = get_desc(cmd)
     f.write(desc2_tmpl.substitute(basename = basename,
-    			      desc = desc))
+                                  desc = desc))
 
 write_rest_footer(f, "index.txt")
 

Modified: grass/branches/releasebranch_7_2/man/build_full_index.py
===================================================================
--- grass/branches/releasebranch_7_2/man/build_full_index.py	2017-01-01 20:52:50 UTC (rev 70188)
+++ grass/branches/releasebranch_7_2/man/build_full_index.py	2017-01-01 21:43:48 UTC (rev 70189)
@@ -15,13 +15,14 @@
 
 os.chdir(html_dir)
 
+# TODO: create some master function/dict somewhere
 class_labels = {
     'd' : 'display',
     'db' : 'database',
     'g' : 'general',
     'i' : 'imagery',
     'm' : 'miscellaneous',
-    'ps' : 'postscript',
+    'ps' : 'PostScript',
     'r' : 'raster',
     'r3' : '3D raster',
     't' : 'temporal',
@@ -32,7 +33,7 @@
 for cmd in html_files('*'):
     prefix = cmd.split('.')[0]
     if prefix not in [item[0] for item in classes]:
-	classes.append((prefix, class_labels.get(prefix, prefix)))
+        classes.append((prefix, class_labels.get(prefix, prefix)))
 classes.sort(key=lambda tup: tup[0])
 
 #begin full index:
@@ -51,13 +52,13 @@
     f.write(cmd2_tmpl.substitute(cmd_label=to_title(cls_label), cmd=cls))
     #for all modules:  
     for cmd in html_files(cls):
-	basename = os.path.splitext(cmd)[0]
-	desc = check_for_desc_override(basename)
-	if desc is None:
-	    desc = get_desc(cmd)
-	f.write(desc1_tmpl.substitute(cmd = cmd,
-				      basename = basename,
-				      desc = desc))
+        basename = os.path.splitext(cmd)[0]
+        desc = check_for_desc_override(basename)
+        if desc is None:
+            desc = get_desc(cmd)
+        f.write(desc1_tmpl.substitute(cmd = cmd,
+                                      basename = basename,
+                                      desc = desc))
     f.write("</table>\n")
 
 write_html_footer(f, "index.html", year)

Modified: grass/branches/releasebranch_7_2/man/build_full_index_rest.py
===================================================================
--- grass/branches/releasebranch_7_2/man/build_full_index_rest.py	2017-01-01 20:52:50 UTC (rev 70188)
+++ grass/branches/releasebranch_7_2/man/build_full_index_rest.py	2017-01-01 21:43:48 UTC (rev 70189)
@@ -15,7 +15,7 @@
 for cmd in rest_files('*'):
     prefix = cmd.split('.')[0]
     if prefix not in classes:
-	classes.append(prefix)
+        classes.append(prefix)
 classes.sort()
 
 #begin full index:
@@ -31,7 +31,7 @@
 #for cls in classes:
     #f.write(cmd1_tmpl.substitute(cmd = cls))
     #if cls != classes[-1]:
-	#f.write(" | ")
+        #f.write(" | ")
 
 f.write(sections)
 
@@ -40,12 +40,12 @@
     f.write(cmd2_tmpl.substitute(cmd = cls))
     #for all modules:  
     for cmd in rest_files(cls):
-	basename = os.path.splitext(cmd)[0]
-	desc = check_for_desc_override(basename)
-	if desc is None:
-	    desc = get_desc(cmd)
-	f.write(desc1_tmpl.substitute(basename = basename,
-				      desc = desc))
+        basename = os.path.splitext(cmd)[0]
+        desc = check_for_desc_override(basename)
+        if desc is None:
+            desc = get_desc(cmd)
+        f.write(desc1_tmpl.substitute(basename = basename,
+                                      desc = desc))
     f.write("\n")
 
 write_rest_footer(f, "index.txt")

Modified: grass/branches/releasebranch_7_2/man/build_graphical_index.py
===================================================================
--- grass/branches/releasebranch_7_2/man/build_graphical_index.py	2017-01-01 20:52:50 UTC (rev 70188)
+++ grass/branches/releasebranch_7_2/man/build_graphical_index.py	2017-01-01 21:43:48 UTC (rev 70189)
@@ -98,13 +98,14 @@
     ('imagery_graphical.html', std_img_name('imagery'), 'Imagery'),
     ('raster3d_graphical.html', std_img_name('raster3d'), '3D raster'),
     ('temporal_graphical.html', std_img_name('temporal'), 'Temporal'),
-    ('misc_graphical.html', std_img_name('misc'), 'Miscellaneous'),
+    ('miscellaneous_graphical.html', std_img_name('miscellaneous'), 'Miscellaneous'),
     ('postscript_graphical.html', std_img_name('cartography'), 'Cartography'),
     ('wxGUI_graphical.html', std_img_name('gui'), 'GUI'),
     ('wxGUI.nviz.html', std_img_name('3dview'), '3D view'),
     ('https://grass.osgeo.org/grass72/manuals/libpython/index.html', std_img_name('python'), 'Python'),
     ('https://grass.osgeo.org/programming7/', std_img_name('c'), 'C library'),
     ('manual_gallery.html', std_img_name('gallery'), 'Gallery'),
+    ('http://grass.osgeo.org/grass72/manuals/addons/', std_img_name('addons'), 'Addons'),
 ]
 
 

Modified: grass/branches/releasebranch_7_2/man/build_html.py
===================================================================
--- grass/branches/releasebranch_7_2/man/build_html.py	2017-01-01 20:52:50 UTC (rev 70188)
+++ grass/branches/releasebranch_7_2/man/build_html.py	2017-01-01 21:43:48 UTC (rev 70189)
@@ -152,9 +152,9 @@
       </ul></td>
       <td width="33%" valign="top" class="box"><h3> Database</h3>
        <ul>
-	<li class="box"><a href="databaseintro.html">Intro: database management</a></li>
-	<li class="box"><a href="sql.html">SQL support in GRASS GIS</a></li>
-	<li class="box"><a href="database.html">Database commands manual</a></li>
+        <li class="box"><a href="databaseintro.html">Intro: database management</a></li>
+        <li class="box"><a href="sql.html">SQL support in GRASS GIS</a></li>
+        <li class="box"><a href="database.html">Database commands manual</a></li>
        </ul>
       </td>
       <td width="33%" valign="top" class="box"><h3> Temporal processing</h3>
@@ -167,13 +167,13 @@
     <tr>
       <td width="33%" valign="top" class="box"><h3> Cartography</h3>
        <ul>
-        <li class="box"><a href="postscript.html">Postscript commands manual</a></li>
+        <li class="box"><a href="postscript.html">PostScript commands manual</a></li>
         <li class="box"><a href="g.gui.psmap.html">wxGUI Cartographic Composer</a></li>
        </ul>
       </td>
       <td width="33%" valign="top" class="box"><h3> Miscellaneous & Variables</h3>
        <ul>
-        <li class="box"><a href="misc.html">Miscellaneous commands manual</a></li>
+        <li class="box"><a href="miscellaneous.html">Miscellaneous commands manual</a></li>
         <li class="box"><a href="variables.html">GRASS variables and environment variables</a></li>
        </ul>
       </td>
@@ -435,6 +435,8 @@
 
 def to_title(name):
     """Convert name of command class/family to form suitable for title"""
+    if name == 'PostScript':
+        return name
     return name.capitalize()
 
 ############################################################################

Modified: grass/branches/releasebranch_7_2/man/build_keywords.py
===================================================================
--- grass/branches/releasebranch_7_2/man/build_keywords.py	2017-01-01 20:52:50 UTC (rev 70188)
+++ grass/branches/releasebranch_7_2/man/build_keywords.py	2017-01-01 21:43:48 UTC (rev 70189)
@@ -42,6 +42,9 @@
             key = key.split('>')[1].split('<')[0]
         except:
             pass
+        if not key:
+            exit("Empty keyword from file %s line: %s"
+                 % (fname, lines[index_keys]))
         if key not in keywords.keys():
             keywords[key] = []
             keywords[key].append(fname)

Modified: grass/branches/releasebranch_7_2/man/build_rest.py
===================================================================
--- grass/branches/releasebranch_7_2/man/build_rest.py	2017-01-01 20:52:50 UTC (rev 70188)
+++ grass/branches/releasebranch_7_2/man/build_rest.py	2017-01-01 21:43:48 UTC (rev 70189)
@@ -67,7 +67,7 @@
 .. toctree::
     :maxdepth: 1
 
-	How to start with GRASS <helptext.html>
+        How to start with GRASS <helptext.html>
         Intro projections and spatial transformations <projectionintro>
         Intro 2D raster map processing <rasterintro>
         Intro 3D raster map (voxel) processing <raster3dintro>
@@ -139,7 +139,7 @@
 .. toctree::
     :maxdepth: 1
     
-        Miscellaneous commands manual <misc>
+        Miscellaneous commands manual <miscellaneous>
         GRASS variables and environment variables <variables>
 
 Temporal processing
@@ -156,7 +156,7 @@
 .. toctree::
     :maxdepth: 1
     
-        Postscript commands manual <postscript>
+        PostScript commands manual <postscript>
 
 """)
 

Modified: grass/branches/releasebranch_7_2/man/grassdocs.css
===================================================================
--- grass/branches/releasebranch_7_2/man/grassdocs.css	2017-01-01 20:52:50 UTC (rev 70188)
+++ grass/branches/releasebranch_7_2/man/grassdocs.css	2017-01-01 21:43:48 UTC (rev 70189)
@@ -199,3 +199,38 @@
 div.toc {
   background-color: rgba(255, 255, 255, 0.7);
 }
+
+/* This is for a more detailed equivalent of option->descriptions
+ * (perhaps it can be used more generally as well).
+ * Creates a description list with highlighted items titles
+ * but not too visible in the overall text flow. */
+.option_descriptions dt {
+    font-weight: bold;
+    color: #222;
+}
+
+table.compact {
+    font-size: 80%;
+}
+
+/* default style is too spread out */
+table.compact td, table.compact th {
+    padding-left: 0.5em;
+    padding-right: 0.2em;
+    padding-top: 0.2em;
+    padding-bottom: 0.2em;
+}
+
+/* do table using alternate colors of rows */
+table.compact tr:nth-child(odd) {
+    background: #EEE;
+}
+
+table.compact tr:nth-child(even) {
+    background: #FFF;
+}
+
+/* soft strike through so that we can still see the text */
+s {
+    text-decoration-color: rgba(0, 0, 0, 0.53);
+}

Modified: grass/branches/releasebranch_7_2/man/sphinx/conf.py
===================================================================
--- grass/branches/releasebranch_7_2/man/sphinx/conf.py	2017-01-01 20:52:50 UTC (rev 70188)
+++ grass/branches/releasebranch_7_2/man/sphinx/conf.py	2017-01-01 21:43:48 UTC (rev 70189)
@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 #
-# GRASS 7.0 Documentation documentation build configuration file, created by
+# GRASS 7.2 Documentation documentation build configuration file, created by
 # sphinx-quickstart on Thu Aug  9 17:16:28 2012.
 #
 # This file is execfile()d with the current directory set to its containing dir.
@@ -41,7 +41,7 @@
 
 # General information about the project.
 project = u'GRASS 7.2 Documentation'
-copyright = u'2016, GRASS Development Team'
+copyright = u'2017, GRASS Development Team'
 
 # The version info for the project you're documenting, acts as replacement for
 # |version| and |release|, also used in various other places throughout the
@@ -164,7 +164,7 @@
 #html_file_suffix = None
 
 # Output file base name for HTML help builder.
-htmlhelp_basename = 'GRASS70Documentationdoc'
+htmlhelp_basename = 'GRASS72Documentationdoc'
 
 
 # -- Options for LaTeX output --------------------------------------------------
@@ -228,7 +228,7 @@
 #  dir menu entry, description, category)
 texinfo_documents = [
   ('content', 'GRASS72Documentation', u'GRASS 7.2 Documentation Documentation',
-   u'GRASS Development Team', 'GRASS70Documentation', 'One line description of project.',
+   u'GRASS Development Team', 'GRASS72Documentation', 'One line description of project.',
    'Miscellaneous'),
 ]
 
@@ -248,7 +248,7 @@
 epub_title = u'GRASS 7.2 Documentation'
 epub_author = u'GRASS Development Team'
 epub_publisher = u'GRASS Development Team'
-epub_copyright = u'2012, GRASS Development Team'
+epub_copyright = u'2017, GRASS Development Team'
 
 # The language of the text. It defaults to the language option
 # or en if the language is not set.

Modified: grass/branches/releasebranch_7_2/misc/m.cogo/main.c
===================================================================
--- grass/branches/releasebranch_7_2/misc/m.cogo/main.c	2017-01-01 20:52:50 UTC (rev 70188)
+++ grass/branches/releasebranch_7_2/misc/m.cogo/main.c	2017-01-01 21:43:48 UTC (rev 70189)
@@ -224,6 +224,7 @@
     module = G_define_module();
     G_add_keyword(_("miscellaneous"));
     G_add_keyword(_("distance"));
+    G_add_keyword(_("polar"));
     module->label = _("A simple utility for converting bearing and "
 		      "distance measurements to coordinates and vice versa.");
     module->description = _("It assumes a cartesian coordinate system");

Modified: grass/branches/releasebranch_7_2/misc/m.measure/main.c
===================================================================
--- grass/branches/releasebranch_7_2/misc/m.measure/main.c	2017-01-01 20:52:50 UTC (rev 70188)
+++ grass/branches/releasebranch_7_2/misc/m.measure/main.c	2017-01-01 21:43:48 UTC (rev 70189)
@@ -45,6 +45,8 @@
     module->description = _("Measures the lengths and areas of features.");
     G_add_keyword(_("miscellaneous"));
     G_add_keyword(_("measurement"));
+    G_add_keyword(_("distance"));
+    G_add_keyword(_("area"));
 
     coords = G_define_standard_option(G_OPT_M_COORDS);
     coords->required = YES;

Modified: grass/branches/releasebranch_7_2/misc/m.nviz.image/main.c
===================================================================
--- grass/branches/releasebranch_7_2/misc/m.nviz.image/main.c	2017-01-01 20:52:50 UTC (rev 70188)
+++ grass/branches/releasebranch_7_2/misc/m.nviz.image/main.c	2017-01-01 21:43:48 UTC (rev 70189)
@@ -47,6 +47,7 @@
     G_gisinit(argv[0]);
 
     module = G_define_module();
+    G_add_keyword(_("miscellaneous"));
     G_add_keyword(_("visualization"));
     G_add_keyword(_("graphics"));
     G_add_keyword(_("raster"));

Modified: grass/branches/releasebranch_7_2/scripts/m.proj/m.proj.py
===================================================================
--- grass/branches/releasebranch_7_2/scripts/m.proj/m.proj.py	2017-01-01 20:52:50 UTC (rev 70188)
+++ grass/branches/releasebranch_7_2/scripts/m.proj/m.proj.py	2017-01-01 21:43:48 UTC (rev 70189)
@@ -29,6 +29,7 @@
 #% description: Converts coordinates from one projection to another (cs2cs frontend).
 #% keyword: miscellaneous
 #% keyword: projection
+#% keyword: transformation
 #%end
 #%option G_OPT_M_COORDS
 #% description: Input coordinates to reproject

Modified: grass/branches/releasebranch_7_2/tools/mkhtml.py
===================================================================
--- grass/branches/releasebranch_7_2/tools/mkhtml.py	2017-01-01 20:52:50 UTC (rev 70188)
+++ grass/branches/releasebranch_7_2/tools/mkhtml.py	2017-01-01 21:43:48 UTC (rev 70189)
@@ -258,7 +258,7 @@
     'db': 'database',
     'g' : 'general',
     'i' : 'imagery',
-    'm' : 'misc',
+    'm' : 'miscellaneous',
     'ps': 'postscript',
     'p' : 'paint',
     'r' : 'raster',
@@ -271,14 +271,17 @@
 
 def to_title(name):
     """Convert name of command class/family to form suitable for title"""
-    return name.capitalize()
+    if name == 'raster3d':
+        return '3D raster'
+    elif name == 'postscript':
+        return 'PostScript'
+    else:
+        return name.capitalize()
 
+
 index_titles = {}
 for key, name in index_names.iteritems():
-    if key == 'r3':
-        index_titles[key] = '3D raster'
-    else:
-        index_titles[key] = to_title(name)
+    index_titles[key] = to_title(name)
 
 # process footer
 index = re.search('(<!-- meta page index:)(.*)(-->)', src_data, re.IGNORECASE)
@@ -287,7 +290,7 @@
     if '|' in index_name:
         index_name, index_name_cap = index_name.split('|', 1)
     else:
-        index_name_cap = index_name
+        index_name_cap = to_title(index_name)
 else:
     mod_class = pgm.split('.', 1)[0]
     index_name = index_names.get(mod_class, '')

Modified: grass/branches/releasebranch_7_2/tools/mkrest.py
===================================================================
--- grass/branches/releasebranch_7_2/tools/mkrest.py	2017-01-01 20:52:50 UTC (rev 70188)
+++ grass/branches/releasebranch_7_2/tools/mkrest.py	2017-01-01 21:43:48 UTC (rev 70189)
@@ -99,7 +99,7 @@
     'db': 'database',
     'g': 'general',
     'i': 'imagery',
-    'm': 'misc',
+    'm': 'miscellaneous',
     'ps': 'postscript',
     'p': 'paint',
     'r': 'raster',



More information about the grass-commit mailing list