[GRASS-SVN] r66018 - grass/trunk/man
svn_grass at osgeo.org
svn_grass at osgeo.org
Tue Aug 25 17:25:55 PDT 2015
Author: wenzeslaus
Date: 2015-08-25 17:25:55 -0700 (Tue, 25 Aug 2015)
New Revision: 66018
Modified:
grass/trunk/man/build_graphical_index.py
Log:
docs: g.gui. from image when wxGUI.*.html was picked in graphical index
Modified: grass/trunk/man/build_graphical_index.py
===================================================================
--- grass/trunk/man/build_graphical_index.py 2015-08-25 21:14:50 UTC (rev 66017)
+++ grass/trunk/man/build_graphical_index.py 2015-08-26 00:25:55 UTC (rev 66018)
@@ -84,6 +84,12 @@
files.append(filename)
return files
+def remove_module_name(string, module):
+ string = string.replace(module.replace('wxGUI.', 'g.gui.'), '')
+ string = string.replace(module.replace('.', '_'), '') # using _
+ string = string.replace(module.replace('.', ''), '') # using nothing
+ string = string.replace(module, '') # using original dots
+ return string
def title_form_names(html_name, img_name):
# we ignore the possibility of having extension at the end of image
@@ -92,9 +98,7 @@
module_name = html_name.replace('.html', '')
for extension in img_extensions:
img_name = img_name.replace('.' + extension, '')
- img_name = img_name.replace(module_name.replace('.', '_'), '') # using _
- img_name = img_name.replace(module_name.replace('.', ''), '') # using nothing
- img_name = img_name.replace(module_name, '') # using original dots
+ img_name = remove_module_name(img_name, module_name)
img_name = img_name.replace('_', ' ')
img_name = img_name.strip()
if img_name:
More information about the grass-commit
mailing list