Describe - Tilde inversions
Tildes, aka “tilde inversions” or simply “inversions” are an alternative way to add data to an entry, without using decorators, as decorators are not convenient for long texts. To write a tilde inversion, simply put a tilde symbol ~ in front of the entry that you wish to invert. The inverted entry is no longer part of the production, but refers solely to the head of the production now.
What happens behind the scenes is that the inversion is added as a decorator to the item, with the tag of the inversion being the name of the decorator. (However, this is not fully implemented yet, and the tilde inversions are added as items at the moment, as a hack around. The feature will be implemented in the next releases)
The example below illustrate how to use inversions. In the first example, we use inversions to add shorter versions to some items in a list, including the head. In the second example, we achieve the same with decorators:
Example (tilde inversions):
Harry Potter books ->
~ HP books <shorter>,
Harry Potter and the Sorcerer's Stone - J. K. Rowling ->
~ Harry Potter & The Sorcerer's Stone <shorter>,
~ The Sorcerer's Stone <shorter>;
Harry Potter and the Chamber of Secrets - J. K. Rowling ->
~Harry Potter The Chamber of Secrets <shorter>,
~Chamber of secrets <shorter>;
;
Example (decorators):
Harry Potter books
{shorter| HP books} ->
Harry Potter and the Sorcerer's Stone - J. K. Rowling
{shorter|Harry Potter & The Sorcerer's Stone}
{shorter|The Sorcerer's Stone},
Harry Potter and the Chamber of Secrets - J. K. Rowling
{shorter | Harry Potter The Chamber of Secrets}
{shorter | Chamber of secrets};