Files
vectorcraft/docs
dotCooCoo 8ff8dbefc6 Scripts: DocumentPreset settings refuse a value of the wrong kind or size
Assigning a DocumentPreset setting stored any value until the run ended,
and the value was checked only when addDocument read it. A script could
keep gigabytes of strings in presets that no addDocument would accept.

The setter now checks the value before storing it: a value of the
setting's enumeration, a finite number, a title of at most 4096 bytes,
true or false for documentBleedLink, or four finite numbers for
documentBleedOffsetRect. undefined unsets any setting, and the three
settings addDocument does not apply yet also take null. A value of
another kind throws a TypeError, a longer title throws a RangeError, and
the setting keeps its old value. addDocument still checks the ranges.
2026-11-27 20:16:03 -08:00
..
…