.. automodule:: pysubs2 :members: load, load_from_whisper, make_time, Color, Alignment, VERSION
.. autoclass:: pysubs2.SSAFile :members: events, styles, info, fps, format, aegisub_project, fonts_opaque
.. automethod:: SSAFile.load
.. automethod:: SSAFile.save
.. automethod:: SSAFile.from_string
.. automethod:: SSAFile.to_string
.. automethod:: SSAFile.from_file
.. automethod:: SSAFile.to_file
.. automethod:: SSAFile.shift
.. automethod:: SSAFile.transform_framerate
.. automethod:: SSAFile.rename_style
.. automethod:: SSAFile.import_styles
.. automethod:: SSAFile.remove_miscellaneous_events
.. automethod:: SSAFile.equals
.. automethod:: SSAFile.sort
.. autoclass:: pysubs2.SSAEvent :members:
.. autoclass:: pysubs2.SSAStyle :members:
.. automodule:: pysubs2.time :members: :exclude-members: Times
.. automodule:: pysubs2.exceptions :members:
Note
This submodule contains pysubs2 internals. It's mostly of interest if you're looking to implement a subtitle format not supported by the library. In that case, have a look at :class:`pysubs2.formats.FormatBase`.
.. autofunction:: pysubs2.substation.parse_tags
.. automodule:: pysubs2.formats :members:
.. autoclass:: pysubs2.formats.FormatBase :members:
Here you can find specific details regarding support of the individual subtitle formats.
Tip
Some formats support additional keyword parameters in their from_file()
or to_file()
methods.
These are used to customize the parser/writer behaviour.
.. autoclass:: pysubs2.substation.SubstationFormat :members:
.. autofunction:: pysubs2.substation.parse_tags
.. autoclass:: pysubs2.subrip.SubripFormat :members:
.. autoclass:: pysubs2.mpl2.MPL2Format :members:
.. autoclass:: pysubs2.tmp.TmpFormat :members:
.. autoclass:: pysubs2.webvtt.WebVTTFormat :members:
.. autoclass:: pysubs2.microdvd.MicroDVDFormat :members:
.. autoclass:: pysubs2.jsonformat.JSONFormat :members:
.. autofunction:: pysubs2.whisper.load_from_whisper