• Main Page
  • Related Pages
  • Namespaces
  • Classes
  • Files
  • File List
  • File Members

fl_Layout.h

Go to the documentation of this file.
00001 /* AbiWord
00002  * Copyright (C) 1998 AbiSource, Inc.
00003  *
00004  * This program is free software; you can redistribute it and/or
00005  * modify it under the terms of the GNU General Public License
00006  * as published by the Free Software Foundation; either version 2
00007  * of the License, or (at your option) any later version.
00008  *
00009  * This program is distributed in the hope that it will be useful,
00010  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00011  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00012  * GNU General Public License for more details.
00013  *
00014  * You should have received a copy of the GNU General Public License
00015  * along with this program; if not, write to the Free Software
00016  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
00017  * 02110-1301 USA.
00018  */
00019 
00020 
00021 
00022 #ifndef FL_LAYOUT_H
00023 #define FL_LAYOUT_H
00024 
00025 #include "ut_types.h"
00026 #include "pt_Types.h"
00027 #include "fl_AutoNum.h"
00028 
00029 class PP_AttrProp;
00030 class PP_RevisionAttr;
00031 class PD_Document;
00032 class fd_Field;
00033 class po_Bookmark;
00034 class pf_Frag_Strux;
00035 
00044 class ABI_EXPORT fl_Layout
00045 {
00046 public:
00047     fl_Layout(PTStruxType type, pf_Frag_Strux* sdh);
00048     virtual ~fl_Layout();
00049 
00050     pf_Frag_Strux*           getStruxDocHandle(void) const
00051         { return m_sdh; }
00052     pf_Frag_Strux*           getEndStruxDocHandle(void) const
00053         { return m_endSdh; }
00054     void                         setEndStruxDocHandle(pf_Frag_Strux * pfs);
00055     PTStruxType         getType(void) const
00056         { return m_type; }
00057     void                setType(PTStruxType type);
00058     PT_AttrPropIndex    getAttrPropIndex(void) const
00059         { return m_apIndex; }
00060     void                setAttrPropIndex(PT_AttrPropIndex apIndex);
00061 
00062     bool                getAttrProp(const PP_AttrProp ** ppAP, std::unique_ptr<PP_RevisionAttr>& pRevisions,
00063                                     bool bShowRevisions, UT_uint32 iRevisionId,
00064                                     bool &bHiddenRevision) const;
00065 
00066     bool    getSpanAttrProp(UT_uint32 offset, bool bLeftSide, const PP_AttrProp ** ppAP,
00067                                 std::unique_ptr<PP_RevisionAttr>& pRevisions,
00068                                 bool bShowRevisions, UT_uint32 iRevisionId,
00069                                 bool &bHiddenRevision) const;
00070 
00071     bool                getField(UT_uint32 offset, fd_Field * &pField);
00072     po_Bookmark *       getBookmark(UT_uint32 offset);
00073     virtual void        listUpdate(void) { return; }
00074     inline const fl_AutoNumPtr &    getAutoNum(void) const { return m_pAutoNum; }
00075     void                setAutoNum(const fl_AutoNumPtr & pAutoNum);
00076 
00077     PD_Document *       getDocument(void) const { return m_pDoc; };
00078 
00079 protected:
00080     PTStruxType             m_type;
00081     PT_AttrPropIndex        m_apIndex;
00082     fl_AutoNumPtr           m_pAutoNum;
00083 
00084     PD_Document *           m_pDoc;     // set by child
00085 private:
00086     pf_Frag_Strux*      m_sdh;
00087     pf_Frag_Strux*      m_endSdh;
00088 };
00089 
00090 #endif /* FL_LAYOUT_H */

Generated on Sun Feb 14 2021 for AbiWord by  doxygen 1.7.1