From bcd54868c56f3fc4d71c40e4bb98b96b9a4e9fb5 Mon Sep 17 00:00:00 2001 From: T0mstone Date: Tue, 15 Jul 2025 09:41:08 +0200 Subject: [PATCH 01/14] Add conventions document --- CONTRIBUTING.md | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 CONTRIBUTING.md diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000..fd16737 --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,38 @@ +# Conventions +When adding new modules, symbols or variants, please try to be consistent with +the following list of conventions. These aren't always hard rules, especially +because of how messy Unicode can be, but you should adhere to them if possible. + +General conventions: +- Modifiers are entirely lowercase. +- Modifiers that correspond to symbols (by having the same name) have six established meanings: + - The symbol is added around the base like an accent or an attachment (smaller than the base), e.g. `eq.quest`. + - The symbol is stacked below the base, e.g. `gt.lt`. + - The symbol is stacked to the right of the base, e.g. `colon.eq`. + - The symbol is overlaid at the center of the base, e.g. `integral.dash`. + - The symbol surrounds the base, e.g. `plus.square`. + - The symbol is placed inside the base, e.g. `triangle.stroked.dot`. +Established generic modifiers: +- `.l`/`.r`/`.t`/`.b`: The four main directions (left/right/top/bottom). + - For delimiters, `.l` means opening and `.r` means closing (see [#100](https://github.com/typst/codex/pull/100)). +- `.tl`/`.tr`/`.bl`/`.br`: The four corners + +- `.double`, `.triple`, `.quad`: A symbol that has 2-4 of something. +- `.stroked`/`.filled`: A symbol that has an empty/filled interior. + (They correspond to Unicode's "white"/"black".) +- `.tiny`/`.small`/`.medium`/`.big`: A geometric shape with a certain size. +- `.light`/`.heavy`: A shape with a certain stroke weight. +- `.dotted`: A shape with a dotted line instead of a full stroke. +Established concrete modifiers: +- `.big`: A big (n-ary) version of an operator. +- `.alt`: An alternative version that is still more or less the same symbol. +- `.not`: A symbol with a (typically diagonal) line through it. +- `.o`: A symbol with a circle around it (see [#62](https://github.com/typst/codex/pull/62)) +- `.sq`: A "squarified" version of a symbol (see [#110](https://github.com/typst/codex/pull/110)) +- `.rev`: A horizontally mirrored version of a symbol (see [#108](https://github.com/typst/codex/issues/108)) +- `.inv`: Either vertically mirrored or a 180° rotated version of a symbol (see [#108](https://github.com/typst/codex/issues/108)) +- `.cw`/`.ccw`: Clockwise/Counterclockwise +Established exceptions: +- When `.eq` is used in the second sense (stacked below), it only adds a single line and not two. + For two lines below, `.equiv` is used. +- `.not` (see above) does not correspond to the symbol `not` despite having the same name. From 8cb32996ddcfba4db391124f4cb85dbddff2a5ea Mon Sep 17 00:00:00 2001 From: T0mstone Date: Wed, 16 Jul 2025 12:42:37 +0200 Subject: [PATCH 02/14] Implement suggestions Co-authored-by: Malo <57839069+MDLC01@users.noreply.github.com> --- CONTRIBUTING.md | 38 +++++++++++++++++++++++--------------- 1 file changed, 23 insertions(+), 15 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index fd16737..fa0b3b5 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,21 +1,33 @@ +# Proposals +Proposals used to be written in the [Proposals document](https://typst.app/project/riXtMSim5zLCo7DWngIFbT), +although it is now preferred to have a GitHub issue for each one. +Nonetheless, the document still contains a lot of useful information. + # Conventions When adding new modules, symbols or variants, please try to be consistent with -the following list of conventions. These aren't always hard rules, especially -because of how messy Unicode can be, but you should adhere to them if possible. +existing ones. Below are some guidelines based on existing symbols. These aren't +always hard rules, especially because of how messy Unicode can be, but you should +adhere to them if possible. General conventions: -- Modifiers are entirely lowercase. -- Modifiers that correspond to symbols (by having the same name) have six established meanings: - - The symbol is added around the base like an accent or an attachment (smaller than the base), e.g. `eq.quest`. +- Modifier and module names are entirely lowercase. + Symbol names are lowercase unless the symbol is an uppercase letter. +- When a symbol is added to a base, the symbol name is used as a modifier on the base. + [^1](Though a modifier can also just coincidentally be a symbol name, e.g. `.not`.) + This can have the following meanings: + - The symbol is added around or inside the base as a subordinate (smaller than the base), + e.g. `eq.quest`, `triangle.stroked.dot`. - The symbol is stacked below the base, e.g. `gt.lt`. - The symbol is stacked to the right of the base, e.g. `colon.eq`. - The symbol is overlaid at the center of the base, e.g. `integral.dash`. - The symbol surrounds the base, e.g. `plus.square`. - - The symbol is placed inside the base, e.g. `triangle.stroked.dot`. +- Notable exceptions to the previous convention: + - When `.eq` is used in the second sense (stacked below), it only adds a single line and not two. + For two lines below, `.equiv` is used. Established generic modifiers: -- `.l`/`.r`/`.t`/`.b`: The four main directions (left/right/top/bottom). +- `.l`/`.r`/`.t`/`.b`: The four main directions (left/right/top/bottom), e.g. `arrow.{l,r,t,b}`. - For delimiters, `.l` means opening and `.r` means closing (see [#100](https://github.com/typst/codex/pull/100)). -- `.tl`/`.tr`/`.bl`/`.br`: The four corners +- `.tl`/`.tr`/`.bl`/`.br`: The four corners, e.g. `arrow.{tl,tr,bl,br}`. - `.double`, `.triple`, `.quad`: A symbol that has 2-4 of something. - `.stroked`/`.filled`: A symbol that has an empty/filled interior. @@ -23,16 +35,12 @@ Established generic modifiers: - `.tiny`/`.small`/`.medium`/`.big`: A geometric shape with a certain size. - `.light`/`.heavy`: A shape with a certain stroke weight. - `.dotted`: A shape with a dotted line instead of a full stroke. +- `.alt`: An alternate glyph for the symbol. Established concrete modifiers: -- `.big`: A big (n-ary) version of an operator. -- `.alt`: An alternative version that is still more or less the same symbol. -- `.not`: A symbol with a (typically diagonal) line through it. +- `.big`: A [large](https://www.unicode.org/Public/math/latest/MathClassEx-15.html) (n-ary) version of an operator. +- `.not`: A negation of the symbol. - `.o`: A symbol with a circle around it (see [#62](https://github.com/typst/codex/pull/62)) - `.sq`: A "squarified" version of a symbol (see [#110](https://github.com/typst/codex/pull/110)) - `.rev`: A horizontally mirrored version of a symbol (see [#108](https://github.com/typst/codex/issues/108)) - `.inv`: Either vertically mirrored or a 180° rotated version of a symbol (see [#108](https://github.com/typst/codex/issues/108)) - `.cw`/`.ccw`: Clockwise/Counterclockwise -Established exceptions: -- When `.eq` is used in the second sense (stacked below), it only adds a single line and not two. - For two lines below, `.equiv` is used. -- `.not` (see above) does not correspond to the symbol `not` despite having the same name. From baf90424ab7b81576e26155e8500fdf1fc5af461 Mon Sep 17 00:00:00 2001 From: T0mstone Date: Wed, 16 Jul 2025 13:04:59 +0200 Subject: [PATCH 03/14] Implement suggestions (Part 2) Co-authored-by: Malo <57839069+MDLC01@users.noreply.github.com> --- CONTRIBUTING.md | 42 ++++++++++++++++++++++++------------------ 1 file changed, 24 insertions(+), 18 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index fa0b3b5..0679cbe 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -12,8 +12,7 @@ adhere to them if possible. General conventions: - Modifier and module names are entirely lowercase. Symbol names are lowercase unless the symbol is an uppercase letter. -- When a symbol is added to a base, the symbol name is used as a modifier on the base. - [^1](Though a modifier can also just coincidentally be a symbol name, e.g. `.not`.) +- When a symbol is added to a base, the symbol name is used as a modifier on the base.[^modifname] This can have the following meanings: - The symbol is added around or inside the base as a subordinate (smaller than the base), e.g. `eq.quest`, `triangle.stroked.dot`. @@ -25,22 +24,29 @@ General conventions: - When `.eq` is used in the second sense (stacked below), it only adds a single line and not two. For two lines below, `.equiv` is used. Established generic modifiers: -- `.l`/`.r`/`.t`/`.b`: The four main directions (left/right/top/bottom), e.g. `arrow.{l,r,t,b}`. - - For delimiters, `.l` means opening and `.r` means closing (see [#100](https://github.com/typst/codex/pull/100)). -- `.tl`/`.tr`/`.bl`/`.br`: The four corners, e.g. `arrow.{tl,tr,bl,br}`. +- `.l`/`.r`/`.t`/`.b`: The four main directions (left/right/top/bottom), e.g. `arrow.l`, `times.r`. + - For delimiters, `.l` means opening and `.r` means closing, e.g. `paren.l`, `quote.r`. +- `.tl`/`.tr`/`.bl`/`.br`: The four corners, e.g. `arrow.tl`, `triangle.stroked.tr`. -- `.double`, `.triple`, `.quad`: A symbol that has 2-4 of something. -- `.stroked`/`.filled`: A symbol that has an empty/filled interior. +- `.double`, `.triple`, `.quad`: A symbol that has 2-4 of something, e.g. `excl.double`, `eq.quad`. +- `.stroked`/`.filled`: A symbol that has an empty/filled interior, e.g. `circle.stroked`, `arrow.r.filled`. (They correspond to Unicode's "white"/"black".) -- `.tiny`/`.small`/`.medium`/`.big`: A geometric shape with a certain size. -- `.light`/`.heavy`: A shape with a certain stroke weight. -- `.dotted`: A shape with a dotted line instead of a full stroke. -- `.alt`: An alternate glyph for the symbol. +- `.tiny`/`.small`/`.medium`/`.big`: A geometric shape with a certain size, e.g. `square.stroked.small`. +- `.light`/`.heavy`: A shape with a certain stroke weight, e.g. `checkmark.heavy`. +- `.dotted`: A shape with a dotted line instead of a full stroke, e.g. `circle.dotted`. +- `.alt`: An alternate glyph for the symbol, e.g. `phi.alt`. Established concrete modifiers: -- `.big`: A [large](https://www.unicode.org/Public/math/latest/MathClassEx-15.html) (n-ary) version of an operator. -- `.not`: A negation of the symbol. -- `.o`: A symbol with a circle around it (see [#62](https://github.com/typst/codex/pull/62)) -- `.sq`: A "squarified" version of a symbol (see [#110](https://github.com/typst/codex/pull/110)) -- `.rev`: A horizontally mirrored version of a symbol (see [#108](https://github.com/typst/codex/issues/108)) -- `.inv`: Either vertically mirrored or a 180° rotated version of a symbol (see [#108](https://github.com/typst/codex/issues/108)) -- `.cw`/`.ccw`: Clockwise/Counterclockwise +- `.big`: A [large](https://www.unicode.org/Public/math/latest/MathClassEx-15.html) (n-ary) version + of an operator, e.g. `union.big`. +- `.not`: A negation of the symbol, e.g. `eq.not`. +- `.o`: A symbol with a circle around it, e.g. `plus.circle`. + - See also [#62](https://github.com/typst/codex/pull/62) +- `.sq`: A "squarified" version of a symbol, e.g. `subset.eq`. + - See also [#110](https://github.com/typst/codex/pull/110) +- `.rev`: A horizontally mirrored version of a symbol, e.g. `in.rev`. + - See also [#108](https://github.com/typst/codex/issues/108). +- `.inv`: Either vertically mirrored or a 180° rotated version of a symbol, e.g. `amp.inv`, `Omega.inv`. + - See also [#108](https://github.com/typst/codex/issues/108). +- `.cw`/`.ccw`: Clockwise/Counterclockwise, e.g. `arrow.cw`, `integral.ccw`. + +[^modifname]: Though a modifier can also just coincidentally be a symbol name, e.g. `.not`. \ No newline at end of file From 4f204e9069b963abe2f927575d6c6116ea4e1a50 Mon Sep 17 00:00:00 2001 From: T0mstone Date: Wed, 16 Jul 2025 13:07:05 +0200 Subject: [PATCH 04/14] Fix and improve formatting --- CONTRIBUTING.md | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 0679cbe..c8a417b 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -9,7 +9,7 @@ existing ones. Below are some guidelines based on existing symbols. These aren't always hard rules, especially because of how messy Unicode can be, but you should adhere to them if possible. -General conventions: +**General conventions:** - Modifier and module names are entirely lowercase. Symbol names are lowercase unless the symbol is an uppercase letter. - When a symbol is added to a base, the symbol name is used as a modifier on the base.[^modifname] @@ -23,7 +23,8 @@ General conventions: - Notable exceptions to the previous convention: - When `.eq` is used in the second sense (stacked below), it only adds a single line and not two. For two lines below, `.equiv` is used. -Established generic modifiers: + +**Established generic modifiers:** - `.l`/`.r`/`.t`/`.b`: The four main directions (left/right/top/bottom), e.g. `arrow.l`, `times.r`. - For delimiters, `.l` means opening and `.r` means closing, e.g. `paren.l`, `quote.r`. - `.tl`/`.tr`/`.bl`/`.br`: The four corners, e.g. `arrow.tl`, `triangle.stroked.tr`. @@ -35,7 +36,8 @@ Established generic modifiers: - `.light`/`.heavy`: A shape with a certain stroke weight, e.g. `checkmark.heavy`. - `.dotted`: A shape with a dotted line instead of a full stroke, e.g. `circle.dotted`. - `.alt`: An alternate glyph for the symbol, e.g. `phi.alt`. -Established concrete modifiers: + +**Established concrete modifiers:** - `.big`: A [large](https://www.unicode.org/Public/math/latest/MathClassEx-15.html) (n-ary) version of an operator, e.g. `union.big`. - `.not`: A negation of the symbol, e.g. `eq.not`. From 677e67f7782ea4a10803ccc9efaf3ccbcf2191bf Mon Sep 17 00:00:00 2001 From: T0mstone Date: Wed, 16 Jul 2025 13:11:48 +0200 Subject: [PATCH 05/14] Change formatting again --- CONTRIBUTING.md | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index c8a417b..b5cbe51 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -9,7 +9,7 @@ existing ones. Below are some guidelines based on existing symbols. These aren't always hard rules, especially because of how messy Unicode can be, but you should adhere to them if possible. -**General conventions:** +### General Conventions - Modifier and module names are entirely lowercase. Symbol names are lowercase unless the symbol is an uppercase letter. - When a symbol is added to a base, the symbol name is used as a modifier on the base.[^modifname] @@ -24,7 +24,10 @@ adhere to them if possible. - When `.eq` is used in the second sense (stacked below), it only adds a single line and not two. For two lines below, `.equiv` is used. -**Established generic modifiers:** +[^modifname]: Though a modifier can also just coincidentally be a symbol name, e.g. `.not`. + +### Established Generic Modifiers +These have a broad meaning and can have varying interpretations. - `.l`/`.r`/`.t`/`.b`: The four main directions (left/right/top/bottom), e.g. `arrow.l`, `times.r`. - For delimiters, `.l` means opening and `.r` means closing, e.g. `paren.l`, `quote.r`. - `.tl`/`.tr`/`.bl`/`.br`: The four corners, e.g. `arrow.tl`, `triangle.stroked.tr`. @@ -37,7 +40,8 @@ adhere to them if possible. - `.dotted`: A shape with a dotted line instead of a full stroke, e.g. `circle.dotted`. - `.alt`: An alternate glyph for the symbol, e.g. `phi.alt`. -**Established concrete modifiers:** +### Established Concrete Modifiers +These have a specific meaning that is not open to much interpretation. - `.big`: A [large](https://www.unicode.org/Public/math/latest/MathClassEx-15.html) (n-ary) version of an operator, e.g. `union.big`. - `.not`: A negation of the symbol, e.g. `eq.not`. @@ -50,5 +54,3 @@ adhere to them if possible. - `.inv`: Either vertically mirrored or a 180° rotated version of a symbol, e.g. `amp.inv`, `Omega.inv`. - See also [#108](https://github.com/typst/codex/issues/108). - `.cw`/`.ccw`: Clockwise/Counterclockwise, e.g. `arrow.cw`, `integral.ccw`. - -[^modifname]: Though a modifier can also just coincidentally be a symbol name, e.g. `.not`. \ No newline at end of file From b6fc5d6a0db5e20961af719fbb0275abc5fae86c Mon Sep 17 00:00:00 2001 From: T0mstone Date: Wed, 16 Jul 2025 13:14:17 +0200 Subject: [PATCH 06/14] Add last missing example --- CONTRIBUTING.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index b5cbe51..dbe35d6 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -21,8 +21,8 @@ adhere to them if possible. - The symbol is overlaid at the center of the base, e.g. `integral.dash`. - The symbol surrounds the base, e.g. `plus.square`. - Notable exceptions to the previous convention: - - When `.eq` is used in the second sense (stacked below), it only adds a single line and not two. - For two lines below, `.equiv` is used. + - When `.eq` is used in the second sense (stacked below), it only adds a single line and not two, + e.g. `lt.eq`. For two lines below, `.equiv` is used, e.g. `lt.equiv`. [^modifname]: Though a modifier can also just coincidentally be a symbol name, e.g. `.not`. From 67550cf641e300d23c80b87f094a3d8409da6c54 Mon Sep 17 00:00:00 2001 From: T0mstone <39707032+T0mstone@users.noreply.github.com> Date: Wed, 16 Jul 2025 13:28:05 +0200 Subject: [PATCH 07/14] Reformat slightly and add intro paragraph --- CONTRIBUTING.md | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index dbe35d6..fda8603 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,9 +1,12 @@ -# Proposals +# Contributing Guidelines +Contributions are welcome! This document provides some resources and guidelines to help with the process. + +## Proposals Proposals used to be written in the [Proposals document](https://typst.app/project/riXtMSim5zLCo7DWngIFbT), although it is now preferred to have a GitHub issue for each one. Nonetheless, the document still contains a lot of useful information. -# Conventions +## Conventions When adding new modules, symbols or variants, please try to be consistent with existing ones. Below are some guidelines based on existing symbols. These aren't always hard rules, especially because of how messy Unicode can be, but you should From ceafd2e84860947a646046f4e04b21c6a08d80fa Mon Sep 17 00:00:00 2001 From: T0mstone Date: Wed, 16 Jul 2025 13:37:55 +0200 Subject: [PATCH 08/14] Add paragraph for newcomers --- CONTRIBUTING.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index fda8603..507670d 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,6 +1,9 @@ # Contributing Guidelines Contributions are welcome! This document provides some resources and guidelines to help with the process. +Symbol definitions are in `src/modules/`; The syntax should be mostly self-evident. +If you need help with a contribution, you can ask us [on Discord](https://discord.com/channels/1054443721975922748/1277628305142452306). + ## Proposals Proposals used to be written in the [Proposals document](https://typst.app/project/riXtMSim5zLCo7DWngIFbT), although it is now preferred to have a GitHub issue for each one. From 4262c65acf93a6198ce20a4a6be27e211c1aa3d6 Mon Sep 17 00:00:00 2001 From: T0mstone Date: Wed, 16 Jul 2025 13:42:12 +0200 Subject: [PATCH 09/14] Add note about symbol name length Co-authored-by: Malo <57839069+MDLC01@users.noreply.github.com> --- CONTRIBUTING.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 507670d..0c73429 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -17,7 +17,8 @@ adhere to them if possible. ### General Conventions - Modifier and module names are entirely lowercase. - Symbol names are lowercase unless the symbol is an uppercase letter. +- Symbol names are lowercase unless the symbol is an uppercase letter. +- Symbol names should be at least two characters long so they can be used easily in typst's math mode. - When a symbol is added to a base, the symbol name is used as a modifier on the base.[^modifname] This can have the following meanings: - The symbol is added around or inside the base as a subordinate (smaller than the base), From 10d25457d54a380f91b2bb16f0d9199fe37b30f8 Mon Sep 17 00:00:00 2001 From: T0mstone Date: Mon, 21 Jul 2025 11:25:19 +0200 Subject: [PATCH 10/14] Add note about diagonals Co-authored-by: Malo <57839069+MDLC01@users.noreply.github.com> --- CONTRIBUTING.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 0c73429..eeb91af 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -38,7 +38,10 @@ These have a broad meaning and can have varying interpretations. - `.l`/`.r`/`.t`/`.b`: The four main directions (left/right/top/bottom), e.g. `arrow.l`, `times.r`. - For delimiters, `.l` means opening and `.r` means closing, e.g. `paren.l`, `quote.r`. - `.tl`/`.tr`/`.bl`/`.br`: The four corners, e.g. `arrow.tl`, `triangle.stroked.tr`. - + - Generally, these are used for a single, diagonal direction, + whereas combinations of two main directions (like `.t.l`) are used to mean both of them at once, + e.g. `arrow.t.l`, if it existed, would be an arrow that points both top and left, + similarly to how `arrow.l.r` is an arrow pointing both left and right. - `.double`, `.triple`, `.quad`: A symbol that has 2-4 of something, e.g. `excl.double`, `eq.quad`. - `.stroked`/`.filled`: A symbol that has an empty/filled interior, e.g. `circle.stroked`, `arrow.r.filled`. (They correspond to Unicode's "white"/"black".) From 1d6e351c2960a646c8c302a9b987ad507072ad85 Mon Sep 17 00:00:00 2001 From: T0mstone Date: Mon, 21 Jul 2025 11:31:10 +0200 Subject: [PATCH 11/14] Re-order modifiers --- CONTRIBUTING.md | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index eeb91af..625ec67 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -35,6 +35,7 @@ adhere to them if possible. ### Established Generic Modifiers These have a broad meaning and can have varying interpretations. + - `.l`/`.r`/`.t`/`.b`: The four main directions (left/right/top/bottom), e.g. `arrow.l`, `times.r`. - For delimiters, `.l` means opening and `.r` means closing, e.g. `paren.l`, `quote.r`. - `.tl`/`.tr`/`.bl`/`.br`: The four corners, e.g. `arrow.tl`, `triangle.stroked.tr`. @@ -42,25 +43,28 @@ These have a broad meaning and can have varying interpretations. whereas combinations of two main directions (like `.t.l`) are used to mean both of them at once, e.g. `arrow.t.l`, if it existed, would be an arrow that points both top and left, similarly to how `arrow.l.r` is an arrow pointing both left and right. -- `.double`, `.triple`, `.quad`: A symbol that has 2-4 of something, e.g. `excl.double`, `eq.quad`. +- `.cw`/`.ccw`: Clockwise/Counterclockwise, e.g. `arrow.cw`, `integral.ccw`. +- `.tiny`/`.small`/`.medium`/`.big`: A geometric shape with a certain size, e.g. `square.stroked.small`. + - `.stroked`/`.filled`: A symbol that has an empty/filled interior, e.g. `circle.stroked`, `arrow.r.filled`. (They correspond to Unicode's "white"/"black".) -- `.tiny`/`.small`/`.medium`/`.big`: A geometric shape with a certain size, e.g. `square.stroked.small`. -- `.light`/`.heavy`: A shape with a certain stroke weight, e.g. `checkmark.heavy`. - `.dotted`: A shape with a dotted line instead of a full stroke, e.g. `circle.dotted`. +- `.light`/`.heavy`: A shape with a certain stroke weight, e.g. `checkmark.heavy`. + - `.alt`: An alternate glyph for the symbol, e.g. `phi.alt`. +- `.double`, `.triple`, `.quad`: A symbol that has 2-4 of something, e.g. `excl.double`, `eq.quad`. ### Established Concrete Modifiers These have a specific meaning that is not open to much interpretation. + - `.big`: A [large](https://www.unicode.org/Public/math/latest/MathClassEx-15.html) (n-ary) version of an operator, e.g. `union.big`. +- `.inv`: Either vertically mirrored or a 180° rotated version of a symbol, e.g. `amp.inv`, `Omega.inv`. + - See also [#108](https://github.com/typst/codex/issues/108). - `.not`: A negation of the symbol, e.g. `eq.not`. - `.o`: A symbol with a circle around it, e.g. `plus.circle`. - See also [#62](https://github.com/typst/codex/pull/62) -- `.sq`: A "squarified" version of a symbol, e.g. `subset.eq`. - - See also [#110](https://github.com/typst/codex/pull/110) - `.rev`: A horizontally mirrored version of a symbol, e.g. `in.rev`. - See also [#108](https://github.com/typst/codex/issues/108). -- `.inv`: Either vertically mirrored or a 180° rotated version of a symbol, e.g. `amp.inv`, `Omega.inv`. - - See also [#108](https://github.com/typst/codex/issues/108). -- `.cw`/`.ccw`: Clockwise/Counterclockwise, e.g. `arrow.cw`, `integral.ccw`. +- `.sq`: A "squarified" version of a symbol, e.g. `subset.eq`. + - See also [#110](https://github.com/typst/codex/pull/110) From 49d8d1bf5b28869c34d5e9ec6a8c608f9979e406 Mon Sep 17 00:00:00 2001 From: T0mstone <39707032+T0mstone@users.noreply.github.com> Date: Mon, 21 Jul 2025 13:44:02 +0200 Subject: [PATCH 12/14] Fix Typst capitalization Co-authored-by: Malo <57839069+MDLC01@users.noreply.github.com> --- CONTRIBUTING.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 625ec67..32d7535 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -18,7 +18,7 @@ adhere to them if possible. ### General Conventions - Modifier and module names are entirely lowercase. - Symbol names are lowercase unless the symbol is an uppercase letter. -- Symbol names should be at least two characters long so they can be used easily in typst's math mode. +- Symbol names should be at least two characters long so they can be used easily in Typst's math mode. - When a symbol is added to a base, the symbol name is used as a modifier on the base.[^modifname] This can have the following meanings: - The symbol is added around or inside the base as a subordinate (smaller than the base), From d23d15df8facdda0ef865d1aea4f2701f612dad4 Mon Sep 17 00:00:00 2001 From: T0mstone Date: Wed, 23 Jul 2025 14:57:56 +0200 Subject: [PATCH 13/14] Fix typo --- CONTRIBUTING.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 32d7535..6f97551 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -66,5 +66,5 @@ These have a specific meaning that is not open to much interpretation. - See also [#62](https://github.com/typst/codex/pull/62) - `.rev`: A horizontally mirrored version of a symbol, e.g. `in.rev`. - See also [#108](https://github.com/typst/codex/issues/108). -- `.sq`: A "squarified" version of a symbol, e.g. `subset.eq`. +- `.sq`: A "squarified" version of a symbol, e.g. `subset.sq`. - See also [#110](https://github.com/typst/codex/pull/110) From a8a9bd43e6956f0b482f69beefc37f6187ca7199 Mon Sep 17 00:00:00 2001 From: T0mstone Date: Tue, 14 Oct 2025 22:42:26 +0200 Subject: [PATCH 14/14] Add note about US spelling See https://github.com/typst/codex/pull/79#issuecomment-2926388519 --- CONTRIBUTING.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 6f97551..4f51e4f 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -16,6 +16,7 @@ always hard rules, especially because of how messy Unicode can be, but you shoul adhere to them if possible. ### General Conventions +- English words use US spelling. - Modifier and module names are entirely lowercase. - Symbol names are lowercase unless the symbol is an uppercase letter. - Symbol names should be at least two characters long so they can be used easily in Typst's math mode.