Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(87)

Side by Side Diff: ui/gfx/render_text_linux.h

Issue 10591003: Expose GetBaseline() method on RenderText. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « ui/gfx/render_text.h ('k') | ui/gfx/render_text_linux.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_LINUX_H_ 5 #ifndef UI_GFX_RENDER_TEXT_LINUX_H_
6 #define UI_GFX_RENDER_TEXT_LINUX_H_ 6 #define UI_GFX_RENDER_TEXT_LINUX_H_
7 #pragma once 7 #pragma once
8 8
9 #include <pango/pango.h> 9 #include <pango/pango.h>
10 #include <vector> 10 #include <vector>
11 11
12 #include "ui/gfx/render_text.h" 12 #include "ui/gfx/render_text.h"
13 13
14 namespace gfx { 14 namespace gfx {
15 15
16 // RenderTextLinux is the Linux implementation of RenderText using Pango. 16 // RenderTextLinux is the Linux implementation of RenderText using Pango.
17 class RenderTextLinux : public RenderText { 17 class RenderTextLinux : public RenderText {
18 public: 18 public:
19 RenderTextLinux(); 19 RenderTextLinux();
20 virtual ~RenderTextLinux(); 20 virtual ~RenderTextLinux();
21 21
22 // Overridden from RenderText: 22 // Overridden from RenderText:
23 virtual base::i18n::TextDirection GetTextDirection() OVERRIDE; 23 virtual base::i18n::TextDirection GetTextDirection() OVERRIDE;
24 virtual Size GetStringSize() OVERRIDE; 24 virtual Size GetStringSize() OVERRIDE;
25 virtual int GetBaseline() OVERRIDE;
25 virtual SelectionModel FindCursorPosition(const Point& point) OVERRIDE; 26 virtual SelectionModel FindCursorPosition(const Point& point) OVERRIDE;
26 virtual std::vector<FontSpan> GetFontSpansForTesting() OVERRIDE; 27 virtual std::vector<FontSpan> GetFontSpansForTesting() OVERRIDE;
27 28
28 protected: 29 protected:
29 // Overridden from RenderText: 30 // Overridden from RenderText:
30 virtual SelectionModel AdjacentCharSelectionModel( 31 virtual SelectionModel AdjacentCharSelectionModel(
31 const SelectionModel& selection, 32 const SelectionModel& selection,
32 VisualCursorDirection direction) OVERRIDE; 33 VisualCursorDirection direction) OVERRIDE;
33 virtual SelectionModel AdjacentWordSelectionModel( 34 virtual SelectionModel AdjacentWordSelectionModel(
34 const SelectionModel& selection, 35 const SelectionModel& selection,
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
91 const char* layout_text_; 92 const char* layout_text_;
92 // The text length. 93 // The text length.
93 size_t layout_text_len_; 94 size_t layout_text_len_;
94 95
95 DISALLOW_COPY_AND_ASSIGN(RenderTextLinux); 96 DISALLOW_COPY_AND_ASSIGN(RenderTextLinux);
96 }; 97 };
97 98
98 } // namespace gfx 99 } // namespace gfx
99 100
100 #endif // UI_GFX_RENDER_TEXT_LINUX_H_ 101 #endif // UI_GFX_RENDER_TEXT_LINUX_H_
OLDNEW
« no previous file with comments | « ui/gfx/render_text.h ('k') | ui/gfx/render_text_linux.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698