Commit Graph

206 Commits

Author SHA1 Message Date
Kovid Goyal
cb289125ab
Use _GNU_SOURCE instead of POSIX_SOURCE for fileno()
Maybe that will work with FreeBSD
2018-07-29 21:43:02 +05:30
Kovid Goyal
3d1e604a6c
Make the glfw strdup implementation more efficient 2018-07-29 12:21:56 +05:30
Kovid Goyal
1ca49b9380
Fix #761 2018-07-29 12:15:21 +05:30
Kovid Goyal
ed934a0206
Fix #758 2018-07-29 11:07:36 +05:30
Kovid Goyal
97401f843a
Sigh. Apparently _XOPEN_SOURCE is needed on older linux systems for fileno() 2018-07-28 23:54:23 +05:30
Kovid Goyal
02635d506e
Dont use _XOPEN_SOURCE when building
Apparently it has exactly opposite semantics for glibc and whatever libcs
are used on BSD. What a clusterfuck.
2018-07-28 22:56:18 +05:30
Kovid Goyal
bd4831e2ee
Some explicit includes needed for FreeBSD 2018-07-26 19:50:38 +05:30
Kovid Goyal
1486af8770
More debug output when using --debug-keyboard 2018-07-26 08:41:16 +05:30
Kovid Goyal
55556aaac4
Ensure queued display events are dispatched when polling/waiting for events 2018-07-13 10:56:12 +05:30
Kovid Goyal
31853ee20c
Handle errno better when polling for events 2018-07-13 10:33:18 +05:30
Kovid Goyal
037bfeff82
Give IBUS a maximum of three seconds to respond to a key press
Previously was using the default timeout, which is 25 seconds
2018-07-12 18:18:21 +05:30
Kovid Goyal
98ede457a0
Do not hand on startup if the ibus daemon is hung 2018-07-12 18:18:21 +05:30
Kovid Goyal
1a1aa2d6aa
Nicer debug print for key debugging 2018-07-12 18:18:20 +05:30
Kovid Goyal
6e9aecdff3
Fix Shift key not working with IBUS
Fixes #721
2018-07-12 18:18:20 +05:30
Kovid Goyal
95187632bf
Allow using GLFW_IM_MODULE to activate ibus 2018-07-12 18:18:20 +05:30
Kovid Goyal
e3e28a023c
Fix exporting to glfw 2018-07-12 18:18:20 +05:30
Kovid Goyal
29dd766a67
Fix unused vars warning 2018-07-12 18:18:20 +05:30
Kovid Goyal
851145e69e
Add some debug prints for IBUS key handling 2018-07-12 18:18:20 +05:30
Kovid Goyal
b2e300c440
Simplify key round-tripping to IBUS
Only send to IBUS after full xkb processing. This is needed as otherwise
modifier state tracking does not work reliably. If you use alt+tab to
switch away from the window, the window never receives the release event
for the alt modifier.

