byroot / pysrt

Python parser for SubRip (srt) files
GNU General Public License v3.0
446 stars 67 forks source link

Inserting Subtitle Snippet #69

Open Fobax opened 7 years ago

Fobax commented 7 years ago

I think it would be nice to have a method where you could insert a subtitle into an existing .srt file. For example:

subs = pysrt.open('some/file.srt')
subs.insert("some subtitle", [start-time], [end-time])

The method would then shift all the existing subtitles down accordingly. Just a thought...