/typography

Beautiful typesetting in MODX without the work.

Primary LanguagePHPMIT LicenseMIT

Typography

Proper typesetting can help increase reader understanding, because text flows better and is easier to follow. Typography helps with this by applying the following transformations to your text which makes it “properly typeset”:

  • Straight quotes ( " and ' ) into “curly” quote HTML entities
  • Backticks-style quotes (``like this'') into “curly” quote HTML entities
  • Dashes (“--” and “---”) into en- and em-dash HTML entities
  • Three consecutive dots (“...”) into an ellipsis HTML entity
  • (c), (r), (tm) and (deg) into ©, ®, ™ and ° HTML entities

Installation

Install this MODX output filter via MODX Package Management. Get the latest dev version here or use Git Package Management to make it even easier.

Example Usage

Add typography as an output filter to any MODX field, including Template Variables:

    [[*content:typography]]

Additional Information

To learn more, including special notes on handling leading single-quotes, visit the project website: http://rthrash.github.io/typography/

File bugs and feature requests at GitHub: https://github.com/rthrash/typography/issues

Copyright 2015 Ryan Thrash. Released under the MIT license.