mirror of
https://github.com/rkd77/elinks.git
synced 2024-12-04 14:46:47 -05:00
More perl snacks; added macro:[] for #define'd values; api dom/scanner.h
This commit is contained in:
parent
620730e642
commit
0e5853cae7
@ -172,6 +172,7 @@ $(HTML_DIR)/perl-hooks.html: $(top_srcdir)/contrib/perl/hooks.pl
|
||||
#
|
||||
|
||||
DOM_API = \
|
||||
$(top_srcdir)/src/dom/scanner.h \
|
||||
$(top_srcdir)/src/dom/stack.h \
|
||||
$(top_srcdir)/src/dom/sgml/parser.h
|
||||
|
||||
|
@ -14,6 +14,9 @@ monospacedwords=\basciidoc\(1\)
|
||||
[struct-inlinemacro]
|
||||
<a id="{target}">struct {target}: {0}</a>
|
||||
|
||||
[macro-inlinemacro]
|
||||
<a id="{target}">struct {target}: {0}</a>
|
||||
|
||||
[typedef-inlinemacro]
|
||||
<a id="{target}">typedef {target}: {0}</a>
|
||||
|
||||
|
@ -73,12 +73,15 @@ while (<>)
|
||||
$title = "enum:$1" . "[$title]";
|
||||
$idpath = "";
|
||||
|
||||
} elsif (/#define\s+(\w+)\s*{/) {
|
||||
} elsif (/#define\s+(\w+)[(]/) {
|
||||
$title = "func:$1" . "[$title]";
|
||||
$idpath = "";
|
||||
|
||||
} elsif (/#define\s+(\w+)/) {
|
||||
$title = "macro:$1" . "[$title]";
|
||||
$idpath = "";
|
||||
|
||||
} else {
|
||||
|
||||
if (/typedef/) {
|
||||
if (/.*\(\*(\w+)\)\(/) {
|
||||
$title = "typedef:$1" . "[$title]";
|
||||
@ -90,6 +93,10 @@ while (<>)
|
||||
if (/.*[\s*](\w+)\(/) {
|
||||
$title = "func:$1" . "[$title]";
|
||||
$idpath = "";
|
||||
} elsif (/.*\(\*(\w+)\)\(/) {
|
||||
$body = "#newline#" . $title if not $body;
|
||||
$title = "id:[$idpath$1]::";
|
||||
$indent = "\t";
|
||||
} elsif (/[^=]*[\s*](\w+)[\[\s,:;]/) {
|
||||
$body = "#newline#" . $title if not $body;
|
||||
$title = "id:[$idpath$1]::";
|
||||
|
Loading…
Reference in New Issue
Block a user