Commit Graph
40 Commits
Author SHA1 Message Date
Stephane Fontaine 81d88f1839 rustfmt 2019-02-23 13:04:39 -08:00
Stephane Fontaine 92fe601151 Keep calm, don't panic! 2019-02-23 13:04:39 -08:00
Stephane Fontaine d233b0f871 Prevent spurious xkb event dispatching
Thnks to the fact that all windows share the same `keyboard` instance
2019-02-23 13:04:39 -08:00
Stephane Fontaine b94527664f Initial xkbcommon support
Remove detailed xcb select event hack

Only remove consumed "mod5" for now

which is AltGr.

Get actual modifiers from xkb.

it should enable 1:1 match with user's xmodmad

[clippy] allow keys deadcodes

handle mods & keys separately. Allows passing down `ctrl+2`

state.key_get_utf8 will interpret ctrl+2 (or @, space, ~) to 'ctrl \u{0}'

no need to wait for events.

+ Send delete as enum variant not by char value

Hook XKeysym to termwiz::KeyCode

prefer dealing with chars instead of utf8

Actually this breaks multi unicode characters .. such as J́
Others can be found with
perl -lane '/"\s+#/ && print' < /usr/share/X11/locale/en_US.UTF-8/Compose

Anyway we will need to return a Vec of chars for those.

cleanup

apply rustfmt

query locale via libc
2019-02-23 13:04:39 -08:00
Wez Furlong 826a0df380 add helper for calling from TabHost -> TerminalWindow 2019-02-23 00:35:49 -08:00
Wez Furlong 5dad7019da fixup some warnings on linux 2019-02-22 20:33:07 -08:00
Wez Furlong d113068fb0 add default_prog configuration option
@PedroHLC request this and it is easy enough to add, and gave me
the opportunity to clean up some code a little bit.
2019-02-22 18:48:38 -08:00
Wez Furlong 7277559abc fixup linux build for changes I made over on macOS 2019-02-22 15:58:19 -08:00
Wez Furlong c818225a5d ctrl|cmd +/- to manipulate font size with glutin backend
Simliar code needs to be added to the x11 backend in a follow on
commit.

Refs: https://github.com/wez/wezterm/issues/2
2019-02-22 15:22:31 -08:00
Wez Furlong 7e2e48dadc add default metrics accessor to FontConfiguration struct 2019-02-22 15:21:07 -08:00
Wez Furlong 8c821bc9e6 Allow specifying the gui system via the cli 2019-02-20 08:53:59 -08:00
Wez Furlong 99ff395a9a restore spawning windows on x11
compiled but untested
2019-02-19 23:55:29 -08:00
Wez Furlong 314f7cc103 Allow runtime selection of gui system
This allows choosing between X11 and Glutin, which simplifies some
conditional code and allows some short term flexibility on unix
systems.  However, what it really opens up is running a future
headless server mode (think: tmux).

This change comes with the cost of temporarily breaking creating
a new window on x11.
2019-02-19 23:39:13 -08:00
Wez Furlong feb0af7ca8 traitify bits of futurecore 2019-02-19 22:57:39 -08:00
Wez Furlong ee06d34b18 extract some gui running code
This breaks the x11 flavor of the build for the moment.
2019-02-19 21:57:12 -08:00
Wez Furlong 4ab73ebb2c start to allow runtime gui frontend changes 2019-02-19 21:09:55 -08:00
Wez Furlong 2fc62bbf1b fixup compilation for x11 2019-02-19 07:53:54 -08:00
Wez Furlong b905c112e2 add plumbing for spawning windows+tabs in glutin 2019-02-19 07:51:49 -08:00
Wez Furlong 28cba72472 improve throughput and responsiveness of glutin based loop 2019-02-19 07:04:00 -08:00
Wez Furlong 7e38628486 update termwiz to 2018 edition 2019-02-18 23:26:41 -08:00
Wez Furlong 571562351d migrate wezterm to 2018 edition 2019-02-18 23:17:33 -08:00
Wez Furlong d69c718a73 use the clipboard crate
This removes some tricksy code in favor of a third party crate,
which unlocks the clipboard on windows.  I'm not sure how well
this will work on the pure x11 impl yet.
2019-02-17 18:49:22 -08:00
Wez Furlong 400a85befc fixup process termination detection on windows 2019-02-17 14:02:03 -08:00
Wez Furlong b387464054 implement pty enabled spawner for win32
We can now start a process with a new pty, but fail when we reach
the shader spec.  Progress!
2019-02-17 09:05:37 -08:00
Wez Furlong 2c3d56c717 sigchld is a unix concept 2019-02-16 15:08:52 -08:00
Wez Furlong f42463b601 make pty reading slightly more portable to win 2019-02-16 15:03:34 -08:00
Wez Furlong 66a6b4b912 can run with glutin/x11/opengl on linux again
Not everything is implemented, and this isn't intended to be the main
usage at the moment, but it does prove to me on WSL that this codepath
works.  I want to get native windows code working through here too.
2019-02-16 14:28:02 -08:00
Wez Furlong 8995974124 rejigger gliumwindows to not need non-blocking io for pty 2019-02-16 13:34:09 -08:00
Wez Furlong d95da9c159 add feature to force building with glutin on linux
this helps me verify from WSL that I didn't break compilation in
the refactoring to follow
2019-02-16 09:27:22 -08:00
Wez Furlong 9bc99f5f1c tweak windows imports 2019-02-16 08:54:24 -08:00
Wez Furlong 2db17562a6 rustfmt 2019-02-16 00:08:38 -08:00
Wez Furlong 61fec42216 cargo fmt with current stable rustfmt 2018-09-19 20:06:31 -07:00
Wez Furlong 039eadc05f update rustfmt 2018-07-11 08:30:49 -07:00
Wez Furlong d73892a4fd update for recent rustfmt changes
No functional changes
2018-04-11 13:15:12 -07:00
Wez Furlong edf44c9c48 We can now spawn and switch tabs! 2018-03-04 16:46:14 -08:00
Wez Furlong cabc6681b6 add tab spawning 2018-03-04 16:27:02 -08:00
Wez Furlong eb7153eb50 theoretically deal with a single tab closing on its own 2018-03-04 13:26:40 -08:00
Wez Furlong d571d555f1 impl Evented for XCB Connection 2018-03-04 12:30:43 -08:00
Wez Furlong 41cfcfdb15 Bring back my original xcb+egl window bits 2018-03-04 07:27:18 -08:00
Wez Furlong 079ac49c6b add guiloop as indirection over glutinloop
... and remove dep on glutin.  We don't properly compile yet,
but this is a step to bringing back the egl bits we had originally.
2018-03-03 22:03:12 -08:00