# Text position different in Firefox

**URL:** <https://phaser.discourse.group/t/text-position-different-in-firefox/6383>\
**Category:** Phaser 3\
**Created:** [May 21, 2020, 12:50am UTC](https://phaser.discourse.group/t/text-position-different-in-firefox/6383 "2020-05-21T00:50:43Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![bradydowling](https://yyz2.discourse-cdn.com/free1/user_avatar/phaser.discourse.group/bradydowling/32/1146_2.png) [@bradydowling](https://phaser.discourse.group/u/bradydowling)\
**Post date:** [May 21, 2020, 12:50am UTC](https://phaser.discourse.group/t/text-position-different-in-firefox/6383/1 "2020-05-21T00:50:43Z")

</div>

For some reason when I add text to my game, the x and y position are both off when I load it in Firefox. I’m using Firefox Developer edition. Loading it in Chrome gives me correct positioning.

Here’s the full code: [https://github.com/bradydowling/phaser-ball-shoot](https://github.com/bradydowling/phaser-ball-shoot)

I’m just adding text like so:

```javascript
    const soundButton = this.add.text(
      this.physics.world.bounds.width - 200,
      40,
      'Sound on',
      {
        fontFamily: 'Monaco, Courier, monospace',
        fontSize: '20px',
        fill: '#fff',
      }
    );

```

Here is the game config I’m using:

```javascript
const config = {
  type: Phaser.AUTO,
  width: 800,
  height: 640,
  scale: {
    autoCenter: Phaser.Scale.CENTER_BOTH,
  },
  scene: [Intro, Gameplay],
  physics: {
    default: 'arcade',
  },
};

```

And here is the simplest scene this is happening in:

```javascript
import Phaser from 'phaser';

export default class Intro extends Phaser.Scene {
  constructor() {
    super('intro');

    this.enterKey;
  }

  preload() {}

  create() {
    this.enterKey = this.input.keyboard.addKey(
      Phaser.Input.Keyboard.KeyCodes.ENTER
    );

    const middleX = this.physics.world.bounds.width / 2;
    const titleText = this.add.text(
      middleX,
      this.physics.world.bounds.height * 0.25,
      'Tip Dunk Shootout',
      {
        fontFamily: 'Monaco, Courier, monospace',
        fontSize: '40px',
        fill: '#fff',
      }
    );
    titleText.setOrigin(0.5);

    const middleY = this.physics.world.bounds.height / 2;
    const welcomeText = this.add.text(
      middleX,
      middleY,
      'Press ENTER to start gameplay',
      {
        fontFamily: 'Monaco, Courier, monospace',
        fontSize: '20px',
        fill: '#fff',
      }
    );
    welcomeText.setOrigin(0.5);
  }

  update() {
    if (this.enterKey.isDown) {
      this.scene.start('gameplay');
    }
  }
}

```

This issue happens with all text I try to add, in all scenes. Am I doing something wrong?

---

<div class="post-metadata">

**Author:** ![samme](https://yyz2.discourse-cdn.com/free1/user_avatar/phaser.discourse.group/samme/32/5275_2.png) [@samme](https://phaser.discourse.group/u/samme)\
**Post date:** [May 21, 2020, 1:38am UTC](https://phaser.discourse.group/t/text-position-different-in-firefox/6383/2 "2020-05-21T01:38:25Z")

</div>

Can you screenshot?

---

<div class="post-metadata">

**Author:** ![bradydowling](https://yyz2.discourse-cdn.com/free1/user_avatar/phaser.discourse.group/bradydowling/32/1146_2.png) [@bradydowling](https://phaser.discourse.group/u/bradydowling)\
**Post date:** [May 21, 2020, 1:51am UTC](https://phaser.discourse.group/t/text-position-different-in-firefox/6383/3 "2020-05-21T01:51:34Z")

</div>

### Chrome

 ![Screen Shot 2020-05-20 at 9.50.21 PM](https://global.discourse-cdn.com/free1/uploads/phaser1/original/2X/c/c1baa44b528e5aa9969ca546032610fcb0267a49.png)

### Firefox

 ![Screen Shot 2020-05-20 at 9.51.05 PM](https://global.discourse-cdn.com/free1/uploads/phaser1/original/2X/4/42b6c0dc0385f325f64f66f4cc9e3baa055e4bba.png)

---

<div class="post-metadata">

**Author:** ![Darko](https://yyz2.discourse-cdn.com/free1/user_avatar/phaser.discourse.group/darko/32/3335_2.png) [@Darko](https://phaser.discourse.group/u/Darko)\
**Post date:** [May 21, 2020, 5:17am UTC](https://phaser.discourse.group/t/text-position-different-in-firefox/6383/4 "2020-05-21T05:17:11Z")

</div>

Hi, I tested your game in my local and both browsers are working fine, no issues with the text.  
Does it happen always?  
Probably your Firefox version or local config?

---

<div class="post-metadata">

**Author:** ![bradydowling](https://yyz2.discourse-cdn.com/free1/user_avatar/phaser.discourse.group/bradydowling/32/1146_2.png) [@bradydowling](https://phaser.discourse.group/u/bradydowling)\
**Post date:** [May 23, 2020, 1:03am UTC](https://phaser.discourse.group/t/text-position-different-in-firefox/6383/5 "2020-05-23T01:03:55Z")

</div>

Hmm, indeed this is only happening in Firefox Developer edition. I tried disabling uBlock origin and privacy/tracking protection to see if that would fix it but it didn’t do the job. **It works fine in normal Firefox 76.**

I’m curious if anyone else has seen this with developer edition but glad it’s working. Thanks for the sanity check!

---

<div class="post-metadata">

**Author:** ![Darko](https://yyz2.discourse-cdn.com/free1/user_avatar/phaser.discourse.group/darko/32/3335_2.png) [@Darko](https://phaser.discourse.group/u/Darko)\
**Post date:** [May 23, 2020, 9:12am UTC](https://phaser.discourse.group/t/text-position-different-in-firefox/6383/6 "2020-05-23T09:12:51Z")

</div>

In a quick search I found this…

> **[Experimental features in Firefox](https://developer.mozilla.org/en-US/docs/Mozilla/Firefox/Experimental_features)**
>
> This page lists features that are in Nightly versions of Firefox along with information on how to activate them, if necessary.

 ![imagen](https://global.discourse-cdn.com/free1/uploads/phaser1/original/2X/9/9ade4370f44c59d071b1ef2b3077004839bce5bc.png)

Probably something experimental with the canvas or related…

---

<div class="post-metadata">

**Author:** ![bradydowling](https://yyz2.discourse-cdn.com/free1/user_avatar/phaser.discourse.group/bradydowling/32/1146_2.png) [@bradydowling](https://phaser.discourse.group/u/bradydowling)\
**Post date:** [May 23, 2020, 4:19pm UTC](https://phaser.discourse.group/t/text-position-different-in-firefox/6383/7 "2020-05-23T16:19:02Z")

</div>

Very good find. I didn’t see anything that’s different from default in the WebGL, Canvas, etc section. For now I’ll just use my vanilla Firefox to run it but I’ll scan through more settings later or maybe just reset all flags. Not sure if there’s a way to see all non-default flags in config so I might have to just eyeball it.
