version 1.82, 2008/08/27 14:17:55
|
version 1.83, 2008/09/04 09:17:09
|
Line 352 static void ParseTemplate (XTigerTemplat
|
Line 352 static void ParseTemplate (XTigerTemplat
|
void CreateTemplate(Document doc, char *templatePath) |
void CreateTemplate(Document doc, char *templatePath) |
{ |
{ |
#ifdef TEMPLATES |
#ifdef TEMPLATES |
Document newdoc = 0; |
|
Element root, head, elem, xt, title, child, last; |
Element root, head, elem, xt, title, child, last; |
ElementType elType, xtType; |
ElementType elType, xtType; |
char *s; |
char *s; |
ThotBool mathPI; |
|
SSchema templSchema; |
SSchema templSchema; |
XTigerTemplate t; |
XTigerTemplate t; |
|
|
Line 446 void CreateTemplate(Document doc, char *
|
Line 444 void CreateTemplate(Document doc, char *
|
// Save changes |
// Save changes |
TtaSetStructureChecking (TRUE, doc); |
TtaSetStructureChecking (TRUE, doc); |
|
|
// Save document |
|
//TtaGetEnvBoolean ("GENERATE_MATHPI", &mathPI); |
|
//TtaSetEnvBoolean("GENERATE_MATHPI", TRUE, TRUE); |
|
//SaveDocumentToNewDoc(doc, newdoc, templatePath); |
|
//TtaSetEnvBoolean("GENERATE_MATHPI", mathPI, TRUE); |
|
|
|
TtaClearUndoHistory (doc); |
TtaClearUndoHistory (doc); |
RemoveParsingErrors (doc); |
RemoveParsingErrors (doc); |
|
|
Line 565 void CreateInstance(char *templatePath,
|
Line 557 void CreateInstance(char *templatePath,
|
{ |
{ |
TtaSetDocumentCharset (doc, charset, FALSE); |
TtaSetDocumentCharset (doc, charset, FALSE); |
DocumentMeta[doc]->charset = TtaStrdup (charsetname); |
DocumentMeta[doc]->charset = TtaStrdup (charsetname); |
SetNamespacesAndDTD (doc); |
SetNamespacesAndDTD (doc, FALSE); |
} |
} |
|
|
// Parse template to fill structure and remove extra data |
// Parse template to fill structure and remove extra data |