summaryrefslogtreecommitdiff
path: root/library/src/meta
diff options
context:
space:
mode:
Diffstat (limited to 'library/src/meta')
-rw-r--r--library/src/meta/context.rs4
-rw-r--r--library/src/meta/counter.rs18
-rw-r--r--library/src/meta/link.rs8
-rw-r--r--library/src/meta/numbering.rs2
-rw-r--r--library/src/meta/query.rs2
-rw-r--r--library/src/meta/reference.rs10
-rw-r--r--library/src/meta/state.rs20
7 files changed, 31 insertions, 33 deletions
diff --git a/library/src/meta/context.rs b/library/src/meta/context.rs
index 2ed359ee..a42c6980 100644
--- a/library/src/meta/context.rs
+++ b/library/src/meta/context.rs
@@ -15,7 +15,7 @@ use crate::prelude::*;
///
/// ## Methods
/// ### page()
-/// Return the page number for this location.
+/// Returns the page number for this location.
///
/// Note that this does not return the value of the [page counter]($func/counter)
/// at this location, but the true page number (starting from one).
@@ -26,7 +26,7 @@ use crate::prelude::*;
/// - returns: integer
///
/// ### position()
-/// Return a dictionary with the page number and the x, y position for this
+/// Returns a dictionary with the page number and the x, y position for this
/// location. The page number starts at one and the coordinates are measured
/// from the top-left of the page.
///
diff --git a/library/src/meta/counter.rs b/library/src/meta/counter.rs
index 65522c40..4825bc65 100644
--- a/library/src/meta/counter.rs
+++ b/library/src/meta/counter.rs
@@ -11,7 +11,7 @@ use crate::layout::PageElem;
use crate::math::EquationElem;
use crate::prelude::*;
-/// Count through pages, elements, and more.
+/// Counts through pages, elements, and more.
///
/// With the counter function, you can access and modify counters for pages,
/// headings, figures, and more. Moreover, you can define custom counters for
@@ -23,9 +23,9 @@ use crate::prelude::*;
/// on the counter. To see any output, you also have to enable heading
/// [numbering]($func/heading.numbering).
///
-/// The display function optionally takes an argument telling it how to
-/// format the counter. This can be a
-/// [numbering pattern or a function]($func/numbering).
+/// The `display` method optionally takes an argument telling it how to format
+/// the counter. This can be a [numbering pattern or a
+/// function]($func/numbering).
///
/// ```example
/// #set heading(numbering: "1.")
@@ -203,7 +203,7 @@ use crate::prelude::*;
///
/// ## Methods
/// ### display()
-/// Display the value of the counter.
+/// Displays the value of the counter.
///
/// - numbering: string or function (positional)
/// A [numbering pattern or a function]($func/numbering), which specifies how
@@ -224,7 +224,7 @@ use crate::prelude::*;
/// - returns: content
///
/// ### step()
-/// Increase the value of the counter by one.
+/// Increases the value of the counter by one.
///
/// The update will be in effect at the position where the returned content is
/// inserted into the document. If you don't put the output into the document,
@@ -238,7 +238,7 @@ use crate::prelude::*;
/// - returns: content
///
/// ### update()
-/// Update the value of the counter.
+/// Updates the value of the counter.
///
/// Just like with `step`, the update only occurs if you put the resulting
/// content into the document.
@@ -252,7 +252,7 @@ use crate::prelude::*;
/// - returns: content
///
/// ### at()
-/// Get the value of the counter at the given location. Always returns an
+/// Gets the value of the counter at the given location. Always returns an
/// array of integers, even if the counter has just one number.
///
/// - location: location (positional, required)
@@ -263,7 +263,7 @@ use crate::prelude::*;
/// - returns: array
///
/// ### final()
-/// Get the value of the counter at the end of the document. Always returns an
+/// Gets the value of the counter at the end of the document. Always returns an
/// array of integers, even if the counter has just one number.
///
/// - location: location (positional, required)
diff --git a/library/src/meta/link.rs b/library/src/meta/link.rs
index c3d8718c..2a53b84f 100644
--- a/library/src/meta/link.rs
+++ b/library/src/meta/link.rs
@@ -1,12 +1,10 @@
use crate::prelude::*;
use crate::text::{Hyphenate, TextElem};
-/// Link to a URL or a location in the document.
+/// Links to a URL or a location in the document.
///
-/// The link function makes its positional `body` argument clickable and links
-/// it to the destination specified by the `dest` argument. By default, links
-/// are not styled any different from normal text. However, you can easily apply
-/// a style of your choice with a show rule.
+/// By default, links are not styled any different from normal text. However,
+/// you can easily apply a style of your choice with a show rule.
///
/// ## Example { #example }
/// ```example
diff --git a/library/src/meta/numbering.rs b/library/src/meta/numbering.rs
index ed71c1be..8698f7b9 100644
--- a/library/src/meta/numbering.rs
+++ b/library/src/meta/numbering.rs
@@ -6,7 +6,7 @@ use ecow::EcoVec;
use crate::prelude::*;
use crate::text::Case;
-/// Apply a numbering to a sequence of numbers.
+/// Applies a numbering to a sequence of numbers.
///
/// A numbering defines how a sequence of numbers should be displayed as
/// content. It is defined either through a pattern string or an arbitrary
diff --git a/library/src/meta/query.rs b/library/src/meta/query.rs
index 7f839f97..826b812e 100644
--- a/library/src/meta/query.rs
+++ b/library/src/meta/query.rs
@@ -1,6 +1,6 @@
use crate::prelude::*;
-/// Find elements in the document.
+/// Finds elements in the document.
///
/// The `query` functions lets you search your document for elements of a
/// particular type or with a particular label.
diff --git a/library/src/meta/reference.rs b/library/src/meta/reference.rs
index 7f21a3ce..457085fd 100644
--- a/library/src/meta/reference.rs
+++ b/library/src/meta/reference.rs
@@ -6,11 +6,11 @@ use crate::text::TextElem;
/// A reference to a label or bibliography.
///
-/// The reference function produces a textual reference to a label. For example,
-/// a reference to a heading will yield an appropriate string such as "Section
-/// 1" for a reference to the first heading. The references are also links to
-/// the respective element. Reference syntax can also be used to
-/// [cite]($func/cite) from a bibliography.
+/// Produces a textual reference to a label. For example, a reference to a
+/// heading will yield an appropriate string such as "Section 1" for a reference
+/// to the first heading. The references are also links to the respective
+/// element. Reference syntax can also be used to [cite]($func/cite) from a
+/// bibliography.
///
/// Referenceable elements include [headings]($func/heading),
/// [figures]($func/figure), and [equations]($func/math.equation). To create a
diff --git a/library/src/meta/state.rs b/library/src/meta/state.rs
index a8e37901..aee53a29 100644
--- a/library/src/meta/state.rs
+++ b/library/src/meta/state.rs
@@ -6,14 +6,14 @@ use typst::model::DelayedErrors;
use crate::prelude::*;
-/// Manage stateful parts of your document.
+/// Manages stateful parts of your document.
///
/// Let's say you have some computations in your document and want to remember
/// the result of your last computation to use it in the next one. You might try
-/// something similar the code below and would expect it to output 10, 13, 26,
-/// and 21. However this **does not work** in Typst. If you test this code, you
-/// will see that Typst complains with the following error message: _Variables
-/// from outside the function are read-only and cannot be modified._
+/// something similar to the code below and expect it to output 10, 13, 26, and
+/// 21. However this **does not work** in Typst. If you test this code, you will
+/// see that Typst complains with the following error message: _Variables from
+/// outside the function are read-only and cannot be modified._
///
/// ```typ
/// #let x = 0
@@ -177,13 +177,13 @@ use crate::prelude::*;
/// ```
///
/// In general, you should _typically_ not generate state updates from within
-/// `locate` calls or `display` calls of state or counters. Instead pass a
+/// `locate` calls or `display` calls of state or counters. Instead, pass a
/// function to `update` that determines the value of the state based on its
/// previous value.
///
/// ## Methods
/// ### display()
-/// Display the value of the state.
+/// Displays the value of the state.
///
/// - format: function (positional)
/// A function which receives the value of the state and can return arbitrary
@@ -193,7 +193,7 @@ use crate::prelude::*;
/// - returns: content
///
/// ### update()
-/// Update the value of the state.
+/// Updates the value of the state.
///
/// The update will be in effect at the position where the returned content is
/// inserted into the document. If you don't put the output into the document,
@@ -209,7 +209,7 @@ use crate::prelude::*;
/// - returns: content
///
/// ### at()
-/// Get the value of the state at the given location.
+/// Gets the value of the state at the given location.
///
/// - location: location (positional, required)
/// The location at which the state's value should be retrieved. A suitable
@@ -219,7 +219,7 @@ use crate::prelude::*;
/// - returns: any
///
/// ### final()
-/// Get the value of the state at the end of the document.
+/// Gets the value of the state at the end of the document.
///
/// - location: location (positional, required)
/// Can be any location. Why is it required then? As noted before, Typst has