Recent Releases of typst
typst - Version 0.13.1 (March 7, 2025)
View changelog with links into the documentation on typst.app/docs
Command Line Interface
- Fixed high CPU usage for
typst watchon Linux. Depending on the project size, CPU usage would spike for varying amounts of time. This bug appeared with 0.13.0 due to a behavioral change in the inotify file watching backend.
HTML export
- Fixed export of tables with gutters
- Fixed usage of
<html>and<body>element within context - Fixed querying of metadata next to
<html>and<body>element
Visualization
- Fixed curves with multiple non-closed components
Introspection
- Fixed a regression where labelled symbols could not be queried by label
Deprecations
- Fixed false positives in deprecation warnings for type/str comparisons
Contributors
Thanks to everyone who contributed to this release: @7ijme, @Andrew15-5, @Emm54321, @F2011, @MDLC01, @PgBiel, @SharzyL, @aodenis.
- Rust
Published by laurmaedje 12 months ago
typst - Version 0.13.0 (February 19, 2025)
Read the announcement blog post
View changelog with links into the documentation on typst.app/docs
Highlights
- There is now a distinction between proper paragraphs and just inline-level content. This is important for future work on accessibility and means that first line indent can now be enabled for all paragraphs instead of just consecutive ones.
- The
outlinehas a better out-of-the-box look and is more customizable - The new
curvefunction (that supersedes thepathfunction) provides a simpler and more flexible interface for creating Bézier curves - The
imagefunction now supports raw pixel raster formats for generating images from within Typst - Functions that accept file paths now also accept raw bytes, for full flexibility
- WebAssembly plugins are more flexible and automatically run multi-threaded
- Fixed a long-standing bug where single-letter strings in math (
$"a"$) would be displayed in italics - You can now specify which charset should be covered by which font family
- The
pdf.embedfunction lets you embed arbitrary files in the exported PDF - HTML export is currently under active development. The feature is still very incomplete, but already available for experimentation behind a feature flag.
Model
- There is now a distinction between proper paragraphs and just inline-level content (Breaking change)
- All text at the root of a document is wrapped in paragraphs. Meanwhile, text in a container (like a block) is only wrapped in a paragraph if the container holds any block-level content. If all of the content is inline-level, no paragraph is created.
- In the laid-out document, it's not immediately visible whether text became part of a paragraph. However, it is still important for accessibility, HTML export, and for properties like
first-line-indent. - Show rules on
parnow only affect proper paragraphs - The
first-line-indentandhanging-indentproperties also only affect proper paragraphs - Creating a
par[..]with body content that is not fully inline-level will result in a warning - The default show rules of various built-in elements like lists, quotes, etc. were adjusted to ensure they produce/don't produce paragraphs as appropriate
- Removed support for booleans and content in
outline.indent
- The
outlinefunction was fully reworked to improve its out-of-the-box behavior (Breaking change)- Outline entries are now blocks and are thus affected by block spacing
- The
autoindentation mode now aligns numberings and titles outline-wide for a grid-like look - Automatic indentation now also indents entries without a numbering
- Titles wrapping over multiple lines now have hanging indent
- The page number won't appear alone on its own line anymore
- The link now spans the full entry instead of just the title and page number
- The default spacing between outline leader dots was increased
- The
fillparameter was moved fromoutlinetooutline.entryand can thus be configured through show-set rules - Removed
bodyandpagefields from outline entry - Added
indented,prefix,inner,body, andpagemethods on outline entries to simplify writing of show rules
- Added configuration to
par.first-line-indentfor indenting all paragraphs instead of just consecutive ones - Added
formparameter toreffunction. Setting the form to"page"will produce a page reference instead of a textual one. - Added
document.descriptionfield, which results in corresponding PDF and HTML metadata - Added
enum.reversedparameter - Added support for Greek numbering
- When the
linkfunction wraps around a container like a block, it will now generate only one link for the whole block instead of individual links for all the visible leaf elements. This significantly reduces PDF file sizes when combininglinkandrepeat. - The
linkfunction will now only strip one prefix (likemailto:ortel:) instead of multiple - The link function now suppresses hyphenation via a built-in show-set rule rather than through its default show rule
- Displaying the page counter without a specified numbering will now take the page numbering into account
Visualization
- Added new
curvefunction that supersedes thepathfunction and provides a simpler and more flexible interface. Thepathfunction is now deprecated. - The
imagefunction now supports raw pixel raster formats. This can be used to generate images from within Typst without the need for encoding in an image exchange format. - Added
image.scalingparameter for configuring how an image is scaled by PNG export and PDF viewers (smooth or pixelated) - Added
image.iccparameter for providing or overriding the ICC profile of an image - Renamed
patterntotiling. The namepatternremains as a deprecated alias. - Added
gradient.center,gradient.radius,gradient.focal-center, andgradient.focal-radiusmethods - Fixed interaction of clipping and outset on
boxandblock - Fixed panic with
pathof infinite length - Fixed non-solid (e.g. tiling) text fills in clipped blocks
- Fixed a crash for images with a DPI value of zero
- Fixed floating-point error in
gradient.repeat - Auto-detection of image formats from a raw buffer now has support for SVGs
Scripting
- Functions that accept file paths now also accept raw bytes
image,cbor,csv,json,toml,xml, andyamlnow support a path string or bytes and their.decodevariants are deprecatedplugin,bibliography,bibliography.style,cite.style,raw.theme, andraw.syntaxesnow accept bytes in addition to path strings. These did not have.decodevariants, so this adds new flexibility.- The
pathargument/field ofimageandbibliographywas renamed tosourceandsources, respectively (Minor breaking change)
- Improved WebAssembly plugins
- The
plugintype is replaced by apluginfunction that returns a module containing normal Typst functions. This module can be used with import syntax. (Breaking change) - Plugins now automatically run in multiple threads without any changes by plugin authors
- A new
plugin.transitionAPI is introduced which allows plugins to run impure initialization in a way that doesn't break Typst's purity guarantees
- The
- The variable name bound by a bare import (no renaming, no import list) is now determined statically and dynamic imports without
asrenaming (e.g.import "ot" + "her.typ") are a hard error (Breaking change) - Values of the
argumentstype can now be added with+and joined in curly-braced code blocks - Functions in an element function's scope can now be called with method syntax, bringing elements and types closer (in anticipation of a future full unification of the two). Currently, this is only useful for
outline.entryas no other element function defines methods. - Added
calc.normfunction - Added support for 32-bit floats in
float.from-bytesandfloat.to-bytes - The
decimalconstructor now also accepts decimal values - Improved
reprof symbols, arguments, and types - Duplicate symbol variants and modifiers are now a hard error (Breaking change)
Math
- Fixed a bug where single letter strings in math (
$"a"$) would be displayed in italics - Math function calls can now have hyphenated named arguments and support argument spreading
- Better looking accents thanks to support for the
flac(Flattened Accent Forms) anddtls(Dotless Forms) OpenType features - Added
lcmtext operator - The
boldfunction now works with ϝ and Ϝ - The
italicfunction now works with ħ - Fixed a bug where the extent of a math equation was wrongly affected by internal metadata
- Fixed interaction of
lrand context expressions - Fixed weak spacing being unconditionally ignored in
lr - Fixed sub/superscripts sometimes being in the wrong position with
lr - Fixed multi-line annotations (e.g. overbrace) changing the math baseline
- Fixed merging of attachments when the base is a nested equation
- Fixed resolving of contextual (em-based) text sizes within math
- Fixed spacing around up tacks (⊥)
Bibliography
- Prose and author-only citations now use editor names if the author names are unavailable
- Some non-standard but widely used BibLaTeX
editortypes likeproducer,writer,scriptwriter, andnone(defined by widespread stylebiblatex-chicagoto mean performers withinmusicandvideoentries) are now recognized - CSL styles can now render affixes around the bibliography
- For BibTeX entries with
eprinttype = {pubmed}, the PubMed ID will now be correctly processed - Whitespace handling for strings delimiting initialized names has been improved
- Uppercase spelling after apostrophes used as quotation marks is now possible
- Fixed bugs around the handling of CSL delimiting characters
- Fixed a problem with parsing multibyte characters in page ranges that could prevent Hayagriva from parsing some BibTeX page ranges
- Updated CSL APA style
- Updated CSL locales for Finnish, Swiss German, Austrian German, German, and Arabic
Text
- Added support for specifying which charset should be covered by which font family
- Added
allparameter tosmallcapsfunction that also enables small capitals on uppercase letters - Added basic i18n for Basque and Bulgarian
- Justification does not affect raw blocks anymore
- CJK-Latin-spacing does not affect raw text anymore
- Fixed wrong language codes being used for Greek and Ukrainian
- Fixed default quotes for Croatian and Bulgarian
- Fixed crash in RTL text handling
- Added support for
rawsyntax highlighting for a few new languages: CFML, NSIS, and WGSL - New font metadata exception for New Computer Modern Sans Math
- Updated bundled New Computer Modern fonts to version 7.0.1
Layout
- Fixed various bugs with footnotes
- Fixed footnotes getting lost when multiple footnotes were nested within another footnote
- Fixed endless loops with empty and overlarge footnotes
- Fixed crash with overlarge footnotes within a floating placement
- Fixed sizing of quadratic shapes (
squareandcircle) - Fixed
block.stickynot working properly at the top of a container - Fixed crash due to consecutive weak spacing
- Fixed crash when a block or text have negative sizes
- Fixed unnecessary hyphenations occurring in rare scenarios due to a bad interaction between padding and paragraph optimization
- Fixed lone citations in
alignnot becoming their own paragraph
Syntax
- Top-level closing square brackets that do not have a matching opening square bracket are now a hard error (Minor breaking change)
- Adding a space between the identifier and the parentheses in a set rule is not allowed anymore (Minor breaking change)
- Numbers with a unit cannot have a base prefix anymore, e.g.
0b100000ptis not allowed anymore. Previously, it was syntactically allowed but always resolved to a value of zero. (Minor breaking change) - Using
isas an identifier will now warn as it might become a keyword in the future - Fixed minor whitespace handling bugs
- in math mode argument lists
- at the end of headings
- between a term list's term and description
- Fixed parsing of empty single line raw blocks with 3+ backticks and a language tag
- Fixed minor bug with parentheses parsing in math
- Markup that can only appear at the start of the line (headings, lists) can now also appear at the start of a list item
- A shebang
#!at the very start of a file is now ignored
PDF export
- Added
pdf.embedfunction for embedding arbitrary files in the exported PDF - Added support for PDF/A-3b export
- The PDF timestamp will now contain the timezone by default
HTML export
Note: HTML export is currently under active development. The feature is still very incomplete, but already available for experimentation behind a feature flag.
- Added HTML output support for some (but not all) of the built-in elements
- Added
html.elemfunction for outputting an arbitrary HTML element - Added
html.framefunction for integrating content that requires layout into HTML (by embedding an SVG) - Added
targetfunction which returns either"paged"or"html"depending on the export target
Tooling and Diagnostics
- Autocompletion improvements
- Added autocompletion for file paths
- Smarter autocompletion of variables: Completing
rect(fill: |)will now only show variables which contain a valid fill (either directly or nested, e.g. a dictionary containing a valid fill) - Different functions will now autocomplete with different brackets (round vs square) depending on which kind is more useful
- Positional parameters which are already provided aren't autocompleted again anymore
- Fixed variable autocompletion not considering parameters
- Added autocompletion snippets for common figure usages
- Fixed autocompletion after half-completed import item
- Fixed autocompletion for
citefunction
- Added warning when an unconditional return in a code block discards joined content
- Fixed error message when accessing non-existent label
- Fixed handling of nested imports in IDE functionality
Command Line Interface
- Added
--featuresargument andTYPST_FEATURESenvironment variable for opting into experimental features. The only feature so far ishtml. - Added a live reloading HTTP server to
typst watchwhen targeting HTML - Fixed self-update not being aware about certain target architectures
- Fixed crash when piping
typst fontsoutput to another command - Fixed handling of relative paths in
--make-depsoutput - Fixed handling of multipage SVG and PNG export in
--make-depsoutput - Colons in filenames are now correctly escaped in
--make-depsoutput
Symbols
- New
inter,inter.and,inter.big,inter.dot,inter.double,inter.sq,inter.sq.big,inter.sq.double,integral.interasymp,asymp.notmapsto,mapsto.longdivides.not.rev,divides.struckinterleave,interleave.big,interleave.struckeq.triple.not,eq.dots,eq.dots.down,eq.dots.upsmt,smt.eq,lat,lat.eqcolon.tri,colon.tri.opdagger.triple,dagger.l,dagger.r,dagger.invhourglass.stroked,hourglass.filleddie.six,die.five,die.four,die.three,die.two,die.oneerrorbar.square.stroked,errorbar.square.filled,errorbar.diamond.stroked,errorbar.diamond.filled,errorbar.circle.stroked,errorbar.circle.fillednumeroOmega.inv
- Renamed
ohm.invtoOmega.inv
- Changed codepoint (Breaking change)
angle.l.doublefrom《to⟪angle.r.doublefrom》to⟫angstromfrom U+212B (Å) to U+00C5 (Å)
- Deprecated
sectand all its variants in favor ofinterintegral.sectin favor ofintegral.inter
- Removed (Breaking change)
degree.cin favor of°C($upright(°C)$or$upright(degree C)$in math)degree.fin favor of°F($upright(°F)$or$upright(degree F)$in math)kelvinin favor of just K ($upright(K)$in math)
Deprecations
- The
pathfunction in favor of thecurvefunction - The name
patternfor tiling patterns in favor of the new nametiling image.decode,cbor.decode,csv.decode,json.decode,toml.decode,xml.decode,yaml.decodein favor of the top-level functions directly accepting both paths and bytes- The
sectand its variants in favor ofinter, andintegral.sectin favor ofintegral.inter - The compatibility behavior of type/str comparisons (e.g.
int == "integer") which was temporarily introduced in Typst 0.8 now emits warnings. It will be removed in Typst 0.14.
Removals
- Removed
stylefunction andstylesargument ofmeasure, use a context expression instead (Breaking change) - Removed
state.displayfunction, usestate.getinstead (Breaking change) - Removed
locationargument ofstate.at,counter.at, andquery(Breaking change) - Removed compatibility behavior where
counter.displayworked without context (Breaking change) - Removed compatibility behavior of
locate(Breaking change)
Development
- The
typst::compilefunction is now generic and can return either aPagedDocumentor anHtmlDocument typst-timingnow supports WebAssembly targets viaweb-syswhen thewasmfeature is enabled- Increased minimum supported Rust version to 1.80
- Fixed linux/arm64 Docker image
Contributors
Thanks to everyone who contributed to this release: @wrzian, @mkorje, @MDLC01, @PgBiel, @bluebear94, @01mf02, @EpicEricEE, @Andrew15-5, @wznmickey, @Coekjan, @jbirnick, @Dherse, @joshuagawley, @Myriad-Dreamin, @NiklasEi, @TwoF1nger, @frozolotl, @swaits, @3w36zj6, @Carbophile, @Drodt, @Emm54321, @Eric-Song-Nop, @Garmelon, @HydroH, @LaurenzV, @LuxxxLucy, @Orange149, @OverflowCat, @SekoiaTree, @SelfMadeSystem, @SkiFire13, @T0mstone, @Tetragramm, @Toafu, @arbrauns, @asibahi, @bbb651, @cskeeters, @dginev, @elegaanz, @escwxyz, @freundTech, @fynsta, @hongjr03, @iagobaapellaniz, @jakobjpeters, @jsoref, @lucaslugao, @mtoohey31, @nineff, @peng1999, @quachpas, @wzf03, @xkevio.
- Rust
Published by laurmaedje about 1 year ago
typst - Version 0.13.0, Release Candidate 1 (February 5, 2025)
For a preliminary 0.13 changelog, see https://staging.typst.app/docs/changelog/0.13.0
- Rust
Published by laurmaedje about 1 year ago
typst - Version 0.12.0 (October 18, 2024)
View changelog with links into the documentation on typst.app/docs
Highlights
- Added support for multi-column floating placement and figures
- Added support for automatic line numbering (often used in academic papers)
- Typst's layout engine is now multithreaded. Typical speedups are 2-3x for larger documents. The multithreading operates on page break boundaries, so explicit page breaks are necessary for it to kick in.
- Paragraph justification was optimized with a new two-pass algorithm. Speedups are larger for shorter paragraphs and go up to 6x.
- Highly reduced PDF file sizes due to better font subsetting (thanks to @LaurenzV)
- Emoji are now exported properly in PDF
- Added initial support for PDF/A. For now, only the PDF/A-2b profile is supported, but more is planned for the future.
- Added various options for configuring the CLI's environment (fonts, package paths, etc.)
- Text show rules now match across multiple text elements
- Block-level equations can now optionally break over multiple pages
- Fixed a bug where some fonts would not print correctly on professional printers
- Fixed a long-standing bug which could cause headings to be orphaned at the bottom of the page
Layout
- Added support for multi-column floating placement and figures via
place.scopeandfigure.scope. Two-column documents should now preferset page(columns: 2)overshow: column.with(2)(see the page setup guide). - Added support for automatic line numbering (often used in academic papers)
- Added
par.spacingproperty for configuring paragraph spacing. This should now be used instead ofshow par: set block(spacing: ..)(Breaking change) - Block-level elements like lists, grids, and stacks now show themselves as blocks and are thus affected by all block properties (e.g.
stroke) rather than justspacing(Breaking change) - Added
block.stickyproperty which prevents a page break after a block - Added
place.flushfunction which forces all floating figures to be placed before any further content - Added
skewfunction - Added
autooption forpage.headerandpage.footerwhich results in an automatic header/footer based on the numbering (which was previously inaccessible after a change) - Added
gapandjustifyparameters torepeatfunction - Added
widthandheightparameters to themeasurefunction to define the space in which the content should be measured. Especially useful in combination withlayout. - The height of a
block,image,rect,square,ellipse, orcirclecan now be specified in fractional units - The
scalefunction now supports absolute lengths forx,y,factor. This way an element of unknown size can be scaled to a fixed size. - The values of
block.aboveandblock.belowcan now be retrieved in context expressions. - Increased accuracy of conversions between absolute units (pt, mm, cm, in)
- Fixed a bug which could cause headings to be orphaned at the bottom of the page
- Fixed footnotes within breakable blocks appearing on the page where the breakable block ends instead of at the page where the footnote marker is
- Fixed numbering of nested footnotes and footnotes in floats
- Fixed empty pages appearing when a context expression wraps whole pages
- Fixed
set block(spacing: x)behaving differently fromset block(above: x, below: x) - Fixed behavior of
rotateandscalewithreflow: true - Fixed interaction of
align(horizon)andv(1fr) - Fixed various bugs where floating placement would yield overlapping results
- Fixed a bug where widow/orphan prevention would unnecessarily move text into the next column
- Fixed weak spacing not being trimmed at the start and end of lines in a paragraph (only at the start and end of paragraphs)
- Fixed interaction of weak page break and
pagebreak.to - Fixed compilation output of a single weak page break
- Fixed crash when padding by
100%
Text
- Tuned hyphenation: It is less eager by default and hyphenations close to the edges of words are now discouraged more strongly (May lead to larger layout reflows)
- New default font: Libertinus Serif. This is the maintained successor to the old default font Linux Libertine. (May lead to smaller reflows)
- Setting the font to an unavailable family will now result in a warning
- Implemented a new smart quote algorithm, fixing various bugs where smart quotes weren't all that smart
- Added
text.costsparameter for tweaking various parameters that affect the choices of the layout engine during text layout - Added
typmhighlighting mode for math in raw blocks - Added basic i18n for Galician, Catalan, Latin, Icelandic, Hebrew
- Implemented hyphenation duplication for Czech, Croatian, Lower Sorbian, Polish, Portuguese, Slovak, and Spanish.
- The
smallcapsfunction is now an element function and can thereby be used in show(-set) rules. - The
raw.themeparameter can now be set tononeto disable highlighting even in the presence of a language tag, and toautoto reset to the default - Multiple stylistic sets can now be enabled at once
- Fixed the Chinese translation for "Equation"
- Fixed that hyphenation could occur outside of words
- Fixed incorrect layout of bidirectional text in edge cases
- Fixed layout of paragraphs with explicit trailing whitespace
- Fixed bugs related to empty paragraphs created via
#"" - Fixed accidental trailing spaces for line breaks immediately preceding an inline equation
- Fixed
text.historical-ligaturesnot working correctly - Fixed accidental repetition of Thai characters around line breaks in some circumstances
- Fixed smart quotes for Swiss French
- New font metadata exceptions for Archivo, Kaiti SC, and Kaiti TC
- Updated bundled New Computer Modern fonts to version 6.0
Math
- Block-level equations can now break over multiple pages if enabled via
show math.equation: set block(breakable: true). - Matrix and vector sizing is now more consistent across different cell contents
- Added
stretchfunction for manually or automatically stretching characters like arrows or parentheses horizontally or vertically - Improved layout of attachments on parenthesized as well as under- or overlined expressions
- Improved layout of nested attachments resulting from code like
#let a0 = $a_0$; $a0^1$ - Improved layout of primes close to superscripts
- Improved layout of fractions
- Typst now makes use of math-specific height-dependent kerning information in some fonts for better attachment layout
- The
floorandceilfunctions in math are now callable symbols, such that$ floor(x) = lr(floor.l x floor.r) $ - The
mat.delim,vec.delim, andcases.delimparameters now allow any character that is considered a delimiter or "fence" (e.g. |) by Unicode. Thedelim: "||"notation is not supported anymore and should be replaced bydelim: bar.double(Minor breaking change) - Added
vec.alignandmat.alignparameters - Added
underparen,overparen,undershell, andovershell - Added
~shorthand fortilde.opin math mode (Minor breaking change) - Fixed baseline alignment of equation numbers
- Fixed positioning of corner brackets (⌜, ⌝, ⌞, ⌟)
- Fixed baseline of large roots
- Fixed multiple minor layout bugs with attachments
- Fixed that alignment points could affect line height in math
- Fixed that spaces could show up between text and invisible elements like
metadatain math - Fixed a crash with recursive show rules in math
- Fixed
lr.sizenot affecting characters enclosed inmidin some cases - Fixed resolving of em units in sub- and superscripts
- Fixed bounding box of inline equations when a text edge is set to
"bounds"
Introspection
- Implemented a new system by which Typst tracks where elements end up on the pages. This may lead to subtly different behavior in introspections. (Breaking change)
- Fixed various bugs with wrong counter behavior in complex layout situations, through a new, more principled implementation
- Counter updates can now be before the first, in between, and after the last page when isolated by weak page breaks. This allows, for instance, updating a counter before the first page header and background.
- Fixed logical ordering of introspections within footnotes and figures
- Fixed incorrect
here().position()whenplacewas used in a context expression - Fixed resolved positions of elements (in particular, headings) whose show rule emits an invisible element (like a state update) before a page break
- Fixed behavior of stepping a counter at a deeper level than its current state has
- Fixed citation formatting not working in table headers and a few other places
- Displaying the footnote counter will now respect the footnote numbering style
Model
- Document set rules do not need to be at the very start of the document anymore. The only restriction is that they must not occur inside of layout containers.
- The
spacingproperty of lists, enumerations, and term lists is now also respected for tight lists - Tight lists now only attach (with tighter spacing) to preceding paragraphs, not arbitrary blocks
- The
quoteelement is now locatable (can be used in queries) - The bibliography heading now uses
depthinstead oflevelso that its level can still be configured via a show-set rule - Added support for more numbering formats: Devanagari, Eastern Arabic, Bengali, and circled numbers
- Added
hanging-indentparameter to heading function to tweak the appearance of multi-line headings and improved default appearance of multi-line headings - Improved handling of bidirectional text in outline entry
- Fixed document set rules being ignored in an otherwise empty document
- Fixed document set rules not being usable in context expressions
- Fixed bad interaction between
set documentandset page - Fixed
show figure: set align(..). Since the default figure alignment is now a show-set rule, it is not revoked byshow figure: it => it.bodyanymore. (Minor breaking change) - Fixed numbering of footnote references
- Fixed spacing after bibliography heading
Bibliography
- The Hayagriva YAML
publisherfield can now accept a dictionary with alocationkey. The top-levellocationkey is now primarily intended for event and item locations. - Multiple page ranges with prefixes and suffixes are now allowed
- Added
directorand catch-all editor types to BibLaTeX parsing - Added support for disambiguation to alphanumeric citation style
- The year 0 will now render as 1BC
- Fixes for sorting of bibliography entries
- Fixed pluralization of page range labels
- Fixed sorting of citations by their number
- Fixed how citation number ranges collapse
- Fixed when the short form of a title is used
- Fixed parsing of unbalanced dollars in BibLaTeX
urlfield - Updated built-in citation styles
Visualization
- Added
fill-ruleparameter topathandpolygonfunctions - Fixed color mixing and gradients for Luma colors
- Fixed conversion from Luma to CMYK colors
- Fixed offset gradient strokes in PNG export
- Fixed unintended cropping of some SVGs
- SVGs with foreign objects now produce a warning as they will likely not render correctly in Typst
Syntax
- Added support for nested imports like
import "file.typ": module.item - Added support for parenthesized imports like
import "file.typ": (a, b, c). With those, the import list can break over multiple lines. - Fixed edge case in parsing of reference syntax
- Fixed edge case in parsing of heading, list, enum, and term markers immediately followed by comments
- Fixed rare crash in parsing of parenthesized expressions
Scripting
- Added new fixed-point
decimalnumber type for highly precise arithmetic on numbers in base 10, as needed for finance - Added
stdmodule for accessing standard library definitions even when a variable with the same name shadows/overwrites it - Added
array.to-dict,array.reduce,array.windowsmethods - Added
exactargument toarray.zip - Added
arguments.atmethod - Added
int.from-bytes,int.to-bytes,float.from-bytes, andfloat.to-bytes - Added proper support for negative values of the
digitsparameter ofcalc.round(the behaviour existed before but was subtly broken) - Conversions from
inttofloatwill now error instead of saturating if the float is too large (Minor breaking change) - Added
float.nanandfloat.inf, removedcalc.nan(Minor breaking change) - Certain symbols are now generally callable like functions and not only specifically in math. Examples are accents or
floorandceil. - Improved
reprof relative values, sequences, infinities, NaN,type(none)andtype(auto) - Fixed crash on whole packages (rather than just files) cyclically importing each other
- Fixed return type of
calc.roundon integers when a non-zero value is provided fordigits
Styling
- Text show rules now match across multiple text elements
- The string
"in a text show rule now matches smart quotes - Fixed a long-standing styling bug where the header and footer would incorrectly inherit styles from a lone element on the page (e.g. a heading)
- Fixed
set pagenot working directly after a counter/state update - Page fields configured via an explicit
page(..)[..]call can now be properly retrieved in context expressions
Export
- Highly reduced PDF file sizes due to better font subsetting
- Emoji are now exported properly in PDF
- Added initial support for PDF/A. For now, only the standard PDF/A-2b is supported, but more is planned for the future. Enabled via
--pdf-standard a-2bin the CLI and via the UI in File > Export as > PDF in the web app. - Setting
page.filltononewill now lead to transparent pages instead of white ones in PNG and SVG. The new default ofautomeans transparent for PDF and white for PNG and SVG. - Improved text copy-paste from PDF in complex scenarios
- Exported SVGs now contain the
data-typst-labelattribute on groups resulting from labelled boxes and blocks - Fixed a bug where some fonts would not print correctly on professional printers
- Fixed a bug where transparency could leak from one PDF object to another
- Fixed a bug with CMYK gradients in PDF
- Fixed various bugs with export of Oklab gradients in PDF
- Fixed crashes related to rendering of non-outline glyphs
- Two small fixes for PDF standard conformance
Performance
- Typst's layout engine is now multithreaded. Typical speedups are 2-3x for larger documents. The multithreading operates on page break boundaries, so explicit page breaks are necessary for it to kick in.
- Paragraph justification was optimized with a new two-pass algorithm. Speedups are larger for shorter paragraphs and range from 1-6x.
Command Line Interface
- Added
--pagesoption to select specific page ranges to export - Added
--package-pathand--package-cache-pathas well asTYPST_PACKAGE_PATHandTYPST_PACKAGE_CACHE_PATHenvironment variables for configuring where packages are loaded from and cached in, respectively - Added
--ignore-system-fontsflag to disable system fonts fully for better reproducibility - Added
--make-depsargument for outputting the dependencies of the current compilation as a Makefile - Added
--prettyoption totypst query, with the default now being to minify (only applies to JSON format) - Added
--backup-pathtotypst updateto configure where the previous version is backed up - Added useful links to help output
- The CLI will now greet users who invoke just
typstfor the first time - The document can now be written to stdout by passing
-as the output filename (for PDF or single-page image export) - Typst will now emit a proper error message instead of failing silently when the certificate specified by
--certorTYPST_CERTcould not be loaded - The CLI now respects the
SOURCE_DATE_EPOCHenvironment variable for better reproducibility - When exporting multiple images, you can now use
t(total pages),p(current page), and0p(zero-padded current page, same as currentn) in the output path - The input and output paths now allow non-UTF-8 values
- Times are now formatted more consistently across the CLI
- Fixed a bug related to the
--openflag - Fixed path completions for
typstnot working in zsh
Tooling and Diagnostics
- The "compiler" field for specifying the minimum Typst version required by a package now supports imprecise bounds like 0.11 instead of 0.11.0
- Added warning when a label is ignored by Typst because no preceding labellable element exists
- Added hint when trying to apply labels in code mode
- Added hint when trying to call a standard library function that has been shadowed/overwritten by a local definition
- Added hint when trying to set both the language and the region in the
langparameter - Added hints when trying to compile non-Typst files (e.g. after having typed
typst c file.pdfby accident) - Added hint when a string is used where a label is expected
- Added hint when a stray end of a block comment (
*/) is encountered - Added hints when destructuring arrays with the wrong number of elements
- Improved error message when trying to use a keyword as an identifier in a let binding
- Improved error messages when accessing nonexistent fields
- Improved error message when a package exists, but not the specified version
- Improved hints for unknown variables
- Improved hint when trying to convert a length with non-zero em component to an absolute unit
- Fixed a crash that could be triggered by certain hover tooltips
- Fixed an off-by-one error in to-source jumps when first-line-indent is enabled
- Fixed suggestions for
.after the end of an inline code expressions - Fixed autocompletions being duplicated in a specific case
Symbols
- New:
parallelogram,original,image,crossmark,rest,natural,flat,sharp,tiny,miny,copyleft,trademark,emoji.beet,emoji.fingerprint,emoji.harp,emoji.shovel,emoji.splatter,emoji.tree.leafless, - New variants:
club.stroked,diamond.stroked,heart.stroked,spade.stroked,gt.neq,lt.neq,checkmark.heavy,paren.double,brace.double,shell.double,arrow.turn,plus.double,plus.triple,infinity.bar,infinity.incomplete,infinity.tie,multimap.double,ballot.check,ballot.check.heavy,emptyset.bar,emptyset.circle,emptyset.arrow.l,emptyset.arrow.r,parallel.struck,parallel.eq,parallel.equiv,parallel.slanted,parallel.tilde,angle.l.curly,angle.l.dot,angle.r.curly,angle.r.dot,angle.oblique,angle.s,em.two,em.three - Renamed:
turtletoshell,notestonote,ballot.xtoballot.cross,succ.eqtosucc.curly.eq,prec.eqtoprec.curly.eq,servicemarktotrademark.service,emoji.face.tiredtoemoji.face.distress(Breaking change) - Changed codepoint:
prec.eq,prec.neq,succ.eq,succ.neq,trianglefrom ▷ to △,emoji.face.tired(Breaking change) - Removed:
lt.curlyin favor ofprec,gt.curlyin favor ofsucc(Breaking change)
Deprecations
counter.displaywithout an established contextcounter.finalwith a locationstate.finalwith a locationstate.displayquerywith a location as the second argumentlocatewith a callback functionmeasurewith stylesstyle
Development
- Added
typst-kitcrate which provides useful APIs forWorldimplementors - Added go-to-definition API in
typst-ide - Added package manifest parsing APIs to
typst-syntax - As the compiler is now capable of multithreading,
Worldimplementations must satisfySendandSync - Changed signature of
World::mainto allow for the scenario where the main file could not be loaded - Removed
Tracerin favor ofWarned<T>andtypst::tracefunction - The
xz2dependency used by the self-updater is now statically linked - The Dockerfile now has an
ENTRYPOINTdirective
Contributors
Thanks to everyone who contributed to this release: @Leedehai, @MDLC01, @Coekjan, @bluebear94, @mkorje, @EpicEricEE, @PgBiel, @frozolotl, @elegaanz, @Dherse, @knuesel, @Andrew15-5, @Enter-tainer, @LaurenzV, @Myriad-Dreamin, @rikhuijzer, @ssotoen, @tingerrr, @FlorentCLMichel, @T0mstone, @drupol, @emilyyyylime, @A-Walrus, @LuizAugustoPapa, @PepinhoJp, @freundTech, @gabriel-araujjo, @istudyatuni, @jbirnick, @jsoref, @mattfbacon, @mtoohey31, @nz366, @omniwrench, @shinyfelix, @tulio240, @3w36zj6, @AnarchistHoneybun, @Bzero, @Heinenen, @HydroH, @JHenneberg, @Jacobgarm, @Jocs, @JonPichel, @JustForFun88, @LingkKang, @Lucy-73, @LuxxxLucy, @NiklasEi, @Orange149, @QuarticCat, @SillyFreak, @T1mVo, @Tom4sCruz, @UARTman, @YDX-2147483647, @aaron-jack-manning, @arbrauns, @astrale-sharp, @bk, @chicoferreira, @ctmbl, @danielfleischer, @etiennecollin, @flauschpantoffel, @fynsta, @giannissc, @haenoe, @hardlydearly, @hettlage, @huajingyun01, @inferiorhumanorgans, @jakobjpeters, @jiricekcz, @joserlopes, @kamack38, @kimushun1101, @kravchenkoloznia, @matze, @niklasmohrin, @nishanthkarthik, @nixon-voxell, @saecki, @unclebean, @waywardmonkeys, @wrzian, @zombiepigdragon.
- Rust
Published by laurmaedje over 1 year ago
typst - Version 0.12.0, Release Candidate 2 (October 15, 2024)
View changes since RC1.
- Rust
Published by laurmaedje over 1 year ago
typst - Version 0.12.0, Release Candidate 1 (October 3, 2024)
For a preliminary 0.12 changelog, see https://staging.typst.app/docs/changelog
- Rust
Published by laurmaedje over 1 year ago
typst - Version 0.11.1 (May 17, 2024)
Security
- Fixed a vulnerability where image files at known paths could be embedded into the PDF even if they were outside of the project directory
Bibliography
- Fixed et-al handling in subsequent citations
- Fixed suppression of title for citations and bibliography references with no author
- Fixed handling of initials in citation styles without a delimiter
- Fixed bug with citations in footnotes
Text and Layout
- Fixed interaction of
first-line-indentandoutline - Fixed compression of CJK punctuation marks at line start and end
- Fixed handling of rectangles with negative dimensions
- Fixed layout of
pathin explicitly sized container - Fixed broken
rawtext in right-to-left paragraphs - Fixed tab rendering in
rawtext with languagetyportypc - Fixed highlighting of multi-line
rawtext enclosed by single backticks - Fixed indentation of overflowing lines in
rawblocks - Fixed extra space when
rawtext ends with a backtick
- Fixed interaction of
Math
- Fixed broken equations in right-to-left paragraphs
- Fixed missing blackboard bold letters
- Fixed error on empty arguments in 2D math argument list
- Fixed stretching via
midfor various characters - Fixed that alignment points in equations were affected by
set align(..)
Export
- Fixed smart quotes in PDF outline
- Fixed patterns with spacing in PDF
- Fixed wrong PDF page labels when page numbering was disabled after being previously enabled
Scripting
- Fixed overflow for large numbers in external data files (by converting to floats instead)
- Fixed
str.trim(regex, at: end)when the whole string is matched
Miscellaneous
- Fixed deformed strokes for specific shapes and thicknesses
- Fixed newline handling in code mode: There can now be comments within chained method calls and between an
ifbranch and theelsekeyword - Fixed inefficiency with incremental reparsing
- Fixed autocompletions for relative file imports
- Fixed crash in autocompletion handler
- Fixed a bug where the path and entrypoint printed by
typst initwere not properly escaped - Fixed various documentation errors
Thanks to everyone who contributed to this release: @Leedehai, @elegaanz, @frozolotl, @A-Walrus, @MDLC01, @Myriad-Dreamin, @3w36zj6, @Enter-tainer, @EpicEricEE, @Jocs, @PgBiel, @QuarticCat, @Tom4sCruz, @bluebear94, @etiennecollin, @gabriel-araujjo, @joserlopes, @rikhuijzer, @wrzian.
- Rust
Published by laurmaedje almost 2 years ago
typst - Version 0.11.0 (March 15, 2024)
View changelog with more links on typst.app
Tables (thanks to @PgBiel)
- Tables are now much more flexible, read the new table guide to get started
- Added
table.cellelement for per-cell configuration - Cells can now span multiple columns or rows
- The stroke of individual cells can now be customized
- The
alignandinsetarguments of the table function now also take(x, y) => ..functions - Added
table.hlineandtable.vlinefor convenient line customization - Added
table.headerelement for table headers that repeat on every page - Added
table.footerelement for table footers that repeat on every page - All the new table functionality is also available for grids
- Fixed gutter-related bugs
Templates
- You can now use template packages to get started with new projects. Click Start from template on the web app's dashboard and choose your preferred template or run the
typst init <template>command in the CLI. You can browse the available templates here. - Switching templates after the fact has become easier. You can just import a styling function from a different template package.
- Package authors can now submit their own templates to the package repository. Share a template for a paper, your institution, or an original work to help the community get a head start on their projects.
- Templates and packages are now organized by category and discipline. Filter packages by either taxonomy in the Start from template wizard. If you are a package author, take a look at the new documentation for categories and disciplines.
- You can now use template packages to get started with new projects. Click Start from template on the web app's dashboard and choose your preferred template or run the
Context
- Added context expressions: Read the chapter on context to get started
- With context, you can access settable properties, e.g.
context text.langto access the language set viaset text(lang: "..") - The following existing functions have been made contextual:
query,locate,measure,counter.display,counter.at,counter.final,state.at, andstate.final - Added contextual methods
counter.getandstate.getto retrieve the value of a counter or state in the current context - Added contextual function
hereto retrieve the location of the current context - The
locatefunction now returns the location of a selector's unique match. Its old behavior has been replaced by context expressions and only remains temporarily available for compatibility. - The
counter.atandstate.atmethods are now more flexible: They directly accept any kind of locatable selector with a unique match (e.g. a label) instead of just locations - When context is available,
counter.displaynow directly returns the result of applying the numbering instead of yielding opaque content. It should not be used anymore without context. (Deprecation planned) - The
state.displayfunction should not be used anymore, usestate.getinstead (Deprecation planned) - The
locationargument ofquery,counter.final, andstate.finalshould not be used anymore (Deprecation planned) - The
stylesargument of themeasurefunction should not be used anymore (Deprecation planned) - The
stylefunction should not be used anymore, use context instead (Deprecation planned) - The correct context is now also provided in various other places where it is available, e.g. in show rules, layout callbacks, and numbering functions in the outline
Styling
- Fixed priority of multiple show-set rules: They now apply in the same order as normal set rules would
- Show-set rules on the same element (e.g.
show heading.where(level: 1): set heading(numbering: "1.")) now work properly - Setting properties on an element within a transformational show rule (e.g.
show heading: it => { set heading(..); it }) is not supported anymore (previously it also only worked sometimes); use show-set rules instead (Breaking change) - Text show rules that match their own output now work properly (e.g.
show "cmd": `cmd`) - The elements passed to show rules and returned by queries now contain all fields of their respective element functions rather than just specific ones
- All settable properties can now be used in where selectors
- And and or selectors can now be used with show rules
- Errors within show rules and context expressions are now ignored in all but the last introspection iteration, in line with the behavior of the old
locate - Fixed a bug where document set rules were allowed after content
Layout
- Added
reflowargument torotateandscalewhich lets them affect the layout - Fixed a bug where floating placement or floating figures could end up out of order
- Fixed overlap of text and figure for full-page floating figures
- Fixed various cases where the
hidefunction didn't hide its contents properly - Fixed usage of
handvin stacks - Invisible content like a counter update will no longer force a visible block for just itself
- Fixed a bug with horizontal spacing followed by invisible content (like a counter update) directly at the start of a paragraph
- Added
Text
- Added
strokeproperty for text - Added basic i18n for Serbian and Catalan
- Added support for contemporary Japanese numbering method
- Added patches for various wrong metadata in specific fonts
- The text direction can now be overridden within a paragraph
- Fixed Danish smart quotes
- Fixed font fallback next to a line break
- Fixed width adjustment of JIS-style Japanese punctuation
- Fixed Finnish translation of "Listing"
- Fixed Z-ordering of multiple text decorations (underlines, etc.)
- Fixed a bug due to which text features could not be overridden in consecutive set rules
- Added
Model
- Added
depthandoffsetarguments to heading to increase or decrease the heading level for a bunch of content; the heading syntax now setsdepthrather thanlevel(Breaking change) - List markers) now cycle by default
- The
quotefunction now more robustly selects the correct quotes based on language and nesting - Fixed indent bugs related to the default show rule of terms
- Added
Math
- Inline equations now automatically linebreak at appropriate places
- Added
number-alignargument to equations - Added support for adjusting the
sizeof accents relative to their base - Improved positioning of accents
- Primes are now always attached as scripts by default
- Exposed
math.primeselement which backs the$f'$syntax in math - Math mode is not affected by
strongandemphanymore - Fixed
attachunder fractions - Fixed that
math.classdid not affect smart limit placement - Fixed weak spacing in
lrgroups - Fixed layout of large operators for Cambria Math font
- Fixed math styling of Hebrew symbol codepoints
Symbols
- Added
gradientas an alias fornabla - Added
partialas an alias fordiff,diffwill be deprecated in the future - Added
colon.double,gt.approx,gt.napprox,lt.approx, andlt.napprox - Added
arrow.r.tildeandarrow.l.tilde - Added
tilde.dot - Added
forcesandforces.not - Added
space.nobreak.narrow - Added
lrm(Left-to-Right Mark) andrlm(Right-to-Left Mark) - Fixed
star.strokedsymbol (which previously had the wrong codepoint)
- Added
Scripting
- Arrays can now be compared lexicographically
- Added contextual method
to-absoluteto lengths - Added
calc.root - Added
int.signumandfloat.signummethods - Added
float.is-nanandfloat.is-infinitemethods - Added
int.bit-not,int.bit-and,int.bit-or,int.bit-xor,int.bit-lshift, andint.bit-rshiftmethods - Added
array.chunksmethod - A module can now be converted to a dictionary with the dictionary constructor to access its contents dynamically
- Added
row-typeargument tocsvfunction to configure how rows will be represented - XML parsing now allows DTDs (document type definitions)
- Improved formatting of negative numbers with
strandrepr - For loops can now iterate over bytes
- Fixed a bug with pattern matching in for loops
- Fixed a bug with labels not being part of
.fields()dictionaries - Fixed a bug where unnamed argument sinks wouldn't capture excess arguments
- Fixed typo in
reproutput of strokes
Syntax
- Added support for nested destructuring patterns
- Special spaces (like thin or non-breaking spaces) are now parsed literally instead of being collapsed into normal spaces (Breaking change)
- Korean text can now use emphasis syntax without adding spaces (Breaking change)
- The token
contextis now a keyword and cannot be used as an identifier anymore (Breaking change) - Nested line comments aren't allowed anymore in block comments (Breaking change)
- Fixed a bug where
x.)would be treated as a field access - Text elements can now span across curly braces in markup
- Fixed silently wrong parsing when function name is parenthesized
- Fixed various bugs with parsing of destructuring patterns, arrays, and dictionaries
Tooling & Diagnostics
- Click-to-jump now works properly within
rawtext - Added suggestion for accessing a field if a method doesn't exist
- Improved hint for calling a function stored in a dictionary
- Improved errors for mutable accessor functions on arrays and dictionaries
- Fixed error message when calling constructor of type that doesn't have one
- Fixed confusing error message with nested dictionaries for strokes on different sides
- Fixed autocompletion for multiple packages with the same name from different namespaces
- Click-to-jump now works properly within
Visualization
- The
imagefunction doesn't upscale images beyond their natural size anymore - The
imagefunction now respects rotation stored in EXIF metadata - Added support for SVG filters
- Added alpha component to
lumacolors - Added
color.transparentizeandcolor.opacifymethods - Improved
color.negatefunction - Added
strokeandradiusarguments tohighlightfunction - Changed default
highlightcolor to be transparent - CMYK to RGB conversion is now color-managed
- Fixed crash with gradients in Oklch color space
- Fixed color-mixing for hue-based spaces
- Fixed bugs with color conversion
- SVG sizes are not rounded anymore, preventing slightly wrong aspect ratios
- Fixed a few other SVG-related bugs
color.componentsdoesn't round anything anymore
- The
Export
- PDFs now contain named destinations for headings derived from their labels
- The internal PDF structure was changed to make it easier for external tools to extract or modify individual pages, avoiding a bug with Typst PDFs in Apple Preview
- PDFs produced by Typst should now be byte-by-byte reproducible when
set document(date: none)is set - Added missing flag to PDF annotation
- Fixed multiple bugs with gradients in PDF export
- Fixed a bug with patterns in PDF export
- Fixed a bug with embedding of grayscale images in PDF export
- Fixed a bug with To-Unicode mapping of CFF fonts in PDF export
- Fixed a bug with the generation of the PDF outline
- Fixed a sorting bug in PDF export leading to non-reproducible output
- Fixed a bug with transparent text in PNG export
- Exported SVG files now include units in their top-level
widthandheight
Command line interface
- Added support for passing inputs via a CLI flag
- When passing the filename
-, Typst will now read input from stdin - Now uses the system-native TLS implementation for network fetching which should be generally more robust
- Watch mode will now properly detect when a previously missing file is created
- Added
--colorflag to configure whether to print colored output - Fixed user agent with which packages are downloaded
- Updated bundled fonts to the newest versions
Development
- Added
--vendor-opensslto CLI to configure whether to link OpenSSL statically instead of dynamically (not applicable to Windows and Apple platforms) - Removed old tracing (and its verbosity) flag from the CLI
- Added new
--timingsflag which supersedes the old flamegraph profiling in the CLI - Added minimal CLI to
typst-docscrate for extracting the language and standard library documentation as JSON - The
typst_pdf::exportfunction'sidentargument switched fromOptiontoSmart. It should only be set toSmart::Customif you can provide a stable identifier (like the web app can). The CLI setsSmart::Auto.
- Added
Thanks to everyone who contributed to this release: @Leedehai, @PgBiel, @frozolotl, @Dherse, @MDLC01, @Andrew15-5, @Enter-tainer, @Myriad-Dreamin, @peng1999, @EpicEricEE, @jcbhmr, @Heinenen, @tingerrr, @Jollywatt, @LaurenzV, @YDX-2147483647, @k-84mo10, @s-cerevisiae, @01mf02, @A-Walrus, @C0ffeeCode, @CosmicHorrorDev, @DavidMazarro, @Hofer-Julian, @Jocs, @Midbin, @Quaqqer, @artemist, @astrale-sharp, @cmoog, @drupol, @dyc3, @eltociear, @emilyyyylime, @emmett-rayes, @espinielli, @evfinkn, @f3rn0s, @freundTech, @geekvest, @h-arry-smith, @istudyatuni, @jaroeichler, @jbirnick, @kg583, @mattfbacon, @max397574, @mkpoli, @mkroening, @muzimuzhi, @natsukagami, @nvarner, @onerandomusername, @pineapplehunter, @silvergasp, @t-rapp, @tertsdiepraam, @uetcis, @violetfauna, @voidiz, @xTeamStanly, @xalbd, @xkevio, @zica87.
- Rust
Published by laurmaedje almost 2 years ago
typst - Version 0.11.0, Release Candidate 1 (March 9, 2024)
For a preliminary 0.11 changelog, see https://staging.typst.app/docs/changelog
- Rust
Published by laurmaedje almost 2 years ago
typst - Version 0.10.0 (December 4, 2023)
Bibliography management
- Added support for citation collapsing (e.g.
[1]-[3]instead of[1], [2], [3]) if requested by a CSL style - Fixed bug where an additional space would appear after a group of citations
- Fixed link show rules for links in the bibliography
- Fixed show-set rules on citations
- Fixed bibliography-related crashes that happened on some systems
- Corrected name of the GB/T 7714 family of styles from 7114 to 7714
- Fixed missing title in some bibliography styles
- Fixed printing of volumes in some styles
- Fixed delimiter order for contributors in some styles (e.g. APA)
- Fixed behavior of alphanumeric style
- Fixed multiple bugs with GB/T 7714 style
- Fixed escaping in Hayagriva values
- Fixed crashes with empty dates in Hayagriva files
- Fixed bug with spacing around math blocks
- Fixed title case formatting after verbatim text and apostrophes
- Page ranges in
.bibfiles can now be arbitrary strings - Multi-line values in
.bibfiles are now parsed correctly - Entry keys in
.bibfiles now allow more characters - Fixed error message for empty dates in
.bibfiles - Added support for years of lengths other than 4 without leading zeros in
.bibfiles - More LaTeX commands (e.g. for quotes) are now respected in
.bibfiles
- Added support for citation collapsing (e.g.
Visualization
- Added support for patterns as fills and strokes
- The
alphaparameter of thecomponentsfunction on colors is now a named parameter (Breaking change) - Added support for the Oklch color space
- Improved conversions between colors in different color spaces
- Removed restrictions on Oklab chroma component
- Fixed clipping on blocks and boxes without a stroke
- Fixed bug with gradients on math
- Fixed bug with gradient rotation on text
- Fixed bug with gradient colors in PDF
- Fixed relative base of Oklab chroma ratios
- Fixed Oklab color negation
Text and Layout
- CJK text can now be emphasized with the
*and_syntax even when there are no spaces - Added basic i18n for Greek and Estonian
- Improved default figure caption separator for Chinese, French, and Russian
- Changed default figure supplement for Russian to short form
- Fixed CJK-Latin-spacing before line breaks and in
locatecalls - Fixed line breaking at the end of links
- CJK text can now be emphasized with the
Math
- Added
midfunction for scaling a delimiter up to the height of the surroundinglrgroup - The
opfunction can now take any content, not just strings - Improved documentation for math alignment
- Fixed swallowing of trailing comma when a symbol is used in a function-like way (e.g.
pi(a,b,))
- Added
Scripting
- Any non-identifier dictionary key is now interpreted as an expression: For instance,
((key): value)will create a dictionary with a dynamic key - The
stroketype now has a constructor that converts a value to a stroke or creates one from its parts - Added constructor for
argumentstype - Added
calc.div-euclidandcalc.rem-euclidfunctions - Fixed equality of
arguments - Fixed
reprofcmykcolors - Fixed crashes with provided elements like figure captions, outline entries, and footnote entries
- Any non-identifier dictionary key is now interpreted as an expression: For instance,
Tooling and Diagnostics
- Show rules that match on their own output now produce an appropriate error message instead of a crash (this is a first step, in the future they will just work)
- Too highly or infinitely nested layouts now produce error messages instead of crashes
- Added hints for invalid identifiers
- Added hint when trying to use a manually constructed footnote or outline entry
- Added missing details to autocompletions for types
- Improved error message when passing a named argument where a positional one is expected
- Jump from click now works on raw blocks
Export
- PDF compilation output is now again fully byte-by-byte reproducible if the document's
dateis set manually - Fixed color export in SVG
- Fixed PDF metadata encoding of multiple authors
- PDF compilation output is now again fully byte-by-byte reproducible if the document's
Command line interface
- Fixed a major bug where
typst watchwould confuse files and fail to pick up updates - Fetching of the release metadata in
typst updatenow respects proxies - Fixed bug with
--openflag on Windows when the path contains a space - The
TYPST_FONT_PATHSenvironment variable can now contain multiple paths (separated by;on Windows and:elsewhere) - Updated embedded New Computer Modern fonts to version 4.7
- The watching process doesn't stop anymore when the main file contains invalid UTF-8
- Fixed a major bug where
Miscellaneous Improvements
- Parallelized image encoding in PDF export
- Improved the internal representation of content for improved performance
- Optimized introspection (query, counter, etc.) performance
- The document title can now be arbitrary content instead of just a string
- The
number-alignparameter on numbered lists now also accepts vertical alignments - Fixed selectors on quote elements
- Fixed parsing of
#returnexpression in markup - Fixed bug where inline equations were displayed in equation outlines
- Fixed potential CRLF issue in
rawblocks - Fixed a bug where Chinese numbering couldn't exceed the number 255
Development
- Merged
typstandtypst-libraryand extractedtypst-pdf,typst-svg, andtypst-renderinto separate crates - The Nix flake now includes the git revision when running
typst --version
- Merged
Thanks to everyone who contributed to this release: @Dherse, @frozolotl, @Leedehai, @Andrew15-5, @MDLC01, @danieleades, @tingerrr, @Jollywatt, @cmoog, @peng1999, @Enter-tainer, @JakobSachs, @KronosTheLate, @MyrtleTurtle22, @T0mstone, @TheJosefOlsson, @antonWetzel, @denkspuren, @kokkonisd, @lihe07, @mattfbacon, @rezzubs, @samueltardieu, @xalbd.
- Rust
Published by laurmaedje about 2 years ago
typst - Version 0.9.0 (October 31, 2023)
Bibliography management
- New bibliography engine based on CSL (Citation Style Language). Ships with about 100 commonly used citation styles and can load custom
.cslfiles - Added new
formargument to thecitefunction to produce different forms of citations (e.g. for producing a citation suitable for inclusion in prose) - The
citefunction now takes only a single label/key instead of allowing multiple. Adjacent citations are merged and formatted according to the citation style's rules automatically. This works both with the reference syntax and explicit calls to thecitefunction. (Breaking change) - The
citefunction now takes a label instead of a string (Breaking change) - Added
fullargument to bibliography function to print the full bibliography even if not all works were cited - Bibliography entries can now contain Typst equations (wrapped in
$..$just like in markup), this works both for.ymland.bibbibliographies - The hayagriva YAML format was improved. See its changelog for more details. (Breaking change)
- A few bugs with
.bibfile parsing were fixed - Removed
bracketsargument ofcitefunction in favor ofform
- New bibliography engine based on CSL (Citation Style Language). Ships with about 100 commonly used citation styles and can load custom
Visualization
- Gradients and colors (thanks to @Dherse)
- Added support for gradients on shapes and text
- Supports linear, radial, and conic gradients
- Added support for defining colors in more color spaces, including Oklab, Linear RGB(A), HSL, and HSV
- Added
saturate,desaturate, androtatefunctions on colors - Added
color.mapmodule with predefined color maps that can be used with gradients - Rename
kindfunction on colors tospace - Removed
to-rgba,to-cmyk, andto-lumafunctions in favor of a newcomponentsfunction - Improved rendering of rectangles with corner radius and varying stroke widths
- Added support for properly clipping boxes and blocks with a border radius
- Added
backgroundparameter tooverline,underline, andstrikefunctions - Fixed inaccurate color embedding in PDFs
- Fixed ICC profile handling for images embedded in PDFs
Text and Layout
- Added support for automatically adding proper pacing between CJK and Latin text (enabled by default)
- Added support for automatic adjustment of more CJK punctuation
- Added
quoteelement for inserting inline and block quotes with optional attributions - Added
raw.lineelement for customizing the display of individual lines of raw text, e.g. to add line numbers while keeping proper syntax highlighting - Added support for per-side inset customization to table function
- Added Hungarian and Romanian translations
- Added support for Czech hyphenation
- Added support for setting custom smart quotes
- The default figure separator now reacts to the currently set language and region
- Improved line breaking of links / URLs (especially helpful for bibliographies with many URLs)
- Improved handling of consecutive hyphens in justification algorithm
- Fixed interaction of justification and hanging indent
- Fixed a bug with line breaking of short lines without spaces when justification is enabled
- Fixed font fallback for hyphen generated by hyphenation
- Fixed handling of word joiner and other no-break characters during hyphenation
- Fixed crash when hyphenating after an empty line
- Fixed line breaking of composite emoji like 🏳️🌈
- Fixed missing text in some SVGs
- Fixed font fallback in SVGs
- Fixed behaviour of
toargument onpagebreakfunction - Fixed
set align(..)for equations - Fixed spacing around placed elements
- Fixed coalescing of
aboveandbelowspacing if given in em units and the font sizes differ - Fixed handling of
extentparameter ofunderline,overline, andstrikefunctions - Fixed crash for floating placed elements with no specified vertical alignment
- Partially fixed a bug with citations in footnotes
Math
- Added
gapargument forvec,mat, andcasesfunction - Added
sizeargument forabs,norm,floor,ceil, androundfunctions - Added
reverseparameter to cases function - Added support for multinomial coefficients to
binomfunction - Removed
rotationargument oncancelfunction in favor of a new and more flexibleangleargument (Breaking change) - Added
wideconstant, which inserts twice the spacing ofquad - Added
cschandsechoperators ↼,⇀,↔, and⟷can now be used as accents- Added
integral.dash,integral.dash.double, andintegral.slashsymbols - Added support for specifying negative indices for augmentation lines to position the line from the back
- Fixed default color of matrix augmentation] lines
- Fixed attachment of primes to inline expressions
- Math content now respects the text baseline setting
- Added
Performance
- Fixed a bug related to show rules in templates which would effectively disable incremental compilation in affected documents
- Micro-optimized code in several hot paths, which brings substantial performance gains, in particular in incremental compilations
- Improved incremental parsing, which affects the whole incremental compilation pipeline
- Added support for incremental parsing in the CLI
- Added support for incremental SVG encoding during PDF export, which greatly improves export performance for documents with many SVG
Tooling and Diagnostics
- Improved autocompletion for variables that are in-scope
- Added autocompletion for package imports
- Added autocompletion for labels
- Added tooltip that show which variables a function captures (when hovering over the equals sign or arrow of the function)
- Diagnostics are now deduplicated
- Improved diagnostics when trying to apply unary
+or-to types that only support binary+and- - Error messages now state which label or citation key isn't present in the document or its bibliography
- Fixed a bug where function argument parsing errors where shadowed by function execution errors (e.g. when trying to call
array.sortedand passing the key function as a positional argument instead of a named one).
Export
- Added support for configuring the document's creation
date. If thedateis set toauto(the default), the PDF's creation date will be set to the current date and time. - Added support for configuring document
keywords - Generated PDFs now contain PDF document IDs
- The PDF creator tool metadata now includes the Typst version
- Added support for configuring the document's creation
Web app
- Added version picker to pin a project to an older compiler version (with support for Typst 0.6.0+)
- Fixed desyncs between editor and compiler and improved overall stability
- The app now continues to highlight the document when typing while the document is being compiled
Command line interface
- Added support for discovering fonts through fontconfig
- Now clears the screen instead of resetting the terminal
- Now automatically picks correct file extension for selected output format
- Now only regenerates images for changed pages when using
typst watchwith PNG or SVG export
Miscellaneous Improvements
- Added
versiontype andsys.versionconstant specifying the current compiler version. Can be used to gracefully support multiple versions. - The U+2212 MINUS SIGN is now used when displaying a numeric value, in the
reprof any numeric value and to replace a normal hyphen in text mode when before a digit. This improves, in particular, how negative integer values are displayed in math mode. - Added support for specifying a default value instead of failing for
removefunction in array and dictionary - Simplified page setup guide examples
- Switched the documentation from using the word "hashtag" to the word "hash" where appropriate
- Added support for
array.zipwithout any further arguments - Fixed crash when a plugin tried to read out of bounds memory
- Fixed crashes when handling infinite lengths
- Fixed introspection (mostly bibliography) bugs due to weak page break close to the end of the document
- Added
Development
- Extracted
typst::ideinto separatetypst_idecrate - Removed a few remaining
'staticbounds on&dyn World - Removed unnecessary dependency, which reduces the binary size
- Fixed compilation of
typstby itself (withouttypst-library) - Fixed warnings with Nix flake when using
lib.getExe
- Extracted
Thanks to everyone who contributed to this release: @Dherse, @EpicEricEE, @tingerrr, @LuxxxLucy, @bluebear94, @MDLC01, @Jollywatt, @SekoiaTree, @DVDTSB, @HydroH, @KillTheMule, @LaurenzV, @frozolotl, @peng1999, @0scvr, @7sDream, @8LWXpg, @Enter-tainer, @FlyinPancake, @Myriad-Dreamin, @T0mstone, @TheJosefOlsson, @WannesMalfait, @WeetHet, @Weissnix4711, @Zheoni, @antonWetzel, @arnaudgolfouse, @drupol, @dxniel-19, @extua, @fritzrehde, @johannes-wolf, @qrnch-jan, @toddlerer.
- Rust
Published by laurmaedje over 2 years ago
typst - Version 0.8.0 (September 13, 2023)
Scripting
- Plugins (thanks to @astrale-sharp and @arnaudgolfouse)
- Typst can now load plugins that are compiled to WebAssembly
- Anything that can be compiled to WebAssembly can thus be loaded as a plugin
- These plugins are fully encapsulated (no access to file system or network)
- Plugins can be shipped as part of packages
- Plugins work just the same in the web app
- Types are now first-class values (Breaking change)
- A type is now itself a value
- Some types can be called like functions (those that have a constructor), e.g.
intandstr - Type checks are now of the form
type(10) == intinstead of the oldtype(10) == "integer". Compatibility with the old way will remain for a while to give package authors time to upgrade, but it will be removed at some point. - Methods are now syntax sugar for calling a function scoped to a type, meaning that
"hello".len()is equivalent tostr.len("hello") - Added support for
importrenaming withas - Added a
durationtype - Added support for CBOR encoding and decoding
- Added encoding and decoding functions from and to bytes for data formats:
json.decode,json.encode, and similar functions for other formats - Added
array.interspersefunction - Added
str.revfunction - Added
calc.tauconstant - Made bytes joinable and addable
- Made
array.zipfunction variadic - Fixed bug with
evalwhen themodewas set to"math" - Fixed bug with
ends-withfunction on strings - Fixed bug with destructuring in combination with break, continue, and return
- Fixed argument types of hyperbolic functions, they don't allow angles anymore (Breaking change)
- Renamed some color methods:
rgbabecomesto-rgba,cmykbecomesto-cmyk, andlumabecomesto-luma(Breaking change)
Export
- Added SVG export (thanks to @Enter-tainer)
- Fixed bugs with PDF font embedding
- Added support for page labels that reflect the page numbering style in the PDF
Text and Layout
- Added
highlightfunction for highlighting text with a background color - Added
polygon.regularfunction for drawing a regular polygon - Added support for tabs in
rawelements alongsidetab-widthparameter - The layout engine now tries to prevent "runts" (final lines consisting of just a single word)
- Added Finnish translations
- Added hyphenation support for Polish
- Improved handling of consecutive smart quotes of different kinds
- Fixed vertical alignments for
number-alignargument on page function (Breaking change) - Fixed weak pagebreaks after counter updates
- Fixed missing text in SVG when the text font is set to "New Computer Modern"
- Fixed translations for Chinese
- Fixed crash for empty text in show rule
- Fixed leading spaces when there's a linebreak after a number and a comma
- Fixed placement of floating elements in columns and other containers
- Fixed sizing of block containing just a single box
- Added
Math
- Added support for augmented matrices
- Removed support for automatic matching of fences like
|and||as there were too many false positives. You can use functions likeabsornormor an explicitlrcall instead. (Breaking change) - Fixed spacing after number with decimal point in math
- Fixed bug with primes in subscript
- Fixed weak spacing
- Fixed crash when text within math contains a newline
Tooling and Diagnostics
- Added hints when trying to call a function stored in a dictionary without extra parentheses
- Fixed hint when referencing an equation without numbering
- Added more details to some diagnostics (e.g. when SVG decoding fails)
Command line interface
- Added
typst updatecommand for self-updating the CLI (thanks to @jimvdl) - Added download progress indicator for packages and updates
- Added
--formatargument to explicitly specify the output format - The CLI now respects proxy configuration through environment variables and has a new
--certoption for setting a custom CA certificate - Fixed crash when field wasn't present and
--oneis passed totypst query
- Added
Miscellaneous Improvements
- Added page setup guide
- Added
figure.captionfunction that can be used for simpler figure customization (Breaking change becauseit.captionnow renders the full caption with supplement in figure show rules and manual outlines) - Moved
caption-posargument tofigure.captionfunction and renamed it toposition(Breaking change) - Added
separatorargument tofigure.captionfunction - Added support for combination of and/or and before/after selectors
- Packages can now specify a minimum compiler version they require to work
- Fixed parser bug where method calls could be moved onto their own line for
#letexpressions in markup (Breaking change) - Fixed bugs in sentence and title case conversion for bibliographies
- Fixed supplements for alphanumeric and author-title bibliography styles
- Fixed off-by-one error in APA bibliography style
Development
- Made
SpanandFileIdmore type-safe so that all error conditions must be handled byWorldimplementors
- Made
Thanks to everyone who contributed to this release: @Beiri22, @bluebear94, @jimvdl, @LuxxxLucy, @mattfbacon, @sitandr, @xkevio, @Dherse, @Enter-tainer, @SimonRask, @4BlueTurtles, @Andrew15-5, @KillTheMule, @LaurenzV, @MDLC01, @NeillJohnston, @PgBiel, @Sett17, @SillyFreak, @abramchikd, @antonWetzel, @arj0019, @astrale-sharp, @damaxwell, @frozolotl, @kingfree, @kiviktnm, @klMse, @lolstork, @owiecc, @pavelzw, @raphCode, @sudormrfbin, @t-rapp, @zicklag, @zyoshoka.
- Rust
Published by laurmaedje over 2 years ago
typst - Version 0.7.0 (August 7, 2023)
Text and Layout
- Added support for floating figures through the
placementargument on the figure function - Added support for arbitrary floating content through the
floatargument on the place function - Added support for loading
.sublime-syntaxfiles as highlighting syntaxes for raw blocks - Added support for loading
.tmThemefiles as highlighting themes for raw blocks - Added bounds option to
top-edgeandbottom-edgearguments of text function for tight bounding boxes - Removed nonsensical top- and bottom-edge options, e.g. ascender for the bottom edge (Breaking change)
- Added
scriptargument to text function - Added
alternativeargument to smart quote function - Added basic i18n for Japanese
- Added hyphenation support for
nbandnnlanguage codes in addition tono - Fixed positioning of placed elements in containers (Breaking change)
- Fixed overflowing containers due to optimized line breaks
- Added support for floating figures through the
Export
- Greatly improved export of SVG images to PDF. Many thanks to @LaurenzV for their work on this.
- Added support for the alpha channel of RGBA colors in PDF export
- Fixed a bug with PPI (pixels per inch) for PNG export
Math
- Improved layout of primes (e.g. in
$a'_1$) - Improved display of multi-primes (e.g. in
$a''$) - Improved layout of roots
- Changed relations to show attachments as limits by default (e.g. in
$a ->^x b$) - Large operators and delimiters are now always vertically centered
- Boxes in equations now sit on the baseline instead of being vertically centered by default. Notably, this does not affect blocks because they are not inline elements.
- Added support for weak spacing
- Added support for OpenType character variants
- Added support for customizing the math class of content
- Fixed spacing around
.,\/, and... - Fixed spacing between closing delimiters and large operators
- Fixed a bug with math font weight selection
- Symbols and Operators (Breaking changes)
- Added
id,im, andtrtext operators - Renamed
identtoequivwith aliaseq.tripleand removedident.strictin favor ofeq.quad - Renamed
ast.sqtoast.squareandintegral.sqtointegral.square - Renamed
.eqqmodifier to.equiv(and.neqqto.nequiv) fortilde,gt,lt,prec, andsucc - Added
emptysetas alias fornothing - Added
lt.curlyandgt.curlyas aliases forprecandsucc - Added
aleph,beth, andgimmelas alias foralef,bet, andgimel
- Improved layout of primes (e.g. in
Scripting
- Fields
- Added
absandemfield to lengths - Added
ratioandlengthfield to relative lengths - Added
xandyfield to 2d alignments - Added
paint,thickness,cap,join,dash, andmiter-limitfield to strokes - Accessor and utility methods
- Added
dedupmethod to arrays - Added
pt,mm,cm, andinchesmethod to lengths - Added
degandradmethod to angles - Added
kind,hex,rgba,cmyk, andlumamethod to colors - Added
axis,start,end, andinvmethod to directions - Added
axisandinvmethod to alignments - Added
invmethod to 2d alignments - Added
startargument toenumeratemethod on arrays - Added
color.mixfunction - Added
modeandscopearguments toevalfunction - Added
bytestype for holding large byte buffers - Added
encodingargument to read function to read a file as bytes instead of a string - Added
image.decodefunction for decoding an image directly from a string or bytes - Added
bytesfunction for converting a string or an array of integers to bytes - Added
arrayfunction for converting bytes to an array of integers - Added support for converting bytes to a string with the
strfunction
Tooling and Diagnostics
- Added support for compiler warnings
- Added warning when compilation does not converge within five attempts due to intense use of introspection features
- Added warnings for empty emphasis (
__and**) - Improved error message for invalid field assignments
- Improved error message after single
# - Improved error message when a keyword is used where an identifier is expected
- Fixed parameter autocompletion for functions that are in modules
- Import autocompletion now only shows the latest package version until a colon is typed
- Fixed autocompletion for dictionary key containing a space
- Fixed autocompletion for for loops
Command line interface
- Added
typst querysubcommand to execute a query on the command line - The
--rootand--font-pathsarguments cannot appear in front of the command anymore (Breaking change) - Local and cached packages are now stored in directories of the form
{namespace}/{name}/{version}instead of{namespace}/{name}-{version}(Breaking change) - Now prioritizes explicitly given fonts (via
--font-paths) over system and embedded fonts when both exist - Fixed
typst watchnot working with some text editors - Fixed displayed compilation time (now includes export)
- Added
Miscellaneous Improvements
- Added
bookmarkedargument to heading to control whether a heading becomes part of the PDF outline - Added
caption-posargument to control the position of a figure's caption - Added
metadatafunction for exposing an arbitrary value to the introspection system - Fixed that a
statewas identified by the pair(key, init)instead of just itskey - Improved indent logic of enumerations. Instead of requiring at least as much indent as the end of the marker, they now require only one more space indent than the start of the marker. As a result, even long markers like
12.work with just 2 spaces of indent. - Fixed bug with indent logic of
rawblocks - Fixed a parsing bug with dictionaries
- Added
Development
- Extracted parser and syntax tree into
typst-syntaxcrate - The
World::todayimplementation of Typst dependants may need fixing if they have the same bug that the CLI world had
- Extracted parser and syntax tree into
Thanks to everyone who contributed to this release: @damaxwell, @bluebear94, @PgBiel, @Beiri22, @Dherse, @LaurenzV, @Mafii, @adriandelgado, @lolstork, @AlistairKeiller, @DVDTSB, @Enter-tainer, @EpicEricEE, @Liamolucko, @LingMan, @MDLC01, @Myriad-Dreamin, @StrangeGirlMurph, @T0mstone, @TheLukeGuy, @antonWetzel, @epbuennig, @jeffa5, @kg583, @lynn, @mattfbacon, @mavaddat, @neunenak, @pineapplehunter, @raphCode, @sitandr, @sudormrfbin, @tretre91.
- Rust
Published by laurmaedje over 2 years ago
typst - Version 0.6.0 (June 30, 2023)
Package Management
- Typst now has built-in package management
- You can import published community packages or create and use system-local ones
- Published packages are also supported in the web app
Math
- Added support for optical size variants of glyphs in math mode
- Added argument to enable
limitsconditionally depending on whether the equation is set indisplayorinlinestyle - Added
gt.eq.slantandlt.eq.slantsymbols - Increased precedence of factorials in math mode (
[$1/n!$]works correctly now) - Improved underlines and overlines in math mode
- Fixed usage of
limitsfunction in show rules - Fixed bugs with line breaks in equations
Text and Layout
- Added support for alternating page margins with the
insideandoutsidekeys - Added support for specifying the page
binding - Added
toargument to pagebreak function to skip to the next even or odd page - Added basic i18n for a few more languages (TR, SQ, TL)
- Fixed bug with missing table row at page break
- Fixed bug with underlines
- Fixed bug superfluous table lines
- Fixed smart quotes after line breaks
- Fixed a crash related to text layout
- Added support for alternating page margins with the
Command line interface
- Breaking change: Added requirement for
--root/TYPST_ROOTdirectory to contain the input file because it designates the project root. Existing setups that useTYPST_ROOTto emulate package management should switch to local packages - Breaking change: Now denies file access outside of the project root
- Added support for local packages and on-demand package download
- Now watches all relevant files, within the root and all packages
- Now displays compilation time
- Breaking change: Added requirement for
Miscellaneous Improvements
- Added
outline.entryto customize outline entries with show rules - Added some hints for error messages
- Added some missing syntaxes for
rawhighlighting - Improved rendering of rotated images in PNG export and web app
- Made footnotes reusable and referenceable
- Fixed bug with citations and bibliographies in
locate - Fixed inconsistent tense in documentation
- Added
Development
- Added contribution guide
- Reworked
Worldinterface to accommodate for package management and make it a bit simpler to implement (Breaking change for implementors)
Thanks to everyone who contributed to this release: @bluebear94, @figsoda, @sitandr, @MDLC01, @Mafii, @azerupi, @damaxwell, @AndyBarcia, @DVDTSB, @Jollywatt, @Luis-Licea, @Myriad-Dreamin, @PgBiel, @SUPERCILEX, @TomBinford, @abdulmelikbekmez, @alerque, @chicoferreira, @jskherman, @lucifer1004, @raphCode, @thehydrogen, @zach-capalbo.
- Rust
Published by laurmaedje over 2 years ago
typst - Version 0.5.0 (June 9, 2023)
Text and Layout
- Added
rawsyntax highlighting for many more languages - Added support for Korean numbering
- Added basic i18n for a few more languages (NL, SV, DA)
- Improved linebreaking for East Asian languages
- Expanded functionality of outline
indentproperty - Fixed footnotes in columns
- Fixed page breaking bugs with footnotes
- Fixed bug with handling of footnotes in lists, tables, and figures
- Fixed a bug with CJK punctuation adjustment
- Fixed a crash with rounded rectangles
- Fixed alignment of
lineelements
- Added
Math
- Breaking change: The syntax rules for mathematical attachments were improved:
$f^abs(3)$now parses as$f^(abs(3))$instead of$(f^abs)(3)$. To disambiguate, add a space:$f^zeta (3)$. - Added forced size commands for math (e.g.,
display) - Added
supplementparameter toequation, used by references - New symbols:
bullet,xor,slash.big,sigma.alt,tack.r.not,tack.r.short,tack.r.double.not - Fixed a bug with symbols in matrices
- Fixed a crash in the
attachfunction
- Breaking change: The syntax rules for mathematical attachments were improved:
Scripting
- Added new
datetimetype anddatetime.today()to retrieve the current date - Added
str.from-unicodeandstr.to-unicodefunctions - Added
fieldsmethod on content - Added
baseparameter tostrfunction - Added
calc.expandcalc.ln - Improved accuracy of
calc.powandcalc.log) for specific bases - Fixed removal order for dictionary
- Fixed
.at(default: ..)for strings and content - Fixed field access on styled elements
- Removed deprecated
calc.modfunction
- Added new
Command line interface
- Added PNG export via
typst compile source.typ output-{n}.png. The output path must contain[{n}]if the document has multiple pages. - Added
--diagnostic-format=shortfor Unix-style short diagnostics - Doesn't emit color codes anymore if stderr isn't a TTY
- Now sets the correct exit code when invoked with a non-existent file
- Now ignores UTF-8 BOM in Typst files
- Added PNG export via
Miscellaneous Improvements
- Improved errors for mismatched delimiters
- Improved error message for failed length comparisons
- Fixed a bug with images not showing up in Apple Preview
- Fixed multiple bugs with the PDF outline
- Fixed citations and other searchable elements in
hide - Fixed bugs with reference supplements
- Fixed Nix flake
Thanks to everyone who contributed to this release: @EpicEricEE, @LaurenzV, @PgBiel, @SUPERCILEX, @figsoda, @lynn, @peng1999, @sandalbanditten, @BasixKOR, @JettChenT, @Leedehai, @MDLC01, @StrangeGirlMurph, @alixmacdonald10, @coughmedicine, @epbuennig, @erikwastaken, @glocq, @howjmay, @jassler, @lino-levan, @lucifer1004, @matthiasGmayer, @naim94a, @ollema, @sbatial, @sitandr, @xiongmao86.
- Rust
Published by laurmaedje over 2 years ago
typst - Version 0.4.0 (May 20, 2023)
Footnotes
- Implemented support for footnotes
- The
footnotefunction inserts a footnote - The
footnote.entryfunction can be used to customize the footnote listing - The
"chicago-notes"citation style is now available
Documentation
- Added a Guide for LaTeX users
- Now shows default values for optional arguments
- Added richer outlines in "On this Page"
- Added initial support for search keywords: "Table of Contents" will now find the outline function. Suggestions for more keywords are welcome!
- Fixed issue with search result ranking
- Fixed many more small issues
Math
- Breaking change: Alignment points (
&) in equations now alternate between left and right alignment - Added support for writing roots with Unicode: For example,
$root(x+y)$can now also be written as$√(x+y)$ - Fixed uneven vertical
attachmentalignment - Fixed spacing on decorated elements (e.g., spacing around a canceled operator)
- Fixed styling for stretchable symbols
- Added
tack.r.double,tack.l.double,dotless.ianddotless.jsymbols - Fixed show rules on symbols (e.g.
{show sym.tack: set text(blue)}) - Fixed missing rename from
ast.optoastthat should have been in the previous release
- Breaking change: Alignment points (
Scripting
- Added function scopes: A function can now hold related definitions in its own scope, similar to a module. The new
assert.eqfunction, for instance, is part of theassertfunction's scope. Note that function scopes are currently only available for built-in functions. - Added
assert.eqandassert.nefunctions for simpler equality and inequality assertions with more helpful error messages - Exposed list, enum, and term list items in their respective functions' scope
- The
atmethods on strings, arrays, dictionaries, and content now support specifying a default value - Added support for passing a function to
replacethat is called with each match. - Fixed replacement strings: They are now inserted completely verbatim instead of supporting the previous (unintended) magic dollar syntax for capture groups
- Fixed bug with trailing placeholders in destructuring patterns
- Fixed bug with underscore in parameter destructuring
- Fixed crash with nested patterns and when hovering over an invalid pattern
- Better error messages when casting to an integer or float fails
- Added function scopes: A function can now hold related definitions in its own scope, similar to a module. The new
Text and Layout
- Implemented sophisticated CJK punctuation adjustment
- Disabled overhang for CJK punctuation
- Added basic translations for Traditional Chinese
- Fixed alignment of text inside raw blocks (centering a raw block, e.g. through a figure, will now keep the text itself left-aligned)
- Added support for passing a array instead of a function to configure table cell alignment and fill per column
- Fixed automatic figure
kinddetection - Made alignment of enum numbers configurable, defaulting to
end - Figures can now be made breakable with a show-set rule for blocks in figure
- Initial fix for smart quotes in RTL languages
Export
- Fixed ligatures in PDF export: They are now copyable and searchable
- Exported PDFs now embed ICC profiles for images that have them
- Fixed export of strokes with zero thickness
Web app
- Projects can now contain folders
- Added upload by drag-and-drop into the file panel
- Files from the file panel can now be dragged into the editor to insert them into a Typst file
- You can now copy-paste images and other files from your computer directly into the editor
- Added a button to resend confirmation email
- Added an option to invert preview colors in dark mode
- Added tips to the loading screen and the Help menu. Feel free to propose more!
- Added syntax highlighting for YAML files
- Allowed middle mouse button click on many buttons to navigate into a new tab
- Allowed more project names
- Fixed overridden Vim mode keybindings
- Fixed many bugs regarding file upload and more
Miscellaneous Improvements
- Improved performance of counters, state, and queries
- Improved incremental parsing for more efficient recompilations
- Added support for
.yamlextension in addition to.ymlfor bibliographies - The CLI now emits escape codes only if the output is a TTY
- For users of the
typstcrate: TheDocumentis nowSyncagain and theWorlddoesn't have to be'staticanymore
Thanks to everyone who contributed to this release: @Leedehai, @PgBiel, @Marmare314, @SUPERCILEX, @peng1999, @sitandr, @stevenskevin, @AlistairKeiller, @HarmoGlace, @LaurenzV, @MultisampledNight, @albertothedev, @chris-02, @dvdvgt, @emme1444, @goggle, @jannisko, @jassler, @johannes-wolf, @liferooter, @maciemesser, @mattfbacon, @maxwell-thum, @michidk, @naim94a, @owiecc, @pan93412, @szdytom.
- Rust
Published by laurmaedje almost 3 years ago
typst - Version 0.3.0 (April 26, 2023)
Breaking changes:
- Renamed a few symbols: What was previous
dot.opis now justdotand the basic dot isdot.basic. The same applies toastandtilde. - Renamed
modtoremto more accurately reflect the behaviour. It will remain available asmoduntil the next update as a grace period. - A lone underscore is not a valid identifier anymore, it can now only be used in patterns
- Removed
beforeandafterarguments fromquery. This is now handled through flexible selectors combinator methods - Added support for attachments (sub-, superscripts) that precede the base symbol. The
topandbottomarguments have been renamed totandb.
- Renamed a few symbols: What was previous
New features
- Added support for more complex strokes (configurable caps, joins, and dash patterns)
- Added
cancelfunction for equations - Added support for destructuring in argument lists and assignments
- Added
alttext argument to image function - Added
tomlfunction for loading data from a TOML file - Added
zip,sum, andproductmethods for arrays - Added
fact,perm,binom,gcd,lcm,atan2,quo,trunc, andfractcalculation
Improvements
- Text in SVGs now displays properly
- Typst now generates a PDF heading outline
- References now provides the referenced element as a field in show rules
- Refined linebreak algorithm for better Chinese justification
- Locations are now a valid kind of selector
- Added a few symbols for algebra
- Added Spanish smart quote support
- Added
selectorfunction to turn a selector-like value into a selector on which combinator methods can be called - Improved some error messages
- The outline and bibliography headings can now be styled with show-set rules
- Operations on numbers now produce an error instead of overflowing
Bug fixes
- Fixed wrong linebreak before punctuation that follows inline equations, citations, and other elements
- Fixed a bug with argument sinks
- Fixed strokes with thickness zero
- Fixed hiding and show rules in math
- Fixed alignment in matrices
- Fixed some alignment bugs in equations
- Fixed grid cell alignment
- Fixed alignment of list marker and enum markers in presence of global alignment settings
- Fixed path closing
- Fixed compiler crash with figure references
- A single trailing line breaks is now ignored in math, just like in text
Command line interface
- Font path and compilation root can now be set with the environment variables
TYPST_FONT_PATHSandTYPST_ROOT - The output of
typst fontsnow includes the embedded fonts
- Font path and compilation root can now be set with the environment variables
Development
- Added instrumentation for debugging and optimization
- Added
--updateflag andUPDATE_EXPECTenvironment variable to update reference images for tests - You can now run a specific subset with
--subtest - Tests now run on multiple threads
Thanks to everyone who contributed to this release: @SUPERCILEX, @HarmoGlace, @Marmare314, @PgBiel, @barvirm, @Dherse, @Leedehai, @joeldierkes, @peng1999, @AlistairKeiller, @LaurenzV, @Luis-Licea, @SekoiaTree, @astrale-sharp, @birktj, @dccsillag, @goggle, @johannes-wolf, @mattfbacon, @michidk, @neunenak, @pan93412, @rpitasky, @thinety, @tranzystorek-io, @werifu
- Rust
Published by laurmaedje almost 3 years ago
typst - Version 0.2.0 (April 11, 2023)
Breaking changes:
- Removed support for iterating over index and value in for loops. This is now handled via unpacking and enumerating. Same goes for the
map()method. - Dictionaries now iterate in insertion order instead of alphabetical order.
- Removed support for iterating over index and value in for loops. This is now handled via unpacking and enumerating. Same goes for the
New features
- Added unpacking syntax for let bindings, which allows things like
let (1, 2) = array - Added
enumerate()method - Added
pathfunction for drawing Bézier paths - Added
layoutfunction to access the size of the surrounding page or container - Added
keyparameter tosorted()method
- Added unpacking syntax for let bindings, which allows things like
Command line interface
- Fixed
--openflag blocking the program - New Computer Modern font is now embedded into the binary
- Shell completions and man pages can now be generated by setting the
GEN_ARTIFACTSenvironment variable to a target directory and then building Typst
- Fixed
Miscellaneous improvements
- Fixed page numbering in outline
- Added basic i18n for a few more languages (AR, NB, CS, NN, PL, SL, ES, UA, VI)
- Added a few numbering patterns (Ihora, Chinese)
- Added
sincoperator - Fixed bug where math could not be hidden with
hide - Fixed sizing issues with box, block, and shapes
- Fixed some translations
- Fixed inversion of "R" in
calandfrakstyles - Fixed some styling issues in math
- Fixed supplements of references to headings
- Fixed syntax highlighting of identifiers in certain scenarios
- Ratios can now be multiplied with more types and be converted to floats with the
floatfunction
Thanks to everyone who contributed to this release: @Marmare314, @dccsillag, @Dherse, @EpicEricEE, @Leedehai, @G1gg1L3s, @PgBiel, @RLangendam, @Raphael-CV, @SekoiaTree, @SteamedFish, @adamijak, @asayers, @asibahi, @astrale-sharp, @classabbyamp, @cmoog, @felipeacsi, @figsoda, @ichxorya, @jakobrs, @michidk, @radimsuckr, @rqy2002, @s-zymon, @tbethe, @teenjuna, @viddrobnic.
- Rust
Published by laurmaedje almost 3 years ago
typst - Version 0.1.0 (April 04, 2023)
Breaking changes:
- When using the CLI, you now have to use subcommands:
typst compile file.typortypst c file.typto create a PDFtypst watch file.typortypst w file.typto compile and watchtypst fontsto list all fonts- Manual counters now start at zero. Read the "How to step" section in the counter documentation for more details
- The bibliography styles
"author-date"and"author-title"were renamed to"chicago-author-date"and"chicago-author-title"
Figure improvements
- Figures now automatically detect their content and adapt their behaviour. Figures containing tables, for instance, are automatically prefixed with "Table X" and have a separate counter
- The figure's supplement (e.g. "Figure" or "Table") can now be customized
- In addition, figures can now be completely customized because the show rule gives access to the automatically resolved kind, supplement, and counter
Bibliography improvements
- The
bibliographyfunction now also accepts multiple bibliography paths (as an array) - Parsing of BibLaTeX files is now more permissive (accepts non-numeric edition, pages, volumes, dates, and Jabref-style comments; fixed abbreviation parsing)
- Labels and references can now include
:and.except at the end - Fixed APA bibliography ordering
- The
Drawing additions
- Added
polygonfunction for drawing polygons - Added support for clipping in boxes and blocks
- Added
Command line interface
- Now returns with non-zero status code if there is an error
- Now watches the root directory instead of the current one
- Now puts the PDF file next to input file by default
- Now accepts more kinds of input files (e.g.
/dev/stdin) - Added
--openflag to directly open the PDF
Miscellaneous improvements
- Added
yamlfunction to load data from YAML files - Added basic i18n for a few more languages (IT, RU, ZH, FR, PT)
- Added numbering support for Hebrew
- Added support for integers with base 2, 8, and 16
- Added symbols for double bracket and laplace operator
- The
linkfunction now accepts labels - The link syntax now allows more characters
- Improved justification of Japanese and Chinese text
- Calculation functions behave more consistently w.r.t to non-real results
- Replaced deprecated angle brackets
- Reduced maximum function call depth from 256 to 64
- Fixed
first-line-indentnot being applied when a paragraph starts with styled text - Fixed extraneous spacing in unary operators in equations
- Fixed block spacing, e.g. in
{block(above: 1cm, below: 1cm, ..)} - Fixed styling of text operators in math
- Fixed invalid parsing of language tag in raw block with a single backtick
- Fixed bugs with displaying counters and state
- Fixed crash related to page counter
- Fixed crash when
symbolfunction was called without arguments - Fixed crash in bibliography generation
- Fixed access to label of certain content elements
- Fixed line number in error message for CSV parsing
- Fixed invalid autocompletion after certain markup elements
- Added
Versioning changes: Starting with this release, Typst follows semver. The language and compiler will be version together for now. As a result, all crates and the language share the same version and a breaking change to either the language or any library requires a version bump. Once the language stabilizes (unclear when), the compiler and language version might start to diverge as the compiler APIs will probably remain unstable.
Thanks to everyone who contributed to this release: @Dherse, @barvirm, @HarmoGlace, @figsoda, @frozolotl, @johannes-wolf, @naim94a, @1bitbool, @CGMossa, @FilipAndersson245, @GabrielDertoni, @P-Andersson, @SekoiaTree, @asayers, @birktj, @frungl, @loewenheim, @lvignoli, @lxndio, @marcoradocchia, @mateusfccp, @ollelogdahl, @samlich, @user202729, @utilForever, @wrenger, @yichenchong, @zrr1999.
- Rust
Published by laurmaedje almost 3 years ago
typst - March 28, 2023
- Breaking: Enumerations now require a space after their marker, that is,
1.okmust now be written as1. ok - Breaking: Changed default style for term lists: Does not include a colon anymore and has a bit more indent
- Fixed bibliography ordering in IEEE style
- Fixed parsing of decimals in math:
$1.2/3.4$ - Fixed parsing of unbalanced delimiters in fractions:
$1/(2 (x) - Fixed unexpected parsing of numbers as enumerations, e.g. in
1.2 - Fixed combination of page fill and header
- Fixed compiler crash if
repeatis used in page with automatic width - Fixed matrices with explicit delimiter
- Fixed build of CLI if
gitis not installed - Links in bibliographies are now affected by link styling
- Added support for disabling matrix and vector delimiters. Generally with
#set math.mat(delim: none)or one-off with$mat(delim: #none, 1, 2; 3, 4)$. - Added
separatorargument to term lists - Fixed
indentproperty of term lists - Added
roundfunction for equations - Numberings now allow zeros. To reset a counter, you can write
#counter(..).update(0) - Added
--font-pathargument for CLI - Added Nix flake
- Numerous documentation fixes
- Added documentation for
page()andposition()methods onlocationtype - Added symbols for double, triple, and quadruple dot accent
- Added smart quotes for Norwegian Bokmål
- Fixed hovering over comments in web app
Thanks to everyone who contributed to this release: @Marmare314, @dccsillag, @Dherse, @EpicEricEE, @Leedehai, @G1gg1L3s, @PgBiel, @RLangendam, @Raphael-CV, @SekoiaTree, @SteamedFish, @adamijak, @asayers, @asibahi, @astrale-sharp, @classabbyamp, @cmoog, @felipeacsi, @figsoda, @ichxorya, @jakobrs, @michidk, @radimsuckr, @rqy2002, @s-zymon, @tbethe, @teenjuna, @viddrobnic.
- Rust
Published by laurmaedje almost 3 years ago
typst - March 21, 2023 / 2
With this release, Typst's default fonts for text, math, and code are included in the binary. This should resolve errors like current font does not support math.
- Rust
Published by laurmaedje almost 3 years ago
typst - March 21, 2023
Typst compiler version on the day of the public beta launch.
- Rust
Published by laurmaedje almost 3 years ago