[SCM] Gerris Flow Solver branch, upstream, updated. b3aa46814a06c9cb2912790b23916ffb44f1f203

Stephane Popinet popinet at users.sf.net
Fri May 15 02:54:37 UTC 2009


The following commit has been merged in the upstream branch:
commit 0eaf105d0273460dd4a1e32d235eb8578cab5712
Author: Stephane Popinet <popinet at users.sf.net>
Date:   Fri Sep 7 09:33:20 2007 +1000

    Fixed formatting of gfs2tex parameter file view
    
    darcs-hash:20070906233320-d4795-debe6908229316a02e2bc71f17c9eedb54a08605.gz

diff --git a/doc/examples/gfs2tex.py b/doc/examples/gfs2tex.py
index 13cfc59..e366885 100644
--- a/doc/examples/gfs2tex.py
+++ b/doc/examples/gfs2tex.py
@@ -133,28 +133,30 @@ class Example:
 		      style + '"></head><body><tt class="gfs">\n')
         infile = insthg = 0
         for line in file:
+	    tab = ""
             l = ""
             first = 1
             comment = 0
             for c in line:
                 if c == " " and first:
-                    l += "&nbsp; "
+                    tab += "&nbsp;"
                 else:
                     if first and c == "#":
                         comment = 1
                     first = 0
                     if c == '<':
-                        l += "&lt"
+                        l += "&lt;"
                     elif c == '>':
-                        l += "&gt"
+                        l += "&gt;"
                     elif c == '&':
-                        l += "&amp"
+                        l += "&amp;"
                     else:
                         l += c
             if comment:
                 if infile:
                     record = line.split()
                     if insthg or len(record) > 1:
+			out.write(tab)
                         out.write('<div class="comment">')
                         out.write(l)
                         out.write('</div>')
@@ -165,6 +167,7 @@ class Example:
                         infile = 1
                         insthg = 0
             else:
+		out.write(tab)
                 record = l.split()
                 for r in record:
                     key = None

-- 
Gerris Flow Solver



More information about the debian-science-commits mailing list