Commit Graph
4839 Commits
Author SHA1 Message Date
Wez Furlong 32c39fe5ae docs: changelog for #1457 2022-01-04 20:51:58 -07:00
Wez Furlong 6d72101879 launcher: restore j/k movement by default
You now press `/` to enter search mode
2022-01-04 20:49:21 -07:00
Wez Furlong 621dcd3b30 launcher: don't fall off bottom of launcher when filtered 2022-01-04 20:49:21 -07:00
Wez Furlong 6927faebfb launcher: refactor and simplify 2022-01-04 20:49:21 -07:00
Autumn Lamonte c10ff1e41f fix nits 2022-01-04 19:49:06 -08:00
Autumn Lamonte 07a2acb840 #1457 refactor, ClickPosition 2022-01-04 19:49:06 -08:00
Autumn Lamonte e28e09dfa8 #1457 Fix cell offsets 2022-01-04 19:49:06 -08:00
Autumn Lamonte 81f4bbd4aa #1457 Initial commit compiles but doesn't yet work 2022-01-04 19:49:06 -08:00
Jan Katins c338eb12a0 Better upgrade instruction for nightly on mac
The old way would remove the icon form the dock. it needs greedy-latest because the cask is declared as `latest`.

See https://github.com/wez/wezterm/pull/1500 for the discussion
2022-01-04 16:10:29 -08:00
Wez Furlong 1f6e4497e0 launcher: simplify logic
Remove the local awareness of how to spawn into a window and replace
it with using a KeyAssignment to do that instead.

refs: #1485
2022-01-04 09:49:32 -07:00
Wez Furlong 541701d822 refactor tab navigator into launcher menu
The same core code is used to render both the tab navigator
and the launcher.  The context is specified using some flags
so that you don't get an unholy mess in both places.

The net result of this is that the tab navigator now supports
fuzzy matching.

refs: #664
refs: 1485
2022-01-04 09:35:07 -07:00
Wez Furlong 142f3c7d81 launcher now has fuzzy matching
Just start typing text to build up the fuzzy matching term.
The list of items updates to match the results.

refs: #664
refs: #1485
2022-01-04 08:45:15 -07:00
Wez Furlong 68fb416b34 launcher: fix subtraction overflow for tall windows 2022-01-04 08:05:31 -07:00
Wez Furlong 99f94f8425 launcher overlay: fix build on windows 2022-01-04 08:01:37 -07:00
Wez Furlong 9919745d4e launcher: tidy up key/mod display impl to make it look nicer
Make things a little more compact and display friendly

refs: #1485
2022-01-03 23:38:36 -07:00
Wez Furlong 05ec80d945 gui: dedup and sort key assignment launcher entries
refs: #1485
2022-01-03 23:28:37 -07:00
Wez Furlong 5ddb40c7c8 add Display + Debug impl for SpawnCommand
This makes it look tidier in the launcher menu
2022-01-03 23:19:11 -07:00
Wez Furlong 509122c152 Improve launcher menu
* Allow selecting the first few rows by number
* Allow scrolling through long lists of items
* Add actions from key assignments to list

refs: #1485
refs: #1413
2022-01-03 23:07:54 -07:00
Wez Furlong 3ab78f7fac window: remove stray debug 2022-01-03 21:48:50 -07:00
Wez Furlong f002b16ee1 refactor launcher entries to make it easier to build command palette
refs: #1485
2022-01-03 18:27:58 -07:00
Wez Furlong 359fd15416 docs: fix typo in changelog 2022-01-03 17:20:12 -07:00
Wez Furlong d4ee3d8958 docs: changelog for #1491
closes: #1491
2022-01-03 17:09:05 -07:00
Wez Furlong 0e92894dad docs: changelog for #1499 2022-01-03 15:03:49 -07:00
Wez Furlong 2fc23b7c97 input: add KeyCode number -> phys mapping
refs: https://github.com/wez/wezterm/issues/1483#issuecomment-1004377403
2022-01-03 15:01:34 -07:00
Jan Katins ec31562b83 Fix update instruction for nightly macosx via brew
The update variant errored after rm the cask and I had to install the cask again.
2022-01-03 13:55:01 -08:00
Wez Furlong ad96d84745 fonts: remove descender adjustment
It seems like we don't need this any more; things look better
without it.

refs: #1203
refs: #1499
2022-01-03 14:52:19 -07:00
Wez Furlong 0f3dcc2c2b docs: changelog for #1498 2022-01-03 12:54:50 -07:00
Wez Furlong cc507951d0 gui: fix new tab hover colors
refs: #1498
2022-01-03 12:52:58 -07:00
Wez Furlong 672187973b docs: changelog for #1483 2022-01-03 12:36:22 -07:00
Wez Furlong 29eb6dde23 input: key assignments now default to physical mappings
This commit adjusts the config parsing layer so that:

```
return {
  keys = {
    {key="a", ...}
  }
}
```

