1
1
mirror of https://github.com/wez/wezterm.git synced 2024-09-21 11:50:42 +03:00
Commit Graph

2479 Commits

Author SHA1 Message Date
Wez Furlong
573f2435c8 Automate updating linuxbrew tap
refs: https://github.com/wez/wezterm/issues/239
2020-07-05 09:40:52 -07:00
Wez Furlong
ab1e83c7eb window: fallback to basic opengl context if extensions fail
8f1f1a65ea added support for probing
for opengl extensions, and I thought that I had the fallback covered
but it turned out that we were only falling back if one of the major
extensions wasn't present.

This commit adds a fallback for the case where things look ok at
first glance, but where they fail at runtime for whatever reason.

refs: https://github.com/wez/wezterm/issues/235
2020-06-29 18:05:43 -07:00
Wez Furlong
2c3f59b0e4 cargo update 2020-06-29 17:52:25 -07:00
Wez Furlong
b936e9685b docs: add some input troubleshooting info the FAQ
closes: https://github.com/wez/wezterm/issues/216
2020-06-25 07:15:57 -07:00
Wez Furlong
5b654710cb wezterm: fix already mutably borrowed: BorrowError when switching tabs
Not sure why this didn't bubble up earlier, but the issue was introduced
by 4e6357b218

And it was not setting focus=true on the new tab either :-/

refs: https://github.com/wez/wezterm/issues/232
2020-06-22 17:08:29 -07:00
Wez Furlong
2b2555c62a wezterm: avoid extraneous work in search overlay
viewport changes could do a little bit more than they needed
to when the search overlay was active.  Guard against that by
checking to see if the viewport is already set to the new position.
2020-06-21 22:44:11 -07:00
Wez Furlong
b307df6add term+termwiz: handle OSC L and OSC l
These are equivalent to OSC 2 and OSC 1 respectively.

We now also respond to requests to fetch the window title
2020-06-21 10:46:03 -07:00
Wez Furlong
e507d4e1e7 termwiz: allow OperatingSystemCommandCode to have non-numeric mappings
The code assumed that OSC parameters were always numeric, but that isn't
the case.

In order to allow adding non-numeric OSC code we need to adjust and
allow for the codes to be any string value, and that's what this
commit does.

It shouldn't change any other behavior.
2020-06-21 10:03:28 -07:00
Wez Furlong
076cf3d177 wezterm: teach renderer about overline
This commit adds an overline glyph which is simply a line drawn at
the top of the cell.

Due to the way that we use a single glyph for the line layer, this
actually adds a handful of combination glyphs for the different
underline, overline and strikethrough possibilities.

It's getting a bit hefty.  Adding another similar attribute in
the future (eg: maybe wiggly underlines?) might prove to be too
much for the simple approach we have right now.

```bash
printf "\x1b[53moverline\x1b[0m\n"
```
2020-06-20 23:18:52 -07:00
Wez Furlong
badc4f9d9c term+termwiz: add Overline support
This commit teaches the terminal model about the overline attribute
and the SGR codes to enable/disable overline.

The render layer in the GUI doesn't yet understand this attribute.
2020-06-20 22:48:36 -07:00
Wez Furlong
4e6357b218 term: enable DECSET 1004 Focus Reporting
This is enabled only for local terminals for now; the multiplexer
protocol will need to be extended to carry this signal.
2020-06-20 22:01:56 -07:00
Wez Furlong
e4fb68bb22 docs: update link to upstream color schemes
I noticed that the website was lagging behind the github page,
so link to the screenshots on github directly.
2020-06-20 19:06:06 -07:00
Wez Furlong
77c5220f59 wezterm: sync with new themes from iterm2colorschemes.com
This is a sync with the themese as of
eeded52088
2020-06-20 18:54:19 -07:00
Wez Furlong
2ab87b29a7 docs: update for latest release tag 2020-06-20 16:07:21 -07:00
Wez Furlong
e00b076c81 docs: faq: add note about tmux and unicode
refs: https://github.com/wez/wezterm/issues/220
2020-06-20 13:53:54 -07:00
Wez Furlong
d35e7ba6e4 docs: discuss Alt/Option key behavior and configuration
refs: https://github.com/wez/wezterm/issues/216
2020-06-20 13:37:59 -07:00
Wez Furlong
625caf2e68 docs: link to the contributing file in the repo 2020-06-20 13:09:04 -07:00
Wez Furlong
98fe7cabba docs: add note about hyperlink matching improvements
closes: https://github.com/wez/wezterm/issues/221
2020-06-20 12:51:00 -07:00
Wez Furlong
843ce152ec wezterm: ActivateTab now accepts negative numbers
This allows setting up shortcuts relative to the final tab in
a window, rather than always being relative to the first.

