| 1 |
# The LaTeX package `contract` |
| 2 |
|
| 3 |
Copyright © 2007–2026 Markus Kohm |
| 4 |
|
| 5 |
Release: 2026-04-23 v0.92 |
| 6 |
|
| 7 |
License: LPPL 1.3c |
| 8 |
|
| 9 |
KOMA presents the KOMA-Script spin-off `contract`. Package `contract` provides |
| 10 |
environments for legal contracts, sections, paragraphs and similar. It is the |
| 11 |
official successor to the former KOMA-Script package `scrjura`. |
| 12 |
|
| 13 |
------------------------------------------------------------------------------ |
| 14 |
|
| 15 |
The project is currently hosted and managed on |
| 16 |
[Codeberg](https://codeberg.org/komascript/latex-contract). For safety |
| 17 |
reasons, the repository will continue to be mirrored on |
| 18 |
[GitHub](https://github.com/komascript/latex-contract) for some time. However, |
| 19 |
error reports and push requests will only be acknowledged on |
| 20 |
[Codeberg](https://codeberg.org/komascript/latex-contract). |
| 21 |
|
| 22 |
------------------------------------------------------------------------------ |
| 23 |
|
| 24 |
This work may be distributed and/or modified under the conditions of |
| 25 |
the LaTeX Project Public License, version 1.3c of the license. |
| 26 |
The latest version of this license is in |
| 27 |
http://www.latex-project.org/lppl.txt |
| 28 |
and version 1.3c or later is part of all distributions of LaTeX |
| 29 |
version 2005/12/01 or later. |
| 30 |
|
| 31 |
The Current Maintainer and author of this work is Markus Kohm. |
| 32 |
|
| 33 |
This work consists of the files listed in MANIFEST.md. |
| 34 |
|
| 35 |
------------------------------------------------------------------------------ |
| 36 |
|
| 37 |
# Abstract |
| 38 |
|
| 39 |
For several years |
| 40 |
[KOMA-Script](https://www.sourceforge.net/project/koma-script) provides |
| 41 |
package `scrjura`. The package was developed at the request of and in |
| 42 |
co-operation with a German lawyer. In 2024, the package was separated from |
| 43 |
KOMA-Script and has since been called `contract`. The new name was chosen to |
| 44 |
avoid confusion with KOMA-Script packages. Secondly, it better reflects the |
| 45 |
purpose of the package. |
| 46 |
|
| 47 |
# Contributors/Collaborators |
| 48 |
|
| 49 |
- *Markus Kohm aka KOMA aka [komascript](https://codeberg.org/komascript)*: |
| 50 |
Maintainer, Developer, “go-to guy” |
| 51 |
|
| 52 |
- *[Keks-Dose](https://github.com/Keks-Dose)*: |
| 53 |
Tester, “idea man” |
| 54 |
|
| 55 |
|
| 56 |
# Installation for Users |
| 57 |
|
| 58 |
If you are a user, you should usually wait until the package has been added to |
| 59 |
your preferred TeX distribution. Then you can use the package manager of your |
| 60 |
TeX distribution to install the package. |
| 61 |
|
| 62 |
# Unpacking for Distributors |
| 63 |
|
| 64 |
Distributors should [download the current |
| 65 |
release](https://codeberg.org/komascript/latex-contract/releases). See |
| 66 |
[`MANIFEST.md`](https://codeberg.org/komascript/latex-contract/src/branch/main/MANIFEST.md) |
| 67 |
for information about the files, that build the distribution. |
| 68 |
|
| 69 |
If distributors also want to distribute `contract.sty`, they can |
| 70 |
unpack it using: |
| 71 |
|
| 72 |
tex contract.dtx |
| 73 |
|
| 74 |
or temporary install `contract` into a TEXMF tree using: |
| 75 |
|
| 76 |
l3build install --full --texmfhome <TDS root directory> |
| 77 |
|
| 78 |
and then use the files from the selected `<TDS root directory>`. |
| 79 |
|
| 80 |
# Unpacking and Installation for Developers |
| 81 |
|
| 82 |
Developers who want the current developer version of the code to be installed |
| 83 |
for testing, should clone [the `latex-contract` |
| 84 |
repository](https://codeberg.org/komascript/latex-contract.git), e.g., |
| 85 |
using |
| 86 |
|
| 87 |
git clone https://codeberg.org/komascript/latex-contract.git |
| 88 |
|
| 89 |
You can than unpack and install `contract` using: |
| 90 |
|
| 91 |
l3build install |
| 92 |
|
| 93 |
from within the main directory of the cloned respository. |
| 94 |
|
| 95 |
**Important Note:** The user manual of `contract` uses some packages, which |
| 96 |
are still under development and therefore currently may not be available on |
| 97 |
CTAN. So you usually cannot use `l3build doc` to generate the documentation or |
| 98 |
`l3build install --full` to install `contract` with the documentation. Instead |
| 99 |
you either have to read `contract.dtx` or use the `contract.pdf` available at |
| 100 |
the newest [`contract` |
| 101 |
release](https://codeberg.org/komascript/latex-contract/releases) or [the |
| 102 |
`release` |
| 103 |
branch](https://codeberg.org/komascript/latex-contract/src/branch/release). You |
| 104 |
can copy such PDFs to the `doc/latex/contract/` folder of any TEXMF tree. |
| 105 |
|
| 106 |
# How to get the Manual |
| 107 |
|
| 108 |
After installation of `contract` and the user manual you can use: |
| 109 |
|
| 110 |
texdoc contract |
| 111 |
|
| 112 |
Without installation you can get `contract.pdf` as part of the corresponding |
| 113 |
[`contract` |
| 114 |
release](https://codeberg.org/komascript/latex-contract/releases) or [the |
| 115 |
`release` |
| 116 |
branch](https://codeberg.org/komascript/latex-contract/src/branch/release). |
| 117 |
|
| 118 |
# How to Contribute |
| 119 |
|
| 120 |
To become a contributor, e.g., do heavy testing. If you find an issue, please |
| 121 |
[report it](#how-to-report-issues). You can also become a developer and, e.g., |
| 122 |
make new test files to the package. See the |
| 123 |
[`l3build`](https://ctan.org/pkg/l3build) manual for more information about |
| 124 |
tests. If you've created a new test and think that it would be useful, please |
| 125 |
either do a [pull |
| 126 |
request](https://codeberg.org/komascript/latex-contract/pulls) or [add a new |
| 127 |
issue](#how-to-report-issues) and include your test file. |
| 128 |
|
| 129 |
# How to Report Issues |
| 130 |
|
| 131 |
If you think you have found a bug (or another kind of issue) using |
| 132 |
`contract` you should use [the issue |
| 133 |
tracker](https://codeberg.org/komascript/latex-contract/issues). Please |
| 134 |
first search for similar issues already reported and maybe also already fixed |
| 135 |
and closed. Maybe the replies to such a similar report would help you too. |
| 136 |
|
| 137 |
If your issue is new, you should report it also using [the issue |
| 138 |
tracker](https://codeberg.org/komascript/latex-contract/issues). Please be kind, |
| 139 |
not only when writing the report but also when reading replies and commenting |
| 140 |
or answering. And please always add a minimal working example and usually the |
| 141 |
relevant parts of the `log`-file to your report. Please use the [markdown for |
| 142 |
code](https://docs.codeberg.org/markdown/preformatted-text/) |
| 143 |
to add such files into the text of your report. The correct language |
| 144 |
identifier for LaTeX code would be `latex`. For `log`-files you won't need any |
| 145 |
language identifier. Usually you should not use attachments for code or |
| 146 |
`log`-files unless you've been asked to do so. And please note, reports should |
| 147 |
always be self-containing. External links often break and so the report become |
| 148 |
useles. |
| 149 |
|
| 150 |
# How to Say Thank You for my Work |
| 151 |
|
| 152 |
Hey, I'm doing this as a hobby. So no need to say thank you. But I'm a vain |
| 153 |
fop, so I'm certainly up for a quick thank you by email. If you want to give |
| 154 |
more have a look to my |
| 155 |
[wishlist](https://koma-script.sourceforge.io/wunschliste). It is also |
| 156 |
available [in German](https://koma-script.sourceforge.io/de/koma/wishlist/). |
| 157 |
|
| 158 |
# Milestones |
| 159 |
|
| 160 |
The development has just begun. Currently the first |
| 161 |
milestone: |
| 162 |
|
| 163 |
- [x] creating a new repository |
| 164 |
- [x] copying `scrjura.dtx` from KOMA-Script as `contract.dtx` to the new |
| 165 |
repository |
| 166 |
- [x] creating a new build environment: |
| 167 |
- [x] `README.md` |
| 168 |
- [x] `LICENSE.md` |
| 169 |
- [x] `MANIFEST.md` |
| 170 |
- [x] `build.lua` |
| 171 |
- [x] test files |
| 172 |
- [x] renaming several internals of `contract` |
| 173 |
- [x] adding user documentation based on the `scrjura` chapters of the English |
| 174 |
KOMA-Script manual |
| 175 |
- [x] improving user documentation |
| 176 |
|
| 177 |
has been reached. |
| 178 |
|
| 179 |
Further milestones could be: |
| 180 |
|
| 181 |
- [x] replacing `scrjura` by a `contract` wrapper in KOMA-Script for |
| 182 |
compatibility only |
| 183 |
- [ ] reimplementing several internals of `contract`: |
| 184 |
- [ ] replacing KOMA-Script options by LaTeX key-value options |
| 185 |
- [ ] replacing \newkomafont, \setkomafont by something not KOMA-Script |
| 186 |
related or alterntively replacing the the internally used `scrkbase` |
| 187 |
by `scrextend`, |
| 188 |
- [ ] using `expl3`, |
| 189 |
- [ ] using the new paragraph hooks of LaTeX, |
| 190 |
- [ ] using the extended referencing mechanism of LaTeX. |
| 191 |
|
| 192 |
# From `scrjura` to `contract` |
| 193 |
|
| 194 |
If you have been using the `scrjura` package and are now switching to the |
| 195 |
`contract` package, you should read chapter “From `scrjura` to `contract`” in |
| 196 |
the `contract` user manual. The most important and incompatible change IMHO |
| 197 |
is, that the argument of `\Clause` and `\SubClause` isn't mandaroty any longer |
| 198 |
but optional. So the syntax has changed to `\Clause[<options>]` |
| 199 |
resp. `\SubClause[<options>]`. |
| 200 |
|
| 201 |
**Note:** For a transitional period, KOMA-Script will continue to contain a |
| 202 |
package `scrjura`, which is a wrapper to `contract` and attempts to increase |
| 203 |
compatibility. With this package, the argument of `\Clause` and `\SubClause` |
| 204 |
will remain mandatory for the time being. However, this package is expected to |
| 205 |
disappear from KOMA-Script after a reasonable period of smooth transition. |