Re: Set tkinter top-level window to "always on visible workspace"

2022-03-29 Thread Skip Montanaro
> Also, wmctrl accepts window names instead of ids if you omit the -i > option. In case winfo_id() is not returning the id you need. Nice. That worked. FWIW, Tk never gave me the very outermost window as the parent of the tkinter.Tk instance. Here's the start of hierarchy: % xwininfo -tree xwini

Re: Set tkinter top-level window to "always on visible workspace"

2022-03-28 Thread Cameron Simpson
On 29Mar2022 13:02, Cameron Simpson wrote: >On 28Mar2022 20:47, Skip Montanaro wrote: >>I'm struggling to get the outermost window (not sure what's going on), >>but >>I will keep messing around. > >See what xlsclients says to you. Also, wmctrl accepts window names instead of ids if you omit the

Re: Set tkinter top-level window to "always on visible workspace"

2022-03-28 Thread Cameron Simpson
On 28Mar2022 20:47, Skip Montanaro wrote: >I'm struggling to get the outermost window (not sure what's going on), >but >I will keep messing around. See what xlsclients says to you. Cheers, Cameron Simpson -- https://mail.python.org/mailman/listinfo/python-list

Re: Set tkinter top-level window to "always on visible workspace"

2022-03-28 Thread Skip Montanaro
> Would you accept a solution that involves a subprocess call? > > wmctrl -ir {id} -b add,sticky I'm already checking idle time with xprintidle(1), so what's one more (one-time) subprocess call? Small amount of history, I'm referring to this mouse/typing watcher: https://github.com/smontanaro/py

Re: Set tkinter top-level window to "always on visible workspace"

2022-03-28 Thread Cameron Simpson
On 28Mar2022 19:39, Skip Montanaro wrote: >> I think you must be using xfce4, not fvwm4 (there's an fvwm3 in >> development). See https://xfce.org/ > >Both? [...] >1803 xfwm4 --replace >539426 xfwm4-settings [...] >1755 /usr/bin/ssh-agent /usr/bin/im-launch startxfce4 >1782 /usr/lib/x86_64-linux-g

Re: Set tkinter top-level window to "always on visible workspace"

2022-03-28 Thread Skip Montanaro
> I think you must be using xfce4, not fvwm4 (there's an fvwm3 in > development). See https://xfce.org/ Both? % pgrep -fla xfwm4 1803 xfwm4 --replace 539426 xfwm4-settings % pgrep -fla xfce 1599 xfce4-session 1755 /usr/bin/ssh-agent /usr/bin/im-launch startxfce4 1782 /usr/lib/x86_64-linux-gnu/xf

Re: Set tkinter top-level window to "always on visible workspace"

2022-03-28 Thread Cameron Simpson
On 28Mar2022 10:54, Skip Montanaro wrote: >I do have a ~/.config/xfce4/xfwm4/ >directory, but it is completely empty. On reflection, maybe you're running something else. "ps axf" FTW. Cheers, Cameron Simpson -- https://mail.python.org/mailman/listinfo/python-list

Re: Set tkinter top-level window to "always on visible workspace"

2022-03-28 Thread Cameron Simpson
On 28Mar2022 10:54, Skip Montanaro wrote: >Unfortunately, I no longer recall what window manager(s) I used at the >time (probably twm or fvwm). Now I use fvwm4 and can't find squat >online about configuration files. I do have a ~/.config/xfce4/xfwm4/ >directory, but it is completely empty. I thin

Re: Set tkinter top-level window to "always on visible workspace"

2022-03-28 Thread Chris Angelico
On Tue, 29 Mar 2022 at 09:04, Cameron Simpson wrote: > > On 29Mar2022 06:10, Chris Angelico wrote: > >On Tue, 29 Mar 2022 at 06:08, Christian Gollwitzer wrote: > >> Am 28.03.22 um 20:03 schrieb Chris Angelico: > >> > Would you accept a solution that involves a subprocess call? > >> > > >> > wmct

Re: Set tkinter top-level window to "always on visible workspace"

2022-03-28 Thread Cameron Simpson
On 29Mar2022 06:10, Chris Angelico wrote: >On Tue, 29 Mar 2022 at 06:08, Christian Gollwitzer wrote: >> Am 28.03.22 um 20:03 schrieb Chris Angelico: >> > Would you accept a solution that involves a subprocess call? >> > >> > wmctrl -ir {id} -b add,sticky >> > >> > Now, the only problem is... figu

Re: Set tkinter top-level window to "always on visible workspace"

2022-03-28 Thread Chris Angelico
On Tue, 29 Mar 2022 at 06:08, Christian Gollwitzer wrote: > > Am 28.03.22 um 20:03 schrieb Chris Angelico: > > Would you accept a solution that involves a subprocess call? > > > > wmctrl -ir {id} -b add,sticky > > > > Now, the only problem is... figuring out your window ID. Worst case, > > parse w

Re: Set tkinter top-level window to "always on visible workspace"

2022-03-28 Thread Christian Gollwitzer
Am 28.03.22 um 20:03 schrieb Chris Angelico: Would you accept a solution that involves a subprocess call? wmctrl -ir {id} -b add,sticky Now, the only problem is... figuring out your window ID. Worst case, parse wmctrl -lG to get that info, but it might be possible to get the window ID from Tkin

Re: Set tkinter top-level window to "always on visible workspace"

2022-03-28 Thread Chris Angelico
On Tue, 29 Mar 2022 at 02:56, Skip Montanaro wrote: > > > I might be misguided, but on modern desktops that should be possible > > with a few mouseclicks. E.g. in KDE, there is a little pin icon > > displayed in every title bar of a toplevel window on the left side. > > Correct, and that's what I'

Re: Set tkinter top-level window to "always on visible workspace"

2022-03-28 Thread Skip Montanaro
> I might be misguided, but on modern desktops that should be possible > with a few mouseclicks. E.g. in KDE, there is a little pin icon > displayed in every title bar of a toplevel window on the left side. Correct, and that's what I'm currently doing. I'm lazy though. I want the program to start

Re: Set tkinter top-level window to "always on visible workspace"

2022-03-28 Thread Christian Gollwitzer
Am 28.03.22 um 00:55 schrieb Skip Montanaro: So you might tell your window manager to keep that window on the main workspace. Thanks. I'd forgotten about the possibility of doing this sort of thing in the window manager config. That would certainly be fine in this case. (It's been ages since I

Re: Set tkinter top-level window to "always on visible workspace"

2022-03-27 Thread Skip Montanaro
> So you might tell your window manager to keep that window on the main workspace. Thanks. I'd forgotten about the possibility of doing this sort of thing in the window manager config. That would certainly be fine in this case. (It's been ages since I messed with this sort of thing.) Skip -- htt

Re: Set tkinter top-level window to "always on visible workspace"

2022-03-27 Thread Cameron Simpson
On 27Mar2022 16:23, Skip Montanaro wrote: >I have a tkinter app (Ubuntu/X11 env) whose main window should always be >displayed on the currently visible workspace. Is there some way to set that >attribute programmatically? I see that there is a tkinter.Wm class and that >Toplevel widgets have a wm_

Set tkinter top-level window to "always on visible workspace"

2022-03-27 Thread Skip Montanaro
I have a tkinter app (Ubuntu/X11 env) whose main window should always be displayed on the currently visible workspace. Is there some way to set that attribute programmatically? I see that there is a tkinter.Wm class and that Toplevel widgets have a wm_attributes method, but haven't found any exampl