Giter VIP home page Giter VIP logo

Comments (16)

rvaiya avatar rvaiya commented on May 26, 2024

Interesting. I can't seem to reproduce this. Do you have exactly one instance of warp running? Try killing it and restarting it manually from a terminal window. Don't use the -d flag and see if you get any readable error messages. Hopefully it won't come to having to manually wade through X requests sent to the server :P.

from warpd.

rvaiya avatar rvaiya commented on May 26, 2024

If you've bound the same keysyms to shortcuts using other programs then warp won't be able to grab them (which means it won't start). Have you recently installed/modified any other keyboard software?

from warpd.

wearpants avatar wearpants commented on May 26, 2024

Only one copy of warp, and nothing new AFAIK - so frustrating! Guess it's down to tracing - what am I looking for?

from warpd.

wearpants avatar wearpants commented on May 26, 2024

It's really annoying that it works ok under fluxbox from startx but not otherwise - I'm guessing something DE-related that interferes is getting started by both lightdm & xfce... X startup does so many things, there's a mountain of stuff in /etc/xdg, it's hard to isolate

from warpd.

rvaiya avatar rvaiya commented on May 26, 2024

If it is crashing it should yield some output. Try pkill warp;warp in a terminal and then manually activating the grid. If you don't see any output it may be that your window manager is drawing over the grid windows, this usually only happens if you have a compositor running.

from warpd.

wearpants avatar wearpants commented on May 26, 2024

from warpd.

rvaiya avatar rvaiya commented on May 26, 2024

Try pulling the latest commit and doing make debug && ./bin/warp. Then try pressing the activation key and pasting the output here.

Also see if a different activation key works (try something unorthodox (involving a modifier) which is unlikely to conflict with a system binding ).

from warpd.

wearpants avatar wearpants commented on May 26, 2024
gnocci@gnocci:~/warp$ ~/warp/bin/warp 
DEBUG: Entering main loop
DEBUG: Attempting to grab activation key (C-S-e)

DEBUG: Entering outer grid loop.
^E^E^E^E^E^C
gnocci@gnocci:~/warp$

from warpd.

wearpants avatar wearpants commented on May 26, 2024

Got a real easy solution to this - could we do a command line option -a that does a single activation immediately and then exits, instead of looping? That way I could bind the activation key in the window manager, similar to fluxbox's run dialog (which I was surprised to see isn't built in):

# open a dialog to run programs
Mod1 F2 :Exec fbrun

# warp the pointer
Mod1 x:Exec warp -a

from warpd.

rvaiya avatar rvaiya commented on May 26, 2024

Yes, it was originally designed as a 'oneshot' program designed to be activated by an external keybinding mechanism before I decided to include the ability to bind keys and flesh it out into a proper daemon. I would prefer not to alter the design at this point and should like to find the bug (if there is one). I am also loath to add to the ever proliferating sea of config options. Running as a daemon has some advantages including the ability to cache certain drawing operations which improves performance and makes things like hint mode usable. Given that the grab attempt doesn't seem to fail (warp would crash otherwise) and that I can't seem to reproduce the problem, it is likely on your end. What login option are you selecting in lightdm? The mechanism by which keys are bound accross X is fairly consistent and there aren't too many things which can cause interference.

Are you sure you haven't modified anything (or upgraded a package)? The log you sent suggests that the key is getting successfully grabbed but not recognized. This
shouldn't be too hard to resolve.

Things to try:

Run the following command, press C-S-e and e a few times in isolation (can exit with C-c) and paste the output here.

curl http://ix.io/2n0f|gcc -lX11 -xc -o /tmp/o - && /tmp/o

Sending the contents of ~/.Xsession and /etc/lightdm/lightdm.conf

from warpd.

wearpants avatar wearpants commented on May 26, 2024

Are you sure you haven't modified anything (or upgraded a package)? The log you sent suggests that the key is getting successfully grabbed but not recognized. This
shouldn't be too hard to resolve.

I think that's just the key being echoed by the terminal? Doesn't show if I have a different window focused

from warpd.

wearpants avatar wearpants commented on May 26, 2024

curl http://ix.io/2n0f|gcc -lX11 -xc -o /tmp/o - && /tmp/o

Doesn't build:

