You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Text.setShadow has two new optional parameters: shadowStroke and shadowFill. These allow you to set if the drop shadow is applied to the Text stroke, the Text fill or both of them (thanks @qdrj phaserjs#1766)
Text.shadowStroke and Text.shadowFill allow you to toggle if the drop shadow is applied to the Text stroke or fill independently.
Copy file name to clipboardExpand all lines: README.md
+2Lines changed: 2 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -268,6 +268,8 @@ Version 2.4 - "Katar" - in dev
268
268
* Phaser.Matrix.copyFrom and copyTo allow you to copy Matrix values from and to other Matrix objects.
269
269
* Phaser.Matrix.setTo allows you to set all properties of a Matrix in a single call.
270
270
* The Phaser.Matrix constructor now allows you to optionally set all Matrix properties on instantiation.
271
+
* Text.setShadow has two new optional parameters: `shadowStroke` and `shadowFill`. These allow you to set if the drop shadow is applied to the Text stroke, the Text fill or both of them (thanks @qdrj#1766)
272
+
* Text.shadowStroke and Text.shadowFill allow you to toggle if the drop shadow is applied to the Text stroke or fill independently.
Copy file name to clipboardExpand all lines: src/gameobjects/Text.js
+85-9Lines changed: 85 additions & 9 deletions
Original file line number
Diff line number
Diff line change
@@ -198,18 +198,24 @@ Phaser.Text.prototype.destroy = function (destroyChildren) {
198
198
* @param {number} [y=0] - The shadowOffsetY value in pixels. This is how far offset vertically the shadow effect will be.
199
199
* @param {string} [color='rgba(0,0,0,1)'] - The color of the shadow, as given in CSS rgba or hex format. Set the alpha component to 0 to disable the shadow.
200
200
* @param {number} [blur=0] - The shadowBlur value. Make the shadow softer by applying a Gaussian blur to it. A number from 0 (no blur) up to approx. 10 (depending on scene).
201
+
* @param {boolean} [shadowStroke=true] - Apply the drop shadow to the Text stroke (if set).
202
+
* @param {boolean} [shadowFill=true] - Apply the drop shadow to the Text fill (if set).
0 commit comments