WordPress.org

Making WordPress.org

Opened 15 months ago

Last modified 2 weeks ago

#3933 reopened enhancement

Optimize fonts for Persian language

Reported by: parsmizban Owned by:
Milestone: Priority: high
Component: General Keywords: has-screenshots has-patch 2nd-opinion
Cc:

Description

Hi,
We need some font optimization for Persian language on O2 theme and other wp.org themes,
How we can coordinate it?

I think we can add a font family for every language (if need) in CSS files, like this:

html[lang="fa-IR"] body{
    font-family: Tahoma, Arial, Arial, sans-serif;
}

Although we have a specific web font which we can provide to include it in the theme
if it is possible for meta team to add such things
Waiting for a response
Thank you for any help

Attachments (2)

Font.zip (289.8 KB) - added by dedidata 7 months ago.
Font Pack
wp-iransans-font.jpg (85.4 KB) - added by dedidata 7 months ago.
screenshot

Download all attachments as: .zip

Change History (27)

#1 @parsmizban
15 months ago

The license for the IRANSans font is allowed for whole wordpress.org site by fontiran.com
IranSans font is a suitable font for Persian

Last edited 4 weeks ago by parsmizban (previous) (diff)

#2 @dd32
14 months ago

Hey @parsmizban,

I think I'd prefer us to simply copy what WordPress itself does, which is defined here:
https://core.trac.wordpress.org/browser/trunk/src/wp-admin/css/l10n.css

in short, that would result in:

body.rtl {
     font-family: Tahoma, Arial, sans-serif;
}
html[lang="he-IL"] body.rtl {
     font-family: Arial, sans-serif;
}

Would that be enough to make the fonts more legible?
It looks like it'll need to be added to quite a few of the w.org themes, as there isn't any shared stylesheets for everything.

#3 @parsmizban
14 months ago

@dd32

Hi,

Yes, It works too, and it will fix that
I think my solution may be is better, Because other RTL languages may be don't like Tahoma, Arial
as their default
But:

html[lang="fa-IR"] body.rtl {
     font-family: Tahoma, Arial, Arial, sans-serif;
}

is same as :

html[lang="fa-IR"] body {
     font-family: Tahoma, Arial, Arial, sans-serif;
}

Because Persian language should be in RTL always, But you can check for RTL again too
It's ok

Last edited 14 months ago by parsmizban (previous) (diff)

#4 @parsmizban
14 months ago

Last edited 4 weeks ago by parsmizban (previous) (diff)

#5 @dedidata
7 months ago

@dd32
Hi,
Could you please use this font for Persian language on O2 theme?
The license for the font is allowed for whole wordpress.org site by fontiran.com
IranSans font is a suitable font for Persian
I attached the font pack, license and a shot

@font-face {
	font-family: IRANSans;
	font-style: normal;
	font-weight: normal;
	src: url('../fonts/IRANSansWeb.eot');
	src: url('../fonts/IRANSansWeb.eot?#iefix') format('embedded-opentype'),  /* IE6-8 */
		url('../fonts/IRANSansWeb.woff2') format('woff2'),  /* FF39+,Chrome36+, Opera24+*/
		url('../fonts/IRANSansWeb.woff') format('woff'),  /* FF3.6+, IE9, Chrome6+, Saf5.1+*/
		url('../fonts/IRANSansWeb.ttf') format('truetype');
}
@font-face {
	font-family: IRANSans;
	font-style: normal;
	font-weight: bold;
	src: url('../fonts/IRANSansWeb_Bold.eot');
	src: url('../fonts/IRANSansWeb_Bold.eot?#iefix') format('embedded-opentype'),  /* IE6-8 */
		url('../fonts/IRANSansWeb_Bold.woff2') format('woff2'),  /* FF39+,Chrome36+, Opera24+*/
		url('../fonts/IRANSansWeb_Bold.woff') format('woff'),  /* FF3.6+, IE9, Chrome6+, Saf5.1+*/
		url('../fonts/IRANSansWeb_Bold.ttf') format('truetype');
}
html[lang="fa-IR"] body {
	font-family: IRANSans, Tahoma, Arial, sans-serif !important;
}

CC @tobifjellner

Last edited 7 months ago by dedidata (previous) (diff)

@dedidata
7 months ago

Font Pack

@dedidata
7 months ago

screenshot

#6 @dedidata
7 months ago

  • Keywords has-patch has-screenshots added
  • Priority changed from normal to high
  • Type changed from defect to enhancement

#7 @dd32
7 months ago

  • Keywords needs-patch added; has-patch removed

I'm not going to add any custom font stacks for languages, although I'll happily update it to match what's inside WordPress itself if it's not already the same.

That's the same result as as I said above in comment #2. If you'd like the font stack to be better, please open a discussion with WordPress core directly to get better fonts in there for everyone.

If someone can go through the existing sites and locate which sites need their font stacks updated to match WordPress, that's be greatly appreciated.

Last edited 7 months ago by dd32 (previous) (diff)

#8 follow-up: @dedidata
7 months ago

@dd32
All advanced Persian sites (Powered by WordPress) don't use default fonts
All of them install a plugin to change the fonts
So think the wp.org itself has a bad font for Persian
So when everybody visits the fa.wp.org, they don't like that and they will go to other advanced web sites, and So we lose visitors
There are many other web sites out there which are providing things
As we can't install our desire plugins on wp.org, So how we can change the font on wp.org?
You mean we should change the default font on the core of WordPress in the first step?
It is a thing related to themes
Typography for default preinstalled English fonts (sans serif, Arial, ...) is much much better than Persian
That means which an English web site using preinstalled fonts will be advanced in look and feel
But it is not true for Persian using default preinstalled fonts

