input.conf (3055B)
1 # Main reference: 2 # https://mpv.io/manual/master/#command-interface 3 4 # Rebind 5 . cycle-values loop-file inf no 6 a cycle audio 7 s cycle sub 8 Shift+a cycle audio down 9 Shift+s cycle sub down 10 Ctrl+s screenshot video # without subtitles 11 Ctrl+Shift+s screenshot # with subtitles 12 13 # Volume controls 14 k add volume 5 15 j add volume -5 16 UP add volume 5 17 DOWN add volume -5 18 19 # Position Seeking 20 l seek 5 21 h seek -5 22 RIGHT seek 5 23 LEFT seek -5 24 25 # 2x volume controls 26 Shift+k add volume 10 27 Shift+j add volume -10 28 Shift+UP add volume 10 29 Shift+DOWN add volume -10 30 31 # 6x Position Seeking 32 Shift+l seek 30 33 Shift+h seek -30 34 Shift+RIGHT seek 30 35 Shift+LEFT seek -30 36 37 # Define Ctrl+[/] to rotate video 38 Ctrl+[ add video-rotate 90 39 Ctrl+] add video-rotate -90 40 41 # Define Alt+=/- to zoom in / zoom out 42 Alt+= add video-zoom 0.25 43 Alt+- add video-zoom -0.25 44 45 # Reset zooming with Alt+Backspace 46 Alt+BS set video-zoom 0; set video-pan-x 0; set video-pan-y 0 47 48 # ------------------------------------------------------------------------ 49 # Scripts 50 # - Delete the current file 51 Ctrl+d run "/bin/sh" "-c" "(choice=`printf 'Yes\nNo' | dmenu -p \"Delete \\\"${path}\\\"?\"` && [ $choice = 'Yes' ] && rm \"${PWD}/${path}\" && dunstify \"MPV\" \"Removed \\\"${PWD}/${path}\\\".\")" 52 53 # - Copy the name of the file to clipboard 54 Ctrl+y run "/bin/sh" "-c" "printf '%s' \"${path}\" | xclip -selection c"; show-text "Copied ${path} to Clipboard" 55 56 # - Copy subtitle-text to clipboard 57 ctrl+s run "/bin/sh" "-c" "echo \"${sub-text}\" | tr '\n' ' ' | xclip -selection c" ; show-text "Copied subtitle to clipboard." 58 59 # - Copy a word from subtitle-text to clipboard (dmenu) 60 ctrl+shift+s run "/bin/sh" "-c" "echo \"${sub-text}\" | tr ' ' '\n' | dmenu -i -l 20 | xclip -selection c" ; show-text "Copied word to clipboard." 61 62 # TODO: Figure this out 63 # - Paste from clipboard to playlist 64 Ctrl+p run "/bin/sh" "-c" "xclip -selection c -o" 65 ctrl+p loadfile "$(xclip -selection c -o)" append-play 66 67 68 c run "st" "-g" "81x25-10-10" "-e" "/bin/sh" "-c" "youtube-viewer --colorful --comments-order=relevance --comments='https://www.youtube.com/${filename}' --page=1 --no-interactive | less -R" 69 70 # ------------------------------------------------------------------------ 71 # Mouse controls 72 # - Define mouse scrolling to change volume 73 WHEEL_UP add volume 5 74 WHEEL_DOWN add volume -5 75 76 # - Define mouse scrolling to change position 77 WHEEL_RIGHT seek 5 78 WHEEL_LEFT seek -5 79 80 # - Define Shift+Mouse-Scrolling to move 5s 81 Shift+WHEEL_UP seek 5 82 Shift+WHEEL_DOWN seek -5