The default assignment for CTRL+SHIFT+9 is now `ActivateTab=-1`
as a convenient way to always reach the last tab.

refs: https://github.com/wez/wezterm/issues/228
2020-06-20 12:45:09 -07:00
Wez Furlong
d1dd28df46 update Cargo.lock
Should have been included in refs: https://github.com/wez/wezterm/pull/226
2020-06-20 12:37:40 -07:00
Luben Karavelov
5a76302c84 Update to allsorts-0.4 2020-06-20 12:31:11 -07:00
Wez Furlong
59ca0da7ad term: fix representation of unmodified F5+
We were unconditionally adding the encoded form of the modifier
mask (eg: appending `;1~` to the sequence) and not all apps know
how to interpret that.

refs: https://github.com/wez/wezterm/issues/227
2020-06-20 12:11:35 -07:00
Wez Furlong
fded650ccb term: add DECRQSS DECSLRM response
While testing this with esctest, it was apparent that xterm deviates
from the DEC docs by allowing a minimum region size smaller than 2,
so adjust our restriction accordingly.
2020-06-20 11:12:18 -07:00
Wez Furlong
b69c9b1c70 termwiz+term: add basic support for DECRQSS
Now that we're reporting a higher level from DA1, apps are asking
more exotic codes.  eg: vttest now asks about the conformance level,
but doesn't have a timeout on that request and hangs if we don't
respond.

This commit adds a bit of plumbing to make it easier to consume
and parse DCS sequences that are known to be short/short-lived,
and teaches the term layer to respond to a couple of possible
DECRQSS queries.
2020-06-20 11:04:37 -07:00
Wez Furlong
fea8f2479e termwiz: add Display impl for device control mode 2020-06-20 10:06:50 -07:00
Wez Furlong
aa106b33f1 termwiz: improve Debug impl for EnterDeviceControlMode 2020-06-20 09:51:25 -07:00
Wez Furlong
e2dc0add83 termwiz: recognize CSI > PP ; Pv m sequence
This is an xterm sequence that adjusts how the terminal
encodes keyboard output.

This commit teaches termwiz to parse and encode the sequence,
but doesn't teach the terminal emulator to do anything with it
at this time.

I'm adding this because vim sends these sequences and I wanted
to understand what they were for.
2020-06-19 23:40:48 -07:00
Wez Furlong
28eda7663e ci: take another pass at updating apt 2020-06-19 21:46:33 -07:00
Wez Furlong
99e736605e ci: run apt update on all apt based systems
GitHub actions ubuntu runs have been broken for the last day and
a half, so insert this to see if it will help.
2020-06-19 21:28:05 -07:00
Wez Furlong
35a3f802c2 termwiz+term: improved emulation conformance in a number of areas
This commit adds support for left/right margins and has been
tested against esctest, with a final status of:

```
309 tests passed, 239 known bugs
```

"known bugs" also includes unimplemented features; we have a
similar degree as iTerm2.

