[InlineText*] |
- [
- Content +]
|
Content | Xtable | Paper | Slides | Link | [] | InlineText )* ];; type InlineText = Char | <(`b|`i) {||}>[InlineText*] | [InlineText*] | Xa | Ximg | Xbr ;; type Box = Content | Content;; type NavigBox = Content | [];; let fun authors ([Author+] -> String) | [ a ] -> a | [ a1 a2 ] -> a1 @ ", and " @ a2 | [ a; rem ] -> a @ ", " @ authors rem;; let fun text (t : [InlineText*]) : Inlines = map t with x -> [ (text x) ] | x -> (text x) | x -> (text x) | z -> z;; let fun content (t : Content) : Flow = transform t with | c -> [ title !(content c) ] |
[ tit aut::Author* com ab ] -> [ (match r with | { file = f } -> tit | _ -> tit ) '. ' !(authors aut) '. ' !(text com) [ 'Abstract:' !(content ab) ] ] |[ tit aut::Author* com ] -> [ tit '. ' !(authors aut) '. ' !(text com) ] | [] -> let code = load_file f in (* let code = transform code with | '\n' -> [ '\n'
[] ] | ' ' -> "\160" | c -> [c] in *) [[code ] ] | com -> [ title '. ' !(text com) ] |
- lis -> [
- x ->
- (content x)) ]
| Xtable & x -> [ x ]
|
x -> [
(text x) ] |
- x -> [
- (text x) ]
| x -> text [ x ];;
let fun main2html (Box -> Flow)
c -> [ [(r.title) !(match r with { subtitle = t } -> [t] | _ -> []) [] !(content c) ] ] | c -> [
- (map lis with