This uses imlib2 for loading the image and thus supports more image formats than
just PNG.
Almost fixes: FS#958
Signed-off-by: Uli Schlachter <psychon@znc.in>
So the utility of `awful.placement` is not merely limited to client objects,
but also to wiboxes.
[us: use appropriate naming convention; catch misplaced statement]
Signed-off-by: Anurag Priyam <anurag08priyam@gmail.com>
Signed-off-by: Uli Schlachter <psychon@znc.in>
Given an object's coordinates, `awful.screen.getbycoord` can be used to
determine the screen than the object is, or should be attached to.
Signed-off-by: Anurag Priyam <anurag08priyam@gmail.com>
Signed-off-by: Uli Schlachter <psychon@znc.in>
The `screen` property on wibox (drawin) was removed in the commit - 'drawin:
Remove screen property'.
Signed-off-by: Anurag Priyam <anurag08priyam@gmail.com>
Signed-off-by: Uli Schlachter <psychon@znc.in>
Luadoc confuses '<stop>' with an HTML tag otherwise.
Signed-off-by: Anurag Priyam <anurag08priyam@gmail.com>
Signed-off-by: Uli Schlachter <psychon@znc.in>
In general, patterns are specified as 'type:arguments', where 'arguments' is
specific to the pattern used. The example provided in the documentation,
defined the pattern type to be 'linear', but used arguments meant to create
radial pattern. So we modify the example to use the correct type -- 'radial'.
Signed-off-by: Anurag Priyam <anurag08priyam@gmail.com>
Signed-off-by: Uli Schlachter <psychon@znc.in>
The documentation for these functions were hidden (intentionally?) from luadoc
because of misspelt @class and @name tags. Fixed the spelling, so luadoc can do
its job.
Signed-off-by: Anurag Priyam <anurag08priyam@gmail.com>
Signed-off-by: Uli Schlachter <psychon@znc.in>
Symbols (or, visual hints) used to indicate that a client is: 'ontop' or
'floating' or 'maximized_horizontal' or 'maximized_vertical', can now be
defined in the theme, or passed to awful.widget.tasklist() as the last, 'style'
argument (see docs).
Signed-off-by: Anurag Priyam <anurag08priyam@gmail.com>
Signed-off-by: Uli Schlachter <psychon@znc.in>
Most probably, the original author chose to use 'K' first, switched to
'myclock' later, and forgot to update remaining occurrences of 'K'.
Signed-off-by: Anurag Priyam <anurag08priyam@gmail.com>
Signed-off-by: Uli Schlachter <psychon@znc.in>
This was first fixed in 79b1f5aba1, but 3fbb5f15 reintroduced the crash. The
only "real" change in here is that there is now a "return;" after the
warn("Trying...");. The rest is just re-indentation.
Signed-off-by: Uli Schlachter <psychon@znc.in>
There was a few days ago a bug report about missing icons with provided
link to the original ones. My previous patch was with icons made
by me using the ones from default theme, just changed the color.
Probably you should ignore it and use this one unless you like
my made more.
Signed-off-by: Arvydas Sidorenko <asido4@gmail.com>
Signed-off-by: Uli Schlachter <psychon@znc.in>
The default background color (None) means that the server will leave the
window's content untouched when an exposure happens. This should get rid of all
cases of "flashing window".
The real background will later be drawn while awesome is handling the expose
event.
Signed-off-by: Uli Schlachter <psychon@znc.in>
Before this commit, a submenu was border_width pixels lower than its parent menu
entry. Fix this by not adding the border_width to the submenu's position.
We still have to add the border_width to the parent menu's width so that the
border of the submenu entry doesn't overlap the content of its parent menu (the
borders of the two menus do overlap!).
Signed-off-by: Uli Schlachter <psychon@znc.in>
Initializing the client property "floating_geometry" on the
property::geometry signal is problematic since this is emitted before
client_set_border_width(), causing the internal client geometry to get
stored and later passed to client:geometry() which assumes it includes
titlebar and borders.
Signed-off-by: Corey Thompson <cmtptr@gmail.com>
Signed-off-by: Uli Schlachter <psychon@znc.in>
If the first argument to cycle must be > 1 or else return nil
immediately.
Signed-off-by: Perry Hargrave <resixian@gmail.com>
Signed-off-by: Uli Schlachter <psychon@znc.in>
Whenever awesome's C code calls into lua via a protected call, the debug::error
signal is emitted on errors. We now use this to give naughty popups for every
single error that happens. This should help people to notice errors easier.
The only exception are mouse and key grabbers and config loading, those don't go
through debug::error. I guess that means that the grabbers need to be hooked up
to debug::error. :-)
Signed-off-by: Uli Schlachter <psychon@znc.in>
If loading of any config file fails, awesome will now remember the error message
and make it available to lua. The default config is modified to open a naughty
popup on errors.
This should help all those people who modify their config and then wonder why
there change is ignored, not noticing awesome's error message on stderr.
Signed-off-by: Uli Schlachter <psychon@znc.in>
In the textbox' draw() callback we forgot to set the pango layout's width and
height. Whoops.
This was tested with the following code which makes it visible when the textbox
draws outside of its assigned space:
local w = wibox({ screen = 1 })
w.y = 10
w.x = 10
w.width = 150
w.height = 150
w.visible = true
local wi = wibox.widget.base.make_widget()
local t = wibox.widget.textbox()
t:set_markup("Foo <b>bar</b> <i>Foobar</i> und so weiter")
wi.draw = function(d, wibox, cr, width, height)
cr:move_to(24.5, 0)
cr:line_to(24.5, 150)
cr:move_to(0, 24.5)
cr:line_to(150, 24.5)
cr:move_to(124.5, 0)
cr:line_to(124.5, 150)
cr:move_to(0, 124.5)
cr:line_to(150, 124.5)
cr:set_line_width(1)
cr:stroke()
cr:translate(25, 25)
t.draw(t, wibox, cr, 100, 100)
end
w:set_widget(wi)
Signed-off-by: Uli Schlachter <psychon@znc.in>
Tagging sticky clients shouldn't hurt anything, but it helps a lot if the client
later becomes unsticky. I'd have no tags in that case.
Signed-off-by: Uli Schlachter <psychon@znc.in>
This moves the loading of the rc.lua and managing of pre-existing clients to
after we ungrab the server during startup. To make sure we have no races with
clients which start up parallel to awesome, we do the QueryTree for all the
clients that we have to manage before the ungrab, but start managing the clients
only after the ungrab.
This means that we have already selected our event mask on the root window in
scan() and thus received an UnmapNotify event when we reparent windows into a
frame window. This has the effect that we immediately unmanage the client again,
whoops.
To fix this, we grab the server again and remove our event mask on the root
window again while we reparent.
This should hopefully fix all cases where we deadlock during startup because
pulseaudio wants to talk to the X server, but is being ignored because we have
the server grabbed while at the same time we are waiting for pulseaudio.
Signed-off-by: Uli Schlachter <psychon@znc.in>
Setting a metatable on a lightuserdata sets the metatable for *all*
lightuserdata. Only tables and userdata have per-instance metatables.
This commit is an ugly hack to convert screen objects to real userdata.
Mailing list thread:
http://thread.gmane.org/gmane.comp.window-managers.awesome.devel/6543
Signed-off-by: Uli Schlachter <psychon@znc.in>
Instead of re-creating all the widgets for the list entries on each update, this
code now caches its widgets again and only creates new widgets when a new
client/tag appears.
Signed-off-by: Uli Schlachter <psychon@znc.in>
We were only creating an X11 window for a new drawin after we handled all the
options that were passed in. However, this means that drawin({ height = 4 })
would try to resize the window before we created a window, which caused an X11
error.
Fix this by moving our initialization before of the handling of construction
arguments.
Signed-off-by: Uli Schlachter <psychon@znc.in>
This option is no longer valid in modelines, so it has been removed from
all modelines using the following shellscript:
#!/bin/ksh
git ls-tree -r HEAD | cut -f2 | while read f; do
egrep -e '^(//|--) vim: .*encoding=' $f >/dev/null || continue
sed -E -e '/^(\/\/|--) vim:/s/:encoding=utf-8//' $f > /tmp/foo
mv /tmp/foo $f
done
Signed-off-by: Gregor Best <gbe@ring0.de>
Signed-off-by: Uli Schlachter <psychon@znc.in>