escape <> for HTML; uniform 14em navbar; uppercase C
This commit is contained in:
parent
c23e2a9b6f
commit
25fd0b6bed
|
@ -160,7 +160,7 @@ table.index td { text-align: left; vertical-align: top; }
|
||||||
|
|
||||||
#navigation {
|
#navigation {
|
||||||
float: left;
|
float: left;
|
||||||
width: 18em;
|
width: 14em;
|
||||||
vertical-align: top;
|
vertical-align: top;
|
||||||
background-color: #f0f0f0;
|
background-color: #f0f0f0;
|
||||||
overflow: visible;
|
overflow: visible;
|
||||||
|
@ -194,7 +194,7 @@ table.index td { text-align: left; vertical-align: top; }
|
||||||
}
|
}
|
||||||
|
|
||||||
#content {
|
#content {
|
||||||
margin-left: 18em;
|
margin-left: 14em;
|
||||||
padding: 1em;
|
padding: 1em;
|
||||||
width: 700px;
|
width: 700px;
|
||||||
border-left: 2px solid #cccccc;
|
border-left: 2px solid #cccccc;
|
||||||
|
|
|
@ -47,7 +47,7 @@ local function resolve_inline_references (ldoc, txt, item, plain)
|
||||||
label = label:gsub('_','\\_')
|
label = label:gsub('_','\\_')
|
||||||
end
|
end
|
||||||
local html = ldoc.href(ref) or '#'
|
local html = ldoc.href(ref) or '#'
|
||||||
label = label or qname
|
label = ldoc.escape(label or qname)
|
||||||
local res = ('<a href="%s">%s</a>'):format(html,label)
|
local res = ('<a href="%s">%s</a>'):format(html,label)
|
||||||
return res
|
return res
|
||||||
end))
|
end))
|
||||||
|
@ -58,6 +58,7 @@ local function resolve_inline_references (ldoc, txt, item, plain)
|
||||||
if name and do_escape then
|
if name and do_escape then
|
||||||
label = name:gsub('_', '\\_')
|
label = name:gsub('_', '\\_')
|
||||||
end
|
end
|
||||||
|
label = ldoc.escape(label)
|
||||||
if ref then
|
if ref then
|
||||||
return ('<a href="%s">%s</a>'):format(ldoc.href(ref),label)
|
return ('<a href="%s">%s</a>'):format(ldoc.href(ref),label)
|
||||||
else
|
else
|
||||||
|
|
|
@ -24,7 +24,7 @@ end
|
||||||
|
|
||||||
local spans = {keyword=true,number=true,string=true,comment=true,global=true,backtick=true}
|
local spans = {keyword=true,number=true,string=true,comment=true,global=true,backtick=true}
|
||||||
|
|
||||||
local cpp_lang = {c = true, cpp = true, cxx = true, h = true}
|
local cpp_lang = {C = true, c = true, cpp = true, cxx = true, h = true}
|
||||||
|
|
||||||
function prettify.lua (lang, fname, code, initial_lineno, pre, linenos)
|
function prettify.lua (lang, fname, code, initial_lineno, pre, linenos)
|
||||||
local res, lexer, tokenizer = List(), require 'ldoc.lexer'
|
local res, lexer, tokenizer = List(), require 'ldoc.lexer'
|
||||||
|
|
Loading…
Reference in New Issue