diff options
Diffstat (limited to 'src/xmlcomposer.cpp')
-rw-r--r-- | src/xmlcomposer.cpp | 43 |
1 files changed, 42 insertions, 1 deletions
diff --git a/src/xmlcomposer.cpp b/src/xmlcomposer.cpp index 73d9521..cce87d4 100644 --- a/src/xmlcomposer.cpp +++ b/src/xmlcomposer.cpp @@ -682,6 +682,47 @@ ON_GROUPEND(Style) } +// Font Table Analyser -------------------------------------------------------------- + +ON_INITIALIZE(FontTable) +{ + AN_ELEMENT(kElFontTable); +} + +ON_GROUPSTART(FontTable) +{ + // Each group should be a style + AN_ANALYSER(Font); + + // Without any character data + AN_DESTINATION(Null); +} + + +// Font Analyser -------------------------------------------------------------------- + +ON_INITIALIZE(Font) +{ + AN_ELEMENT(kElFont); + AN_DESTINATION_ATTR(kAtName); +} + +ON_CONTROLWORD(Font) +{ + // The font id + if(cw == "f" && flags & kHasParam) + AN_ATTRIBUTE(kAtId, param); + + else + DEFAULT_CONTROLWORD; +} + +ON_GROUPSTART(Font) +{ + AN_ANALYSER(Skip); +} + + // List Table Analyser -------------------------------------------------------------- ON_INITIALIZE(ListTable) @@ -918,7 +959,7 @@ ON_CONTROLWORD(Root) else if(cw == "info") AN_ANALYSER(Info); else if(cw == "fonttbl") - AN_ANALYSER(Skip); + AN_ANALYSER(FontTable); else if(cw == "colortbl") AN_ANALYSER(Skip); else if(cw == "footnote") |