Which is (or should be) a key in the SSAFile.styles dict. Subtitles and styles are connected via an SSAFile they belong to. (note the spelling, which is different from SubStation proper). Like a subtitle event, a style also consists of “fields” see SSAStyle.FIELDS for a list
In SubStation, each subtitle ( SSAEvent) is associated with a style which defines its font, color, etc. SSAStyle - a subtitle style ¶ class pysubs2. Text of subtitle (with SubStation override tags) type = None ¶ Subtitle start time (in milliseconds) style = None ¶
AEGISUB SUBTITLE OUTLINECOLOR DISAPPEAR FULL
See SSAFile.shift() for full description. Writing to this property replaces SSAEvent.text with given plain Subtitle text as multi-line string with no tags (read/write property). Layer number, 0 is the lowest layer (ASS only) marginl = None ¶ SSAEvent.type to "Dialogue" or "Comment". Setting this property is equivalent to changing
When true, the subtitle is a comment, ie. Subtitle end time (in milliseconds) equals ( other ) ¶įield-based equality for SSAEvents. Setting negative durations raises ValueError. Writing to this property adjusts SSAEvent.end. Subtitle duration in milliseconds (read/write property). > ev = SSAEvent ( start = make_time ( s = 1 ), end = make_time ( s = 2.5 ), text = "Hello World!" ) FIELDS = frozenset() ¶ Wasn’t loaded from MicroDVD, or if you wish save it withĭifferent framerate, use this argument. the framerate usedįor loading the file, if any). fps ( float) – Framerate for frame-based formats (MicroDVD),įor other formats this argument is ignored.Otherwise, format is detectedĪutomatically from file extension. format ( str) – Optional, specifies desired subtitle format.encoding ( str) – Character encoding of output file.ĭefaults to UTF-8, which should be fine for most purposes.save ( path, encoding=u'utf-8', format_=None, fps=None, **kwargs ) ¶ load ( "microdvd-subtitles.sub", fps = 23.976 ) SSAFile. load ( "subrip-subtitles.srt" ) > subs2 = pysubs2.