table.options added as many rows as the requested header and footer
counts needed, without a limit. A large number typed into the Table
panel's Header Rows field froze the app and exhausted memory. Both
counts are now capped at 100, the limit table.insert already has.
The cross-reference index composed its destination stories through
the cache. One with a running header asked for the running-header
index, which composed the story holding the cross-reference, which
asked for the cross-reference index again: the stack overflowed and
the app aborted. Destination stories with a running header are now
composed without it, like those with cross-references already were.
The grid was walked from its start, one line per step, with no
bound. A start far above the page (from document.preferences, a
saved file or an IDML package) made the next frame draw lines until
the app ran out of memory. The lines are now the ones inside the
page, found without walking those above it, and never more than one
per point of the tallest page.
Preferences OK stored whatever number the dialog held as the Story
Editor font size. One that is not finite ("nan", "inf", or a number
too large for an f32) was written to ui.json as null; the next launch
could not read the file, started with the default UI settings and
saved them over it on exit. The size is now kept between 8 and 36 pt,
the slider's range, and a value that is not a finite number leaves
the size as it was.
Keep each app's recovery data in an owned run folder. Validate current folder and lock ownership and disable recovery when isolation fails instead of using the shared root.
Fixes#496.
Co-authored-by: noah1400 <[email protected]>
Co-authored-by: skylar taylor-barrick <[email protected]>