mpv2oboeru

mpv helpers to create flashcards from movies and TV shows
git clone anongit@rnpnr.xyz:mpv2oboeru.git
Log | Files | Refs | Feed | README | LICENSE

Commit: 72eb8fa0f26ae6524793a37e0370e4acbf5e325a
Parent: 7b2b9d68fc268364fe203280cbbc2bbf3a4a91a1
Author: Ren Tatsumoto
Date:   Tue, 29 Sep 2020 16:15:37 +0300

rewrite menu

Diffstat:
Msubs2srs.lua | 42++++++++++++++++++------------------------
1 file changed, 18 insertions(+), 24 deletions(-)

diff --git a/subs2srs.lua b/subs2srs.lua @@ -813,30 +813,24 @@ menu.update = function() table.sort(subs.list) local osd = OSD:new():size(config.menu_font_size):align(4) - osd:bold('mpvacious: advanced options'):newline() - osd:newline() - - osd:bold('Start time: '):append(human_readable_time(subs.get_timing('start'))):newline() - osd:bold('End time: '):append(human_readable_time(subs.get_timing('end'))):newline() - osd:bold('Clipboard autocopy: '):append(clip_autocopy.enabled()):newline() - osd:newline() - - osd:bold('Menu bindings:'):newline() - osd:tab():bold('c: '):append('Set timings to the current sub'):newline() - osd:tab():bold('s: '):append('Set start time to current position'):newline() - osd:tab():bold('e: '):append('Set end time to current position'):newline() - osd:tab():bold('r: '):append('Reset timings'):newline() - osd:tab():bold('n: '):append('Export note'):newline() - osd:tab():bold('g: '):append('Export note using the `Add Cards` GUI'):newline() - osd:tab():bold('m: '):append('Add audio and image to the last added note '):italics('(+shift to overwrite)'):newline() - osd:tab():bold('t: '):append('Toggle clipboard autocopy'):newline() - osd:tab():bold('ESC: '):append('Close'):newline() - osd:newline() - - osd:bold('Global bindings:'):newline() - osd:tab():bold('ctrl+e: '):append('Export note'):newline() - osd:tab():bold('ctrl+h: '):append('Seek to the start of the line'):newline() - osd:tab():bold('ctrl+c: '):append('Copy current subtitle to clipboard'):newline() + osd:submenu('mpvacious options'):newline() + osd:item('Start time: '):text(human_readable_time(subs.get_timing('start'))):newline() + osd:item('End time: '):text(human_readable_time(subs.get_timing('end'))):newline() + osd:item('Clipboard autocopy: '):text(clip_autocopy.enabled()):newline() + osd:submenu('Menu bindings'):newline() + osd:tab():item('c: '):text('Set timings to the current sub'):newline() + osd:tab():item('s: '):text('Set start time to current position'):newline() + osd:tab():item('e: '):text('Set end time to current position'):newline() + osd:tab():item('r: '):text('Reset timings'):newline() + osd:tab():item('n: '):text('Export note'):newline() + osd:tab():item('g: '):text('Export note using the `Add Cards` GUI'):newline() + osd:tab():item('m: '):text('Update the last added note '):italics('(+shift to overwrite)'):newline() + osd:tab():item('t: '):text('Toggle clipboard autocopy'):newline() + osd:tab():item('ESC: '):text('Close'):newline() + osd:submenu('Global bindings'):newline() + osd:tab():item('ctrl+e: '):text('Export note'):newline() + osd:tab():item('ctrl+h: '):text('Seek to the start of the line'):newline() + osd:tab():item('ctrl+c: '):text('Copy current subtitle to clipboard'):newline() menu.overlay_draw(osd:get_text()) end