gnocci@gnocci:~/warp/src$ curl http://ix.io/2n0f|gcc -lX11  -xc -o /tmp/o - && /tmp/o
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  1522  100  1522    0     0   7352      0 --:--:-- --:--:-- --:--:--  7317
<stdin>: In function ‘grab_keyseq’:
<stdin>:63:2: warning: ‘XKeycodeToKeysym’ is deprecated [-Wdeprecated-declarations]
In file included from <stdin>:1:
/usr/include/X11/Xlib.h:1687:15: note: declared here
 1687 | extern KeySym XKeycodeToKeysym(
      |               ^~~~~~~~~~~~~~~~
<stdin>: In function ‘main’:
<stdin>:84:4: warning: ‘XKeycodeToKeysym’ is deprecated [-Wdeprecated-declarations]
In file included from <stdin>:1:
/usr/include/X11/Xlib.h:1687:15: note: declared here
 1687 | extern KeySym XKeycodeToKeysym(
      |               ^~~~~~~~~~~~~~~~
/usr/bin/ld: /tmp/ccE253uw.o: in function `parse_keyseq':
:(.text+0x119): undefined reference to `XStringToKeysym'
/usr/bin/ld: :(.text+0x1ab): undefined reference to `XKeysymToKeycode'
/usr/bin/ld: /tmp/ccE253uw.o: in function `grab_keyseq':
:(.text+0x21a): undefined reference to `XKeycodeToKeysym'
/usr/bin/ld: :(.text+0x222): undefined reference to `XKeysymToString'
/usr/bin/ld: :(.text+0x293): undefined reference to `XGrabKey'
/usr/bin/ld: /tmp/ccE253uw.o: in function `main':
:(.text+0x2f0): undefined reference to `XOpenDisplay'
/usr/bin/ld: :(.text+0x334): undefined reference to `XNextEvent'
/usr/bin/ld: :(.text+0x364): undefined reference to `XKeycodeToKeysym'
/usr/bin/ld: :(.text+0x36c): undefined reference to `XKeysymToString'
collect2: error: ld returned 1 exit status

Don't have a ~/.Xsession, here's lightdm.conf:

[Seat:*]
autologin-guest=false
autologin-user=gnocci
autologin-user-timeout=0

from warpd.

rvaiya avatar rvaiya commented on May 26, 2024

Oops, made the flag mistake again :P. Should be curl http://ix.io/2n0f|gcc -xc -o /tmp/o - -lX11 && /tmp/o. The ^E is indeed your terminal but I was
referring to the Entering outer grid loop.

from warpd.

rvaiya avatar rvaiya commented on May 26, 2024

I assume at this point you know that C-S-e == Control + Shift + e (and not Control + Super + e). I only mention it because the symptoms you describe suggest the possibility you are using the wrong activation sequence. Try using a simpler activation key like C-e and let me know if it works.

from warpd.

wearpants avatar wearpants commented on May 26, 2024

Yeah I tried C-e, same result

gnocci@gnocci:~$ curl http://ix.io/2n0f|gcc -xc -o /tmp/o - -lX11 && /tmp/o
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  1522  100  1522    0     0   6825      0 --:--:-- --:--:-- --:--:--  6825
<stdin>: In function ‘grab_keyseq’:
<stdin>:63:2: warning: ‘XKeycodeToKeysym’ is deprecated [-Wdeprecated-declarations]
In file included from <stdin>:1:
/usr/include/X11/Xlib.h:1687:15: note: declared here
 1687 | extern KeySym XKeycodeToKeysym(
      |               ^~~~~~~~~~~~~~~~
<stdin>: In function ‘main’:
<stdin>:84:4: warning: ‘XKeycodeToKeysym’ is deprecated [-Wdeprecated-declarations]
In file included from <stdin>:1:
/usr/include/X11/Xlib.h:1687:15: note: declared here
 1687 | extern KeySym XKeycodeToKeysym(
      |               ^~~~~~~~~~~~~~~~
Binding 26(e) with mods 5
1
Binding 26(e) with mods 0
1
Grabbed keys, waiting for input
^E^E^E^E^E^E^E^E^E^Eeeeeeee^C
gnocci@gnocci:~$ 

from warpd.

rvaiya avatar rvaiya commented on May 26, 2024

(continued offline)...

Resolved: Numlock interferes with modifier detection, this has subsequently been addressed in a commit.

from warpd.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.