aboutsummaryrefslogtreecommitdiffhomepage
path: root/include/core
diff options
context:
space:
mode:
Diffstat (limited to 'include/core')
-rw-r--r--include/core/SkDevice.h15
1 files changed, 15 insertions, 0 deletions
diff --git a/include/core/SkDevice.h b/include/core/SkDevice.h
index 55d823b747..7332ba7b4e 100644
--- a/include/core/SkDevice.h
+++ b/include/core/SkDevice.h
@@ -214,6 +214,21 @@ public:
SkRefDict& getRefDict() { return fRefDict; }
+ struct TextFlags {
+ uint32_t fFlags; // SkPaint::getFlags()
+ SkPaint::Hinting fHinting;
+ };
+
+ /**
+ * Device may filter the text flags for drawing text here. If it wants to
+ * make a change to the specified values, it should write them into the
+ * textflags parameter (output) and return true. If the paint is fine as
+ * is, then ignore the textflags parameter and return false.
+ *
+ * The baseclass SkDevice filters based on its depth and blitters.
+ */
+ virtual bool filterTextFlags(const SkPaint& paint, TextFlags*);
+
protected:
/** Update as needed the pixel value in the bitmap, so that the caller can access
the pixels directly. Note: only the pixels field should be altered. The config/width/height/rowbytes