How to make terminal sushi a file with focus on it
I plan to use sushi as my preview application in Zotero(A famous open source research assistant), it is similar to run a command which is "sushi FILENAME" in shell. it turn out that the preview window does not have focus and is buried under Zotero mainwindow. For finding out possible workaround, I tried to do the following:
- Execute "/usr/bin/sushi MyFileName.pdf" in terminal, the preview windows only have focus for the first time I run the command, then I close the preview windows; after that every time I excute the same command, the preview window is always behind the terminal windows.
- I think it may be caused by gnome, so I try to use evince(the ubuntu default PDF reader) open PDF file, execute "/usr/bin/evince MyFileName.pdf" in terminal, the new window have focus every time. same result for other PDF reader application(libreoffice...etc)
- Open file in Nautilus, the preview window always show with focus on it, so sushi perfroms perfectly in this case.
- Comparing the above will find that sushi cant preview file with focus on it when run it in terminal. What's the reason for this kind of behavior? Any possible workarounds for this? my device: Ubuntu 20.04 //gnome version: 3.36.8
PS: Now my temporary solution is install the gnome extension (steal my focus) to force all new window immediately into focus,