From: Christian Biesinger (cbiesinger@web.de)
Date: Sat May 04 2002 - 11:18:51 EDT
Hello!
How do I add footers and headers to a document from an importer?
Should I just do this:
        const char* attrs[] = {
                "type",
                "header",
                "name",
                "sdwDocHdr",
                0
        };
        getDoc()->appendStrux(PTX_Section, attrs);
        getDoc()->appendStrux(PTX_Block, NULL);
        getDoc()->appendSpan(str, UT_UCS_strlen(str));
And for the text strux:
        const char* attrs[] = {
                "header",
                "sdwDocHdr",
                0
        };
        if (!getDoc()->appendStrux(PTX_Section, attrs))
                return UT_IE_NOMEMORY;
        if (!getDoc()->appendStrux(PTX_Block, NULL))
                return UT_IE_NOMEMORY;
Should this work?
(Right now it doesn't, but that may be because I do the second
appendStrux actually before the first one)
-- 
"They that can give up essential liberty to obtain a little temporary
safety deserve neither liberty nor safety."
                                                 -- Benjamin Franklin
This archive was generated by hypermail 2.1.4 : Sat May 04 2002 - 11:21:46 EDT