Opening a document laid out every type object for its bounds and
baselines and threw the layouts away, and the first frame laid the same
objects out again. The open now keeps them, up to 128 MiB, and a frame
takes each one once.
A frame takes a layout only for a text object equal to the one laid out,
and only while the fonts, the system fallback setting and the hyphenation
exceptions are unchanged. When the last frame being drawn ends, the rest
are dropped if a frame took one, and all of them are dropped after eight
frames that take none. A layout with bitmap or color glyphs and a text
object with a gradient are not kept.
The only callers of `menus::menu_open` are the native palette-window
code in `panel_docking.rs` and its native tests, so on wasm32 the
re-export and the function were unused and `cargo xtask wasm` printed
two warnings for them. Both now carry `#[cfg(not(target_arch = "wasm32"))]`.
The menu bar still records whether a menu is open on every target.
The progress doc listed the moved-path stroke outline reuse twice, once
with the timings first measured and once with the timings measured
against current main. The line with the earlier timings is removed.
The gradient swatches menu, the Image Trace button's list of presets, the
Appearance panel's swatch picker and the top level of the Add New Effect
popup (Appearance panel, Properties) had no length limit, so rows past the
bottom of a short window could not be reached. Each now uses menu_scroll.
Items, order and commands do not change, and a list that fits does not
scroll.
A tool group's flyout and the All Tools drawer draw in the main window,
so a floating panel's OS window covered them. On the desktop, except on
Wayland, floating panels now hide while either one is open, as they do
for a menu or a dialog, and show again when it closes. A flyout or
drawer left set under a hidden toolbar does not draw and does not hide
them.
Type › Font and the plug-in rows come from process-wide state, and a test
running alongside can add to them. Two tests read the menus more than once
and compared the reads, so a font added in between failed them:
fonts_that_load_read_the_menus_again adds Vertitest Sans, for one.
every_in_window_item_is_in_the_mac_menu_bar_once now lays out the Mac bar
from the in-window bar it compares it with, so both come from one read.
documents_and_selections_change_state_not_structure changes the document
between its reads, so it runs through undisturbed, which runs it again when
the shortcut, plug-in or font generations change.
``params` must be an object` read as "gradyan" and `missing `effect`` read as "isim", the keys of two other rows. Both rows now keep the key in backticks, as the rows next to them do.
The Artboards panel menu asks whether Delete Empty Artboards can run on
every frame while it is open, and each ask measured the document. With
an open path of 200,000 anchors across two artboards, that took 70.4 ms
a frame in a release build.
The answer is now kept per open document with the version of the
document it was measured on, and is measured again when the document
changes. A later frame takes under 0.001 ms. The first frame after an
edit measures once. A change of the selection or the view keeps the
answer.
A paste relinked every copy to the document's resources even when no
resource had another name or color and the objects linked no graphic
style. It now leaves those copies as they are.
Finding the pasted type looked each id up and compared every text object
with the ones already found. Text commands and the bounds refresh after
a paste now look all ids up in one walk and keep the found ids in a set.
Giving a pasted group new ids builds its map of old to new ids only for
an Objects on Path group, which is the only kind that reads it.
A pasted solid paint with no swatch link and a tint other than 1 now
keeps that tint when no relinking runs. Saved art carries a tint of 1 on
such a paint.
The reader holds an overflow paragraph break (`(\r) TX`) until more type
follows it. When that type came, the break took the state in force then,
not the state where the break was read:
- A story that started with the break took the `TV` direction of the
characters after it, so `1 TV (\r) TX 0 TV (Body) Tx` opened horizontal
and gave no warning.
- A break read in the other direction inside a story did not count as a
direction change.
- The empty paragraph that the break ended took the attributes of the
paragraph after it, while `(\r) Tx` keeps its own.
The pending break now records `TV` and, when it ends an empty paragraph,
that paragraph's attributes.
The main window's menu floor was stored once for the whole egui context,
so a menu in a panel's OS window stopped at the main window's bottom bars
instead of its own edge. The floor is now kept per window, and a window
with no recorded floor uses its bottom edge. A menu list is also never
taller than the window, so the last items of a menu stay reachable in a
100 pt window, below the 120 pt minimum.
The Digits, Stylistic Sets, Save Selection and Move to Group submenus,
the libraries menu, the Color Guide's Limit to Library menu and the Layers
panel's Filter popup now scroll the same way.
The sentence inside the braces made every_description_parses fail. The object.expand and effect.expandAppearance texts now also limit the replaced-art case to a dimension selected with that art.
Object > Expand left a dimension's recipe on its group, so the next move
redrew the live dimension and discarded the expanded art. Expand now ends
the live link of a dimension whose art it changes, in the same undo step.
Moving or scaling the group leaves its art as it is, the art no longer
follows what it measured, and undo gives the live dimension back.
Expand Appearance, Create Outlines and Outline Stroke had the same fault
and now do the same, also when they reach only a part of a dimension. A
dimension whose art a command leaves as it was stays live. A dimension
selected with the art it measures becomes a plain group when Expand,
Expand Appearance or Outline Stroke replaces only that art.
The fill read apart from a clipping path that was read on %_ lines, and
the copies of its subpaths, are recorded as read on those lines too, so
the copy of a look's art that is removed takes them along. The file
format notes list a compound clipping path whose subpaths paint
differently among the exceptions to a clipping path keeping its fill.
In a compound clipping path whose subpaths paint differently, the fill
of a subpath that does not clip was read apart with the clipping
subpaths' fills. Only the clipping subpaths' fills are read apart now,
and a subpath that does not clip keeps its fill, as before.
A fill read apart from a clipping path took a copy of the clipping
path's opacity mask whose art kept the original's ids, so the document
held two objects with one id. The copy of the mask's art, and the
subpaths of a fill read apart from a compound clipping path, now get
ids of their own and stay linked to the same swatches.
Each layer a multi-layer mask covers gets a copy of the mask's path, so
a fill kept on that path painted in every layer, over the art the mask
covers in the layers before. The mask's fill is read as a path of its
own again, where the mask's path is, and the copies have no fill. A
fill read apart from a compound clipping path is a compound path whose
subpaths do not clip and have ids of their own. A fill read apart, its
subpaths and their points count toward the importer's object limit.
Docs: docs/file-format-parity.md.
The reader took the fill off a clipping path in a file's editing data and
added a copy of the path, holding only that fill, under the art it clips.
A clipping path paints its own fill under the clipped art and its stroke
over it, so the reader now keeps the fill on the clipping path. A filled
clipping path opens as one path instead of two, in a clipping group, a
clipping layer and each level of nested clipping paths. Its note, tags and
gradient stroke (`1 BB`) are on that path as before.
A compound clipping path whose subpaths all paint alike keeps their fill.
When its subpaths paint differently, the fills of the filled subpaths are
still a compound path of their own under the clipped art, so a subpath
the file does not fill stays unfilled. Clipping paths in a compound path
that holds its drawn look still have their fills read as paths of their
own under the art, each with its clipping path's opacity mask.
Docs: docs/file-format-parity.md.
A dialog's OK ignores a repeat of Enter, and an egui context keeps a key
down until it is released. The Color Picker, Swatch Options and Define
Grid tests pressed Enter in one context without releasing it, so every
press after the first was a repeat and the dialog stayed open. Each test
now releases Enter after pressing it.
With the caret before a # that stays, bare digits are not inserted ahead of it; a full code replaces the text instead. A paste that replaces the field's digits also removes bare-digit pastes kept earlier in the same frame.
A click put the caret among the six digits and the text box holds seven
characters, so only the first character of a pasted code went in. The
field then held no new color, and Enter closed the dialog with the old
color. A press on a field drawn before the hex field also dropped what
was typed, while Tab and Enter applied it.
The hex fields of the Color Picker, Swatch Options, Recolor Artwork, the
Color panel, Document Setup, Duotone, Color Themes and Perspective Grid
now share one set of rules:
- A click or keyboard focus selects the digits.
- A code of six digits, with or without #, replaces the digits wherever
the caret is.
- A code of three digits also replaces them, unless the paste holds only
those digits and exactly three digits stay. Those digits then edit the
text in place.
- A paste of only one, two, four or five digits edits the text in place
when it does not cover all of the text and the result has at most six
digits.
- Any other paste leaves the field as it was.
- A press elsewhere commits the text in the frame of the press.
- A commit returns the digits without # and writes a three-digit code out
as six, so Duotone reads a typed # and Perspective Grid, whose parser
reads six digits only, takes a three-digit code.
Part of #5013
The file-format entry states the 20,000-name limit across brush art and per section, the first-definition rule, and that colors past the limit still count toward the color mode.
Stair Step's glyphs stay upright, so their matrices never show the path
turning and the spacing fit found no turn at all. The fit now takes the
path through each glyph's origin, which lies on the path, and measures
how far it turns over a step from the circle through three origins in a
row.
Each brush art section keeps only the first definition of each color name, and at most 20,000 names. The art of the brushes that come in brings at most 20,000 different color names in all, every section's color operators before any section's gradient stops, so art that no brush uses or that a later section replaces takes no places. Colors left out still count toward the color mode.
A test also checks that a global process color which only a brush's art defines with its color operator stays a process color when a gradient stop names it.