diff options
| author | Laurenz <laurmaedje@gmail.com> | 2023-08-04 15:09:01 +0200 |
|---|---|---|
| committer | Laurenz <laurmaedje@gmail.com> | 2023-08-04 15:46:46 +0200 |
| commit | b8b0137504d388efbe2d1ba5082c0dcabcd8bc8a (patch) | |
| tree | 825abab07230c702bca8efee026d9b98ecfa2aae /crates/typst-library/src/text | |
| parent | 028d2f53085022c39945b1a99c9dc78eb8069d4a (diff) | |
Bytes type
- Moves `Bytes` from `util` to `eval` module
- Accepts bytes in `str` function for bytes -> str conversion
- Adds `bytes` function for str | array -> bytes conversion
- Adds `array` function for bytes -> array conversion
- Adds `len`, `at`, and `slice` methods for bytes
- Adds `encoding` parameter to `read` function
Diffstat (limited to 'crates/typst-library/src/text')
| -rw-r--r-- | crates/typst-library/src/text/raw.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/typst-library/src/text/raw.rs b/crates/typst-library/src/text/raw.rs index 6713f5d0..3d3fff40 100644 --- a/crates/typst-library/src/text/raw.rs +++ b/crates/typst-library/src/text/raw.rs @@ -6,8 +6,8 @@ use once_cell::unsync::Lazy as UnsyncLazy; use syntect::highlighting as synt; use syntect::parsing::{SyntaxDefinition, SyntaxSet, SyntaxSetBuilder}; use typst::diag::FileError; +use typst::eval::Bytes; use typst::syntax::{self, LinkedNode}; -use typst::util::Bytes; use super::{ FontFamily, FontList, Hyphenate, LinebreakElem, SmartQuoteElem, TextElem, TextSize, |