As of this commit, we now report as a vt520ish machine to DA1.
I confess to not having read enough of the relevant docs
to know whether this is totally righteous.
2020-06-19 21:20:05 -07:00
Wez Furlong
efe425c4f6 term: s/scroll_region/top_and_bottom_margins/ 2020-06-18 15:41:54 -07:00
Wez Furlong
e30f42a868 termwiz: fix hyperlink matching issue with double wide chars
refs: https://github.com/wez/wezterm/issues/221
2020-06-18 09:46:03 -07:00
Wez Furlong
bd3844d665 term: improve CUU conformance, pass CUU esctests 2020-06-18 07:45:33 -07:00
Wez Furlong
e373755be2 termwiz: improve CSI parsing conformance
We weren't parsing `CSI 2H`; we'd decide that because it needed two
parameters it was an error instead of defaulting the omitted second
parameter to 1.
2020-06-18 07:44:26 -07:00
Wez Furlong
99108afa60 term: improve CUD conformance and pass CUD esctest 2020-06-18 07:19:49 -07:00
Wez Furlong
5ef357bb95 termwiz: improve rgb color parsing conformance with XParseColor 2020-06-18 06:59:02 -07:00
Wez Furlong
22f6ec0070 term: implement CBT and pass CBT esctests 2020-06-18 05:50:28 -07:00
Wez Furlong
1288819180 term: improve esctest BS test conformance 2020-06-18 05:43:47 -07:00
Wez Furlong
b6e9fb07d4 term: improve esctest ANSIRCTests conformance
These tweaks to cursor save/restore enable wezterm to pass my wezterm
enabled local branch of esctest.
2020-06-17 23:09:37 -07:00
Wez Furlong
2957173a57 termwiz: also allow #FFF form of color spec
We allowed the 6-digit variant, also allow the 3-digit variant.
2020-06-17 21:56:30 -07:00
Wez Furlong
5c5bef934b add decset 1047; our impl is the same as decset 47 2020-06-17 21:44:11 -07:00
Wez Furlong
15606c2e49 docs: update released version info for some newer features 2020-06-17 00:08:43 -07:00
Wez Furlong
574233e8d7 docs: add a bit about contributing 2020-06-16 22:16:56 -07:00
Wez Furlong
8f1f1a65ea window: handle opengl context loss on windows.
With this commit, we now survive a reinstall or upgrade of the nvidia
drivers on my Windows sytem without crashing.

This commit allows notifying the application of the context loss
so the application can either try to reinit opengl or open a new
window as a replacement and init opengl there.

I've not had success at reinitializing opengl after a driver upgrade;
it seems to be persistently stuck in a state where it fails to allocate
a vertex buffer.

SO, the state we have now is that we try to reinit opengl on a new
window, and if that fails, leave it set to the software renderer.

This isn't a perfect UX, but it is better than terminating!

refs: https://github.com/wez/wezterm/issues/156
2020-06-16 21:17:48 -07:00
Wez Furlong
3f04ce3bba wezterm: remove unused failure deps, bump lazy_static 2020-06-16 17:27:06 -07:00
Wez Furlong
46111c1cdb docs: fix config link 2020-06-16 16:07:39 -07:00
Wez Furlong
d9f84da6ec fonts: fix second parameter of wezterm.font
The following configuration now works as intended:

```lua
local wezterm = require 'wezterm';
return {
  -- font = wezterm.font('JetBrains Mono'),
  font_rules = {
    {
      italic = false,
      intensity = "Normal",
      font = wezterm.font("JetBrains Mono"),
    },
    {
      italic = true,
      font = wezterm.font("JetBrains Mono", {italic=true}),
    },
    {
      intensity = "Bold",
      font = wezterm.font("JetBrains Mono", {bold=true}),
    },
    {
      italic = true,
      intensity = "Bold",
      font = wezterm.font("JetBrains Mono", {bold=true, italic=true}),
    }
  },
}
```
2020-06-16 08:27:35 -07:00
Wez Furlong
ff32dc727f window: allow opengl reinit on context loss on macos
Again, I haven't seen a case where this triggers, but this compiles
and works in the normal case.
2020-06-15 12:33:52 -07:00
Wez Furlong
6744a0235d window: fixup tests for opengl init changes 2020-06-15 12:33:30 -07:00
Wez Furlong
aa93008935 window: allow re-initializing opengl for X11 and Wayland
I don't have a great way to test this on those platforms,
so other than compiling and running and verifying that things
work normally, I'm not sure if this is sufficient!
2020-06-15 09:03:16 -07:00