Skip to content

Text truncated when setLetterSpacing is used #6915

@monteiz

Description

@monteiz

Version

  • Phaser Version: 3.85.2
  • Operating system: MacOS
  • Browser: Chrome and Safari show the same issue

Description

The "Y" of "PLAY" is truncated when setLetterSpacing is used.

Example Test Code

class Example extends Phaser.Scene
{
    create ()
    {
        this.add.text(20, 20, 'PLAY',{
				fontSize: "10rem",
				fontFamily: "Roboto Condensed, sans-serif-condensed",
				fontStyle: "bold",
			}).setColor('#ffffff');

        this.add.text(20, 200, 'PLAY',{
				fontSize: "10rem",
				fontFamily: "Roboto Condensed, sans-serif-condensed",
				fontStyle: "bold",
			}).setColor('#ffffff').setLetterSpacing(70);
    }
}

const config = {
    type: Phaser.AUTO,
    width: 800,
    height: 600,
    parent: 'phaser-example',
    scene: Example
};

const game = new Phaser.Game(config);

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions