Add Persian (Farsi) langgroup

NEW
Assigned to

Status

()

Core
Internationalization
15 years ago
9 years ago

People

(Reporter: smontagu, Assigned: smontagu)

Tracking

(Blocks: 1 bug)

Trunk
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(Not tracked)

Details

(Assignee)

Description

15 years ago
I have noticed when testing bugs on Farsi web pages that the text is often
rendered in a mixture of fonts, because the default Arabic fonts don't always
include characters that are used in Farsi. It would be helpful to be able to
specify different fonts for Farsi and Arabic.

The ISO-639 code for Farsi is "fa", but I'm not sure whether the correct English
name is "Farsi" or "Persian"
(Assignee)

Comment 1

15 years ago
languageNames.properties currently has "Farsi" so we should probably stay with
that for consistency, even though
http://www.loc.gov/standards/iso639-2/langcodes.html says "Persian". 

Comment 2

15 years ago
The politically correct word to use in an English context is "Persian". That is
the ISO standard name for the language in all of its publications, a requirement
of Iranian Academy for Persian Language and Literature, and appears on the cover
of all bilingual dictionaries published here.

What can we do to fix languageNames.properties?
Summary: Add Farsi (Persian) langgroup → Add Persian (Farsi) langgroup
(Assignee)

Comment 3

15 years ago
The change to languageNames.properties is included in the patch to bug 178491.
(Assignee)

Updated

15 years ago
Blocks: 208295
(Assignee)

Comment 4

15 years ago
See also bug 208295. Both these can be fixed by changes to a few properties files.
(Assignee)

Updated

15 years ago
Depends on: 178491

Comment 5

15 years ago
The patch on bug 178491 has been checked in, but I'm not sure it actually fixes 
the bug as described by the reporter.

Comment 6

15 years ago
It's a bit more complex than a couple of additions in properties files. I know
this because I've recently added Tamil (x-tamil) lang group and enabled the font
selection menu for Devanagari and Tamil on Win32 and Xft-build. It's also
platform/toolkit dependent because the way fonts are selected based on langGroup
are platform/toolkit dependent.   

In case of Persian, it's not clear what has to be done. 'langGroups' in Mozilla
are actually  script tags. Thus, there's no langGroup such as en, fr, it, es,
ru, hi, and ta.  Instead, we have x-western,  x-cyrillic, x-devanagari, and
x-tamil. 

For Latin, we have x-western and x-central-europe, which could be a model ....

Because both Arabic and Persian use Arabic script, in theory we should have
x-arabic (instead of ar) and that should work for all the languages that use
Arabic 'script', but as Simon wrote that it doesn't work in practice. 

Comment 7

14 years ago
> Because both Arabic and Persian use Arabic script, in theory we should have
> x-arabic (instead of ar) and that should work for all the languages that use
> Arabic 'script', but as Simon wrote that it doesn't work in practice. 

Characters for Urdu and Farsi are almost identical and are part of the Arabic
Unicode set.  Direction and all other things remain same.  I hope that can be of
help.

Updated

13 years ago
Blocks: 285718

Comment 8

10 years ago
Ideally pages have a lang="fa" tag that is passed down to layou engine and a suitable Persian font is selected.  That's currently happening with fontconfig on ff3 IIRC, and the per-script font selection dialog has no effect.
QA Contact: amyy → i18n

Comment 9

9 years ago
Simon, is this still an issue?
(Assignee)

Comment 10

9 years ago
Ehsan, I expect you read more Persian sites than I do :) If you think we don't need separate langgroups for Arabic and Persian, feel free to mark this WONTFIX.

Comment 11

9 years ago
(In reply to comment #10)
> Ehsan, I expect you read more Persian sites than I do :) If you think we don't
> need separate langgroups for Arabic and Persian, feel free to mark this
> WONTFIX.

Yeah :-)  The thing is, I'm not exactly sure how to tell whether this is an issue or not.  Currently, on Windows and Linux, a suitable Persian font is chosen by default whether the page includes lang="fa" or not.  But then again I don't have any font installed which has only Arabic and not Persian characters.

Can you guide me to be able to effectively detect whether this is an issue or not?

Comment 12

9 years ago
On Linux at least, proper language tags should be enough.
You need to log in before you can comment on or make changes to this bug.