aboutsummaryrefslogtreecommitdiffhomepage
path: root/include
diff options
context:
space:
mode:
authorGravatar reed@google.com <reed@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2011-11-21 16:42:10 +0000
committerGravatar reed@google.com <reed@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2011-11-21 16:42:10 +0000
commit8426058dee0faf75a18b81cfcde47ee8ab8c31d9 (patch)
tree21fe6d20a825a49e93e3f0ea388761a324a46971 /include
parent8ef3fd0ca6595adb9a8172c84dc0c55c9c096e09 (diff)
ensure we never change the text_encoding of the master paint, since it is used
to interpret the text/length parameters in draw[Pos]Text. git-svn-id: http://skia.googlecode.com/svn/trunk@2724 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'include')
-rw-r--r--include/effects/SkLayerDrawLooper.h13
1 files changed, 11 insertions, 2 deletions
diff --git a/include/effects/SkLayerDrawLooper.h b/include/effects/SkLayerDrawLooper.h
index 3440186e17..b9b080232d 100644
--- a/include/effects/SkLayerDrawLooper.h
+++ b/include/effects/SkLayerDrawLooper.h
@@ -22,7 +22,8 @@ public:
* Bits specifies which aspects of the layer's paint should replace the
* corresponding aspects on the draw's paint.
* kEntirePaint_Bits means use the layer's paint completely.
- * 0 means ignore the layer's paint.
+ * 0 means ignore the layer's paint... except that LayerInfo's fFlagsMask
+ * and fColorMode are always applied.
*/
enum Bits {
kStyle_Bit = 1 << 0, //!< use this layer's Style/stroke settings
@@ -33,7 +34,15 @@ public:
kColorFilter_Bit = 1 << 5, //!< use this layer's colorfilter
kXfermode_Bit = 1 << 6, //!< use this layer's xfermode
- kEntirePaint_Bits = -1, //!< use this layer's paint entirely
+ /**
+ * Use the layer's paint entirely, with these exceptions:
+ * - We never override the draw's paint's text_encoding, since that is
+ * used to interpret the text/len parameters in draw[Pos]Text.
+ * - Flags and Color are always computed using the LayerInfo's
+ * fFlagsMask and fColorMode.
+ */
+ kEntirePaint_Bits = -1,
+
};
typedef int32_t BitFlags;