2 # Copyright Simon Lydell 2015.
4 # This file is part of VimFx.
6 # VimFx is free software: you can redistribute it and/or modify
7 # it under the terms of the GNU General Public License as published by
8 # the Free Software Foundation, either version 3 of the License, or
9 # (at your option) any later version.
11 # VimFx is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 # GNU General Public License for more details.
16 # You should have received a copy of the GNU General Public License
17 # along with VimFx. If not, see <http://www.gnu.org/licenses/>.
20 notation = require('vim-like-key-notation')
36 'aR': 'reload_all_force'
41 'G': 'scroll_to_bottom'
42 '0 ^': 'scroll_to_left'
43 '$': 'scroll_to_right'
48 'd': 'scroll_half_page_down'
49 'u': 'scroll_half_page_up'
50 '<space>': 'scroll_page_down'
51 '<s-space>': 'scroll_page_up'
57 'gK': 'tab_move_right'
60 'g^': 'tab_first_non_pinned'
62 'gp': 'toggle_pin_tab'
64 'gx$': 'close_tabs_to_end'
65 'gxa': 'close_other_tabs'
71 'gf': 'follow_in_focused_tab'
72 'af': 'follow_multiple'
73 '[': 'follow_previous'
96 '<space>': 'rotate_markers_forward'
97 '<s-space>': 'rotate_markers_backward'
98 '<backspace>': 'delete_hint_char'
101 '<escape> <enter>': 'exit'
104 'hint_chars': 'fjdkslaghrueiwovncm'
105 'prev_patterns': 'prev,previous,‹,«,◀,←,<<,<,back,newer'
106 'next_patterns': 'next,›,»,▶,→,>>,>,more,older'
108 'prevent_autofocus': true
109 'ignore_keyboard_layout': false
112 'autofocus_limit': 100
113 'smoothScroll.lines.spring-constant': '1000'
114 'smoothScroll.pages.spring-constant': '2500'
115 'smoothScroll.other.spring-constant': '2500'
121 for modeName, modeShortcuts of shortcuts
122 for keys, name of modeShortcuts
123 name = "mode_#{ modeName }_#{ name }" unless modeName == 'normal'
124 key_options["commands.#{ name }.keys"] =
125 keys.split(/\s+/).map(notation.parseSequence)
127 all = Object.assign({}, options, advanced_options, key_options)
129 exports.options = options
130 exports.advanced_options = advanced_options
131 exports.key_options = key_options
133 exports.BRANCH = 'extensions.VimFx.'