diff options
author | Dan Oscarsson <DanOscarsson@users.noreply.github.com> | 2016-10-05 13:52:47 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2016-11-12 18:42:55 +0100 |
commit | e54c123d5a08b6212533ddcced2cb1a50fa3d2b2 (patch) | |
tree | b6132f98f88924239d8f5c6fcb4cd2d96afd5d49 /libass/ass_types.h | |
parent | 35dc4dd0e14e3afb4a2c7e319a3f4110e20c7cf2 (diff) | |
download | libass-e54c123d5a08b6212533ddcced2cb1a50fa3d2b2.tar.bz2 libass-e54c123d5a08b6212533ddcced2cb1a50fa3d2b2.tar.xz |
Add text justification
Subtitle recommendations often include that multi line
subtitles should be left justified as this is easier for
the eyes. This is also the standard used by several television
companies.
This add the possibility to define how subtitles are to
be justified, independently of where they are aligned.
The most common way could be to set justify to left, and have
alignment to center. But you can, for example, have alignment
to left and justify to center, giving subtitles to the left but
justifed on the center (instead of normal left justified).
Using justify right and alignment of center, might be good
choice for Arabic.
If justify is not defined, all works like before.
If justify is defined, subtitles are aligned as defined
by alignment and justified as defined by justify.
ASS is not extended by this, justify can only be defined
by setting Justify to wanted justification.
Diffstat (limited to 'libass/ass_types.h')
-rw-r--r-- | libass/ass_types.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/libass/ass_types.h b/libass/ass_types.h index f4a6ae5e..88951a79 100644 --- a/libass/ass_types.h +++ b/libass/ass_types.h @@ -28,6 +28,10 @@ #define HALIGN_LEFT 1 #define HALIGN_CENTER 2 #define HALIGN_RIGHT 3 +#define ASS_JUSTIFY_AUTO 0 +#define ASS_JUSTIFY_LEFT 1 +#define ASS_JUSTIFY_CENTER 2 +#define ASS_JUSTIFY_RIGHT 3 #define FONT_WEIGHT_LIGHT 300 #define FONT_WEIGHT_MEDIUM 400 @@ -73,6 +77,7 @@ typedef struct ass_style { int Encoding; int treat_fontname_as_pattern; double Blur; + int Justify; } ASS_Style; |