Skip to content

Commit

Permalink
[docs] replace string with str
Browse files Browse the repository at this point in the history
  • Loading branch information
Mc-Zen committed May 14, 2024
1 parent 8ea91c1 commit ea9110d
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 17 deletions.
20 changes: 10 additions & 10 deletions src/decorations.typ
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,12 @@
/// Basic command for labelling a wire at the start.
/// - content (content): Label to display, e.g., `$|0〉$`.
/// - n (content): How many wires the `lstick` should span.
/// - brace (auto, none, string): If `brace` is `auto`, then a default `{` brace
/// - brace (auto, none, str): If `brace` is `auto`, then a default `{` brace
/// is shown only if `n > 1`. A brace is always shown when
/// explicitly given, e.g., `"}"`, `"["` or `"|"`. No brace is shown for
/// `brace: none`
/// - pad (length): Adds a padding between the label and the connected wire to the right.
/// - label (array, string, content, dictionary): One or more labels to add to the gate.
/// - label (array, str, content, dictionary): One or more labels to add to the gate.
/// See @@gate().
#let lstick(
content,
Expand All @@ -55,11 +55,11 @@
/// - content (content): Label to display, e.g., `$|0〉$`.
/// - n (content): How many wires the `rstick` should span.
/// - pad (length): Adds a padding between the label and the connected wire to the left.
/// - brace (auto, none, string): If `brace` is `auto`, then a default `}` brace
/// - brace (auto, none, str): If `brace` is `auto`, then a default `}` brace
/// is shown only if `n > 1`. A brace is always shown when
/// explicitly given, e.g., `"}"`, `"["` or `"|"`. No brace is shown for
/// `brace: none`.
/// - label (array, string, content, dictionary): One or more labels to add to the gate.
/// - label (array, str, content, dictionary): One or more labels to add to the gate.
/// See @@gate().
#let rstick(
content,
Expand All @@ -73,7 +73,7 @@

/// Create a midstick, i.e., a mid-circuit text.
/// - content (content): Label to display, e.g., `$|0〉$`.
/// - label (array, string, content, dictionary): One or more labels to add to the gate.
/// - label (array, str, content, dictionary): One or more labels to add to the gate.
#let midstick(
content,
fill: none,
Expand Down Expand Up @@ -114,7 +114,7 @@
/// - steps (int): Number of columns to include.
/// - x (auto, int): The starting column of the gategroup.
/// - y (auto, int): The starting wire of the gategroup.
/// - z (string): The gategroup can be placed `"below"` or `"above"` the circuit.
/// - z (str): The gategroup can be placed `"below"` or `"above"` the circuit.
/// - padding (length, dictionary): Padding of rectangle. May be one length
/// for all sides or a dictionary with the keys `left`, `right`, `top`,
/// `bottom` and `default`. Not all keys need to be specified. The value
Expand All @@ -123,7 +123,7 @@
/// - stroke (stroke): Stroke for rectangle.
/// - fill (color): Fill color for rectangle.
/// - radius (length, dictionary): Corner radius for rectangle.
/// - label (array, string, content, dictionary): One or more labels to add to the
/// - label (array, str, content, dictionary): One or more labels to add to the
/// group. See @@gate().
#let gategroup(
wires,
Expand Down Expand Up @@ -153,9 +153,9 @@
/// - n (int): Number of wires to slice.
/// - x (auto, int): The starting column of the slice.
/// - y (auto, int): The starting wire of the slice.
/// - z (string): The slice can be placed `"below"` or `"above"` the circuit.
/// - z (str): The slice can be placed `"below"` or `"above"` the circuit.
/// - stroke (stroke): Line style for the slice.
/// - label (array, string, content, dictionary): One or more labels to add to the
/// - label (array, str, content, dictionary): One or more labels to add to the
/// slice. See @@gate().
#let slice(
n: 0,
Expand Down Expand Up @@ -186,7 +186,7 @@
/// signature should be with signature `(col-coords, row-coords) => {}`.
/// This function is expected to display the content to draw in absolute
/// coordinates within the circuit.
/// - z (string): The annotation can be placed `"below"` or `"above"` the circuit.
/// - z (str): The annotation can be placed `"below"` or `"above"` the circuit.
#let annotate(
columns,
rows,
Expand Down
12 changes: 6 additions & 6 deletions src/gates.typ
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
/// Signature: `(gate, draw-params) => {}`.
/// - draw-function (function): Drawing function that produces the displayed content.
/// Signature: `(gate, draw-params) => {}`.
/// - label (array, string, content, dictionary): One or more labels to add to the gate.
/// - label (array, str, content, dictionary): One or more labels to add to the gate.
/// Usually, a label consists of a dictionary with entries for the keys
/// `content` (the label content), `pos` (2d alignment specifying the
/// position of the label) and optionally `dx` and/or `dy` (lengths, ratios
Expand Down Expand Up @@ -105,9 +105,9 @@
/// - Affect height on only the first and last wire (`false`)
/// - Affect the height of all wires (`true`)
/// - Affect the height on no wire (`none`)
/// - label (array, string, content, dictionary): One or more labels to add to the gate.
/// - label (array, str, content, dictionary): One or more labels to add to the gate.
/// See @@gate().
/// - wire-label (array, string, content, dictionary): One or more labels to add to the
/// - wire-label (array, str, content, dictionary): One or more labels to add to the
/// control wire. Works analogous to `labels` but with default positioning to the
/// right of the wire.
/// - data (any): Optional additional gate data. This can for example be a dictionary
Expand Down Expand Up @@ -164,7 +164,7 @@
/// qubit the specified number of wires up or down.
/// - wire-count (int): Wire count for the (optional) control wire.
/// - n (int): Number of wires to span this meter across.
/// - label (array, string, content, dictionary): One or more labels to add to the gate.
/// - label (array, str, content, dictionary): One or more labels to add to the gate.
/// See @@gate().
#let meter(
target: none,
Expand Down Expand Up @@ -299,7 +299,7 @@
///
/// - n (int): How many wires up or down the target wire lives.
/// - size (length): Size of the target symbol.
/// - wire-label (array, string, content, dictionary): One or more labels
/// - wire-label (array, str, content, dictionary): One or more labels
/// to add to the control wire. See @@mqgate().
#let swap(
n,
Expand Down Expand Up @@ -334,7 +334,7 @@
/// - size (length): Size of the control circle.
/// - show-dot (boolean): Whether to show the control dot. Set this to
/// false to obtain a vertical wire with no dots at all.
/// - wire-label (array, string, content, dictionary): One or more labels
/// - wire-label (array, str, content, dictionary): One or more labels
/// to add to the control wire. See @@mqgate().
#let ctrl(
n,
Expand Down
2 changes: 1 addition & 1 deletion src/quantum-circuit.typ
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
/// - font-size (length): Default font size for text in the circuit.
/// - scale (ratio): Total scale factor applied to the entire
/// circuit without changing proportions
/// - baseline (length, content, string): Set the baseline for the circuit. If a
/// - baseline (length, content, str): Set the baseline for the circuit. If a
/// content or a string is given, the baseline will be adjusted auto-
/// matically to align with the center of it. One useful application is
/// `"="` so the circuit aligns with the equals symbol.
Expand Down

0 comments on commit ea9110d

Please sign in to comment.