win-vind

You can operate Windows with key bindings like Vim.

MIT License

Stars
1.9K
Committers
4

Bot releases are hidden (Show)

win-vind - v5.1.0-beta1

Published by pit-ray over 1 year ago

Minor

New

  • Added <gridmove> function to move a cursor using hints located with grid-cell style (#115, #145, #155).
  • To change fonts or colors, added its options as gridmove_bgcolor, gridmove_fontcolor, gridmove_fontname, gridmove_fontsize, and gridmove_fontweight.
  • Added the gridmove_size option in order to set the grid size, which assumes a text as its value, such as 12x8 for horizontal 12 cells and vertical 8 cells.

In this build, the default bindings of <gridmove> in gui normal mode are set to <c-m>.
For example, we can change its parameters.

gnnoremap <ctrl-h> <gridmove><click_left>  " move and click
set gridmove_size=12x8   " 8x12 matrix
set gridmove_bgcolor=323232
set gridmove_fontcolor=c8c8c8
set gridmove_fontsize=14
set gridmove_fontweight=500
set gridmove_fontname=Arial

Plaese try it.

win-vind - v5.0.0-beta5

Published by pit-ray over 1 year ago

Fix

  • Add runtime tests and fix discovered bugs.

Change

  • Changed the system tray icon to a modern style.
win-vind - v5.0.0-beta4

Published by pit-ray almost 2 years ago

Change

  • The format of version is changed as MAJOR.MINOR.PATCH.TAG.
win-vind - v5.0.0-beta3

Published by pit-ray almost 2 years ago

Add

  • Add listen_interval option to change interval time of synchronous timer. (#112)
  • Add --command option to execute arbitrary commands from terminal. (#101, #97)
  • Introducing automatic runtime test in Python.

Fix

  • Fix problem with mouse not working by --func/--command.

Change

  • Remove default_config directory.
  • Change support year
  • Support old option name for compatibility.
win-vind - v5.0.0-beta2

Published by pit-ray almost 2 years ago

Fix

  • Fix the problem the inputs jam with only system keys like <esc-left>.
win-vind - v5.0.0-beta1

Published by pit-ray almost 2 years ago

The difference between conventional win-vind

Attention: This version also includes the contents of v4.4.0-rc1. Please refer those changes as well.

1. Syntax of .vindrc (Discussed in #96)

The difference between map and noremap

The conventional map and noremap have different purposes. The map is designed to propagate defined macros to other applications except for win-vind, whereas the noremap effects in win-vind score only.

However, the NEW map and the NEW noremap have similar features of Vim and are separated on whether allow remapping like Vim.

Specifically, the map allows remapping with user-defined mapping like the following.

nmap f h  " f --> h
nmap t f  " t --> h

The noremap performs only the default map.

nnoremap f h  " f --> h
nnoremap t f  " t --> f

Arguments of map/noremap

The command kind is the same, but the way to interpret the arguments.

Command Syntax
noremap noremap [trigger-cmd] [target-cmd]
map map [trigger-cmd] [target-cmd]
unmap unmap [trigger-cmd]
mapclear mapclear
command command [trigger-cmd] [targer-cmd]
delcommand delcommand [trigger-cmd] [target-cmd]
comclear comclear

Note: The syntax is not included [ and ].

The [trigger-cmd] is assumed to key typing only and the [target-cmd] has three types of intepretation.

Type of [target-cmd] Example Notes
Function Name map FF <easy_click_left> Calls the pre-defined functions.
Internal Macro map XX a<ctrl-f>bcd Generate macros inside the internal scope of win-vind. This feature uses to define some shortcuts to a function or some combined mapping consisting of multiple pre-defined functions.
External Macro map g {This text is inserted} Define macros that are propagated outside of win-vind by enclosing them in { and }. This emulates the action of the user pressing the keyboard itself, and a single key to single key mapping (e.g. map a {b}) is the most efficient low-level mapping done.

These [target-cmd] can be incorporated into a single map as follows.

map g <easy_click_left>b{This text is inserted}<switch_window>hh<cr>

The mapping represents a macro that is triggered by g, activates easy_click, jumps to the position of the hint in b, enters the string "This text is inserted", and then selects the two-left window with switch_window.

This version will preform an optimization process that merges several maps into one map, unless it contains a command to change the mode. For example, the following mappings will be merged into one.

  • Raw map
nmap b h
nmap o b
nmap p o
  • Optimized map (THIS VERSION)
nmap p h

Below are some examples of use.

  1. Define mode change mapping
    imap <win-[> <to_edi_normal>
    imap <win-]> <to_gui_normal>
    
  2. Text input macros
    nmap mail {[email protected]}
    
  3. Web page launcher
    nmap <ctrl-1> :execute https://example.com<cr>
    
  4. Application launcher
    nmap <ctrl-2> :! notepad<cr>
    
  5. Copy the current line to the bottom line as in Vim.
    enmap t yyGp
    

Mode Prefix (Mentioned in #91)

We received many requests to register maps across several modes, so we added batch-mapping with the same grouping as in Vim.

You can mode prefix to specify modes.

Prefix Mode
  GUI Normal, GUI Visual, Edi Normal, Edi Visual
g GUI Normal, GUI Visual
e Edi Normal, Edi Visual
n GUI Normal, Edi Normal
v GUI Visual, Edi Visual
gn GUI Normal
gv GUI Visual
en Edi Normal
ev Edi Visual
i Insert Mode
r Resident Mode
c Command Mode

However, external macros in cmap and cnoremap are not input to other applications and behave the same as internal macros.

Self-Mapping (#123)

You can disable the absorption of some keys and allow them to be input, as in map <alt> {<alt>}. However, this is only valid for a single key.
If the target command consists of multiple characters like map g abcgd and contains a trigger command, the following warning statement will be printed to log and no mapping will be done.

[Warning] Some part of the command generated from mapping `g * :e https://google.com<return>` was ignored to avoid an infinite loop because it was mapped to itself by mapping `g * :e https://google.com<return>`. If you wish to enter the generated command as is, enclose it in `{}`.

Changed default mapping (Discussed in #118)

Since the mode transition combined with ESC in win-vind was not well received, we adopted the same command as in Vim.

Type of map Function ID Conventional trigger of map New trigger of map
imap to_gui_normal <Esc-Left> <Ctrl-]>
imap to_edi_normal <Esc-Right> <Ctrl-[>

Renamed function name

The conventional <syscmd_*> function names are renamed to simple ones. Please refer next link.
https://github.com/pit-ray/win-vind/blob/master/src/bind/mapdefault.cpp#L466-L522

Eliminated options and replacements

The following is the correspondence between the options that were removed and their replacements. The - is completely obsolete.

Eliminated options Replacements
window_accel window_velocity
window_tweight window_velocity
window_maxv window_velocity
cursor_tweight cursor_resolution
cursor_maxv -
cmd_maxchar -
cmd_maxhist -

Details of the new options are as follows.

New options Notes
window_velocity Pixel-level velocity in the constatnt acceleration motion of the window in winresizer.
cursor_resolution A weight for scaling the time of constant acceleration motion of the mouse cursor.

Implementation

The default map has been defined by default_config/.vindrc but is now embedded in the code to increase startup speed.

win-vind - v4.4.0-rc1

Published by pit-ray over 2 years ago

Minor

New

  • Add the following word-motion which behave almost exactly like Vim. (#57, #75)

    ID Feature Emulation
    move_fwd_word words forward for normal mode. w
    move_fwd_word_simple words forward for visual mode. w
    move_bck_word words backward for normal mode. b
    move_bck_word_simple words backward for visual mode. b
    move_fwd_bigword WORDS forward. W
    move_bck_bigword WORDS backward. B
    move_end_word Forward to the end of words. e
    move_end_bigword Forward to the end of WORDS. E
    move_bckend_word Backward to the end of words. ge
    move_bckend_bigword Backward to the end of WORDS. gE

    These functions do not work in visual mode except for w and b, because they copy the text once and retrieve the text via the clipboard. iskeyword option is fixed to the default value of Vim in Windows and cannot change it currently.
    There is an option charbreak to set the criteria for considering a Unicode character as a single character.

    ID Type Default Note
    charbreak str grapheme Mode for how to split a single Unicode character. The grapheme mode treats a combination character as a single character. The codepoint mode processes the combination character for each codepoint.
win-vind - v4.1.1

Published by pit-ray about 3 years ago

Patch

Fix

  • Fix an invalid width in ArrangeWindow.
  • Fix a problem that freezes when there are no target windows in the exception list arrangewin_ignore.
  • Fix the problem not terminating it after pressing the update button.
win-vind - v4.1.0

Published by pit-ray about 3 years ago

Minor

Fix

  • Fix the problem that command in .vindrc is misinterpreted as cmap.

New

  • Support cmap and cnoremap.
  • Added a list option arrangewin_ignore to remove from the target in ArrangeWindows.
    set arrangewin_ignore = gvim, rainmeter
    
  • Added option to perform UI scan asynchronously, which is required by EasyClick and autofocus_textarea, for performance rather than accuracy. (uiacachebuild, uiacachebuild_lifetime, uiacachebuild_staybegin, uiacachebuild_stayend). A performance improvement of about 30 times can be expected.
    set uiacachebuild
    set uiacachebuild_lifetime = 1000 "frequent update
    
  • Add autofocus_textarea option to automatically focus the nearest text field to the mouse cursor when transitioning to Editor Normal Mode (#26).

Change (*Attention)

  • Change the default binding of transition to Resident Mode to <Esc-Down> due to duplication of <C-i> shortcut for italicizing in MS Office.
  • Also, change the default binding from Resident Mode to Insert Mode to <Esc-Up>.
win-vind - v4.1.0-rc1

Published by pit-ray over 3 years ago

Minor

Fix

  • Fix the problem that command in .vindrc is misinterpreted as cmap.

New

  • Support cmap and cnoremap.
  • Add autofocus_textarea option to automatically focus the nearest text field to the mouse cursor when transitioning to Editor Normal Mode (#26).

Change

  • Change the default binding of transition to Resident Mode to <Esc-Down> due to duplication of <C-i> shortcut for italicizing in MS Office.
  • Also, change the default binding from Resident Mode to Insert Mode to <Esc-Up>.
win-vind - v4.0.1

Published by pit-ray over 3 years ago

Patch

Fix

  • Fix the problem that the head number for repeating is shown in Resident Mode. (#24)
win-vind - v4.0.0

Published by pit-ray over 3 years ago

Major Update

New

  • Support low-level key mapping (e.g. imap <capslock> <ctrl>) (#20)
  • Support Run Commands style configuration .vindrc
  • Support set, map, noremap, unmap, mapclear, command, delcommand, comclear, and source commands.
  • Add a menu to check updates in the the task tray.
  • Add a menu to register into the startup list in task tray.
  • Support startup in zip version.
  • Support win-vind.exe --help.
  • Add winresizer for GUI.
  • Add Instant GUI Mode to use as mapleader.
  • Add ShellExecute wrapper binding (:execute, :e, :edit)
  • Support real command line with your favorite shell in :! command
  • Support automatic detection of keyboard layout
  • Faster boot
  • Change command in visual block (#22)

Change

  • Eliminated GUI-based configuration
  • Renew default mode layers (#19)
  • Renew default bindings
  • Eliminated settings of shortcut application.
  • All bindings and options have been renamed, so it is not compatible with v3 and earlier.

Fix

  • Fix the deadlock of LoweLevelKeyboardProc and SendInput.
  • Fix the problem that when multiple characters were inputted at the same time, they are deleted with once BackSpace in Command Mode.
  • And fixed minor bugs.

For Developer

  • Updated the version of wxWidgets to 3.1.5.
  • The source code for wxgui will not be built since we have discontinued GUI-based configuration, but we are keeping it in case there is a request for a GUI for configuration.
win-vind - v3.3.0

Published by pit-ray over 3 years ago

Minor

Improve

  • EasyClick supports multi-thread drawing
  • Supports for window rotation without window tiling
  • Supports for multiple monitors with Exchange and Snap of a window
  • SwitchWindow supports keystroke repeating when selecting a window
  • Support a syntax like 2d2w in Vim emulation
  • Support UNICODE in Suppress For Vim option

New

  • Add <Esc> canceling to prevent freezing when passing very large values as the head number in a command (e.g. 100000h).

Fix

  • Fix the problem referring to the screen metrics of the primary monitor in jump_top.
  • Change the measurement points for the distance in Select or Exchange of a window
  • Disable keystroke repeating for hints in EasyClick

Development

  • Change the key matching system to an automaton based one
  • Major refactoring of the bindings-selection algorithm
  • Organized the directory hierarchy.
  • Add global namespace vind
  • Significantly reduced the number of arguments to BindedFunc::process by making the KeyLogger a polymorphism one instead of STL-based.
  • Add architecture documentation for development.
  • Add some test codes
  • Fix a problem that setup_libs.bat over-install though the libraries are already installed.
win-vind - v3.2.3

Published by pit-ray over 3 years ago

Patch

Fix

  • Fix the problem not working Add and Delete and Return to Default buttons in the Bindings tab of GUI. (#13)
win-vind - v3.2.2

Published by pit-ray over 3 years ago

Patch

Fix

  • Changed the way to get the home directory. (#8)

Change

  • Apply some delay when exists a lot of GUI objects in EasyClick, so it's a little faster.
win-vind - v3.2.1

Published by pit-ray over 3 years ago

Patch

Fix

  • Fix a problem with misunderstanding the root directory when using it from the command line.
  • Support Unicode in a feature to make a directory.
win-vind - v3.2.0

Published by pit-ray over 3 years ago

Minor

Change

  • Support a 3-character hinting in EasyClick.
  • The time required to scan GUI objects in EasyClick reduced BY A THIRD.
  • Changed a function name from CloseOpenedFile to CloseCurrentTab.
  • Changed some default bindings.
  • Support Unicode filenames
  • Refactored GUI of the settings panel.

New

  • Add features to resize windows

    • Arrange all windows (<C-w>=)
    • Rotate arranged windows in a current monitor (<C-w>r)
    • Rotate arranged windows in a current monitor in reverse (<C-w>R)
    • Exchange a window with the most nearest one (<C-w>x)
    • Resize the width of a window (:vertical resize <num>)
    • Increase the width of a window (<C-w><gt>, :vertical resize +<num>)
    • Decrease the width of a window (<C-w><lt>, :vertical resize -<num>)
    • Resize the height of a window (:resize <num>)
    • Increase the height of a window (<C-w>+, :resize +<num>)
    • Decrease the height of a window (<C-w>-, :resize -<num>)
    • Snap a current window to left (<C-w>H)
    • Snap a current window to right (<C-w>L)
    • Snap a current window to top (<C-w>K)
    • Snap a current window to bottom (<C-w>J)
  • Add features to select windows

    • Select a left window (<C-w>h)
    • Select a right window (<C-w>l)
    • Select an upper window (<C-w>k)
    • Select a lower window (<C-w>j)
  • Add features to open windows

    • Open a new window with horizontal split (:split)
    • Open a new window with vertical split (:vsplit)
win-vind - v3.1.0

Published by pit-ray over 3 years ago

Minor

Fix

  • Fix resource leaks

Change

  • Generate log directory when it does not exist.
  • Generate log files with a date.
  • Fix the problem generating an unnamed .exe file.
  • Improve the exception system of GUI.
  • Disable showing -- TARGETING ON -- or -- TARGETING OFF -- when Dedicate to One Window is disabled.

New

  • Add various versions of EasyClick (#5)
    • Easy Click Left (FF, Fo)
    • Easy Click Right (Fa)
    • Easy Click Middle (Fm)
    • Easy Click Hover (Fh)
  • Implement a useful GUI for key-config.
    • Add a feature to search functions.
    • Add a feature to edit bindings with gVim.
    • Add guides of a key config file when editing with vim.
  • Add Vim keybindings in the preferences window of win-vind.
    • Forward UI Navigation (l, <Right>)
    • Backward UI Navigation (h, <Left>)
    • Decide a Focused UI object (o)
    • My Config Window Normal Mode (<Esc>)
    • My Config Window Insert Mode (i, a)
  • Add a feature to keep old settings.
  • Supports the high DPI.
  • Supports free GUI font change.
win-vind - v3.0.2

Published by pit-ray over 3 years ago

Patch

Fix

  • Fix the problem not working scrolling (e.g. <c-e>, <c-y>).
  • Fix the problem unintentionally inputting 4 after % command.
win-vind - v3.0.1

Published by pit-ray almost 4 years ago

Patch

Fix

  • Fix the problem repeating key-stroke infinity.
  • Improve safety.
  • Fix the problem of not absorbing key inputs when using Insert Mode.

Change

  • Change the time to check the shared memory for inter-processing communication.
  • Change UI design to modern (MSVC build).
  • EasyClick always makes a center of a window a candidate as well.

New

  • Support Microsoft Visual Studio 2019 64-bit / 32-bit
  • Support providing 32-bit binary.
  • Add some scripts to prepare environments for development.
Package Rankings
Top 6.64% on Proxy.golang.org