WordPress.org

Make WordPress Core

Opened 2 years ago

Closed 2 years ago

#19962 closed defect (bug) (fixed)

Make default spellchecker languages menu translatable

Reported by: SergeyBiryukov Owned by: nacin
Milestone: 3.4 Priority: normal
Severity: normal Version:
Component: I18N Keywords: has-patch
Focuses: Cc:

Description

Currently translators use mce_spellchecker_languages filter to localize spellchecker menu.

We should make the default string translatable so that it could be done without any PHP code.

Attachments (1)

19962.patch (900 bytes) - added by SergeyBiryukov 2 years ago.

Download all attachments as: .zip

Change History (5)

SergeyBiryukov2 years ago

comment:1 follow-ups: nacin2 years ago

mce_spellchecker_languages is such a weird filter. It ideally should operate on an array.

Should translators be only adding strings, or replacing them? I imagine they may wish to set the default language as well?

Perhaps we can introduce some new filters that makes this suck less, and provide a better interface for translators as well.

comment:2 in reply to: ↑ 1 SergeyBiryukov2 years ago

Replying to nacin:

Should translators be only adding strings, or replacing them? I imagine they may wish to set the default language as well?

It's currently possible to add or remove languages from the string, as well as set the default language (by adding plus sign in front of its name).

comment:3 in reply to: ↑ 1 azaozz2 years ago

Replying to nacin:

mce_spellchecker_languages is such a weird filter...

Yes, unlikely the rest of the TinyMCE related filters it only exposes the actual option there. As far as I remember the idea was that the list of available languages in the editor would be replaced for different locales, not translated.

On the other hand it's been a long standing questions whether to keep this TinyMCE plugin in core at all. It adds quite a bit of PHP code duplication some of our API, uses Google translate by default which may go away one day, and is not particularly useful in all browsers except IE as they have built-in spellcheckers that are configurable, etc.

It seems IE10 will include a spellchecker, so perhaps we should reevaluate keeping that MCE plugin in core. Seems better if it was an external WP plugin that would add it.

Version 0, edited 2 years ago by azaozz (next)

comment:4 nacin2 years ago

  • Owner set to nacin
  • Resolution set to fixed
  • Status changed from new to closed

In [19833]:

Translate TinyMCE's spellchecker languages. props SergeyBiryukov, fixes #19962.

Note: See TracTickets for help on using tickets.