Skip to content

Commit 178c3be

Browse files
hpcfzlPgBiellaurmaedje
authored
Improve Guide for LaTeX users, Query Function, and replace invisible emojis (typst#6620)
Co-authored-by: PgBiel <[email protected]> Co-authored-by: Laurenz <[email protected]>
1 parent d415834 commit 178c3be

File tree

4 files changed

+12
-11
lines changed

4 files changed

+12
-11
lines changed

crates/typst-library/src/introspection/query.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ use crate::foundations::{Array, Context, LocatableSelector, Value, func};
66

77
/// Finds elements in the document.
88
///
9-
/// The `query` functions lets you search your document for elements of a
9+
/// The `query` function lets you search your document for elements of a
1010
/// particular type or with a particular label. To use it, you first need to
1111
/// ensure that [context] is available.
1212
///

crates/typst-library/src/layout/page.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -340,7 +340,7 @@ pub struct PageElem {
340340
/// This content will overlay the page's body.
341341
///
342342
/// ```example
343-
/// #set page(foreground: text(24pt)[🥸])
343+
/// #set page(foreground: text(24pt)[🤓])
344344
///
345345
/// Reviewer 2 has marked our paper
346346
/// "Weak Reject" because they did

crates/typst-library/src/model/table.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -625,7 +625,7 @@ pub struct TableVLine {
625625
/// cell(align: left)[🌴🚗],
626626
/// cell(
627627
/// inset: 0.06em,
628-
/// text(1.62em)[🛖🌅🌊],
628+
/// text(1.62em)[🏝️🌅🌊],
629629
/// ),
630630
/// )
631631
/// ```

docs/guides/guide-for-latex-users.md

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,10 @@ collaborative editor and run Typst in your browser, no installation required.
3333

3434
If you choose to use Typst on your computer instead, you can download the
3535
compiler as a single, small binary which any user can run, no root privileges
36-
required. Unlike LaTeX, packages are downloaded when you first use them and
37-
then cached locally, keeping your Typst installation lean. You can use your own
38-
editor and decide where to store your files with the local compiler.
36+
required. Unlike popular LaTeX distributions such as TeX Live, packages are
37+
downloaded when you first use them and then cached locally, keeping your Typst
38+
installation lean. You can use your own editor and decide where to store your
39+
files with the local compiler.
3940

4041
## How do I create a new, empty document? { #getting-started }
4142
That's easy. You just create a new, empty text file (the file extension is
@@ -459,7 +460,7 @@ and their corresponding Typst functions.
459460
| LaTeX Package | Typst Alternative |
460461
|:--------------------------------|:-------------------------------------------|
461462
| graphicx, svg | [`image`] function |
462-
| tabularx | [`table`], [`grid`] functions |
463+
| tabularx, tabularray | [`table`], [`grid`] functions |
463464
| fontenc, inputenc, unicode-math | Just start writing! |
464465
| babel, polyglossia | [`text`]($text.lang) function: `[#set text(lang: "zh")]` |
465466
| amsmath | [Math mode]($category/math) |
@@ -550,8 +551,8 @@ $ f(x) = (x + 1) / x $
550551
to include more than one value in a sub- or superscript, enclose their contents
551552
in parentheses: `{$x_(a -> epsilon)$}`.
552553

553-
Since variables in math mode do not need to be prepended with a `#` or a `/`,
554-
you can also call functions without these special characters:
554+
Since variables in math mode do not need to be prepended with a `#` (or a `\`
555+
like in LaTeX), you can also call functions without these special characters:
555556

556557
```example
557558
$ f(x, y) := cases(
@@ -580,8 +581,8 @@ their call with a `#`. Nobody can stop you from using rectangles or emoji as
580581
your variables anymore:
581582

582583
```example
583-
$ sum^10_(🥸=1)
584-
#rect(width: 4mm, height: 2mm)/🥸
584+
$ sum^10_(🤓=1)
585+
#rect(width: 4mm, height: 2mm)/🤓
585586
= 🧠 maltese $
586587
```
587588

0 commit comments

Comments
 (0)