Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

180
Views
Gnome extension keybinding latency

I am building out a gnome extension that will allow me to have several keybinding shortcuts. The first one I am trying to tackle is HJKL for arrow keys like in vim. I am using the following code to accomplish this:

let mode = Shell.ActionMode.ALL;
let flag = Meta.KeyBindingFlags.NONE;
let settings = getSettings();    

Main.wm.addKeybinding("left-h", settings, flag, mode, () => log('test') );

here is the shortcut schema:

<key type="as" name="left-h">
    <default><![CDATA[['h']]]></default>
    <summary>The shortcut key</summary>
    <description>You can create GTK entry in pref and set it as CDATA</description>
</key>

This all works as expected. My only issue is that there is about one second of latency when the key is pressed to when there is a log to the output. My first thought was that the log is just slow, so I set it up to call a python script with spawn_command_line_sync that is responsible for simulating a key press which also had ~1s of latency after the button was pressed to when the command fired. (I am using a python script for this because I couldn't find a way to press keys via GJS) Is it possible to get rid of that latency? Right now they keybindings are unusable because of it.

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!