Bug 840695. Make aAntialiasMode default to AA_DEFAULT, because, well, it's the default. r=bas

--HG--
extra : rebase_source : f22329337aa120573efc13fa6ac0bb111ff0dba2
This commit is contained in:
Robert O'Callahan 2013-02-25 12:01:16 +13:00
parent 9d307d2ea1
commit 94dcb604c5
4 changed files with 29 additions and 1 deletions

View File

@ -64,7 +64,7 @@ struct NativeFont {
struct DrawOptions {
DrawOptions(Float aAlpha = 1.0f,
CompositionOp aCompositionOp = OP_OVER,
AntialiasMode aAntialiasMode = AA_GRAY,
AntialiasMode aAntialiasMode = AA_DEFAULT,
Snapping aSnapping = SNAP_NONE)
: mAlpha(aAlpha)
, mCompositionOp(aCompositionOp)

View File

@ -47,6 +47,8 @@ fails-if(B2G) != text-font-lang.html text-font-lang-notref.html
== text-measure.html text-measure-ref.html
random-if(!d2d) != text-subpixel-1.html text-subpixel-1-ref.html
== strokeText-path.html strokeText-path-ref.html
# check that emoji character renders as something non-blank (for Apple Color Emoji font, bug 715798)

View File

@ -0,0 +1,12 @@
<!DOCTYPE HTML>
<html>
<body style="background:white">
<canvas id="c" width="500" height="500"></canvas>
<script>
var ctx = c.getContext('2d');
ctx.fillStyle = "black";
ctx.font = "50px sans-serif";
ctx.fillText("Hello", 200, 200);
</script>
</body>
</html>

View File

@ -0,0 +1,14 @@
<!DOCTYPE HTML>
<html>
<body>
<canvas moz-opaque id="c" width="500" height="500"></canvas>
<script>
var ctx = c.getContext('2d');
ctx.fillStyle = "white";
ctx.fillRect(0, 0, 500, 500);
ctx.fillStyle = "black";
ctx.font = "50px sans-serif";
ctx.fillText("Hello", 200, 200);
</script>
</body>
</html>