APIDump: Linkification works.
This commit is contained in:
parent
24e70d534b
commit
9352af683d
@ -295,10 +295,9 @@ function WriteHtmlClass(a_ClassAPI, a_AllAPI)
|
|||||||
return;
|
return;
|
||||||
end
|
end
|
||||||
|
|
||||||
|
-- Make a link out of anything with the special linkifying syntax {{link|title}}
|
||||||
local function LinkifyString(a_String)
|
local function LinkifyString(a_String)
|
||||||
-- TODO: Make a link out of anything with the special linkifying syntax {{link|title}}
|
return (a_String:gsub("{{([^|]*)|([^}]*)}}", "<a href=\"%1.html\">%2</a>")); -- The extra parenthesis remove the extra values returned by gsub()
|
||||||
-- a_String:gsub("{{([^|]*)|([^}])*}}", "<a href=\"%1\">%2</a>");
|
|
||||||
return a_String;
|
|
||||||
end
|
end
|
||||||
|
|
||||||
-- Writes a table containing all functions in the specified list, with an optional "inherited from" header when a_InheritedName is valid
|
-- Writes a table containing all functions in the specified list, with an optional "inherited from" header when a_InheritedName is valid
|
||||||
@ -361,7 +360,7 @@ function WriteHtmlClass(a_ClassAPI, a_AllAPI)
|
|||||||
cf:write("<a name=\"desc\"><h1>" .. a_ClassAPI.Name .. " class</h1></a>\n");
|
cf:write("<a name=\"desc\"><h1>" .. a_ClassAPI.Name .. " class</h1></a>\n");
|
||||||
if (a_ClassAPI.Desc ~= nil) then
|
if (a_ClassAPI.Desc ~= nil) then
|
||||||
cf:write("<p>");
|
cf:write("<p>");
|
||||||
cf:write(a_ClassAPI.Desc);
|
cf:write(LinkifyString(a_ClassAPI.Desc));
|
||||||
cf:write("</p>\n");
|
cf:write("</p>\n");
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user