aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBadlop <badlop@process-one.net>2009-10-23 15:12:32 +0000
committerBadlop <badlop@process-one.net>2009-10-23 15:12:32 +0000
commit22fffb32ca8d4e446bb3cea08790e256e0e157d7 (patch)
treeb4a8808fb8dd18e3d9e6ee12108bd8373421d0b5
parentAdd escobar_hilite.erl and escobar.css. (diff)
Customize escobar_hilite.erl for ejabberd purposes.
SVN Revision: 2699
-rw-r--r--doc/devdoc/escobar.css6
-rw-r--r--doc/devdoc/escobar_hilite.erl8
2 files changed, 11 insertions, 3 deletions
diff --git a/doc/devdoc/escobar.css b/doc/devdoc/escobar.css
index 49a55dc21..048fedac1 100644
--- a/doc/devdoc/escobar.css
+++ b/doc/devdoc/escobar.css
@@ -11,3 +11,9 @@
.call {color: purple}
.attribute {color: firebrick}
.error{color: red}
+.l {
+ font-style: normal;
+ font-weight: normal;
+ text-decoration: none;
+ color: gray;
+}
diff --git a/doc/devdoc/escobar_hilite.erl b/doc/devdoc/escobar_hilite.erl
index a6c773975..056b41d45 100644
--- a/doc/devdoc/escobar_hilite.erl
+++ b/doc/devdoc/escobar_hilite.erl
@@ -296,15 +296,17 @@ mu(application,Node) ->
_ ->
nil
end;
+mu(function = Class, {tree, function, _, {function, _, [{tree, clause, _, {clause, Vars, _, _}} | _]}}) ->
+ dehtml('span', [{class,Class}, {arity,length(Vars)}]);
mu(Class,_Node) ->
dehtml('span', [{class,Class}]).
dehtml(Tag,Atts) ->
flatten([$<,str(Tag),$ ,[[str(A),"=\"",str(V),"\" "]||{A,V}<-Atts],$>]).
-str(I) when integer(I) -> integer_to_list(I);
-str(A) when atom(A) -> atom_to_list(A);
-str(L) when list(L) -> L.
+str(I) when is_integer(I) -> integer_to_list(I);
+str(A) when is_atom(A) -> atom_to_list(A);
+str(L) when is_list(L) -> L.
is_guard_or_builtin(atom,1) ->guard;
is_guard_or_builtin(binary,1) ->guard;