OLD | NEW |
1 /* | 1 /* |
2 * (C) 1999 Lars Knoll (knoll@kde.org) | 2 * (C) 1999 Lars Knoll (knoll@kde.org) |
3 * (C) 2000 Dirk Mueller (mueller@kde.org) | 3 * (C) 2000 Dirk Mueller (mueller@kde.org) |
4 * Copyright (C) 2004, 2005, 2006, 2007 Apple Inc. All rights reserved. | 4 * Copyright (C) 2004, 2005, 2006, 2007 Apple Inc. All rights reserved. |
5 * | 5 * |
6 * This library is free software; you can redistribute it and/or | 6 * This library is free software; you can redistribute it and/or |
7 * modify it under the terms of the GNU Library General Public | 7 * modify it under the terms of the GNU Library General Public |
8 * License as published by the Free Software Foundation; either | 8 * License as published by the Free Software Foundation; either |
9 * version 2 of the License, or (at your option) any later version. | 9 * version 2 of the License, or (at your option) any later version. |
10 * | 10 * |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
52 private: | 52 private: |
53 virtual void setTextInternal(PassRefPtr<StringImpl>); | 53 virtual void setTextInternal(PassRefPtr<StringImpl>); |
54 virtual UChar previousCharacter() const; | 54 virtual UChar previousCharacter() const; |
55 | 55 |
56 unsigned m_start; | 56 unsigned m_start; |
57 unsigned m_end; | 57 unsigned m_end; |
58 RefPtr<StringImpl> m_contentString; | 58 RefPtr<StringImpl> m_contentString; |
59 RenderObject* m_firstLetter; | 59 RenderObject* m_firstLetter; |
60 }; | 60 }; |
61 | 61 |
| 62 inline RenderTextFragment* toRenderTextFragment(RenderObject* object) |
| 63 { |
| 64 ASSERT(!object || toRenderText(object)->isTextFragment()); |
| 65 return static_cast<RenderTextFragment*>(object); |
| 66 } |
| 67 |
| 68 inline const RenderTextFragment* toRenderTextFragment(const RenderObject* object
) |
| 69 { |
| 70 ASSERT(!object || toRenderText(object)->isTextFragment()); |
| 71 return static_cast<const RenderTextFragment*>(object); |
| 72 } |
| 73 |
| 74 // This will catch anyone doing an unnecessary cast. |
| 75 void toRenderTextFragment(const RenderTextFragment*); |
| 76 |
62 } // namespace WebCore | 77 } // namespace WebCore |
63 | 78 |
64 #endif // RenderTextFragment_h | 79 #endif // RenderTextFragment_h |
OLD | NEW |