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

Side by Side Diff: ui/gfx/canvas_skia.cc

Issue 7265011: RenderText API Outline. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Add some placeholder functionality on Windows. Created 9 years, 5 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
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #include "ui/gfx/canvas_skia.h" 5 #include "ui/gfx/canvas_skia.h"
6 6
7 #include <limits> 7 #include <limits>
8 8
9 #include "base/i18n/rtl.h" 9 #include "base/i18n/rtl.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 276 matching lines...) Expand 10 before | Expand all | Expand 10 after
287 } 287 }
288 288
289 void CanvasSkia::DrawStringInt(const string16& text, 289 void CanvasSkia::DrawStringInt(const string16& text,
290 const gfx::Font& font, 290 const gfx::Font& font,
291 const SkColor& color, 291 const SkColor& color,
292 const gfx::Rect& display_rect) { 292 const gfx::Rect& display_rect) {
293 DrawStringInt(text, font, color, display_rect.x(), display_rect.y(), 293 DrawStringInt(text, font, color, display_rect.x(), display_rect.y(),
294 display_rect.width(), display_rect.height()); 294 display_rect.width(), display_rect.height());
295 } 295 }
296 296
297 // TODO(msw): Common implementation calls a RenderText function???
298 //void CanvasSkia::DrawStringInt(const gfx::RenderText& render_text) {
299 // NOTIMPLEMENTED();
300 //}
301
297 void CanvasSkia::TileImageInt(const SkBitmap& bitmap, 302 void CanvasSkia::TileImageInt(const SkBitmap& bitmap,
298 int x, int y, int w, int h) { 303 int x, int y, int w, int h) {
299 TileImageInt(bitmap, 0, 0, x, y, w, h); 304 TileImageInt(bitmap, 0, 0, x, y, w, h);
300 } 305 }
301 306
302 void CanvasSkia::TileImageInt(const SkBitmap& bitmap, 307 void CanvasSkia::TileImageInt(const SkBitmap& bitmap,
303 int src_x, int src_y, 308 int src_x, int src_y,
304 int dest_x, int dest_y, int w, int h) { 309 int dest_x, int dest_y, int w, int h) {
305 if (!IntersectsClipRectInt(dest_x, dest_y, w, h)) 310 if (!IntersectsClipRectInt(dest_x, dest_y, w, h))
306 return; 311 return;
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after
387 392
388 CanvasPaint* CanvasPaint::CreateCanvasPaint(gfx::NativeView view) { 393 CanvasPaint* CanvasPaint::CreateCanvasPaint(gfx::NativeView view) {
389 #if defined(OS_WIN) 394 #if defined(OS_WIN)
390 return new CanvasPaintWin(view); 395 return new CanvasPaintWin(view);
391 #else 396 #else
392 return NULL; 397 return NULL;
393 #endif 398 #endif
394 } 399 }
395 400
396 } // namespace gfx 401 } // namespace gfx
OLDNEW
« no previous file with comments | « ui/gfx/canvas_skia.h ('k') | ui/gfx/canvas_skia_linux.cc » ('j') | ui/gfx/render_text.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698