[ Solved ] Linux - How to check wether the deco/border is set or not
Hello Forum !
On my search for a solution to get the active window-id, I stumbled over this forum. You were listed
at the very top in Google, and it seems, not without any reason : I found the info in less than five
minutes, record-breaking !
So I will try to get another very essential info concerning windows in Linux here: How, and where, can
I get the state of the deco/border around a window ?
Sorry, what do you mean by the "state"? What sort of states are you thinking of? As in, is it maximised, minimised or floating? Or something different?
Hey Snark1994 !
Oh, I just mean, if deco or border exists or not.
Somewhere there must be the setting, but I don't know where.
I'm still not 100% sure of what you mean.. Can you show a screenshot of a window with a border and a window without? I mean, some window managers don't use borders (like XMonad), but if you're trying to work out which window manager the person is using then I feel you're not doing Good Things.
Perhaps a better question for me to ask is "What is your end goal? What are you actually trying to achieve?"
Sorry if I've just misunderstood what you're saying...
@ Snark1994 : It's more my limited English, I fear.
Some time ago I used Xmonad, too. My absolutely favourite WM,
but its Haskell-config is far out of my knowledge!
But what I remember is, that you can have pure borders in
Xmonad for sure.
I don't think, we need a screenshot here, let me try to explain:
The borders are what Xmonad,also my Openbox and many other WMs are
providing. They can be displayed around the window, if there is no
The decoration is the standart what you may have around the window,
with the buttons and handles on it. You can toggle them on and off,
and that's my problem:
I just need to know, if the decos/borders are on, or if the window
is totally naked, means, not anything around it.
It's needed for a session-restore-script I'm working on.
borders are the extra outline parts on the *sides* of a window. The top part is called the titlebar and the bottom part is usually called the resize ba, or something like that, because of being able to grab the corners to resize the window. Some window managers allow you to enable/disable each of these individually -of course some wm's don't even draw some or any of them.
@ gnashley : Sorry, but there are 2 different kinds of window margins,
the decos and the borders. It's a little hard to differentiate between
them in words, they are all borders or margins or edges or rands...
Regardless of the used terms, I want to know, from where I can get
the info, if there are any "whatevers" around a particular window, or not.
The denomination "border", "decoration" etc. depend on the libraries used, the windowmanager etc. and the X-server. If you want to know how it works on your system, you will have to look at which libraries the your windowmanager uses (is programmed with).
@ markush : Yes, and that's the problem. I'm not such an expierienced Gtk/C-programmer,
more precisely, neighter nor!
I'm just a little Bash/Awk-scripting, and looking for the place where that infos are stored.
Much of the other window related infos are accessible through little GNU/Unix - helpers,
but that ones unfortunately not.
When you use openbox (as you mentioned above), you should read it's documentation and probably look in the sources.
But I have another idea, I have used FVWM2 for quite some time and it is very good documented, they have a very good mailinglist. If you really want to understand, how such a WM works, I would recommend to install FVWM, http://www.fvwm.org/documentation/
@ markush : You're right, Openbox is the WM I'm using, and it's
good documented and highly configurable, but that single part
I'm looking for seems only available as a setting.
The best sources you can look through are such knowledgebases
like in these forum.The big advantage is, that a forum works
Fvwm was on my mind some time ago, but it's a real monster!
But you can find many templates for it's configuration. Look for example here http://ironphoenix.org/tril/fvwm/configs/
@ markush : No, I will stay a while with the *boxes, I love them !
As you can see, I've problems enough in that tiny universe...
xwininfo or xprop may be of some help.
@ gnashley : Yes, Xwininfo, Xprop, Wmctrl and others all became my friends.
I have looked through their different outputs, but it seems I will have no
luck with the deco issue.
Sometimes, you can't think stupid enough, so I had to be pushed with my nose
on the xprop -root option. The manual says, this option is only useful if you
have an "obscured rootwindow", which I hopefully never get, so I didn't try...
Logically thought, you can't get infos about any undetermined
window with xprop. It just works for a specified window, which
I don't have when I'm searching for it. So the rootwindow was
the right place !
But the deco-infos I need seemes to be deeply hidden inside Openbox, and contrary to its name, I will let the box closed !
Fortunatly, the absence of that info will not destroy the main intention
for my scripts. The placement of the windows, with or without any
decos/borders, is carried out correctly, and that is the essential point.
Having the right decos/borders for any particular window would "just" make
the script perfect, other, real professional DEs don't care about that...
|All times are GMT -5. The time now is 07:52 AM.|