On Sun, Feb 07, 2010 at 03:04:37PM +1000, Adam Nielsen wrote: > Hi all, > > I'd like to try some advanced Awesome config with Firefox but I'm a bit > stuck, > any help would be appreciated. > > I want to configure two Firefox windows side by side (and this is fine with > one of the tiling layouts), however I don't want any other Firefox windows > tiled. At the moment if I open the Preferences window my two browser windows > get squished up. I would like the prefs window to be floating. >
This should do the trick for your Preferences window:
{ match = { "Firefox.*" }, tag = "www", master = true },
{ match = { "Firefox Preferences" }, tag = "www" },
> Normal browser windows seem to have two classes, "Firefox" and "Navigator"
> whereas the prefs window has "Firefox" and "Browser". It looks like setting
> any window with the "Firefox" class but not the "Navigator" class to floating
> would do the trick, but I'm not sure how to accomplish this.
>
If you want more than just the Preferences window fixed, it's a bit more
complex. I have my Firefox
configured such that the 2nd, 3rd ... nth windows float, but the primary window
is tiled. This is
accomplished with the following code:
-- make all Firefox windows > 1 float
firefox_count = 0
local function manage_firefox( c )
if "Firefox" == c.class then
awful.client.toggletag( c, "www" )
firefox_count = firefox_count + 1
if firefox_count > 1 then
awful.client.floating.set( c, true );
print( "floating " .. c.class .. " (count: " .. firefox_count ..
")" )
end
end
c:remove_signal( "property::class", manage_firefox )
end
client.add_signal(
"new",
function( c )
c:add_signal( "property::class", manage_firefox )
end )
client.add_signal(
"unmanage",
function (c)
if "Firefox" == c.class then
firefox_count = firefox_count - 1
end
end )
You could change the conditional in the first block to be 'if firefox_count >
2' to support your
layout.
> Secondly, opening PDF files and other attachments that load external
> applications also causes the browser windows to squish up. I would like any
> application opened while tag 3 is focussed to appear on tag 4 instead, and
> the
> layout switches to show tag 4 (and hide tag 3.) Is that possible?
>
You could configure those apps to different tags under config.apps. Otherwise,
you should be able
to do that with shifty by making the tag with Firefox 'exclusive'. This forces
new windows in said
tag to be opened in another tag. See http://awesome.naquadah.org/wiki/Shifty
for more info on
shifty.
> Many thanks,
> Adam.
HTH.
--
Richard Kolkovich
http://www.sigil.org
PGP Key: 0x9E54EF59 (http://pgp.mit.edu)
pgpIywRFiYpIb.pgp
Description: PGP signature