is now treated as being implicitly the same as `key="phys:A"`.

You can explicitly use `key="mapped:a"` to use the post-keyboard-map
processed value of a key to trigger an assignment, rather than
the physical key location.

refs: #1483
2022-01-03 12:33:19 -07:00
Wez Furlong 83fbba0615 input: define keycode -> phys mapping
refs: #1483
2022-01-03 12:12:10 -07:00
Wez Furlong 8f8ee4e87e input: don't normalize ctrl-backspace to ctrl-h
refs: #1495
2022-01-03 11:28:47 -07:00
Wez Furlong e2e7d60200 fix build on linux
refs: #1495
2022-01-03 11:11:36 -07:00
Wez Furlong 2890e4e723 keyboard: use more consistent backspace/delete names for physkeycodes
refs: #1495
2022-01-03 11:05:38 -07:00
Wez Furlong 34dd0b6688 add mapping from phys to keycode, tidy up windows event processing
refs: #1483
2022-01-03 10:56:32 -07:00
Wez Furlong 640ffbe1e8 window: remove unused local variable on macos 2022-01-03 09:24:30 -07:00
Wez Furlong 5f26746286 window/gui: remove raw/phys fallback fields from KeyEvent
Since we now have RawKeyEvent and a sane way to indicate handling,
we don't need these any more, and it simplifies key dispatch to
remove them.

refs: #1483
2022-01-03 09:13:55 -07:00
Wez Furlong 2616efa72e window: fix test build 2022-01-03 09:13:38 -07:00
Wez Furlong 83052530d9 window: populate live_resizing for Windows
refs: https://github.com/wez/wezterm/issues/1491
2022-01-03 08:41:55 -07:00
Wez Furlong 49904eac9c window: populate live_resizing for x11/wayland
We don't really know for sure, but we can make a reasonable deduction on
X11.

refs: https://github.com/wez/wezterm/issues/1491
2022-01-03 08:38:03 -07:00
Wez Furlong 0224f65fed gui: avoid glitchy live resize
Pass down whether we are in a live resize to the gui layer, so that
we don't incorrectly assume that the scale has changed, and fight
with the window manager.

Built this on my mac: will need to fixup for windows and linux.

refs: https://github.com/wez/wezterm/issues/1491
2022-01-03 08:29:05 -07:00
Benoit de Chezelles 462a256e83 Add missing New in latest release's changelog 2022-01-03 07:04:01 -08:00
Wez Furlong c0502012d5 redefine key assignments in terms of physical key location
and then remove horrible mac hacks.

This resolves the root cause for some horrible mac key mapping stuff
that is responsible for at least 3 different user issues by making the
default key assignments work from the physical key location.  That makes
them unambiguous.

refs: https://github.com/wez/wezterm/issues/601
refs: https://github.com/wez/wezterm/issues/760
refs: https://github.com/wez/wezterm/issues/1080
refs: https://github.com/wez/wezterm/issues/1483
2022-01-03 00:22:51 -07:00
Wez Furlong 369f388f90 window: macOS: workaround key repeat issue when use_ime=true
The logic is explained in comments in this commit.

While we're at it, tweak the IME window position so that it
sits below the text.

refs: #1131
2022-01-02 23:36:57 -07:00
Wez Furlong 05073fbaf9 window: macos: fix double pressing of dead key
We want it to emit the original key; it wasn't changing
any state.
2022-01-02 21:27:17 -07:00
Wez Furlong 8a476b70ab window: macos: generate dead key events
refs: #688
2022-01-02 21:14:59 -07:00
Wez Furlong 7988e65526 cargo update 2022-01-02 19:48:38 -07:00
Wez Furlong 028026049d add window:dead_key_is_active window:leader_is_active
This commit adds a couple of helper methods that provide insight into
the state of the keyboard layer.

The intent is for users to add status information about the keyboard
state.

This commit also ensures that we schedule an update when the leader
key duration expires, and ensures that we close out the leader state
for an invalid key press.

refs: #686
closes: #688

```lua
local wezterm = require 'wezterm';

wezterm.on("update-right-status", function(window, pane)
  local leader = ""
  if window:leader_is_active() then
    leader = "LEADER"
  end
  local dead = ""
  if window:dead_key_active() then
    dead = "DEAD"
  end
  window:set_right_status(leader .. " " .. dead)
end);

return {
  leader = { key="a", mods="CTRL" },
  colors = {
    dead_key_cursor = "orange",
  },
}
```
2022-01-02 19:41:21 -07:00
Wez Furlong c29212be49 add colors.dead_key_cursor to signal dead and leader key processing
When set, the cursor will change to this color during dead key
or leader key processing.

```lua
return {
  colors = {
    dead_key_cursor = "orange",
  },
}
```

refs: #686
refs: #688
2022-01-02 17:49:32 -07:00
Wez Furlong 306133af7a window: implement dead key status events for x11/wayland
refs: #688
2022-01-02 17:20:29 -07:00