The smallcaps package

[Tags:bsd3, library, program]

smallcaps is a pre-processor library for LaTeX files. The library comes with an executable that makes most functionality accessible through a command line interface. The pre-processor formats sequences of uppercase letters with TeX's \small macro or whatever you configure. Uppercase letters at the beginning of sentences are not formatted. Other formatting conditions can be configured by the user.

The executable can be configured through its command line arguments as well as through TeX comments. In the default configuration, lesscase does not change the content of any macro argument or environment (different from document). More and less restrictive configuration profiles can be activated and adapted. Configurations can be stored and restored at any time, even while processing the input file.

Text.SmallCaps
exports the main program as library.
Text.SmallCaps.Config
specifies the default configuration values for Text.SmallCaps.
Text.SmallCaps.TeXParser
parses Text to a TeXElement token stream.
Text.SmallCaps.TeXLaTeXParser
parses a TeXElement token stream and produces a LaTeXElement token stream.
Text.SmallCaps.DocumentParser
replaces uppercase letters in LaTeXElement token streams.

A simple program can be defined as

import Data.Default           ( def )
import Text.SmallCaps         ( smallcaps )
import Text.SmallCaps.Config  ( defaultProfile )
main = smallcaps def defaultProfile

This is virtually all the code that is necessary to implement the executable lesscase. Have a look in the source of the executable twocase which only formats sequences of two or more uppercase letters. It is a good reference for understanding the API changes that took place between the revisions 0.5 and 0.6.

Properties

Versions 0.3.0.0, 0.4, 0.4.0.1, 0.4.1, 0.4.1.1, 0.4.1.2, 0.4.1.3, 0.5.0.0, 0.5.1.0, 0.5.1.1, 0.6.0.0, 0.6.0.1, 0.6.0.2, 0.6.0.3
Dependencies attoparsec (>=0.10 && <0.14), base (>=4.8 && <4.10), containers (==0.5.*), data-default (>=0.5 && <0.8), directory (==1.2.*), filepath (>=1.3 && <1.5), parsec (==3.1.*), smallcaps (==0.6.*), text (>=0.11 && <1.3), transformers (>=0.3 && <0.6) [details]
License BSD3
Author Stefan Berthold
Maintainer stefan.berthold@gmx.net
Stability Unknown
Category Text, LaTeX
Bug tracker https://github.com/ZjMNZHgG5jMXw/smallcaps/issues
Source repository head: git clone https://github.com/ZjMNZHgG5jMXw/smallcaps.git
Uploaded Fri Jun 24 21:41:46 UTC 2016 by StefanBerthold
Distributions LTSHaskell:0.6.0.3, NixOS:0.6.0.2
Downloads 1788 total (32 in the last 30 days)
Votes
0 []
Status Docs available [build log]
Last success reported on 2016-06-24 [all 1 reports]

Modules

[Index]

Downloads

Maintainer's Corner

For package maintainers and hackage trustees