1
1
mirror of https://github.com/wez/wezterm.git synced 2024-11-23 15:04:36 +03:00
Commit Graph

1267 Commits

Author SHA1 Message Date
Wez Furlong
760864b6b2
quick select: make user patterns take precedence
I think the future for this is to extend the Pattern type to accept
a list of regexes and use a RegexSet to unambiguously handle multiple
patterns with captures.

That might help a little with https://github.com/wez/wezterm/issues/3247
but the stated use in that issue may not even work with the rust
regex crate.

For now we do the simple thing and match the user's patterns
first.

refs: https://github.com/wez/wezterm/issues/3456
2023-04-06 15:52:52 -07:00
Wez Furlong
e3e9821c4d
Add InputSelector action
Allows prompting the user to select from a list and then
triggering some action on the selected item.

This is the guts of the launcher menu hooked up to user-supplied
arbitrary entries.
2023-04-05 17:22:09 -07:00
Wez Furlong
153497d01d
admit defeat to intel shader weirdness
I dug out my pixelbook which has intel graphics and runs linux
to try to make sense of this issue, but I'm baffled.
It doesn't appear to NaN going in, but we end up with something
weird happening if we don't fixup the alpha.

Relevant entry to the discussion/background on this is:
https://github.com/wez/wezterm/issues/1180#issuecomment-1496102764

I don't think it's worth sweating over this, so let's just suck it
up.

