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

Side by Side Diff: skia/ext/platform_device.h

Issue 10915065: Add PlatformPictureSkia and RecordingPlatformDeviceSkia. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Minor style changes and move skia include to .cpp file. Created 8 years, 3 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) 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 SKIA_EXT_PLATFORM_DEVICE_H_ 5 #ifndef SKIA_EXT_PLATFORM_DEVICE_H_
6 #define SKIA_EXT_PLATFORM_DEVICE_H_ 6 #define SKIA_EXT_PLATFORM_DEVICE_H_
7 7
8 #include "build/build_config.h" 8 #include "build/build_config.h"
9 9
10 #if defined(OS_WIN) 10 #if defined(OS_WIN)
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after
117 // temporarily create it. However, if you have created the bitmap DC, it will 117 // temporarily create it. However, if you have created the bitmap DC, it will
118 // be more efficient if you don't free it until after this call so it doesn't 118 // be more efficient if you don't free it until after this call so it doesn't
119 // have to be created twice. If src_rect is null, then the entirety of the 119 // have to be created twice. If src_rect is null, then the entirety of the
120 // source device will be copied. 120 // source device will be copied.
121 virtual void DrawToNativeContext(PlatformSurface surface, int x, int y, 121 virtual void DrawToNativeContext(PlatformSurface surface, int x, int y,
122 const PlatformRect* src_rect) = 0; 122 const PlatformRect* src_rect) = 0;
123 123
124 // Returns if GDI is allowed to render text to this device. 124 // Returns if GDI is allowed to render text to this device.
125 virtual bool IsNativeFontRenderingAllowed(); 125 virtual bool IsNativeFontRenderingAllowed();
126 126
127 // Returns if GDI is allowed to render to this device.
reed1 2012/09/17 16:51:24 Is this the same semantic as SupportsPlatformPaint
128 virtual bool IsNativeRenderingAllowed();
129
127 #if defined(OS_WIN) 130 #if defined(OS_WIN)
128 // Loads a SkPath into the GDI context. The path can there after be used for 131 // Loads a SkPath into the GDI context. The path can there after be used for
129 // clipping or as a stroke. Returns false if the path failed to be loaded. 132 // clipping or as a stroke. Returns false if the path failed to be loaded.
130 static bool LoadPathToDC(HDC context, const SkPath& path); 133 static bool LoadPathToDC(HDC context, const SkPath& path);
131 134
132 // Loads a SkRegion into the GDI context. 135 // Loads a SkRegion into the GDI context.
133 static void LoadClippingRegionToDC(HDC context, const SkRegion& region, 136 static void LoadClippingRegionToDC(HDC context, const SkRegion& region,
134 const SkMatrix& transformation); 137 const SkMatrix& transformation);
135 #elif defined(OS_MACOSX) 138 #elif defined(OS_MACOSX)
136 // Loads a SkPath into the CG context. The path can there after be used for 139 // Loads a SkPath into the CG context. The path can there after be used for
(...skipping 27 matching lines...) Expand all
164 #elif defined(OS_MACOSX) 167 #elif defined(OS_MACOSX)
165 // Loads the specified Skia transform into the device context 168 // Loads the specified Skia transform into the device context
166 static void LoadTransformToCGContext(CGContextRef context, 169 static void LoadTransformToCGContext(CGContextRef context,
167 const SkMatrix& matrix); 170 const SkMatrix& matrix);
168 #endif 171 #endif
169 }; 172 };
170 173
171 } // namespace skia 174 } // namespace skia
172 175
173 #endif // SKIA_EXT_PLATFORM_DEVICE_H_ 176 #endif // SKIA_EXT_PLATFORM_DEVICE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698