Last edited 7 months ago by dedidata (previous) (diff)

#9 in reply to: ↑ 8 @dd32
7 months ago

Replying to dedidata:

All advanced Persian sites (Powered by WordPress) don't use default fonts
All of them install a plugin to change the fonts

Like I said, get better fonts in WordPress core, focus on not needing that plugin.
I'm not enabling a plugin unless there's been a good faith effort on improving it and I can see there's a significant benefit.

This ticket was mentioned in Slack in #meta by dedidata. View the logs.


7 months ago

#11 follow-up: @SergeyBiryukov
7 months ago

Let's start with implementing comment:2, seems like that would be an improvement over the current font stack.

WordPress core historically uses Tahoma for all RTL languages except Hebrew, which uses Arial.

#12 follow-up: @dedidata
7 months ago

@SergeyBiryukov
For Persian, Tahoma is suitable for normal and small sizes, And Arial Bold is suitable for headings
But the combination of these 2 fonts will not perfect totally for Persian
The typography of Tahoma and Arial fonts may be good for English or some other languages, but not enough for Persian
Using those fonts, the site will look like an old site in Persian,
That's the reason I mentioned to include IranSans font, I granted a license for whole wp.org
I think this is related to the theme to choose its font, Not related to WordPress core
Many advanced Persian themes and sites use IranSans font for their theme
I don't see any popular Persian sites which use Tahoma or Arial as their font
So we have a theme on WP.org web site which it has its rules, We can define its rules
So we can decide to have an old feel and looking site for Persian, Or an advanced!
I really don't like to lose our visitors by displaying an old looking site

#13 @man4toman
6 weeks ago

I want to continue this ticket because we start to post news and articles in fa.w.org and fa.w.org/team and font change is important to us.

In wporg-main and team section theme(O2), default font for rtl is Open Sans,sans-serif and it's not suitable for Persian language(because of bad readability).

I think @dd32 solution in comment:2 is good for now. We prefer Tahoma instead current fonts.

If we don't want to change default font for other rtl languages, it can be enough for now:

html[lang="fa-IR"] body.rtl { {
     font-family: Tahoma, Arial, sans-serif;
}

CC: @parsmizban

#14 @man4toman
6 weeks ago

@dd32 please let me know if I must create new topic in Core.
Thanks

#15 @mahdiebrahimii
4 weeks ago

We need a better font for Persian language of WordPress.

#16 @CG-TEAM
4 weeks ago

Hi,

We need a better font for Persian language of WordPress like tahoma. Recent font is not good for Persian native.

Thank you.

#17 @vadatiertebat
4 weeks ago

Hi
We need a better font for Persian language of WordPress. one of the beautiful font is IRANSans in Persian language.

Thanks...

#18 @mashhadcode
4 weeks ago

  • Resolution set to invalid
  • Status changed from new to closed

Hi, there is no beauty in Persian WordPress font.
We need a better font for Persian language of WordPress.
Thanks

#19 in reply to: ↑ description @rozairan
4 weeks ago

oh please try better font
Tacoma font will be great

#20 @mahdisarani
4 weeks ago

Hi, We need a better font for Persian language of WordPress.
Thank you

#21 @parsmizban
4 weeks ago

  • Keywords has-patch added; needs-patch removed
  • Resolution invalid deleted
  • Status changed from closed to reopened

#22 @ketabchi
4 weeks ago

Hi,
We need a better font for Persian language of WordPress like tahoma. Recent font is not good for Persian native.
Thank you

#23 in reply to: ↑ 12 @parsmizban
4 weeks ago

  • Keywords 2nd-opinion added

Replying to dedidata:

@SergeyBiryukov
For Persian, Tahoma is suitable for normal and small sizes, And Arial Bold is suitable for headings
But the combination of these 2 fonts will not perfect totally for Persian
The typography of Tahoma and Arial fonts may be good for English or some other languages, but not enough for Persian
Using those fonts, the site will look like an old site in Persian,
That's the reason I mentioned to include IranSans font, I granted a license for whole wp.org
I think this is related to the theme to choose its font, Not related to WordPress core
Many advanced Persian themes and sites use IranSans font for their theme
I don't see any popular Persian sites which use Tahoma or Arial as their font
So we have a theme on WP.org web site which it has its rules, We can define its rules
So we can decide to have an old feel and looking site for Persian, Or an advanced!
I really don't like to lose our visitors by displaying an old looking site

#24 @pash2048
4 weeks ago

We need a better font for Persian language of WordPress

#26 in reply to: ↑ 11 @msn6060
4 weeks ago

Replying to SergeyBiryukov:

Let's start with implementing comment:2, seems like that would be an improvement over the current font stack.

WordPress core historically uses Tahoma for all RTL languages except Hebrew, which uses Arial.

Hi,
Only FYI the Tahoma and Arial fonts are very basic fonts for Persian language.
They used many years ago in Persian web ecosystem.

At the moment, they are not popular to using these fonts (they are like user-agent font). Even they have negative effect in UX for Persian users. Persian users do not like them at all.

In these several years ago, Persian web ecosystem, have prepared many beautiful and also readable fonts for Persian users. They are based on UX for our Persian community and are suitable for users.

You can see many of famous websites in Persian web ecosystem that they do not use from old fonts at all. (this is not a fit sample but you can think Gutenberg vs classic editor :)))

These old fonts and similar web fonts do not have good experience for Persian user, so we need to have suitable fonts and also more readable fonts.

I hope you'll get my point.

BR

Note: See TracTickets for help on using tickets.