merge the formfield patch from ooo-build
[ooovba.git] / starmath / inc / node.hxx
blobe46bae6d8cead277419ac3b07aad5775c1db55b6
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: node.hxx,v $
10 * $Revision: 1.19 $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
32 #ifndef NODE_HXX
33 #define NODE_HXX
36 #include <vector>
38 #include "parse.hxx"
39 #include "types.hxx"
40 #include "rect.hxx"
41 #include "format.hxx"
44 #define ATTR_BOLD 0x0001
45 #define ATTR_ITALIC 0x0002
47 #define FNTSIZ_ABSOLUT 1
48 #define FNTSIZ_PLUS 2
49 #define FNTSIZ_MINUS 3
50 #define FNTSIZ_MULTIPLY 4
51 #define FNTSIZ_DIVIDE 5
53 // flags to interdict respective status changes
54 #define FLG_FONT 0x0001
55 #define FLG_SIZE 0x0002
56 #define FLG_BOLD 0x0004
57 #define FLG_ITALIC 0x0008
58 #define FLG_COLOR 0x0010
59 #define FLG_VISIBLE 0x0020
60 #define FLG_HORALIGN 0x0040
63 extern SmFormat *pActiveFormat;
65 class SmDocShell;
66 class SmNode;
67 class SmStructureNode;
69 typedef std::vector< SmNode * > SmNodeArray;
70 typedef std::vector< SmStructureNode * > SmStructureNodeArray;
73 ////////////////////////////////////////////////////////////////////////////////
75 enum SmScaleMode { SCALE_NONE, SCALE_WIDTH, SCALE_HEIGHT };
77 enum SmNodeType
79 NTABLE, NBRACE, NBRACEBODY, NOPER, NALIGN,
80 NATTRIBUT, NFONT, NUNHOR, NBINHOR, NBINVER,
81 NBINDIAGONAL, NSUBSUP, NMATRIX, NPLACE, NTEXT,
82 NSPECIAL, NGLYPH_SPECIAL, NMATH, NBLANK, NERROR,
83 NLINE, NEXPRESSION, NPOLYLINE, NROOT, NROOTSYMBOL,
84 NRECTANGLE, NVERTICAL_BRACE
88 ////////////////////////////////////////////////////////////////////////////////
91 class SmNode : public SmRect
93 SmFace aFace;
95 SmToken aNodeToken;
96 SmNodeType eType;
97 SmScaleMode eScaleMode;
98 RectHorAlign eRectHorAlign;
99 USHORT nFlags,
100 nAttributes;
101 BOOL bIsPhantom,
102 bIsDebug;
103 protected:
104 SmNode(SmNodeType eNodeType, const SmToken &rNodeToken);
106 // index in accessible text -1 if not (yet) applicable
107 sal_Int32 nAccIndex;
109 public:
110 virtual ~SmNode();
112 virtual BOOL IsVisible() const;
114 virtual USHORT GetNumSubNodes() const;
115 virtual SmNode * GetSubNode(USHORT nIndex);
116 const SmNode * GetSubNode(USHORT nIndex) const
118 return ((SmNode *) this)->GetSubNode(nIndex);
121 virtual SmNode * GetLeftMost();
122 const SmNode * GetLeftMost() const
124 return ((SmNode *) this)->GetLeftMost();
127 USHORT & Flags() { return nFlags; }
128 USHORT & Attributes() { return nAttributes; }
130 BOOL IsDebug() const { return bIsDebug; }
131 BOOL IsPhantom() const { return bIsPhantom; }
132 void SetPhantom(BOOL bIsPhantom);
133 void SetColor(const Color &rColor);
135 void SetAttribut(USHORT nAttrib);
136 void ClearAttribut(USHORT nAttrib);
138 const SmFace & GetFont() const { return aFace; };
139 SmFace & GetFont() { return aFace; };
141 void SetFont(const SmFace &rFace);
142 void SetFontSize(const Fraction &rRelSize, USHORT nType);
143 void SetSize(const Fraction &rScale);
145 virtual void Prepare(const SmFormat &rFormat, const SmDocShell &rDocShell);
146 virtual void PrepareAttributes();
148 #if OSL_DEBUG_LEVEL
149 void ToggleDebug() const;
150 #endif
152 void SetRectHorAlign(RectHorAlign eHorAlign, BOOL bApplyToSubTree = TRUE );
153 RectHorAlign GetRectHorAlign() const { return eRectHorAlign; }
155 const SmRect & GetRect() const { return *this; }
156 SmRect & GetRect() { return *this; }
158 virtual void Move(const Point &rPosition);
159 void MoveTo(const Point &rPosition) { Move(rPosition - GetTopLeft()); }
160 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
161 virtual void CreateTextFromNode(String &rText);
163 #ifdef SM_RECT_DEBUG
164 using SmRect::Draw;
165 #endif
166 virtual void Draw(OutputDevice &rDev, const Point &rPosition) const;
168 virtual void GetAccessibleText( String &rText ) const;
169 sal_Int32 GetAccessibleIndex() const { return nAccIndex; }
170 const SmNode * FindNodeWithAccessibleIndex(xub_StrLen nAccIndex) const;
172 USHORT GetRow() const { return (USHORT)aNodeToken.nRow; }
173 USHORT GetColumn() const { return (USHORT)aNodeToken.nCol; }
175 SmScaleMode GetScaleMode() const { return eScaleMode; }
176 void SetScaleMode(SmScaleMode eMode) { eScaleMode = eMode; }
178 virtual void AdaptToX(const OutputDevice &rDev, ULONG nWidth);
179 virtual void AdaptToY(const OutputDevice &rDev, ULONG nHeight);
181 SmNodeType GetType() const { return eType; }
182 const SmToken & GetToken() const { return aNodeToken; }
184 const SmNode * FindTokenAt(USHORT nRow, USHORT nCol) const;
185 const SmNode * FindRectClosestTo(const Point &rPoint) const;
189 ////////////////////////////////////////////////////////////////////////////////
192 class SmStructureNode : public SmNode
194 SmNodeArray aSubNodes;
196 protected:
197 SmStructureNode(SmNodeType eNodeType, const SmToken &rNodeToken)
198 : SmNode(eNodeType, rNodeToken)
201 public:
202 SmStructureNode( const SmStructureNode &rNode );
203 virtual ~SmStructureNode();
205 virtual BOOL IsVisible() const;
207 virtual USHORT GetNumSubNodes() const;
208 void SetNumSubNodes(USHORT nSize) { aSubNodes.resize(nSize); }
210 using SmNode::GetSubNode;
211 virtual SmNode * GetSubNode(USHORT nIndex);
212 void SetSubNodes(SmNode *pFirst, SmNode *pSecond, SmNode *pThird = NULL);
213 void SetSubNodes(const SmNodeArray &rNodeArray);
215 virtual SmStructureNode & operator = ( const SmStructureNode &rNode );
217 virtual void GetAccessibleText( String &rText ) const;
221 ////////////////////////////////////////////////////////////////////////////////
224 class SmVisibleNode : public SmNode
226 protected:
227 SmVisibleNode(SmNodeType eNodeType, const SmToken &rNodeToken)
228 : SmNode(eNodeType, rNodeToken)
231 public:
233 virtual BOOL IsVisible() const;
234 virtual USHORT GetNumSubNodes() const;
235 using SmNode::GetSubNode;
236 virtual SmNode * GetSubNode(USHORT nIndex);
240 ////////////////////////////////////////////////////////////////////////////////
243 class SmGraphicNode : public SmVisibleNode
245 protected:
246 SmGraphicNode(SmNodeType eNodeType, const SmToken &rNodeToken)
247 : SmVisibleNode(eNodeType, rNodeToken)
250 public:
252 virtual void GetAccessibleText( String &rText ) const;
256 ////////////////////////////////////////////////////////////////////////////////
259 class SmRectangleNode : public SmGraphicNode
261 Size aToSize;
263 public:
264 SmRectangleNode(const SmToken &rNodeToken)
265 : SmGraphicNode(NRECTANGLE, rNodeToken)
268 virtual void AdaptToX(const OutputDevice &rDev, ULONG nWidth);
269 virtual void AdaptToY(const OutputDevice &rDev, ULONG nHeight);
271 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
273 #ifdef SM_RECT_DEBUG
274 using SmRect::Draw;
275 #endif
276 virtual void Draw(OutputDevice &rDev, const Point &rPosition) const;
278 void CreateTextFromNode(String &rText);
282 ////////////////////////////////////////////////////////////////////////////////
285 class SmPolyLineNode : public SmGraphicNode
287 Polygon aPoly;
288 Size aToSize;
289 long nWidth;
291 public:
292 SmPolyLineNode(const SmToken &rNodeToken);
294 long GetWidth() const { return nWidth; }
296 virtual void AdaptToX(const OutputDevice &rDev, ULONG nWidth);
297 virtual void AdaptToY(const OutputDevice &rDev, ULONG nHeight);
299 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
301 #ifdef SM_RECT_DEBUG
302 using SmRect::Draw;
303 #endif
304 virtual void Draw(OutputDevice &rDev, const Point &rPosition) const;
308 ////////////////////////////////////////////////////////////////////////////////
311 class SmTextNode : public SmVisibleNode
313 XubString aText;
314 USHORT nFontDesc;
316 protected:
317 SmTextNode(SmNodeType eNodeType, const SmToken &rNodeToken, USHORT nFontDescP)
318 : SmVisibleNode(eNodeType, rNodeToken)
320 nFontDesc = nFontDescP;
323 public:
324 SmTextNode(const SmToken &rNodeToken, USHORT nFontDescP)
325 : SmVisibleNode(NTEXT, rNodeToken)
327 nFontDesc = nFontDescP;
331 USHORT GetFontDesc() const { return nFontDesc; }
332 void SetText(const XubString &rText) { aText = rText; }
333 const XubString & GetText() const { return aText; }
335 virtual void Prepare(const SmFormat &rFormat, const SmDocShell &rDocShell);
336 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
337 virtual void CreateTextFromNode(String &rText);
339 #ifdef SM_RECT_DEBUG
340 using SmRect::Draw;
341 #endif
342 virtual void Draw(OutputDevice &rDev, const Point &rPosition) const;
344 virtual void GetAccessibleText( String &rText ) const;
348 ////////////////////////////////////////////////////////////////////////////////
351 class SmSpecialNode : public SmTextNode
353 protected:
354 SmSpecialNode(SmNodeType eNodeType, const SmToken &rNodeToken, USHORT _nFontDesc)
355 : SmTextNode(eNodeType, rNodeToken, _nFontDesc)
358 public:
359 SmSpecialNode(const SmToken &rNodeToken)
360 : SmTextNode(NSPECIAL, rNodeToken, FNT_MATH) //! default Font nicht immer richtig
363 virtual void Prepare(const SmFormat &rFormat, const SmDocShell &rDocShell);
364 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
366 #ifdef SM_RECT_DEBUG
367 using SmRect::Draw;
368 #endif
369 virtual void Draw(OutputDevice &rDev, const Point &rPosition) const;
373 ////////////////////////////////////////////////////////////////////////////////
376 class SmGlyphSpecialNode : public SmSpecialNode
378 public:
379 SmGlyphSpecialNode(const SmToken &rNodeToken)
380 : SmSpecialNode(NGLYPH_SPECIAL, rNodeToken, FNT_MATH)
383 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
387 ////////////////////////////////////////////////////////////////////////////////
390 class SmMathSymbolNode : public SmSpecialNode
392 protected:
393 SmMathSymbolNode(SmNodeType eNodeType, const SmToken &rNodeToken)
394 : SmSpecialNode(eNodeType, rNodeToken, FNT_MATH)
396 xub_Unicode cChar = GetToken().cMathChar;
397 if ((xub_Unicode) '\0' != cChar)
398 SetText( cChar );
401 public:
402 SmMathSymbolNode(const SmToken &rNodeToken);
404 virtual void AdaptToX(const OutputDevice &rDev, ULONG nWidth);
405 virtual void AdaptToY(const OutputDevice &rDev, ULONG nHeight);
407 virtual void Prepare(const SmFormat &rFormat, const SmDocShell &rDocShell);
408 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
409 void CreateTextFromNode(String &rText);
413 ////////////////////////////////////////////////////////////////////////////////
416 class SmRootSymbolNode : public SmMathSymbolNode
418 ULONG nBodyWidth; // width of body (argument) of root sign
420 public:
421 SmRootSymbolNode(const SmToken &rNodeToken)
422 : SmMathSymbolNode(NROOTSYMBOL, rNodeToken)
425 virtual void AdaptToX(const OutputDevice &rDev, ULONG nWidth);
426 virtual void AdaptToY(const OutputDevice &rDev, ULONG nHeight);
428 #ifdef SM_RECT_DEBUG
429 using SmRect::Draw;
430 #endif
431 virtual void Draw(OutputDevice &rDev, const Point &rPosition) const;
435 ////////////////////////////////////////////////////////////////////////////////
438 class SmPlaceNode : public SmMathSymbolNode
440 public:
441 SmPlaceNode(const SmToken &rNodeToken)
442 : SmMathSymbolNode(NPLACE, rNodeToken)
446 virtual void Prepare(const SmFormat &rFormat, const SmDocShell &rDocShell);
447 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
451 ////////////////////////////////////////////////////////////////////////////////
454 class SmErrorNode : public SmMathSymbolNode
456 public:
457 SmErrorNode(SmParseError /*eError*/, const SmToken &rNodeToken)
458 : SmMathSymbolNode(NERROR, rNodeToken)
460 SetText((xub_Unicode) MS_ERROR);
463 virtual void Prepare(const SmFormat &rFormat, const SmDocShell &rDocShell);
464 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
468 ////////////////////////////////////////////////////////////////////////////////
471 class SmTableNode : public SmStructureNode
473 public:
474 SmTableNode(const SmToken &rNodeToken)
475 : SmStructureNode(NTABLE, rNodeToken)
478 using SmNode::GetLeftMost;
479 virtual SmNode * GetLeftMost();
481 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
485 ////////////////////////////////////////////////////////////////////////////////
488 class SmLineNode : public SmStructureNode
490 protected:
491 SmLineNode(SmNodeType eNodeType, const SmToken &rNodeToken)
492 : SmStructureNode(eNodeType, rNodeToken)
495 public:
496 SmLineNode(const SmToken &rNodeToken)
497 : SmStructureNode(NLINE, rNodeToken)
500 virtual void Prepare(const SmFormat &rFormat, const SmDocShell &rDocShell);
501 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
505 ////////////////////////////////////////////////////////////////////////////////
508 class SmExpressionNode : public SmLineNode
510 public:
511 SmExpressionNode(const SmToken &rNodeToken)
512 : SmLineNode(NEXPRESSION, rNodeToken)
515 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
516 void CreateTextFromNode(String &rText);
520 ////////////////////////////////////////////////////////////////////////////////
523 class SmUnHorNode : public SmStructureNode
525 public:
526 SmUnHorNode(const SmToken &rNodeToken)
527 : SmStructureNode(NUNHOR, rNodeToken)
529 SetNumSubNodes(2);
532 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
536 ////////////////////////////////////////////////////////////////////////////////
539 class SmRootNode : public SmStructureNode
541 protected:
542 void GetHeightVerOffset(const SmRect &rRect,
543 long &rHeight, long &rVerOffset) const;
544 Point GetExtraPos(const SmRect &rRootSymbol, const SmRect &rExtra) const;
546 public:
547 SmRootNode(const SmToken &rNodeToken)
548 : SmStructureNode(NROOT, rNodeToken)
550 SetNumSubNodes(3);
553 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
554 void CreateTextFromNode(String &rText);
558 ////////////////////////////////////////////////////////////////////////////////
561 class SmBinHorNode : public SmStructureNode
563 public:
564 SmBinHorNode(const SmToken &rNodeToken)
565 : SmStructureNode(NBINHOR, rNodeToken)
567 SetNumSubNodes(3);
570 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
574 ////////////////////////////////////////////////////////////////////////////////
577 class SmBinVerNode : public SmStructureNode
579 public:
580 SmBinVerNode(const SmToken &rNodeToken)
581 : SmStructureNode(NBINVER, rNodeToken)
583 SetNumSubNodes(3);
586 using SmNode::GetLeftMost;
587 virtual SmNode * GetLeftMost();
589 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
590 void CreateTextFromNode(String &rText);
594 ////////////////////////////////////////////////////////////////////////////////
597 class SmBinDiagonalNode : public SmStructureNode
599 BOOL bAscending;
601 void GetOperPosSize(Point &rPos, Size &rSize,
602 const Point &rDiagPoint, double fAngleDeg) const;
604 public:
605 SmBinDiagonalNode(const SmToken &rNodeToken);
607 BOOL IsAscending() const { return bAscending; }
608 void SetAscending(BOOL bVal) { bAscending = bVal; }
610 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
614 ////////////////////////////////////////////////////////////////////////////////
617 // enums used to index sub-/supscripts in the 'aSubNodes' array
618 // in 'SmSubSupNode'
619 // See graphic for positions at char:
621 // CSUP
623 // LSUP H H RSUP
624 // H H
625 // HHHH
626 // H H
627 // LSUB H H RSUB
629 // CSUB
631 enum SmSubSup
632 { CSUB, CSUP, RSUB, RSUP, LSUB, LSUP
635 // numbers of entries in the above enum (that is: the number of possible
636 // sub-/supscripts)
637 #define SUBSUP_NUM_ENTRIES 6
640 class SmSubSupNode : public SmStructureNode
642 BOOL bUseLimits;
644 public:
645 SmSubSupNode(const SmToken &rNodeToken)
646 : SmStructureNode(NSUBSUP, rNodeToken)
648 SetNumSubNodes(1 + SUBSUP_NUM_ENTRIES);
649 bUseLimits = FALSE;
652 SmNode * GetBody() { return GetSubNode(0); }
653 const SmNode * GetBody() const
655 return ((SmSubSupNode *) this)->GetBody();
658 void SetUseLimits(BOOL bVal) { bUseLimits = bVal; }
659 BOOL IsUseLimits() const { return bUseLimits; };
661 SmNode * GetSubSup(SmSubSup eSubSup) { return GetSubNode( sal::static_int_cast< USHORT >(1 + eSubSup) ); };
663 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
664 void CreateTextFromNode(String &rText);
669 ////////////////////////////////////////////////////////////////////////////////
672 class SmBraceNode : public SmStructureNode
674 public:
675 SmBraceNode(const SmToken &rNodeToken)
676 : SmStructureNode(NBRACE, rNodeToken)
678 SetNumSubNodes(3);
681 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
682 void CreateTextFromNode(String &rText);
686 ////////////////////////////////////////////////////////////////////////////////
689 class SmBracebodyNode : public SmStructureNode
691 long nBodyHeight;
693 public:
694 inline SmBracebodyNode(const SmToken &rNodeToken);
696 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
697 long GetBodyHeight() const { return nBodyHeight; }
701 inline SmBracebodyNode::SmBracebodyNode(const SmToken &rNodeToken) :
702 SmStructureNode(NBRACEBODY, rNodeToken)
704 nBodyHeight = 0;
708 ////////////////////////////////////////////////////////////////////////////////
711 class SmVerticalBraceNode : public SmStructureNode
713 public:
714 inline SmVerticalBraceNode(const SmToken &rNodeToken);
716 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
720 inline SmVerticalBraceNode::SmVerticalBraceNode(const SmToken &rNodeToken) :
721 SmStructureNode(NVERTICAL_BRACE, rNodeToken)
723 SetNumSubNodes(3);
727 ////////////////////////////////////////////////////////////////////////////////
730 class SmOperNode : public SmStructureNode
732 public:
733 SmOperNode(const SmToken &rNodeToken)
734 : SmStructureNode(NOPER, rNodeToken)
736 SetNumSubNodes(2);
739 SmNode * GetSymbol();
740 const SmNode * GetSymbol() const
742 return ((SmOperNode *) this)->GetSymbol();
745 long CalcSymbolHeight(const SmNode &rSymbol, const SmFormat &rFormat) const;
747 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
751 ////////////////////////////////////////////////////////////////////////////////
754 class SmAlignNode : public SmStructureNode
756 public:
757 SmAlignNode(const SmToken &rNodeToken)
758 : SmStructureNode(NALIGN, rNodeToken)
761 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
765 ////////////////////////////////////////////////////////////////////////////////
768 class SmAttributNode : public SmStructureNode
770 public:
771 SmAttributNode(const SmToken &rNodeToken)
772 : SmStructureNode(NATTRIBUT, rNodeToken)
775 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
776 void CreateTextFromNode(String &rText);
780 ////////////////////////////////////////////////////////////////////////////////
783 class SmFontNode : public SmStructureNode
785 USHORT nSizeType;
786 Fraction aFontSize;
788 public:
789 SmFontNode(const SmToken &rNodeToken)
790 : SmStructureNode(NFONT, rNodeToken)
792 nSizeType = FNTSIZ_MULTIPLY;
793 aFontSize = Fraction(1L);
796 void SetSizeParameter(const Fraction &rValue, USHORT nType);
797 const Fraction & GetSizeParameter() const {return aFontSize;}
798 const USHORT& GetSizeType() const {return nSizeType;}
800 virtual void Prepare(const SmFormat &rFormat, const SmDocShell &rDocShell);
801 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
802 void CreateTextFromNode(String &rText);
806 ////////////////////////////////////////////////////////////////////////////////
809 class SmMatrixNode : public SmStructureNode
811 USHORT nNumRows,
812 nNumCols;
814 public:
815 SmMatrixNode(const SmToken &rNodeToken)
816 : SmStructureNode(NMATRIX, rNodeToken)
818 nNumRows = nNumCols = 0;
821 USHORT GetNumRows() const {return nNumRows;}
822 USHORT GetNumCols() const {return nNumCols;}
823 void SetRowCol(USHORT nMatrixRows, USHORT nMatrixCols);
825 using SmNode::GetLeftMost;
826 virtual SmNode * GetLeftMost();
828 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
829 void CreateTextFromNode(String &rText);
833 ////////////////////////////////////////////////////////////////////////////////
836 class SmBlankNode : public SmGraphicNode
838 USHORT nNum;
840 public:
841 SmBlankNode(const SmToken &rNodeToken)
842 : SmGraphicNode(NBLANK, rNodeToken)
844 nNum = 0;
847 void IncreaseBy(const SmToken &rToken);
848 void Clear() { nNum = 0; }
850 virtual void Prepare(const SmFormat &rFormat, const SmDocShell &rDocShell);
851 virtual void Arrange(const OutputDevice &rDev, const SmFormat &rFormat);
855 ////////////////////////////////////////////////////////////////////////////////
857 #endif