| OLD | NEW | 
|---|
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be | 
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. | 
| 4 | 4 | 
| 5 #ifndef UI_GFX_RENDER_TEXT_H_ | 5 #ifndef UI_GFX_RENDER_TEXT_H_ | 
| 6 #define UI_GFX_RENDER_TEXT_H_ | 6 #define UI_GFX_RENDER_TEXT_H_ | 
| 7 | 7 | 
| 8 #include <algorithm> | 8 #include <algorithm> | 
| 9 #include <cstring> | 9 #include <cstring> | 
| 10 #include <string> | 10 #include <string> | 
| (...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 200 | 200 | 
| 201   // Creates a platform-specific or cross-platform RenderText instance. | 201   // Creates a platform-specific or cross-platform RenderText instance. | 
| 202   static RenderText* CreateInstance(); | 202   static RenderText* CreateInstance(); | 
| 203   static RenderText* CreateInstanceForEditing(); | 203   static RenderText* CreateInstanceForEditing(); | 
| 204 | 204 | 
| 205   // Creates another instance of the same concrete class. | 205   // Creates another instance of the same concrete class. | 
| 206   virtual scoped_ptr<RenderText> CreateInstanceOfSameType() const = 0; | 206   virtual scoped_ptr<RenderText> CreateInstanceOfSameType() const = 0; | 
| 207 | 207 | 
| 208   const base::string16& text() const { return text_; } | 208   const base::string16& text() const { return text_; } | 
| 209   void SetText(const base::string16& text); | 209   void SetText(const base::string16& text); | 
|  | 210   void AppendText(const base::string16& text); | 
| 210 | 211 | 
| 211   HorizontalAlignment horizontal_alignment() const { | 212   HorizontalAlignment horizontal_alignment() const { | 
| 212     return horizontal_alignment_; | 213     return horizontal_alignment_; | 
| 213   } | 214   } | 
| 214   void SetHorizontalAlignment(HorizontalAlignment alignment); | 215   void SetHorizontalAlignment(HorizontalAlignment alignment); | 
| 215 | 216 | 
| 216   const FontList& font_list() const { return font_list_; } | 217   const FontList& font_list() const { return font_list_; } | 
| 217   void SetFontList(const FontList& font_list); | 218   void SetFontList(const FontList& font_list); | 
| 218 | 219 | 
| 219   bool cursor_enabled() const { return cursor_enabled_; } | 220   bool cursor_enabled() const { return cursor_enabled_; } | 
| (...skipping 575 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 795   // Lines computed by EnsureLayout. These should be invalidated upon | 796   // Lines computed by EnsureLayout. These should be invalidated upon | 
| 796   // OnLayoutTextAttributeChanged and OnDisplayTextAttributeChanged calls. | 797   // OnLayoutTextAttributeChanged and OnDisplayTextAttributeChanged calls. | 
| 797   std::vector<internal::Line> lines_; | 798   std::vector<internal::Line> lines_; | 
| 798 | 799 | 
| 799   DISALLOW_COPY_AND_ASSIGN(RenderText); | 800   DISALLOW_COPY_AND_ASSIGN(RenderText); | 
| 800 }; | 801 }; | 
| 801 | 802 | 
| 802 }  // namespace gfx | 803 }  // namespace gfx | 
| 803 | 804 | 
| 804 #endif  // UI_GFX_RENDER_TEXT_H_ | 805 #endif  // UI_GFX_RENDER_TEXT_H_ | 
| OLD | NEW | 
|---|