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

Side by Side Diff: cc/layers/heads_up_display_layer_impl.h

Issue 1027393004: Fix text clipping in CompositorFrameTime Display (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added MeasureText() Created 5 years, 9 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
« no previous file with comments | « no previous file | cc/layers/heads_up_display_layer_impl.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 2012 The Chromium Authors. All rights reserved. 1 // Copyright 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 CC_LAYERS_HEADS_UP_DISPLAY_LAYER_IMPL_H_ 5 #ifndef CC_LAYERS_HEADS_UP_DISPLAY_LAYER_IMPL_H_
6 #define CC_LAYERS_HEADS_UP_DISPLAY_LAYER_IMPL_H_ 6 #define CC_LAYERS_HEADS_UP_DISPLAY_LAYER_IMPL_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 70
71 HeadsUpDisplayLayerImpl(LayerTreeImpl* tree_impl, int id); 71 HeadsUpDisplayLayerImpl(LayerTreeImpl* tree_impl, int id);
72 72
73 const char* LayerTypeAsString() const override; 73 const char* LayerTypeAsString() const override;
74 74
75 void AsValueInto(base::trace_event::TracedValue* dict) const override; 75 void AsValueInto(base::trace_event::TracedValue* dict) const override;
76 76
77 void UpdateHudContents(); 77 void UpdateHudContents();
78 void DrawHudContents(SkCanvas* canvas); 78 void DrawHudContents(SkCanvas* canvas);
79 79
80 int MeasureText(SkPaint* paint, const std::string& text, int size) const;
80 void DrawText(SkCanvas* canvas, 81 void DrawText(SkCanvas* canvas,
81 SkPaint* paint, 82 SkPaint* paint,
82 const std::string& text, 83 const std::string& text,
83 SkPaint::Align align, 84 SkPaint::Align align,
84 int size, 85 int size,
85 int x, 86 int x,
86 int y) const; 87 int y) const;
87 void DrawText(SkCanvas* canvas, 88 void DrawText(SkCanvas* canvas,
88 SkPaint* paint, 89 SkPaint* paint,
89 const std::string& text, 90 const std::string& text,
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
141 std::vector<DebugRect> paint_rects_; 142 std::vector<DebugRect> paint_rects_;
142 143
143 base::TimeTicks time_of_last_graph_update_; 144 base::TimeTicks time_of_last_graph_update_;
144 145
145 DISALLOW_COPY_AND_ASSIGN(HeadsUpDisplayLayerImpl); 146 DISALLOW_COPY_AND_ASSIGN(HeadsUpDisplayLayerImpl);
146 }; 147 };
147 148
148 } // namespace cc 149 } // namespace cc
149 150
150 #endif // CC_LAYERS_HEADS_UP_DISPLAY_LAYER_IMPL_H_ 151 #endif // CC_LAYERS_HEADS_UP_DISPLAY_LAYER_IMPL_H_
OLDNEW
« no previous file with comments | « no previous file | cc/layers/heads_up_display_layer_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698