mail[Wesnoth-commits] r28921 - /trunk/utils/wiki_grabber.py


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by koraq on August 24, 2008 - 11:58:
Author: mordante
Date: Sun Aug 24 11:58:23 2008
New Revision: 28921

URL: http://svn.gna.org/viewcvs/wesnoth?rev=28921&view=rev
Log:
Fix the output for negative numbers in a cell.

When the text starts with a negative number it's parsed as a new row, by
adding a space in front of all texts this problem is fixed. Cells with
hardcoded text this isn't needed so not done.

Modified:
    trunk/utils/wiki_grabber.py

Modified: trunk/utils/wiki_grabber.py
URL: 
http://svn.gna.org/viewcvs/wesnoth/trunk/utils/wiki_grabber.py?rev=28921&r1=28920&r2=28921&view=diff
==============================================================================
--- trunk/utils/wiki_grabber.py (original)
+++ trunk/utils/wiki_grabber.py Sun Aug 24 11:58:23 2008
@@ -109,13 +109,13 @@
         result += "\n!key\n!type\n!default\n!description\n"
         for i in range(len(res)):
             result += "|-\n"
-            result += "|" + res[i][0] + "\n"
-            result += "|[[GUIVariable#" + res[i][1] + "|" + res[i][1] + 
"]]\n"
+            result += "| " + res[i][0] + "\n"
+            result += "| [[GUIVariable#" + res[i][1] + "|" + res[i][1] + 
"]]\n"
             if(res[i][2] == ""):
-                result += "|mandatory\n"
+                result += "| mandatory\n"
             else:
-                result += "|" + res[i][2] + "\n"
-            result += "|" + re.sub(r'@\*', "\n*", res[i][3]) + "\n"
+                result += "| " + res[i][2] + "\n"
+            result += "| " + re.sub(r'@\*', "\n*", res[i][3]) + "\n"
         result += "|}"
 
         return result
@@ -142,9 +142,9 @@
         result += "\n!Variable\n!type\n!description\n"
         for i in range(len(res)):
             result += "|-\n"
-            result += "|" + res[i][0] + "\n"
-            result += "|" + res[i][1] + "\n"
-            result += "|" + re.sub(r'@\*', "\n*", res[i][2]) + "\n"
+            result += "| " + res[i][0] + "\n"
+            result += "| " + res[i][1] + "\n"
+            result += "| " + re.sub(r'@\*', "\n*", res[i][2]) + "\n"
         result += "|}"
 
         return result
@@ -167,8 +167,8 @@
         result += "\n!Variable\n!description\n"
         for i in range(len(res)):
             result += "|-\n"
-            result += "|<span id=\"" + res[i][0] + "\">" + res[i][0] + 
"</span>\n"
-            result += "|" + re.sub(r'@\*', "\n*", res[i][1]) + "\n"
+            result += "| <span id=\"" + res[i][0] + "\">" + res[i][0] + 
"</span>\n"
+            result += "| " + re.sub(r'@\*', "\n*", res[i][1]) + "\n"
         result += "|}"
 
         return result
@@ -191,8 +191,8 @@
         result += "\n!Section\n!description\n"
         for i in range(len(res)):
             result += "|-\n"
-            result += "|" + res[i][0] + "\n"
-            result += "|" + re.sub(r'@\*', "\n*", res[i][1]) + "\n"
+            result += "| " + res[i][0] + "\n"
+            result += "| " + re.sub(r'@\*', "\n*", res[i][1]) + "\n"
         result += "|}"
 
         return result
@@ -254,15 +254,15 @@
             if(res[i][1] == ""):
                 result += "|not used\n"
             else:
-                result += "|" + res[i][1] + "\n"
-
-            result += "|" + res[i][2] + "\n"
+                result += "| " + res[i][1] + "\n"
+
+            result += "| " + res[i][2] + "\n"
 
             if(res[i][3] == ""):
                 result += "|none\n"
             else:
-                result += "|" + res[i][3] + "\n"
-            result += "|" + re.sub(r'@\*', "\n*", res[i][4]) + "\n"
+                result += "| " + res[i][3] + "\n"
+            result += "| " + re.sub(r'@\*', "\n*", res[i][4]) + "\n"
         result += "|}"
 
         return result




Related Messages


Powered by MHonArc, Updated Sun Aug 24 12:02:23 2008