2
* This file is part of SubLib.
3
* Copyright (C) 2006 Pedro Castro
5
* SubLib is free software; you can redistribute it and/or modify
6
* it under the terms of the GNU General Public License as published by
7
* the Free Software Foundation; either version 2 of the License, or
8
* (at your option) any later version.
10
* SubLib is distributed in the hope that it will be useful,
11
* but WITHOUT ANY WARRANTY; without even the implied warranty of
12
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
* GNU General Public License for more details.
15
* You should have received a copy of the GNU General Public License
16
* along with this program; if not, write to the Free Software
17
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
21
using System.Text.RegularExpressions;
25
internal class SubtitleFormatAdvancedSubStationAlpha : SubtitleFormatSubStationAlpha {
27
protected override string FormatName {
28
get { return "Advanced Sub Station Alpha"; }
31
protected override SubtitleType FormatType {
32
get { return SubtitleType.AdvancedSubStationAlpha; }
35
protected override string[] FormatExtensions {
36
get { return new string[] { "ass" }; }
39
protected override string FormatBodyBeginOut {
40
get { return "[Events]\nFormat: Layer, Start, End, Style, Actor, MarginL, MarginR, MarginV, Effect, Text\n"; }
43
protected override string FormatSubtitleOut {
44
get { return "Dialogue: 0,<<StartHours,1>>:<<StartMinutes>>:<<StartSeconds>>.<<StartCentiseconds>>,<<EndHours,1>>:<<EndMinutes>>:<<EndSeconds>>.<<EndCentiseconds>>,Default,,0000,0000,0000,,<<Style>><<Text>><<EndOfStyle>>"; }
47
protected override string ScriptType {
48
get { return "v4.00+"; }
51
protected override string StyleTypeIn {
52
get { return @"V4\+"; }
55
protected override string StyleSection {
57
return "[V4+ Styles]\nFormat: Name, Fontname, Fontsize, PrimaryColour, SecondaryColour, OutlineColour, BackColour, Bold, Italic, Underline, StrikeOut, ScaleX, ScaleY, Spacing, Angle, BorderStyle, Outline, Shadow, Alignment, MarginL, MarginR, MarginV, Encoding\n" +
58
"Style: Default,Tahoma,24,&H00FFFFFF,&H00FFFFFF,&H00FFFFFF,&H00C0C0C0,-1,0,0,0,100,100,0,0.00,1,2,3,2,20,20,20,1\n\n";