Menu

#629 Key/mouse bindings/shortcuts from VLC

Next_Release
open
nobody
None
5
2016-02-08
2016-01-30
sniffer
No

Here is a copy of keybindings configuration file that maps vlc shortcuts to MPV - people using VLC may find it useful to find the VLC keys configuration file to be shipped together with SMPlayer itself.

These were mapped for MPV but can be mapped to SMPlayer (copy in attachment):

https://github.com/sheharyarn/dotfiles/blob/master/Others/MPV/input.conf

1 Attachments

Discussion

  • sniffer

    sniffer - 2016-01-30

    I've created a VLC keymap file for SMPlayer using: https://wiki.videolan.org/Hotkeys_table/ and default.keys file as a base reference.

    Changes (applied over default.keys):
    - Added all VLC key mappings possible to port,
    - When conflicting key bindings were found, the VLC key bindings took preference,
    - If it was possible I've preserved the original key bindings from SMPlayer (if VLC did not have that key binding),
    - When a key was used in VLC for single action (for ex. stop/pause etc) and SMPlayer had the same key mapped to one of the actions from a pair (for example prev/next or decrease/increase action pairs) both pair mappings were removed to maintain symetry,
    - When a mapping was defined in SMPlayer and was not used in VLC I preserved the original binding as an alternate to the new (VLC) binding,
    - Additionally added (not present in the reference): Ctrl+H to toggle compact mode (Ctrl+C originally, also preserved),
    - Additional bindings added to zoom switching (Ctrl+1/2/3/4 in reference, Alt+1/2/3/4 in VLC 3.0 git).

    Some more testing is obviously needed as I didn't test all of the key bindings myself.

    Note:
    1. When importing these bindings using Options->Settings->Keyboard, changed key bindings that were removed due to conflicts will not be removed after import. (I consider this a bug in SMPlayer (v16.1 here) because if a key binding name is present in the imported file it should override the current value, which is not the case if the new value is empty - i.e there is no key binding),
    2. To more completely resemble VLC you should also change the Mouse Wheel action to Change Volume instead of Seek,
    3. In VLC some actions (e.g. subtitle text scaling) are associated with a modifier key and wheel position change (e.g Ctrl + Mouse Wheel Up) which is not possible in SMPlayer,
    4. SMPlayer does not have an option for Horizonal Mouse Wheel movement (e.g. in VLC horizonal mouse wheel controls Seek/Position).

     

    Last edit: sniffer 2016-01-30
  • Ricardo Villalba

    Some shortcuts failed to load because there were spaces as separators instead of tabs. Anyway I've just modified (r7377) the function that parses the file to allow spaces as well, so it can read your file.

    However there are still some conflicts, for example the cursor keys are used twice:

    move_up Up
    move_down Down
    move_left Left
    move_right Right

    dvdnav_up Up
    dvdnav_down Down
    dvdnav_left Left
    dvdnav_right Right

    It would be great if you could fix them.

     
  • sniffer

    sniffer - 2016-02-04

    Thanks for clearing this up - I haven't noticed those spaces. So thats why empty binding didn't reset the default binding, right?

    When it comes to conflicts it is not easy to figure out what some options are responsible for without going through the source code.

    For example what are those "move" options responsible for? Together with "pl_prev/next/up/down" and "dvdnav" options seems like there are too many.

    IMHO the "move" options with two new "move_prev" and "move_next" options could possibly replace the "dvdnav_{up,down,left,right,prev}" and "pl_{prev,next,move_up,move_down}" and SMPlayer can bind to key actions depending on context. Thats how VLC does it (at least for dvds).

    Do you see making a change here?

    As to what is missing when compared to VLC that could potentially be added is (thats just what I can remember now):
    - dvdnav_next,
    - dvdnav_chapter_{prev,next} or dvdnav_title_{prev,next} (depending on what dvdnav_prev actually does),
    - size_25,
    - the "ctrl + horizontal scroll" option to decrease/increase subtitle text size",
    - if possible please add an option to the Key bindings table in preferences window to allow column sorting by value - one could find duplicates very easily then.

    Any other conflicts that you've spotted?

     
  • Ricardo Villalba

    I've just fixed the conflicts, changing some shortcuts and deleting others.

     

Log in to post a comment.