Login

Tag "­"

Snippet List

Soft hyphenation (­) template filter using PyHyphen

This template filter is meant to insert soft hyphens ([­ entities](http://www.cs.tut.fi/~jkorpela/shy.html)) in text whever it can. For this is relies on a **recent** checkout of the [PyHyphen](http://code.google.com/p/pyhyphen/) interface to the hyphen-2.3 C library, which is also used by Mozilla and OpenOffice.org. It takes two optional parameters: the language to hyphenate in and the minimum word length to consider for hyphenation. If no language is given, the default language from the settings file is used. The second parameter defaults to 5 characters. Usage example: {% load hyphenation %} {{ object.text|hyphenate:"nl-nl,6" }}

  • template
  • filter
  • text
  • hyphenation
  • hyphen
  • soft
  • ­
  • pyhyphen
  • typografy
Read More

1 snippet posted so far.