The downside is that now if the uer has both XCompose and ibus active,
the who knows what will happen.
2018-07-12 18:18:20 +05:30
Kovid Goyal
c6c6a18375
Handle keys returned by IBUS 2018-07-12 18:18:19 +05:30
Kovid Goyal
56063b283e
Implement text commit from the IME system 2018-07-12 18:18:19 +05:30
Kovid Goyal
d27e7ead49
Print an error if too many timers/watches are added 2018-07-12 18:18:19 +05:30
Kovid Goyal
342164ede1
Add API for the application to notify the IME system of state changes 2018-07-12 18:18:19 +05:30
Kovid Goyal
1061e40b98
Bi-directional glfw updates 2018-07-12 18:18:19 +05:30
Kovid Goyal
377115a594
Add a GLFW specific env var to toggle IBUS 2018-07-12 18:18:19 +05:30
Kovid Goyal
e405b68da1
... 2018-07-12 18:18:18 +05:30
Kovid Goyal
d875d7baed
Implement the handler for ibus signals 2018-07-12 18:18:18 +05:30
Kovid Goyal
9c48e4965c
Send key events to ibus 2018-07-12 18:18:18 +05:30
Kovid Goyal
8675659fcb
Fix remaining sync BUS calls
Also work on IBUS integration
2018-07-12 18:18:18 +05:30
Kovid Goyal
3b226618ad
Ensure no ibus comms take place till the connection is fully setup 2018-07-12 18:18:18 +05:30
Kovid Goyal
6879a492dc
Give watches and timers names to ease debugging 2018-07-12 18:18:18 +05:30
Kovid Goyal
4070255dde
Simplify watch->fd matching 2018-07-12 18:18:18 +05:30
Kovid Goyal
dd9e484336
Make the DBUS APIs async 2018-07-12 18:18:18 +05:30
Kovid Goyal
78cda7aa74
Implement dispatch for the IBUS connection 2018-07-12 18:18:17 +05:30
Kovid Goyal
9ced447fa3
Make timer dispatch more efficient 2018-07-12 18:18:17 +05:30
Kovid Goyal
8e665ffedc
Implement DBUS timeout functions 2018-07-12 18:18:17 +05:30
Kovid Goyal
99ea6c08a7
Implement timers for the linux event loops
Needed for dbus integration. Also cleanup the event handling code.
X11 and Wayland now share most of their event polling and dispatch logic.
2018-07-12 18:18:17 +05:30
Kovid Goyal
b0bfa2b2fc
... 2018-07-12 18:18:17 +05:30
Kovid Goyal
3797294838
Use an id for watches 2018-07-12 18:18:17 +05:30
Kovid Goyal
3d6995d1e6
Work on integration of DBUS into event loop 2018-07-12 18:18:17 +05:30
Kovid Goyal
e91eb27e56
Refactor linux backend event loops
Allow waiting for events on an arbitrary number of fds. Needed
for async DBUS integration.
2018-07-12 18:18:17 +05:30
Kovid Goyal
3a4b614ae0
IBUS does not need a connection to the DBUS session bus 2018-07-12 18:18:16 +05:30
Kovid Goyal
26a6d6bef9
Set startup IBUS cursor and focus state 2018-07-12 18:18:16 +05:30
Kovid Goyal
dca81589a7
Finish code to connect to IBUS daemon 2018-07-12 18:18:16 +05:30
Kovid Goyal
5b7c697dfe
Connect to IBUS 2018-07-12 18:18:16 +05:30
Kovid Goyal
18d6b8a0ad
Code to read the IBUS address 2018-07-12 18:18:16 +05:30
Kovid Goyal
cdee601137
Start work on IBUS support 2018-07-12 18:18:16 +05:30
Kovid Goyal
db5aa36f44
Fix deprecation warning from newer versions of wayland-scanner 2018-07-10 19:48:37 +05:30
Kovid Goyal
4313531432
macOS: Use a custom mouse cursor that shows up well on both light and dark backgrounds
Fixes #359. Also, update GLFW from upstream for retina cursor setting
support.
2018-07-07 10:43:30 +05:30
Kovid Goyal
2491fafe98
Update glfw from upstream 2018-06-23 14:59:36 +05:30
Kovid Goyal
2852ce9a4d
Update glfw from upstream 2018-06-23 10:23:21 +05:30
Kovid Goyal
45b0233f60
Update GLFW from upstream
Use the new init hint for keyboard debugging
2018-06-22 13:26:41 +05:30
Kovid Goyal
5dd3243674
Update glfw from upstream 2018-06-22 10:21:51 +05:30
Kovid Goyal
05c475e6ca
Update glfw from upstream 2018-06-11 13:08:21 +05:30
Kovid Goyal
4711746f8f
Linux: When using layouts that map the keys to non-ascii characters, map shortcuts using the ascii equivalents, from the default layout.
Fixes #606
2018-06-11 12:21:35 +05:30
Kovid Goyal
93b1919a38
Update glfw from upstream, to allow kitty to react to Xft.dpi changes 2018-06-11 07:12:06 +05:30
Kovid Goyal
71c1432892
Update glfw from upstream 2018-06-08 18:02:44 +05:30
Kovid Goyal
44b84ba295
Update glfw from upstream 2018-06-08 14:27:30 +05:30
Kovid Goyal
f80f61f84f
... 2018-06-08 12:54:38 +05:30
Kovid Goyal
eecf80469e
Update glfw from upstream
Adds glfwpostemptyevent not working fix to wayland backend as well
2018-06-08 09:14:14 +05:30
Kovid Goyal
dd085a9297
Update glfw from upstream
Fixes https://github.com/glfw/glfw/issues/1281
2018-06-07 21:46:01 +05:30
Kovid Goyal
faa5443d43
macOS: When clicking dock icon with no windows, create a new window 2018-06-07 07:19:39 +05:30
Kovid Goyal
2e8d19601b
macOS: Fix the new OS window keyboard shortcut not working if no kitty window currently has focus.
Fixes #524
2018-06-06 22:18:33 +05:30
Kovid Goyal
138b4cf5da
Fix build breakage caused by FreeBSD support
Also move the changes to the glfw files to glfw.py
2018-06-03 09:17:18 +05:30
Robert Ricci
e7ad2637d8 Don't 'hardcode' linux joystick for x11 module
The correct joystick module appears to be inserted in the list in
glfw.py . This fixes the build on FreeBSD 11
2018-06-02 11:46:10 -06:00
Kovid Goyal
4e6d929e20
Update glfw from upstream 2018-06-01 09:15:35 +05:30
Kovid Goyal
709d19119d
Update bundled glfw 2018-05-20 08:03:58 +05:30
Kovid Goyal
78002cf3ba
Update glfw from upstream
Fixes #488
2018-04-27 15:32:54 +05:30
Kovid Goyal
238508fc0a
Update glfw from upstream
Proper cross-platform fix for issue of mouse cursor not being restored
over un-focused windows.
2018-04-26 08:31:52 +05:30
Kovid Goyal
2b372373ae
Update glfw from upstream 2018-04-24 18:15:28 +05:30
Kovid Goyal
32f16ee5f5
macOS: Add support for dead keys
I have modified GLFW to support dead keys on macOS. That was painful.
Fixes #465
2018-04-20 14:25:53 +05:30
Kovid Goyal
2504266806
macOS: Fix option as alt not working for keys that act as dead keys in the current keyboard layout 2018-04-19 17:44:31 +05:30
Kovid Goyal
5755ba72b1
Fix #449 2018-04-09 20:13:13 +05:30
Kovid Goyal
20b5084904
Update glfw
Fixes #439
2018-04-06 20:18:03 +05:30
Kovid Goyal
9edfafcac2
Update glfw 2018-03-31 12:21:37 +05:30
Kovid Goyal
677c47b9dd
Possible fix for handling unknown modifiers on Xkb systems 2018-03-31 12:21:37 +05:30
Kovid Goyal
b59d7dda11
Import glfw from upstream, key handling on macOS works again 2018-03-31 12:21:37 +05:30
Kovid Goyal
529bb5c6a0
We need xkbcommon >= 0.5 2018-03-31 12:21:36 +05:30
Kovid Goyal
caf9a12b34
Update glfw from upstream
libxkbcommon based keyboard handling now works (at least the basic
stuff, haven't tested compose/mapnotify etc.)
2018-03-31 12:21:36 +05:30
Kovid Goyal
80f3fe6e9f
... 2018-03-29 00:05:37 +05:30
Kovid Goyal
9ba2c4b397
Update glfw from upstream 2018-03-28 19:57:01 +05:30
Kovid Goyal
bfa53d4b45
Update glfw from upstream
Includes proper fix for Wayland key repeat
2018-03-28 15:26:56 +05:30
Kovid Goyal
69f3ceb903
Merge glfw upstream changes to build on Wayland on FreeBSD 2018-03-28 09:47:16 +05:30
Kovid Goyal
d0f839bbd8
Fix audible bell not working under Wayland 2018-03-27 19:45:19 +05:30
Kovid Goyal
48538c0e25
Update bundled glfw 2018-03-27 15:07:25 +05:30
Kovid Goyal
1edf1524f8
Update bundled glfw 2018-03-03 11:21:09 +05:30
Kovid Goyal
77d46630d7
Update bundled glfw 2018-02-08 09:15:40 +05:30
Kovid Goyal
2777b89e45
Update bundled glfw 2018-02-01 13:03:26 +05:30
Kovid Goyal
6ad21fc98f
Update bundled glfw 2018-01-29 12:30:05 +05:30
Kovid Goyal
d43d6ab0a9
Update bundled glfw 2018-01-12 05:34:53 +05:30
Kovid Goyal
bd654d22f4
Read the required wayland protocols version from upstream instead of hardcoding it 2017-12-28 14:12:46 +05:30
Kovid Goyal
12bdd4dddd
Bump min version of wayland-protocols to match upstream 2017-12-27 07:24:38 +05:30
Kovid Goyal
4621ff41d9
Skip building the wayland backend on systems with missing wayland protocol definitions
Fixes #254
2017-12-27 06:22:36 +05:30
Kovid Goyal
2f4f3e3331
Update bundled glfw 2017-12-20 09:07:06 +05:30
Kovid Goyal
b4509e341a
Update glfw 2017-12-01 12:16:18 +05:30
Kovid Goyal
fb41ecb2e5
Update bundled glfw 2017-12-01 12:16:16 +05:30
Kovid Goyal
982a9320c5
Final fixes needed for wayland building
kitty now runs under wayland again
2017-12-01 12:16:13 +05:30
Kovid Goyal
eb8f4e0b3c
isosx -> is_macos 2017-12-01 12:16:13 +05:30
Kovid Goyal
85fcd51ea3
Enable building of glfw-wayland backend 2017-12-01 12:16:13 +05:30
Kovid Goyal
a5078afd1e
Move the bell implementation into glfw 2017-12-01 12:16:13 +05:30
Kovid Goyal
32a6dd2aa1
Add a command line switch to set the name part of WM_CLASS independently 2017-12-01 12:16:13 +05:30
Kovid Goyal
a11d6466c6
Update vendored glfw 2017-12-01 12:16:12 +05:30
Kovid Goyal
3773aaa8a1
Get it building on macOS 2017-12-01 12:16:11 +05:30
Kovid Goyal
cfc99baac4
Get rid of ctypes based loading of libglfw/libX11 2017-12-01 12:15:36 +05:30
Kovid Goyal
dfd8a69cf2
Build kitty against bundled glfw 2017-12-01 12:15:36 +05:30
Kovid Goyal
9307486254
Initial import of glfw 2017-12-01 12:15:36 +05:30