When Avisynth is not installed or not functional, this would otherwise
cause a crash when trying to initialize Avisynth more than once, since
after the first time the refcount would have been incrased anyway.
Also, allow negative fsp.
This doesn't change the behaviour of the SpinCtrl increment/decrement
buttons, just the precision that can manually be set. Small values of
fsp can be useful as a hack to disable all ligatures. Precise values of
fscx/fscy can be useful to compensate for anamorphic resolutions. The
other fields were made more precise for consistency.
This fixes a crash on Windows when double-clicking the draggable
separator between the column headers "Command" and "Description" in the
hotkey configuration dialog.
This makes the internal juggling of fold data even more complicated, but
it has a number of advantages:
- Folds will preserved even when opening the file with Aegisub builds
that don't know about folding.
- Folds will be preserved by automation scripts that re-insert every
line.
- Folds do not break when adding or deleting lines in a text editor or
some other editor, as long as the lines involving folds aren't
touched.
- In particular, merging changes using tools like git will not break
folds.
- Copy/pasting folds also keeps the folds to some extent. This is
impossible to solve in full generality, but simple cases like
cut/pasting a folded section somewhere else work, as long as the file
isn't saved in between.
- This will give automation scripts full access to folding without
needing to set up any additional API functions.
Unlike the other arguments for the resize function, "range_in" does not
use the same format as in the frame props. A frame prop _Range=1 means
limited, while an argument range_in=1 means full range.
The highlighting distinguishes drawing commands from coordinates, and
colors x and y coordinates in different colors to make coordinates
easier to visually parse. Furthermore, in cubic Bezier curves, it
underlines the coordinates which corresponds to endpoints of the curves.
Aegisub will automatically override the YCbCr Matrix field of the
current file's Script Properties with the video's reported color space.
The FFMS2 provider guesses a color space for all videos, but we don't
do this for Vapoursynth. Thus, we now disable this overriding whenever
the colorspace isn't known.
On Windows, Python changes the application's locale upon being called,
which will break wxwidgets, causing various assertion error dialogs or
even crashes (for example when interacting with any sort of float edit
control). Saving the locale and restoring it afterwards seems to be
the only really possible way to remedy this.
The percent values used for the overscan masks follow the BBC's
guidelines, as in
https://en.wikipedia.org/wiki/Overscan#Overscan_amounts .
However, these measure the per-side width as opposed to the total
percentage of width/height being cut off. Thus, they should not be
divided by two when drawing the mask.
The new formula is just the inverse function of the CFR part of
the TimeAtFrame function.
To see how the previous implementation was faulty, see either the added
tests, or
- In Aegisub, open a dummy video with a frame rate of 23.976
- Make a subtitle event with start time 04:44.41
- Double-click the line to (supposedly) seek to its first frame
- This will seek one frame earlier than it should, and the event will
not be displayed on the resulting frame.