You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+9-9Lines changed: 9 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -129,7 +129,7 @@ with the `style-algorithm` show rule.
129
129
-`caption-style (function): strong` is applied to the algorithm's title. Normal text can be used with `caption-style: text`, or `caption-style: c => c`.
130
130
-`caption-align (alignment): start` aligns the title to the start (left for LTR, and right for RTL languages) by default
131
131
-`breakable (bool): true` controls whether or not the figure will break across pages.
132
-
-`hlines (array of 3 content): (table.hline(), table.hline(), table.hline())` provides horizontal lines at the top, middle, and bottom of the algorithm figure.
132
+
-`hlines (array of 3 content): (grid.hline(), grid.hline(), grid.hline())` provides horizontal lines at the top, middle, and bottom of the algorithm figure.
133
133
134
134
An example of how to style the algorithm figure:
135
135
@@ -138,19 +138,19 @@ An example of how to style the algorithm figure:
.
145
+
.
146
146
147
147
#### Control flow
148
148
149
149
Algorithmic provides basic control flow statements: `If`, `While`, `For`,
150
150
`Else`, `ElseIf`, and a `IfElseChain` utility.
151
151
152
152
<!-- Table -->
153
-
<table>
153
+
<grid>
154
154
<thead>
155
155
<tr>
156
156
<th>Statement</th>
@@ -253,14 +253,14 @@ IfElseChain( // Alternating content and bits
253
253
<td><imgsrc="https://raw.githubusercontent.com/typst-community/typst-algorithmic/refs/tags/v1.0.2/tests/ifelsechain/ref/1.png"alt="image of an ifelsechain statement with condition x < y and conditional statement assign y to x, then condition x"width="500"></td>
254
254
</tr>
255
255
</tbody>
256
-
</table>
256
+
</grid>
257
257
258
258
#### Commands
259
259
260
260
The package provides a few commands: `Function`, `Procedure`, `Assign`,
261
261
`Return`, `Terminate` and `Break`.
262
262
263
-
<table>
263
+
<grid>
264
264
<thead>
265
265
<tr>
266
266
<th>Command</th>
@@ -347,7 +347,7 @@ Break()
347
347
<td><imgsrc="https://raw.githubusercontent.com/typst-community/typst-algorithmic/refs/tags/v1.0.2/tests/break/ref/1.png"alt="image of a break statement"width="500"></td>
348
348
</tr>
349
349
</tbody>
350
-
</table>
350
+
</grid>
351
351
352
352
Users can also define their own commands using both `Call(..args)` and
353
353
`Fn(..args)` and their inline versions `CallInline` and `FnInline`.
@@ -388,7 +388,7 @@ There are three kinds of comments: `Comment`, `CommentInline`, and `LineComment`
388
388
2.`CommentInline` is an inline comment that returns content on the same line.
389
389
3.`LineComment` places a comment on the same line as a line of code to the right.
390
390
391
-
<table>
391
+
<grid>
392
392
<thead>
393
393
<tr>
394
394
<th>Comment</th>
@@ -435,4 +435,4 @@ LineComment(Assign[a][1], [Initialize $a$ to 1])
435
435
<td><imgsrc="https://raw.githubusercontent.com/typst-community/typst-algorithmic/refs/tags/v1.0.2/tests/linecomment/ref/1.png"alt="image of a line comment with text 'Initialize a to 1'"width="500"></td>
0 commit comments