aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/luadoc.patch
blob: e0dae6a2b31b784d30eea9f85e2f8cec61861db2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
Preserve some formatting for Lua API documentation in Textadept.
--- luadoc/util.lua.orig	2012-02-10 13:34:46.166184400 -0500
+++ luadoc/util.lua	2012-02-10 13:36:59.847551200 -0500
@@ -29,8 +29,8 @@
 -- @see string.gsub
 
 function trim_comment (s)
-	s = string.gsub(s, "%-%-+(.*)$", "%1")
-	return trim(s)
+	s = string.gsub(s, "%-%-+ ?(.*)$", "%1")
+	return s
 end
 
 -------------------------------------------------------------------------------
@@ -52,7 +52,7 @@
 	if str1 == nil or string.len(str1) == 0 then
 		return str2
 	else
-		return str1 .. " " .. str2
+		return str1 .. "\n" .. str2
 	end
 end