Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

318
Visualizações
wmctrl to open window without focus

I am using the command:

wmctrl -a **id of application** -i

This is very close to what I am looking for, however Is there a away I can use wmctrl without bringing focus to the application.

For example if i run the command to bring up a window on my 2nd screen in terminal the focus of the mouse and keyboard stay on terminal.

over 4 years ago · Santiago Trujillo
1 Respostas
Responde à pergunta

0

xdotool may come in handy in your situation.

  1. You should save your active window's ID to temporary file:

    xdotool getactivewindow > ~/.window_id

  2. Then focus desired window:

    wmctrl -a **id of application** -i

  3. And then restore focus to the previous window:

    xdotool windowfocus $(cat ~/.window_id) xdotool windowactivate $(cat ~/.window_id)

Using xbindkeys, xdotool and wmctrl combined create a very powerful tool-set.

over 4 years ago · Santiago Trujillo Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda