You are not logged in.

#1 2009-07-08 17:42:37

nephish99
Member
Registered: 2007-09-01
Posts: 85

two questions on awesome use SOLVED

Hey all,

I am really digging awesome. Very cool.
I have been trying to find a way to keep the 1pix border on the windows because the color tells me which has focus, but is there a way to have awesome not draw a border for a floating window?

next, when i use mod-p to get the little run dialog at the top, it allows tab completion. I have seen a couple of other tiling wms that use something else. like wmii shows an as-you-type lookup, is there a way to have this in awesome?

Well, thats all the questions i had that i could not find myself.
thanks for any tips

Last edited by nephish99 (2009-07-13 13:33:45)

Offline

#2 2009-07-09 01:30:31

Intrepid
Member
Registered: 2008-06-11
Posts: 254

Re: two questions on awesome use SOLVED

Ok as for tab completion, use dmenu_run to see all the apps and replace Modkey + P in your rc.lua to do this.  This is identical to WMII

Second, I'm sure it would be easy enough to code a hook yourself when creating a floating window which turns off borders.  Have a look at the API called awful at awesome.naquadah.org.  Highly useful information!

Third, Xmonad does that (easily remove border from floating windows), but I don't exactly advocate Xmonad anymore; I like awesome better and it's just as scriptable, again, look at the hook syntax.


Intrepid (adj.): Resolutely courageous; fearless.

Offline

#3 2009-07-09 02:17:55

nephish99
Member
Registered: 2007-09-01
Posts: 85

Re: two questions on awesome use SOLVED

cool, thanks, have the dmenu_run and it's terrific.
So, still looking into the float thing, but wanted to say thanks

Offline

#4 2009-07-09 02:53:31

Intrepid
Member
Registered: 2008-06-11
Posts: 254

Re: two questions on awesome use SOLVED

In your rc.lua, go to the section that says awful.hooks.manage.register(function (c, startup)
Go to the section that says -- Check if the application should be floating.
Underneath EACH line that says awful.client.floating.set within this hook ONLY.....  write this line:

c.border_width = 0

Ok add this COMPLETELY AFTER the section that says "Check if the application should be floating" within this hook ONLY

if awful.client.floating.get(cls) then
     c.border_width = 0
end

Now you need to make a new function when making a window nontiling.  Replace ALL instances of awful.client.floating.toggle in your rc.lua with customfloat .  Now make a new function after beautiful.init:

function customfloat ()
   local c = awful.focus.history.get(screen,0)
   if c then client.focus = c end
   if not awful.client.floating.get(c) then
     c.border_width = beautiful.border_width
   end
end

PLEASE BACK UP YOUR RC.LUA.  I think this code will work but I am not sure as I find it silly you want to disable the borders!

HOWEVER if you want no borders for ONE application, e.g. just Wine programs wink then it's much simpler than this.  You have to make the program start floating first and set the borders to 0 in the manage hook if the window matches the class of the floating window.  Tell me which one you want.

Last edited by Intrepid (2009-07-09 03:01:55)


Intrepid (adj.): Resolutely courageous; fearless.

Offline

#5 2009-07-09 03:27:22

nephish99
Member
Registered: 2007-09-01
Posts: 85

Re: two questions on awesome use SOLVED

Hey, thanks again.
Put into place what you have, but it removed the borders of every window, not just the tiling ones.

The floating terms do look cool though

Offline

#6 2009-07-09 15:44:33

nephish99
Member
Registered: 2007-09-01
Posts: 85

Re: two questions on awesome use SOLVED

you know, if it's easier, it would be cool just to have the border drawn for any focused window, but no others

Offline

#7 2009-07-11 19:42:12

Intrepid
Member
Registered: 2008-06-11
Posts: 254

Re: two questions on awesome use SOLVED

That would actually be much easier.  Then take out all of that code and instead do this.
In awful.hooks.focus.register(function (c) section add this to the end:

 c.border_width = beautiful.border_width

In awful.hooks.unfocus.register(function (c) section Comment every line out with --.  Then add the following at the end

 c.border_width = 0

Intrepid (adj.): Resolutely courageous; fearless.

Offline

#8 2009-07-11 20:32:26

nephish99
Member
Registered: 2007-09-01
Posts: 85

Re: two questions on awesome use SOLVED

works perfectly ! thanks a million.

Offline

#9 2009-07-13 03:00:51

Intrepid
Member
Registered: 2008-06-11
Posts: 254

Re: two questions on awesome use SOLVED

please edit your first post and include in the title [SOLVED] big_smile  And I'm very happy to help!


Intrepid (adj.): Resolutely courageous; fearless.

Offline

Board footer

Powered by FluxBB