mirror of
https://github.com/typst/typst
synced 2025-08-12 22:27:56 +08:00
Two small docs improvements
This commit is contained in:
parent
776c6d1923
commit
1e641be5b2
@ -84,13 +84,22 @@ pub struct ImageElem {
|
|||||||
///
|
///
|
||||||
/// ```example
|
/// ```example
|
||||||
/// #image(
|
/// #image(
|
||||||
|
/// read(
|
||||||
|
/// "tetrahedron.svg",
|
||||||
|
/// encoding: none,
|
||||||
|
/// ),
|
||||||
|
/// format: "svg",
|
||||||
|
/// width: 2cm,
|
||||||
|
/// )
|
||||||
|
///
|
||||||
|
/// #image(
|
||||||
/// bytes(range(16).map(x => x * 16)),
|
/// bytes(range(16).map(x => x * 16)),
|
||||||
/// format: (
|
/// format: (
|
||||||
/// encoding: "luma8",
|
/// encoding: "luma8",
|
||||||
/// width: 4,
|
/// width: 4,
|
||||||
/// height: 4,
|
/// height: 4,
|
||||||
/// ),
|
/// ),
|
||||||
/// width: 1cm,
|
/// width: 2cm,
|
||||||
/// )
|
/// )
|
||||||
/// ```
|
/// ```
|
||||||
pub format: Smart<ImageFormat>,
|
pub format: Smart<ImageFormat>,
|
||||||
|
@ -221,7 +221,8 @@ pub enum ExchangeFormat {
|
|||||||
Png,
|
Png,
|
||||||
/// Lossy raster format suitable for photos.
|
/// Lossy raster format suitable for photos.
|
||||||
Jpg,
|
Jpg,
|
||||||
/// Raster format that is typically used for short animated clips.
|
/// Raster format that is typically used for short animated clips. Typst can
|
||||||
|
/// load GIFs, but they will become static.
|
||||||
Gif,
|
Gif,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user