Before version 7 a LIST stlt holds chunks, not the style table, but the
index left every such list unsplit, so fills and outlines kept there
were not found. The index now splits it by the drawing's version, the
one its first vrsn chunk names, once all of the file's own chunks are
read.
A drawn ellipse whose record ends before its two angles came in as a
whole ellipse with no warning; it is now left out as damage. The file
format table now says that version 3 envelopes are not applied and the
objects under them are kept, and gives one count of the formats opened.
PROVENANCE.md, the crate README and docs/mcp.md now say which parts of
versions 1 to 4 public specifications cover.
The importer's fuzz test of mutated RIFF drawings now also starts from a
drawing with a style table, a clipping container, an outline behind the fill and
a lens, and places each mutated drawing as well as opening it.
The crate's integration tests move to tests/it, one module per area,
built as a single test binary as the other crates' are. The file format
table now lists clipping containers, fills and outlines taken from the object's
style, and the lenses warning.
A drawn outline of width 0 became a stroke of width 0, which the
renderer does not draw. It now becomes a 0.25 pt stroke, the width PDF
import gives a line width of 0.
A zlib stream that fails near its end has already inflated most of its
bytes, which the reader discarded without counting them. Several such
streams could each inflate up to the file's inflate limit. Those bytes
now count toward it.
A curve or polygon whose points go past the coordinate limit was left
out with both the limit warning and the damage warning, in RIFF files
and in files of versions 1 and 2. It now gives the limit warning only.
A polygon without its sides argument is still damage.
Bit 0x10 of an outline's line type puts the outline behind the fill, so
that a filled shape shows only its outer half. The reader now reports
it, and the importer paints such a stroke before the fill. A clipping
container's outline behind its fill becomes a stroke of its own below
the clipping group, the two grouped together, since a clipping path's
stroke paints over the clipped objects. PROVENANCE.md row R49 gives the
sample files.
Bit 0x04 of an outline's line type marks it dashed. Some drawings store
dashes in outlines without that bit, and their own preview pictures show
those outlines solid; the reader drew them dashed. Such outlines now
come in solid. PROVENANCE.md row R48 gives the sample files.
An object with a lens or a transparency carries argument 8000. The
reader does not apply it, and the object comes in opaque; the warnings
now say so instead of nothing. PROVENANCE.md row R47 lists the sample
files that carry the argument.
A container carries argument 8005, whose id names the LIST grp of the
document's LIST clpt with the same id in its spnd chunk. The reader now
gives the container with that group's objects, which keep their own
transforms, and the importer makes a clipping group of them: the
container's shape is the clipping path and keeps its fill and outline.
Before, only the container came in, with no warning.
A container whose group is missing is damage. A group already being
read, or more than 64 clipped groups one inside another, is left out
with the limit warning; the container stays as a plain shape either way.
PROVENANCE.md row R46 gives the layout and the sample files it was
checked against.
A layer without a loda of its own is taken by the low four bits of its
flags' byte 0: 0x0a guides, or a grid when bit 0x10 is also set, and
0x08 the desktop only when byte 2 is set. Sample files flag drawing
layers 0x10, 0x18 and 0x58 with byte 2 clear, which the reader took for
grid layers and left out, and 0x08 with byte 2 clear, which it took for
the desktop.
From version 7 a drawing keeps its styles in LIST stlt, and an object
names its style in argument 200. An object without a fill (20) or
outline (10) argument of its own now takes the fill and outline its
style gives, through the style's parents where the style leaves one to
them. Before, such objects came in without a fill or outline.
The table is read only when it parses to the end of its list; a table
that does not is damage when an object needs a style from it. Its
entries and styles count toward the chunk limit. PROVENANCE.md row R45
gives the layout and the sample files it was checked against.
Version 2 files (markers m and l) start their settings after a 1-bit
picture, so the page box is read two bytes after the settings offset in
the header, and their drawn objects keep the fill at byte 105 and the
shape at 136. Files with the marker l flag drawn objects 0xc0 and are now
read; the marker d, which no sample shows, is refused. A record that does
not start with 24, or a drawn object of an unknown type, ends the walk
instead of reading the bytes after it as records. A rectangle's radius
follows its height directly.
A layer's kind comes from the object type in its own loda (11 grid,
12 guides, 17 desktop), so drawing layers flagged 0x10 or 0x08 are no
longer dropped or taken for the desktop. Object type 0x25 is read as a
path from version 10, and arrowhead ids are looked for from version 6.
PROVENANCE.md now cites the Kaitai specification, the ZIP specification,
the file utility's magic, PRONOM and the public sample files whose bytes
each row was checked against.
A page whose bottom layer is new now goes below the lowest layer the rest of
the page shares with earlier pages, and on top when it shares none, so the
layers keep the order they were first seen in.
File › Open and File › Place read .cdr drawings of versions 1 to 27,
and .cdt templates open as new untitled documents. A new L0 crate,
vectorcraft-cdr, reads the WL files of versions 1 and 2, the RIFF chunk
tree of versions 3 on with its compressed lists, and the ZIP packages of
versions 14 on with their data streams. The importer maps pages to
artboards side by side, layers by name, the master page's guidelines to
guides, groups, curves, paths, rectangles, ellipses, arcs and polygons
with uniform fills and outlines.
Versions 1 and 2 open as one page and one layer of rectangles, whole
ellipses and curves. Version 3 keeps transforms, fills and outlines in
each object, and a group's matrix places its objects; envelopes are not
applied, with a warning. Version 4 reads as version 5 with 12-byte u16
colors and fixed-point transforms.
Text, bitmaps, blends, contours, brush strokes, fountain, pattern,
texture and PostScript fills and arrowheads are left out, and the open
warnings name each kind in every complete catalog. RIFF files that name
a version before 3, drawings after 27 and encrypted, ZIP64 or split
packages are refused with a message. crates/cdr/PROVENANCE.md lists the
public source of each record layout.
Review feedback: with no tolerance, pen or trackpad jitter turned a tap
into a drag and the value was no longer selected. A release within 1 pt
of the press is a tap; anything further keeps the caret.
Regression test: a_tap_with_a_pixel_of_jitter_still_selects_all_on_release.
A client confined by --automation-read-root saw paths outside its read
roots that the person or an earlier request had put in the session:
- plugin.list: the plug-in folder last loaded and its failed files;
plugin.list and plugin.info: a plug-in's source file; plugin.list,
plugin.safeMode and plugin.setEnabled: the file of a plug-in turned
off for the next launch.
- file.recovery.list and file.recovery.restore: a document's original
file; file.recovery.list and file.recovery.save: the recovery folder.
- ui.inspect's scriptReport: the files a run wrote and the included
file a failed run stopped in.
A folder outside the read roots is now null, and a file outside them is
named by its file name. plugin.setEnabled {file} takes that name. The
restored documents keep their files, and unconfined clients and the
app's own UI see the same replies as before.
object.objectsOnPath.selectMember and object.objectsOnPath.moveMember
change only the document and its selection, as the other Objects on
Path commands do, so both join the commands a plug-in may call when its
manifest lists them.
A four-component JPEG whose EXIF orientation turns or flips it went
through the image decoder, which reads CMYK JPEGs as RGB, and was
stored as an RGB PNG without its inks. It is now stored the way a
turned CMYK TIFF is: its inks, 8 bits each, turned and written as a
CMYK TIFF with the turned resolution.
- vectorcraft_doc::cmyk::turned_cmyk turns the inks of a CMYK JPEG or
TIFF, next to stored_cmyk_tiff; tiff_inks is private again.
- raster_image swaps the resolution axes inline, as its HEIF branch
does.
- The links comment and the docs/target-app-parity.md line on EXIF
orientation now describe the turned CMYK TIFF.
A text on a path that many <use> elements show was laid out along the
whole path once per <use>, and the path was found in the file and parsed
again each time, while the 1 MiB limit on texts built for <use> elements
counted only the text's nodes and characters. A file with a short text on
a very long path and many <use> elements of it could keep the importer
busy far past that limit.
- The elements of the path a <textPath> follows now count toward the
limit. Past it, the remaining <use> elements show the text with its own
properties, and the warning names text paths as well as text.
- The path of each <textPath> is found and parsed once and shared by
every <use> that shows its text.
Files within the limit import as before.
`the_menu_bar_is_inert_while_a_file_dialog_is_open` excused a missing
menu row when the composite font or plug-in it named was gone at the
time of the check. A test running alongside can remove such a font and
define it again between the menu read and the check, and the test then
failed. It now runs inside `undisturbed`, as the file's other tests that
compare menu reads do. When the shortcut, plug-in or font generation
changes during a run, the test runs again on a new app. Every row from
before the dialog must then be back as it was.
The element a <use> shows inherits from the <use> rather than from where it
is defined (SVG 2, https://www.w3.org/TR/SVG2/struct.html#UseElement). A
text shown by a <use> now takes the font, size, weight, fill, stroke and
other text properties the <use> or its parents set, in clip paths too,
while the text's own properties still win. Uses with the same parent and
properties share one text. A <use> inside the text it shows is ignored for
inheritance, and texts built for <use> elements stop at 1 MiB of text with
a warning.
An object with an opacity mask draws offscreen over the bounds the
renderer gives it. For a live object (a blend, envelope or repeat) those
bounds took in effects in symbol art and brush art inside it, but not a
path's own effects, so with Clip off the drop shadows of a blend's steps
were cut off at the steps' bounds and did not draw where the mask art
leaves them uncovered. The bounds now also take in how far each path's
own effects paint past it.