You are not logged in.

#1 2008-09-17 13:35:39

dmz
Member
From: Sweden
Registered: 2008-08-27
Posts: 881
Website

1px border around terminals, but not other windows - possible?

Hi, I am looking for a way to be able to have an 1 pixel white border around my terminals (I'm using devilspie to strip them completely off decorations), but I dont want those borders to be around regular GTK-apps - is this possible?

I am using openbox, and here's a screenshot so that you can see what I mean - the scrot window have this border that I want on terminals but not on other windows.. uh:

http://img34.picoodle.com/data/img34/3/ … 5bba75.png

Offline

#2 2008-09-17 15:12:58

neodreams
Member
Registered: 2006-03-20
Posts: 87

Re: 1px border around terminals, but not other windows - possible?

First in your ~/.config/openbox/rc.conf you put that in your applications section:

        <application class="*">
            <decor>no</decor>
            <keepBorder>no</keepBorder>
        </application>

It will remove all decorations and borders for all apps.

Then add another rule in the applications section to put the borders for your terminal, like if it is urxvt you do:

        <application name="urxvt">
            <keepBorder>yes</keepBorder>
        </application>

Reload your config and that's it.

Offline

#3 2008-09-17 15:21:24

dmz
Member
From: Sweden
Registered: 2008-08-27
Posts: 881
Website

Re: 1px border around terminals, but not other windows - possible?

Thanks a lot man.

Offline

#4 2008-09-17 16:15:05

neodreams
Member
Registered: 2006-03-20
Posts: 87

Re: 1px border around terminals, but not other windows - possible?

No i made a mistake sorry, the keepBorder is only usable in the desktop section, so all apps will keep borders or lose them. You can't use that for some applications only.

Maybe the right thing to do is to set <keepBorder>no</keepBorder> in the desktop section, and if your terminal give you the option to add a border, like urxvt, do it.

In your .Xdefaults

urxvt*externalBorder: 1
urxvt*borderColor: #ffffff

Offline

#5 2008-09-17 16:32:01

dmz
Member
From: Sweden
Registered: 2008-08-27
Posts: 881
Website

Re: 1px border around terminals, but not other windows - possible?

neodreams wrote:

No i made a mistake sorry, the keepBorder is only usable in the desktop section, so all apps will keep borders or lose them. You can't use that for some applications only.

Maybe the right thing to do is to set <keepBorder>no</keepBorder> in the desktop section, and if your terminal give you the option to add a border, like urxvt, do it.

In your .Xdefaults

urxvt*externalBorder: 1
urxvt*borderColor: #ffffff

Yeah, I was wondering why the heck it didn't work. Now it finally works as I wanted, thanks again!

Offline

#6 2008-09-18 05:46:10

dav7
Member
From: Australia
Registered: 2008-02-08
Posts: 674

Re: 1px border around terminals, but not other windows - possible?

I have the same problem, except I use pseudo-transparency. The border code does work, but then the pseudo-transparency stuff comes along and sets both the actual terminal background... *and* the border... transparent. So it looks like a bunch of padding.

This is likely a bug, but I don't want to peek inside a terminal emulator yikes so how can I enjoy terminals with borders around them while keeping pseudo-transparency? In case you're thinking "use composite and make the window semitransparent," I'd love to but I can't because using anything that uses composite (xcompmgr, transset) crashes X randomly. As per http://bbs.archlinux.org/viewtopic.php?id=55213 - I have software rendering and don't know how to get hardware rendering, and I think if I got hardware rendering working I'd be able to use composite. sad

PS, I know how the transparency code works without looking at it because software rendering is so slow here I can actually see the solid border appear then dissappear.

PPS. For some reason, using the external border trick here does zero (gives me no border or padding), so I have to use the internal border option - is this why I'm failing? What options give me an external border? I've been trying '-w 10' to no avail.

-dav7

Last edited by dav7 (2008-09-18 05:52:29)


Windows was made for looking at success from a distance through a wall of oversimplicity. Linux removes the wall, so you can just walk up to success and make it your own.
--
Reinventing the wheel is fun. You get to redefine pi.

Offline

Board footer

Powered by FluxBB