[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: xdotool : savez-vous faire ?
- To: linux-31@culte.org
- Subject: Re: xdotool : savez-vous faire ?
- From: Jean-Marc MONGRELET <jeanmarc.mongrelet@free.fr>
- Date: Tue, 12 Sep 2023 18:50:07 +0200
- Authentication-results: pic2m.le-pic.org; dkim=pass (2048-bit key; unprotected) header.d=free.fr header.i=@free.fr header.a=rsa-sha256 header.s=smtp-20201208 header.b=dVex0VHs; dkim-atps=neutral
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/simple; d=free.fr; s=smtp-20201208; t=1694537408; bh=WEav0N+c2JBZ+K/m35o/InApXNC7bniWXiThAswODiI=; h=Date:From:To:Subject:In-Reply-To:References:From; b=dVex0VHsLoUkXuc7zDIMS/is5xrgHy84yVIE9tr1migLsU6vAVmmzTt+C4nVCYfKP 31q/aHabz0eDpb+/xHeSqysqaBYfpz+qbMgXnTurISqVs+/8bCjBd8ogSJ3kKjkW7R I/nVUeI/nSp3ICK5Mmahi/nC0bAyQL6pEu7pLO3Z1AWE57m1BDQbWz9F7pxS0rrFz/ 1z/HsGp/RSqG7+kA0bIsUFBPCwYHEJT4KUIiWYMeJKsO48VKuaALQA/fO9jnnEyuVO wFuJ4H4/dbN6WY/VF0VhQDdmnfm1KcWYs0M36B/CygxQ/N9V0XP2D02ZinRQCZE7vg 35JgkFYcY3/YQ==
- In-reply-to: <1f8c4769-6274-33aa-2c22-747853b92dc4@free.fr>
- References: <1f8c4769-6274-33aa-2c22-747853b92dc4@free.fr>
Bonjour,
Le 12/09/2023 15:57, peterpan31 a écrit :
Je cherche à réaliser la commande "Enregistrer sous" (et bien plus)
depuis LibreOffice Writer par le lancement d'un script faisant appel à
l'outil xdotool.
Je fais pour tester :
#!/bin/bash
# ID de la fenêtre
WD=$(xdotool search --title "LibreOffice Writer" | head -1)
# Dans le cas où Writer ne serai pas dans le desktop courant
# sinon on pourrait faire :
# xdotool windowfocus $WID
xdotool windowactivate $WID
# Un premier raccourci simple
xdotool key alt+a
Et bien, ça bascule vers Writer mais n'exécute pas le raccourci....
Comment dois-je faire ?
Peut-être que l’erreur vient de cette ligne:
WD=$(xdotool search --title "LibreOffice Writer" | head -1)
à remplacer par:
WD=$(xdotool search --title "LibreOffice Writer" | tail -1)
JM