Αναζήτηση στην υποστήριξη

Προσοχή στις απάτες! Δεν θα σας ζητήσουμε ποτέ να καλέσετε ή να στείλετε μήνυμα σε κάποιον αριθμό τηλεφώνου ή να μοιραστείτε προσωπικά δεδομένα. Αναφέρετε τυχόν ύποπτη δραστηριότητα μέσω της επιλογής «Αναφορά κατάχρησης».

Learn More

Some local plaintext files in latin encoding rendered with japanese font settings

  • Καμία απάντηση
  • 0 έχουν αυτό το πρόβλημα
  • 47 προβολές
more options

A certain set of plaintext files are rendered in a weird way when opened in Firefox.

Some plaintext files are rendered "MS Gothic", which is the default monospace font for plaintext files in Japanese encoding. (Also, if I change font.name-list.monospace.ja to "monospace", the font changes).

However, the files are not in Japanese encoding, they do not contain a single character in Japanese encoding. Since the files are local, they have no HTTP headers to determine the encoding, so Firefox must have guessed the encoding somehow. How can I stop firefox from detecting those files as Japanese while they are not?

Also, I noticed that this issue happens only with long files. The shorter a file, the less likely it is that Firefox renders the file as if it had Japanese encoding.

Since I cannot reproduce the issue with smaller files and the files contain confidential information, I am unable to provide a minimal reproducer.

As a workaround, I could change font.name-list.monospace.ja, but this would change (potentially break) rendering of Japanese websites.

I'm using Firefox 124.0.1 on Windows 10, although this issue has been present for at least some months (at least 4 firefox releases).

The screenshot shows an excerpt where the text "C:\Temp\2024-" is partially rendered with Japanese glyphs and fully rendered with "MS Gothic" font which is hard to read with ASCII characters.

PS: I [censored] some of the information in the "Troubleshooting Information" field below.

A certain set of plaintext files are rendered in a weird way when opened in Firefox. Some plaintext files are rendered "MS Gothic", which is the default monospace font for plaintext files in Japanese encoding. (Also, if I change font.name-list.monospace.ja to "monospace", the font changes). However, the files are not in Japanese encoding, they do not contain a single character in Japanese encoding. Since the files are local, they have no HTTP headers to determine the encoding, so Firefox must have guessed the encoding somehow. How can I stop firefox from detecting those files as Japanese while they are not? Also, I noticed that this issue happens only with long files. The shorter a file, the less likely it is that Firefox renders the file as if it had Japanese encoding. Since I cannot reproduce the issue with smaller files and the files contain confidential information, I am unable to provide a minimal reproducer. As a workaround, I could change font.name-list.monospace.ja, but this would change (potentially break) rendering of Japanese websites. I'm using Firefox 124.0.1 on Windows 10, although this issue has been present for at least some months (at least 4 firefox releases). The screenshot shows an excerpt where the text "C:\Temp\2024-" is partially rendered with Japanese glyphs and fully rendered with "MS Gothic" font which is hard to read with ASCII characters. PS: I [censored] some of the information in the "Troubleshooting Information" field below.
Συνημμένα στιγμιότυπα

Πρέπει να συνδεθείτε στον λογαριασμό σας για να απαντήσετε σε δημοσιεύσεις. Ξεκινήστε μια νέα ερώτηση εάν δεν διαθέτετε ακόμα λογαριασμό.