summaryrefslogtreecommitdiff
path: root/src/layout/text.rs
AgeCommit message (Collapse)Author
2021-10-31Reorganize modulesLaurenz
Instead of separating functionality into layout and library, everything lives in the library now. This way, related things live side by side and there are no duplicate file names in the two directories.
2021-10-23Introduce page / block / inline levelsLaurenz
2021-03-25Refactor alignments & directions ๐Ÿ“Laurenz
- Adds lang function - Refactors execution context - Adds StackChild and ParChild enums
2021-03-24Text shaping ๐Ÿš€Laurenz
- Shapes text with rustybuzz - Font fallback with family list - Tofus are shown in the first font Co-Authored-By: Martin <mhaug@live.de>
2021-03-22Better font family definitions โœ’Laurenz
2021-03-19Text colors ๐Ÿฆฉ (#18)Martin
2021-03-19Scheduled maintenance ๐Ÿ”จLaurenz
- New naming scheme - TextNode instead of NodeText - CallExpr instead of ExprCall - ... - Less glob imports - Removes Value::Args variant - Removes prelude - Renames Layouted to Fragment - Moves font into env - Moves shaping into layout - Moves frame into separate module
2021-03-19Configurable font edges โš™Laurenz
Adds top-edge and bottom-edge parameters to the font function. These define how the box around a word is computed. The possible values are: - ascender - cap-height (default top edge) - x-height - baseline (default bottom edge) - descender The defaults are chosen so that it's easy to create good-looking designs with vertical alignment. Since they are much tighter than what most other software uses by default, the default leading had to be increased to 50% of the font size and paragraph spacing to 100% of the font size. The values cap-height and x-height fall back to ascender in case they are zero because this value may occur in fonts that don't have glyphs with cap- or x-height (like Twitter Color Emoji). Since cap-height is the default top edge, doing no fallback would break things badly. Removes softness in favor of a simple boolean for pages and a more finegread u8 for spacing. This is needed to make paragraph spacing consume line spacing created by hard line breaks.
2021-03-12Rename ChildAlign to LayoutAligns โœLaurenz
2021-01-15Split state and scopes, less ref-counting ๐Ÿ”€Laurenz
2021-01-03Move and rename many things ๐Ÿš›Laurenz
2020-11-27Basic environment and resource loader ๐ŸžLaurenz
2020-10-13BoxAlign and Flow aliases โœLaurenz
2020-10-12Naming and grammar โœ”Laurenz
2020-10-12Less vecs in layouting โšกLaurenz
2020-10-12Synchronous layout ๐Ÿช€Laurenz
2020-10-12Adapt to fontdock ๐Ÿ”ผLaurenz
2020-10-11Refactor layouting base ๐ŸชLaurenz
2020-10-11Rename LayoutItem to Layouted โœLaurenz
2020-10-10Refactor text state ๐Ÿ†ŽLaurenz
2020-10-10Switch back to custom geometry types, unified with layout primitives ๐ŸžLaurenz
2020-10-03Rename text layouting to shaping โœLaurenz
2020-09-30Streamline font handling a bit ๐Ÿ“œLaurenz
2020-09-27Fix for updated fontdock โœ”Laurenz
2020-08-30Format everything with rustfmt! ๐Ÿ’šLaurenz
2020-08-30Fix different-fonts-in-text bug โœ”Laurenz
2020-08-03Formatting, documentation and small improvements ๐ŸงฝLaurenz
2020-08-02Refactor model into tree ๐Ÿ›’Laurenz
2020-08-02Layout elements and pure rust rendering ๐ŸฅLaurenz
2020-08-02Refactor argument parsing ๐Ÿ”ฌLaurenz
2020-08-01Raw lengths ๐ŸšฒLaurenz
Replace unitless length with raw f64 and introduce length type with unit.
2020-08-01Port font handling to fontdock and ttf-parser ๐Ÿ›ณLaurenz
- Use fontdock for indexing fonts and querying - Typst binary now automatically indexes and uses system fonts in addition to a fixed font folder! - Removes subsetting support for now (was half-finished anyways, plan is to use harfbuzz for subsetting in the future) - Adds font width configuration support
2020-07-29Move, rename and switch some things (boring) ๐ŸššLaurenz
- Problems -> Diagnostics - Position -> Pos - offset_spans -> Offset trait - Size -> Length (and some more size types renamed) - Paper into its own module - scope::Parser -> parsing::CallParser - Create `Decorations` alias - Remove lots of double newlines - Switch from f32 to f64
2020-02-13New syntax features ๐Ÿ‘”Laurenz
- Forced line breaks with backslash followed by whitespace - (Multline) raw text in backticks - Set font class fallbacks with [font.family] (e.g. [font.family: monospace=("CMU Typewriter Text")]) - More sophisticated procedure to find end of function, which accounts for comments, strings, raw text and nested functions (this is a mix of a feature and a bug fix)
2020-02-06Highlight bold / italic / monospace ๐ŸŽจLaurenz
2020-02-03Better Debug/Display and Derives ๐ŸงฝLaurenz
2020-02-03Upgrade to new toddle interface ๐ŸณLaurenz
2020-01-26Document everything ๐Ÿ“œLaurenz
2020-01-24Reorganize modules ๐ŸงฑLaurenz
2020-01-19Move to non-fatal errors ๐Ÿช‚ [WIP]Laurenz
- Dynamic models instead of SyntaxTrees - No more ParseResult/LayoutResult - Errors and Decorations which are propagated to parent contexts - Models are finally clonable
2020-01-06Formatting ๐Ÿ›€Laurenz
2020-01-06Asyncify font loading ๐ŸชLaurenz
2020-01-04Adopt new font loading engine โš™Laurenz
2019-12-30Simple line layouter ๐ŸงพLaurenz
2019-12-13More consistent library code and functions ๐ŸŽ„Laurenz
2019-12-12Tidying up ๐ŸงนLaurenz
2019-12-11Not too shabby stack layouter ๐Ÿš†Laurenz
2019-12-10Progressing stack layouter ๐ŸšŠLaurenz
2019-12-05Rename crate `typst` -> `typstc` โœLaurenz
2019-12-04Unify error types โ™พLaurenz