xdotoolと新しいターミナルウィンドウ

xdotoolと新しいターミナルウィンドウ

私は最近この素晴らしいxdotoolコマンドを見つけ、作業のために4つのウィンドウを開き、サイズと位置を調整するbashスクリプトを作成します。

以前は、このコマンドを使用して新しい端末を作成することができましたが、xdotool key ctrl+alt+tこのコマンドを使用しようとすると端末に^[^T印刷するだけです。それでは誰でも助けることができますか?そうではなく、これが単なるバグの場合、必要なスクリプトを生成できるようにbashを介して新しい端末を開くことを提案している人はいますか?よろしくお願いします!

gnome-terminal注:ちょうどコマンドが見つかりました。

追加の注意:xdotool key ctrl+shift+n機能しますが、何らかの理由でctrl + alt + tは機能しません。奇妙です。

追加の注意:これは興味のある人のためのスクリプトです。後でウィンドウを開くパスオプションを追加するには、いくつかの変更を適用できます(現在は現在のウィンドウのみが実行されます)。

#!/bin/bash
gnome-terminal
sleep .1
id1="$(xdotool getwindowfocus)"
xdotool windowsize $id1 48% 50%
xdotool windowmove $id1 0 0
gnome-terminal
sleep .1
id2="$(xdotool getwindowfocus)"
xdotool windowsize $id2 48% 50%
xdotool windowmove $id2 0% 50%
gnome-terminal
sleep .1
id3="$(xdotool getwindowfocus)"
xdotool windowsize $id3 50% 50%
xdotool windowmove $id3 50% 50%
gnome-terminal
sleep .1
id4="$(xdotool getwindowfocus)"
xdotool windowsize $id4 50% 50%
xdotool windowmove $id4 50% 0%

ベストアンサー1

おすすめ記事