diff options
| author | Laurenz <laurmaedje@gmail.com> | 2022-12-19 01:16:35 +0100 |
|---|---|---|
| committer | Laurenz <laurmaedje@gmail.com> | 2022-12-19 01:16:35 +0100 |
| commit | b4b022940b908d8fe490b9f4f68bc60dcfb76cd2 (patch) | |
| tree | bc93a2f51295f97f971466ab87bdd763c0ed6002 /library/src/compute | |
| parent | ba384e5bb6c2455eb431f6e1fcc8b98aca1e9879 (diff) | |
Syntax and example sections
Diffstat (limited to 'library/src/compute')
| -rw-r--r-- | library/src/compute/calc.rs | 1 | ||||
| -rw-r--r-- | library/src/compute/create.rs | 12 | ||||
| -rw-r--r-- | library/src/compute/utility.rs | 1 |
3 files changed, 14 insertions, 0 deletions
diff --git a/library/src/compute/calc.rs b/library/src/compute/calc.rs index eccc4531..1984d5ef 100644 --- a/library/src/compute/calc.rs +++ b/library/src/compute/calc.rs @@ -105,6 +105,7 @@ pub fn odd(args: &mut Args) -> SourceResult<Value> { /// # Parameters /// - dividend: ToMod (positional, required) /// The dividend of the modulus. +/// /// - divisor: ToMod (positional, required) /// The divisor of the modulus. /// diff --git a/library/src/compute/create.rs b/library/src/compute/create.rs index e3733d60..cb693a1c 100644 --- a/library/src/compute/create.rs +++ b/library/src/compute/create.rs @@ -77,12 +77,21 @@ pub fn luma(args: &mut Args) -> SourceResult<Value> { /// /// If this string is given, the individual components should not be given. /// +/// # Example +/// ``` +/// #let color = rgb("#239dad") +/// #text(16pt, color)[*Typst*] +/// ``` +/// /// - red: Component (positional) /// The red component. +/// /// - green: Component (positional) /// The green component. +/// /// - blue: Component (positional) /// The blue component. +/// /// - alpha: Component (positional) /// The alpha component. /// @@ -125,10 +134,13 @@ castable! { /// # Parameters /// - cyan: RatioComponent (positional, required) /// The cyan component. +/// /// - magenta: RatioComponent (positional, required) /// The magenta component. +/// /// - yellow: RatioComponent (positional, required) /// The yellow component. +/// /// - key: RatioComponent (positional, required) /// The key component. /// diff --git a/library/src/compute/utility.rs b/library/src/compute/utility.rs index bdad9618..ffad740e 100644 --- a/library/src/compute/utility.rs +++ b/library/src/compute/utility.rs @@ -22,6 +22,7 @@ pub fn lorem(args: &mut Args) -> SourceResult<Value> { /// # Parameters /// - pattern: NumberingPattern (positional, required) /// A string that defines how the numbering works. +/// /// - numbers: NonZeroUsize (positional, variadic) /// The numbers to apply the pattern to. /// |
