wp-Typography

Описание

Улучшьте web-типографику вашего сайта, используя:

  • Переносы – словари переносов для более 70 языков

  • настройки обработки пробелов, в том числе:

    • контроль висячих знаков
    • удержание размерностей с величинами
    • перенос длинных URL и адресов E-mail
  • умную автозамену, в том числе обработку:

    • кавычек
    • тире
    • многоточий
    • символов обслуживания
    • математических знаков
    • дробей
    • наращений
  • CSS-классов для оформления:

    • амперсандов
    • аббревиатур
    • чисел
    • начальных кавычек

Скриншоты

  • wp-Typography "General" settings page.
  • wp-Typography "Hyphenation" settings page.
  • wp-Typography "Intelligent Character Replacement" settings page.
  • wp-Typography "Space Control" settings page.
  • wp-Typography "Add CSS Hooks" settings page.

Установка

Requirements

Требования для использования wp-Typography:

  • установленный на сервере интерпретатор PHP 5.4.0 и новее
  • интерпретатор PHP 5.4.0+ должен включать расширение mbstring (есть в большинстве установок)
  • текст должен быть закодирован в UTF-8

Часто задаваемые вопросы

FAQs are maintained on the wp-Typography website.

Three questions come up so frequently, we will republish their answers here:

Will this plu­gin slow my page load­ing times?

Maybe. For best performance, use a persistent object cache plugin like WP Redis.

This plugin breaks post title links. What gives?

More likely than not, your WordPress theme is using an improper function to set the title attribute of your heading’s link. It is probably using the the_title() function, which delivers the post title after filtering. It should be using the_title_attribute() which delivers the post title before filtering. Change out this function throughout your theme when it is used inside of an HTML tag, and the problem should go away.

If you are uncomfortable editing your theme’s code, you may alternatively go to the wp-Typography settings page in your admin panel and add h1 and h2 to the «Do not process the content of these HTML elements:» field. This will disable typographic processing within improperly designed page title links and page titles.

What are the privacy implications of using the plugin?

wp-Typography does not store, transmit or otherwise process personal data as such. It does cache the content of the site’s posts. If necessary, you can clear this cache from the plugin’s settings page.

Remember, many more FAQs are are addressed the wp-Typography website.

Отзывы

Январь 13, 2019
This plugin helped me a lot. It is easy to use & effective and also provides several features. Thank you. Manfred
Январь 8, 2019
I was afraid of the slowdown mentioned in this plugin FAQ. And not tech-savvy enough to add a cache plugin to avoid this slowdown. So I tried wp-Typography anyway and didn't notice our website being slower than before. It just reads better now. 🙂 Thank you very much!
Июнь 2, 2019
I really like how the extension and all its features work. It works accurate and the processed content looks so nice. I would want to find such plugin (extension) also for MediaWiki 🙂 Edit: Based on the advice, provided below by @pputzer, I've managed to create an alpha version of such extension for MediaWiki, which is available at https://github.com/pa4080/MWTypography. All ideas and contributions are welcome. For now, I just want to say thank you once again!
Октябрь 18, 2018
I did not know I needed it, but after trying this plugin, my posts look much nicer. Had problems with the post title of a widget, but was quickly resolved by the FAQ. Thanks!
Посмотреть все 45 отзывов

Участники и разработчики

«wp-Typography» — проект с открытым исходным кодом. В развитие плагина внесли свой вклад следующие участники:

Участники

«wp-Typography» переведён на 4 языка. Благодарим переводчиков за их работу.

Перевести «wp-Typography» на ваш язык.

Заинтересованы в разработке?

Посмотрите код, проверьте SVN репозиторий, или подпишитесь на журнал разработки по RSS.

Журнал изменений

5.5.4 — March 11, 2019

  • Bugfix: Automatic language detection now also works for locales without a country code (e.g. fi).
  • Bugfix: No PHP notices are shown for missing options anymore.

5.5.3 — February 2, 2019

  • Bugfix: Custom styles containing quote characters are now output correctly.

5.5.2 — January 29, 2019

  • Bugfix: To prevent common false positives for single-letter Roman ordinals (especially in French and Dutch), Roman numeral matching now has to be explicitly enabled in the settings. In addition, only I, V, and X are accepted as single-letter Roman numbers.

5.5.1 — January 27, 2019

  • Bugfix: Parts of hyphenated words should not be detected as Roman numerals anymore.
  • Bugfix: The Unicode hyphen character (‐) is recognized as a valid word combiner.

5.5.0 — January 27, 2019

  • Feature: French (1ère) and «Latin» (1o) ordinal numbers are now supported by the smart ordinals feature (also with Roman numerals, e.g. XIXème).
  • Feature: The list of smart quotes exceptions (words beginning with apostrophes) can now be customized.
  • Feature: HTML5 parser performance hugely improved (up to 11× faster).
  • Bugfix: Output filtering is now suspended during WP-CLI commands.
  • Bugfix: Unit spacing is now properly applied to monetary symbols ($, €, etc.).
  • Bugfix: Certain HTML entities (e.g. &) were accidentally dropped in rare cases.
  • Bugfix: Comply with the new WordPress Coding Standards 2.0.

5.4.2 — September 30, 2018

  • Bugfix: Advanced Custom Fields 5 now uses the correct default values for text, textarea and wysiwyg field types.

5.4.1 — September 15, 2018

  • Bugfix: Comply with new WordPress Coding Standards 1.1.
  • Bugfix: Work around GlotPress issue preventing language pack generation.

5.4.0 — September 9, 2018

  • Feature: New hooks for implementing your own typography fixes:
    • typo_custom_characters_node_fix,
    • typo_custom_spacing_pre_node_fix,
    • typo_custom_spacing_post_node_fix,
    • typo_custom_html_insertion_node_fix,
    • typo_custom_mixed_words_token_fix,
    • typo_custom_compound_words_token_fix,
    • typo_custom_words_token_fix,
    • typo_custom_other_token_fix.
  • Feature: A privacy statement has been added on WordPress 4.9.6+.
  • Feature: A narrow no-break space is now inserted between adjacent primary and secondary quotes.
  • Change: The Unicode hyphen character () is now used instead of the hyphen-minus (-).
  • Change: Significantly updated hyphenation patterns for:
    • Bulgarian,
    • German,
    • German (Traditional),
    • German (Swiss Traditional),
    • Latin (Liturgical), and
    • Thai.
  • Bugfix: The comma is now recognized as a decimal separator (e.g. 1,5, in addition to 1.5).
  • Bugfix: Smart maths properly handles 2-digit years in dates.
  • Bugfix: Smart diacritics won’t try to «correct» the spelling of Uber anymore.
  • Bugfix: French punctuation is now correctly applied to quotes preceeded or followed by round and square brackets.
  • Bugfix: Smart quotes replacement could result in invalid unicode sequences in rare cases.