Reformat lines
Reformat and word-wrap subtitle lines - split too long lines and
merge too short lines. The function works in 3 steps:
- Text preparation - Prepare the
lines of the subtitle.
- WordWrap - Split the lines that
are too long
- Post processing - Split subtitles
that have too many lines or merge single-liners.
The text preparation has these modes:
- Merge and separate dialogs: Merge
all lines that do not start with the Dialog
separator. Empty lines are leaved and spaces trimmed. The result
are lines of dialogs
- Do not merge: Do not merge lines,
only leave empty lines and trim spaces.
- Merge all lines: Merge all lines,
even if they start with a dialog separator. Also remove empty lines
& trim spaces. The result is a single line.
The next phase is WordWrap. In this phase the long lines are split.
The maximum length has these options:
- Mode
- Text width: The text width
using the subtitle's style is compared against the reference screen
width (Settings).
- Character count: The lines must
have at most the count of character that can be specified in the bottom
edit box. Useful for some HW DivX players.
- Pad with: In the Character count
mode the lines can be padded with the specified character (mostly
space) up to the specified width. Useful for some HW DivX players.
The WordWrap has 2 modes:
- Similar length: Try to split the
lines so all the resulting parts have similar length.
- Screen boundary: Split the lines
when they exceed the screen or character boundary.
This is an example
of the Similar length
WordWrap function |
This is an example of the
Screen boundary WordWrap
function |
Similar length |
Screen boundary |
The Similar length mode yields better results when the words are
short. With long words the lines may be significantly different in
length. If the line contains a single word that is longer than the
limit, this word is not split (it stays on a single line). When the
lines are close in length to the multiple of the limit, in the Similar
length mode they can be sometimes divided to more parts (one more) than
in the Screen boundary mode.
The last phase is Post processing.
There are 2 options for this phase:
- Split subtitles with more lines:
Split the subtitles that have more lines than specified in the edit
box. The duration of the resulting subtitles is calculated from the
original duration in the ratio of the character counts.
- Try to keep original lines together:
When a line is reformatted and split to more lines, SP will try to keep
the resulting lines together when splitting subtitles with more lines.
To achieve this, the subtitle may be split to more subtitles than
necessary, but it will keep for example a dialog line (that was split
to 2 lines) in one subtitles.
- Merge adjacent single-line subtitles:
Merge subtitles that are closer than the specified time.
The reformat is performed by clicking on the Reformat button. If the Mark changed subtitles checkbox is checked,
all touched subtitles are marked.