refs: https://github.com/wez/wezterm/issues/1180
2023-04-05 15:07:22 -07:00
Wez Furlong
37e8a5041f
refine charselect move logic per comments on #3449 2023-04-05 08:45:02 -07:00
Chris
6354f01327
character select pgup/down, less jerky navigation, selected centered in list (#3449)
* character select pgup/down support for bigger jumps

* fix jerky selected_row clamping, keeps selected center offset

* die dead code

Co-authored-by: Wez Furlong <wez@wezfurlong.org>

* thx silly rustisms

Co-authored-by: Wez Furlong <wez@wezfurlong.org>

* charselect movements now spcified by amount, or 0 which does full pgsz

* rustfmt

---------

Co-authored-by: Wez Furlong <wez@wezfurlong.org>
2023-04-05 08:41:30 -07:00
Wez Furlong
336fefb52f
Add PromptInputLine and examples of (re)naming tabs/workspaces
refs: https://github.com/wez/wezterm/issues/522
refs: https://github.com/wez/wezterm/issues/1598
2023-04-04 21:11:08 -07:00
Wez Furlong
d3492b27c6
fix: 'wezterm connect --workspace foo dom' part 2
In the spawn initial mux case, we didn't verify that the mux
had no windows with the requested workspace, so we'd start up
with just the default session spawned by the mux when it starts
up.

This commit tries a bit harder to confirm that there is matching
domain/workspace combo before deciding that it is sufficient.

refs: #2734
2023-04-03 08:10:47 -07:00
Wez Furlong
718397d054
render: ensure alt color and mix are well-defined for poly quads
Potentially the root cause of the gnome-style button alpha issue

https://github.com/wez/wezterm/issues/1180#issuecomment-1493818652
a278dbf43f

refs: #1180
2023-04-03 07:47:02 -07:00
Wez Furlong
3dc2ac0a75
fix wezterm connect --workspace
When creating the initial window, we didn't pass through the
provided workspace name.

refs: #2734
2023-04-02 14:04:20 -07:00
Wez Furlong
7735602bfa
suppress dead code warning for locate_app_wide_key_assignment
It is used, just not currently on all platforms, and I want to
compile and verify it on linux which I use most often.
2023-04-02 13:36:13 -07:00
Wez Furlong
25255d90d6
config: lazyily produce ssh domain list
I noticed that in debug builds, `wezterm set-working-directory` had
high/variable latency, and I traced part of it to the ssh config parsing
logic.

Make that lazily evaluate the ssh config.

refs: #3402
2023-04-02 10:34:46 -07:00
Wez Furlong
741570563d
add wezterm cli rename-workspace
refs: #2787
2023-04-02 07:37:45 -07:00
Wez Furlong
ee68e31bbd
tab navigator: use tab title > pane title if set
refs: #1598
refs: #522
2023-04-01 21:52:46 -07:00
Wez Furlong
dd7d22ed6b
mux: propagate tab and window title when it changes
refs: #1598
2023-04-01 21:31:37 -07:00
Wez Furlong
ac3e2307d2
default format-tab-title now respects tab:set_title
Finally getting around to wrapping this up; previously you had
to define your own format-tab-title event handler if you wanted
to show the title that you had set via `tab:set_title`.

Now, if that string is not empty, it will be used instead of
the title string from the active pane.

refs: #1598
2023-04-01 20:06:18 -07:00
Wez Furlong
ea28fb891a
add window:active_tab(), window:active_pane(), tab:active_pane() 2023-04-01 19:46:15 -07:00
Wez Furlong
ed67d0449a
refactor: remove opengl and OpenGL from names
It's not opengl specific any more and those names are overly
long and slightly misleading, so fix them up.
2023-04-01 07:06:26 -07:00
Wez Furlong
aa51468e28
refactor: tidy up window_buttons a little 2023-04-01 06:56:37 -07:00
Wez Furlong
5838b2c98b
refactor: split render.rs into smaller modules 2023-04-01 06:47:27 -07:00
Wez Furlong
edb6aa38f2
integrated buttons: tweak gnome button logic
The pixel sizes are too tiny on my retina mac display, so I wanted
to make them larger. I noticed that the background color was transparent
which resulted in the appearance of a cross behind the button; that's
due to the way that the rounded corners are applied, so we need to
explicitly fill the background with the same color.

Refactor to make changing the size in the future a DRY operation,
but I left the size as-is because it needs more finesse and
I want to come back to that tomorrow.
2023-03-31 23:49:17 -07:00
Wez Furlong
2168709836
minor tidy up of hover handling for maximize button
Remove an unsafe global variable and replace with a member variable
that works similarly to the drag tracking.

Doing this from a mac... may not compile on a windows box!
2023-03-31 23:10:12 -07:00
Wez Furlong
ba34f9608e
rename PushOval -> Oval 2023-03-31 23:10:11 -07:00
Wez Furlong
0a4932cf29
tab bar: fixup placement of macos native titlebar buttons 2023-03-31 22:47:40 -07:00
Wez Furlong
a278dbf43f
remove redundant mix operation from shader
The o_fg_color_mix alpha should already be in range and we
shouldn't need to alter it here.
2023-03-31 21:56:01 -07:00
Wez Furlong
706db2650d
avoid bespoke lightness calc, reuse hsl function 2023-03-31 21:47:12 -07:00
Wez Furlong
422ae51577
allow using Gnome and Windows styles on macos.
Rename macos to MacOsNative to make its intended purpose clearer
2023-03-31 20:35:26 -07:00
Wez Furlong
5b5ae93052
remove some macos conditional compilation
Prefer to configure based on runtime config
2023-03-31 20:23:20 -07:00
YuraIz
6b2137de0b
integrated-title-bar: Add Native button style parameter 2023-03-31 19:59:03 -07:00
YuraIz
ab52277393
integrated-title-bar: Replace window button recoloring
also change shape of rounded corners to ovals
2023-03-31 19:59:01 -07:00
YuraIz
bcd1b03569
integrated-title-bar: Use snap layouts for any maximize button 2023-03-31 19:55:13 -07:00
YuraIz
eab21a669d
integrated-title-bar: Improve windows support 2023-03-31 19:53:45 -07:00
YuraIz
01aeb506c0
integrated-title-bar: Update config options
and rename the "FANCY" option to "INTEGRATED_BUTTONS"
2023-03-31 19:51:46 -07:00
YuraIz
c553646ea4
integrated-title-bar: Remove commented line 2023-03-31 19:45:28 -07:00
YuraIz
baebf907f6
integrated-title-bar: Remove macos button style
macos uses native buttons
2023-03-31 19:45:28 -07:00
Yuri Izmer
e354791c34
integrated-title-bar: Add macOS support 2023-03-31 19:45:28 -07:00
YuraIz
7d79933d28
integrated-title-bar: Ignore style config on macos and windows 2023-03-31 19:45:28 -07:00
YuraIz
6c40c2397e
integrated-title-bar: Add button style option 2023-03-31 19:45:28 -07:00
YuraIz
d39bccca10
integrated-title-bar: Add option to remove useless buttons 2023-03-31 19:45:28 -07:00
YuraIz
2333046e1b
integrated-title-bar: Add button placement option 2023-03-31 19:45:26 -07:00
YuraIz
0401dc26d6
integrated-title-bar: Add libadwaita styled buttons 2023-03-31 19:44:20 -07:00
YuraIz
2cd325fecd
integrated-title-bar: Add initial shape for macos buttons 2023-03-31 19:44:19 -07:00
YuraIz
29fe4709ce
integrated-title-bar: Add color configuration 2023-03-31 19:44:19 -07:00
YuraIz
93308317d7
integrated-title-bar: Add windows support 2023-03-31 19:44:19 -07:00
YuraIz
36f41af81e
integrated-title-bar: Add window buttons to the tabbar 2023-03-31 19:44:13 -07:00
Wez Furlong
76060b7cc2
win:perform_action now works with Copy Mode and other overlays
refs: #3209
2023-03-30 19:46:02 -07:00
Wez Furlong
4a555be7d9
gui: win:perform_action now awaits the underlying perform_key_assignment
This should help a bit with https://github.com/wez/wezterm/issues/3405
even though there is a better solution for the scenario mentioned there.
2023-03-30 19:31:40 -07:00
Wez Furlong
29d10946aa
surface config errors when running wezterm connect
Broken config could cause the gui to exit before it would normally
print the config warnings and errors, making it harder to understand
what is going on.

This commit bundles the config error text together with whatever
caused it to error out in the fatal error case.
2023-03-30 16:19:25 -07:00
Wez Furlong
2c9fd0ef6c
serial: fix some FIXMEs
Now that we have a more regular domain-shaped serial thingy,
refactor the `wezterm serial` command to re-use the common
gui setup and running logic.  This removes some FIXMEs from
around the wonky setup of the domain, which is nice.
2023-03-29 19:34:10 -07:00
Wez Furlong
1e688a5128
Add serial_ports config
This commit teaches the config about SerialDomains, and the mux
layer about constructing a SerialDomain, then changes the GUI
layer to use those pieces to set up `wezterm serial`.

A new `serial_ports` config is added, and the GUI layer knows how
to apply it to the set of domains in the mux.

The result of this is that you can now define a domain for each
serial port and spawn a serial connection into a new tab or window
in your running wezterm gui instance.
2023-03-29 19:05:13 -07:00
Wez Furlong
a7fde7935b
raise ulimit nofile and nproc to a reasonable min value on unix systems
It's a tremendous PITA for the user to do this at the system level on a
mac, where it is sorely needed.  This commit allows raising to a desired
minimum level, but won't decrease from an already larger soft limit.

refs: https://github.com/wez/wezterm/discussions/3353
2023-03-28 07:29:47 -07:00