fixed: compile issue
[opensg.git] / Source / System / Window / Foreground / OSGSimpleTextForeground.inl
blobc9f41732a8661d6e2f11f68e69711ffb204383ac
1 /*---------------------------------------------------------------------------*\
2  *                                OpenSG                                     *
3  *                                                                           *
4  *                                                                           *
5  *               Copyright (C) 2000-2006 by the OpenSG Forum                 *
6  *                                                                           *
7  * contact: David Kabala (djkabala@gmail.com)                                *
8  *                                                                           *
9 \*---------------------------------------------------------------------------*/
10 /*---------------------------------------------------------------------------*\
11  *                                License                                    *
12  *                                                                           *
13  * This library is free software; you can redistribute it and/or modify it   *
14  * under the terms of the GNU Library General Public License as published    *
15  * by the Free Software Foundation, version 2.                               *
16  *                                                                           *
17  * This library is distributed in the hope that it will be useful, but       *
18  * WITHOUT ANY WARRANTY; without even the implied warranty of                *
19  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU         *
20  * Library General Public License for more details.                          *
21  *                                                                           *
22  * You should have received a copy of the GNU Library General Public         *
23  * License along with this library; if not, write to the Free Software       *
24  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.                 *
25  *                                                                           *
26 \*---------------------------------------------------------------------------*/
27 /*---------------------------------------------------------------------------*\
28  *                                Changes                                    *
29  *                                                                           *
30  *                                                                           *
31  *                                                                           *
32  *                                                                           *
33  *                                                                           *
34  *                                                                           *
35 \*---------------------------------------------------------------------------*/
37 //---------------------------------------------------------------------------
38 //  Includes
39 //---------------------------------------------------------------------------
41 OSG_BEGIN_NAMESPACE
43 inline
44 void SimpleTextForeground::addLine(const std::string &szText)
46     editMFLines()->push_back(szText);
49 inline
50 void SimpleTextForeground::clear(void)
52     editMFLines()->clear();
55 inline
56 bool SimpleTextForeground::TextColoredRange::isBounded(UInt32 uiPosition) const
58     return (uiPosition >= _uiStart &&
59             uiPosition <= _uiEnd);
62 inline
63 SimpleTextForeground::TextColoredRange::TextColoredRange(      UInt32  uiStart,
64                                                                UInt32  uiEnd,
65                                                          const Color4f &cColor):
66     _uiStart(uiStart),
67     _uiEnd  (uiEnd  ),
68     _cColor (cColor )
72 inline
73 const Color4f &SimpleTextForeground::TextColoredRange::getColor(void) const
75     return _cColor;
78 inline
79 UInt32 SimpleTextForeground::TextColoredRange::getStart(void) const
81     return _uiStart;
84 inline
85 UInt32 SimpleTextForeground::TextColoredRange::getEnd(void) const
87     return _uiEnd;
91 OSG_END_NAMESPACE