Commit Graph

4948 Commits

Author SHA1 Message Date
Pierre Mazière 05e2ab4d50 fix wibox origin when stretched
Signed-off-by: Pierre Mazière <pierre.maziere@gmail.com>
Signed-off-by: Julien Danjou <julien@danjou.info>
2010-03-19 10:02:18 +01:00
Pierre Mazière 4c00ad63a9 Add the possibity for dynamic menu
Return the label of the selected menu item as an argument for the
callback function

Signed-off-by: Pierre Mazière <pierre.maziere@gmail.com>
Signed-off-by: Julien Danjou <julien@danjou.info>
2010-03-17 15:59:48 +01:00
Maciej Blizinski 3d8aad10d0 Fix gperf usage (FS#740)
Signed-off-by: Julien Danjou <julien@danjou.info>
2010-03-15 09:58:37 +01:00
Adrian C. (anrxc) fda2c091db awesomerc: add Mod4+t to set client on-Top
Signed-off-by: Adrian C. (anrxc) <anrxc@sysphere.org>
Signed-off-by: Julien Danjou <julien@danjou.info>
2010-03-04 09:33:55 +01:00
Adrian C. (anrxc) 20d16fb6ac awful.wibox: update position on height/width property change
Changing the width or height of a (right or bottom positioned)wibox,
after it was initialized, to a value different than used when it was
created would leave the wibox in a wrong position. Position was off by
as many pixels as the difference between the old and the new
value. Now every wibox is repositioned to reflect this new setup.

Signed-off-by: Adrian C. (anrxc) <anrxc@sysphere.org>
Signed-off-by: Julien Danjou <julien@danjou.info>
2010-03-04 09:31:45 +01:00
Gregor Best 09cf4f2c86 client: _really_ honor size hints
If c->honor_size_hints is set to false and the client indicates through
its hints that it wants to be fixed size (by setting min and max width
equal), size hints are not ignored due to client_isfixed not taking
honor_size_hints being false into account. This commit fixes that.

Signed-off-by: Gregor Best <gbe@ring0.de>
Signed-off-by: Julien Danjou <julien@danjou.info>
2010-03-03 09:18:17 +01:00
Julien Danjou 33fae25948 change codename
Signed-off-by: Julien Danjou <julien@danjou.info>
2010-03-02 17:54:05 +01:00
Adrian C. (anrxc) 21d3d2aae5 awful.widget: add progressbar set_max_value property
The awful.widget.graph allows to change the maximum value a graph can
handle, thus allows users to use widgets and scripts that don't scale
the values down to 0 - 1 range. The progressbars did not allow this
and worked with a hard-coded value of 1.

Signed-off-by: Adrian C. (anrxc) <anrxc@sysphere.org>
Signed-off-by: Julien Danjou <julien@danjou.info>
2010-03-02 11:59:52 +01:00
Adrian C. (anrxc) f41d7e270f awsetbg: add fvwm-root support
fvwm-root is a part of the FVWM window manager, and is one of those
utilities that properly support transparency because it can retain and
publish the Pixmap with which the background has been set. It supports
XBM, XPM, PNG and SVG image formats, but is not very rich in options
as opposed to habak or feh.

Signed-off-by: Adrian C. (anrxc) <anrxc@sysphere.org>
Signed-off-by: Julien Danjou <julien@danjou.info>
2010-03-01 16:01:04 +01:00
Adrian C. (anrxc) 9f537bcb37 awful.menu: sanitize support for access keys
Commit 87070ca introduced support for access keys in menus. Chosen
character was "&", an XML entity that has potential to cause problems;
if a user tries to add multiple access keys or just put an ampersand
in the name of the item the menu will break. Breaking happened because
ampersands were not escaped - first one was substituted and the rest
were ignored, but not escaped which triggered a pango markup error.

Signed-off-by: Adrian C. (anrxc) <anrxc@sysphere.org>
Signed-off-by: Julien Danjou <julien@danjou.info>
2010-03-01 15:57:14 +01:00
Matthias Schröder b38569913c awful.menu: support for access keys
You can define a menuitem like before:

awful.menu({ items = { { "&awesome", myawesomemenu,
	 		    beautiful.awesome_icon },
                       { "open &terminal", terminal },
	   })

and the letters following the ampersand in itemname can be used as
access key. (at least former fvwm users might find this familiar)

When there are submenus open awesome ascends during the search from the
current menu to the top level menu.

The access key is shown underlined.

There is no warning for multiple used keys, only the first one found
gets the price.

Signed-off-by: Julien Danjou <julien@danjou.info>
2010-03-01 15:57:00 +01:00
Julien Danjou 4299c5b184 ewmh: remove _NET_WORKAREA support (FS#732)
This fixes problem with Qt 4.6.
Our implementation cannot be standard, and was not standard, so just
stop using this EWMH crap.

Signed-off-by: Julien Danjou <julien@danjou.info>
2010-02-18 10:04:47 +01:00
Gregor Best 574c630a1b naughty: add suspend() and resume()
This commit adds naughty.suspend() and naughy.resume() which allow
suspension of notifications, which is useful e.g. when watching a movie,
where notifications popping up all the time would be disturbing.

While suspended, notifications are collected and displayed after
naughty.resume() is called.

Signed-off-by: Gregor Best <gbe@ring0.de>
Signed-off-by: Julien Danjou <julien@danjou.info>
2010-02-17 16:23:55 +01:00
Andrei 'Garoth' Thorp 0a87e031fe Fix naughty.destroy parameter documentation
Signed-off-by: Julien Danjou <julien@danjou.info>
2010-02-17 16:23:54 +01:00
Uli Schlachter adff92ca53 property.c: Don't leave stuff on the lua stack
property_update_wm_hints() pushes the client but never pops it. This is a really
bad thing (tm).

Signed-off-by: Uli Schlachter <psychon@znc.in>
Signed-off-by: Julien Danjou <julien@danjou.info>
2010-02-10 09:46:28 +01:00
Uli Schlachter bec9e24e7f client_focus_update(): Balance the lua stack
There is a push 15 lines before the push that is removed here, but the client
that is pushed there was never popped. Bad.

Fix this by letting luaA_class_emit_signal() do the needed pop for us.

Signed-off-by: Uli Schlachter <psychon@znc.in>
Signed-off-by: Julien Danjou <julien@danjou.info>
2010-02-10 09:46:25 +01:00
Thomas Arendsen Hein 5f9bd088f2 New images for maximized layout.
Based on an idea by Steve Pomeroy (xxv)

Signed-off-by: Julien Danjou <julien@danjou.info>
2010-01-24 11:23:55 +01:00
Adrian C. (anrxc) 56c1fdf226 awful.rules: fix client tagging with multiple screens
Commit a757dda replaced the awful.client.movetotag call with c:tags()
in the tag property handler. Which introduced a regression when more
than one screen is used. The awful.tag.withcurrent function was being
called even when there was a valid tag property. Now the clients
screen is set to the tag screen to ensure the client is moved to the
correct tag and screen.

Signed-off-by: Adrian C. (anrxc) <anrxc@sysphere.org>
Signed-off-by: Julien Danjou <julien@danjou.info>
2010-01-11 10:09:19 +01:00
Adrian C. (anrxc) dfd6060a53 awful.autofocus: improve client focus with multiple screens
Changing screen focus to an empty tag leaves focus on a client on the
previous screen, if a tag with clients is focused next the focus
remains on the previous screen. Now awful.autofocus compares the tag
screen and clients screen to learn if the focus should be given to a
client on the focused screen. Client that gets the focus is selected
from history, as usual.

Signed-off-by: Adrian C. (anrxc) <anrxc@sysphere.org>
Signed-off-by: Julien Danjou <julien@danjou.info>
2010-01-10 10:31:17 +01:00
koniu a757ddabc4 awful.rules: tag clients without flicker (FS#664)
We unregister the default awful.tag.withcurrent 'manage' signal handler
and have awful.rules.apply handle initial client tagging.

Signed-off-by: koniu <gkusnierz@gmail.com>
Signed-off-by: Julien Danjou <julien@danjou.info>
2010-01-08 19:11:25 +01:00
koniu a1f0669b64 awful.tag: register 'withcurrent' explicitly
This explicitly registers withcurrent(c) as a manage signal handler so
that it can be removed if necessary.

Signed-off-by: koniu <gkusnierz@gmail.com>
Signed-off-by: Julien Danjou <julien@danjou.info>
2010-01-08 19:11:24 +01:00
Julien Danjou d09c3c02e8 Handle synthetic UnmapNotify events *correctly*
Second try:

Turns out I messed up with XCB_EVENT_SENT() and had a "!" too much. The old code
already tried to cope with this, but forgot to actually unmap the window which
it just set to withdrawn state.

This time I tested the patch *again* and now I found even less bugs than on my
last try.

P.S.: I suck.

Signed-off-by: Uli Schlachter <psychon@znc.in>
Signed-off-by: Julien Danjou <julien@danjou.info>
2010-01-06 09:42:05 +01:00
Adrian C. (anrxc) 9038c5165d awful.wibox: sanitize height/width args to function new()
When both height and width arguments are provided to the function
new() there is a check to see if one of them was a screen percentage,
and is expected to be a string. If the user provided absolute pixels,
and argument is of type number awesome will crash. Now tostring is
used to sanitize the arguments during this check.

Signed-off-by: Adrian C. (anrxc) <anrxc@sysphere.org>
Signed-off-by: Julien Danjou <julien@danjou.info>
2010-01-05 09:53:14 +01:00
Alex Alexander b24348219e wibox: fix align
awful.wibox.align() in 3.4.x gets the available screen area from
capi.screen[screen].geometry.

this can easily result in overlapping wiboxes since the work area
provided does not account for existing wiboxes.

In my configuration I use a vertical wibox positioned at the
right and it half-overlaps my top wibox because it is streched and
hard-coded to align at the middle.

Signed-off-by: Julien Danjou <julien@danjou.info>
2010-01-05 09:52:43 +01:00
Julien Danjou 553b2bfe99 change codename
Signed-off-by: Julien Danjou <julien@danjou.info>
2010-01-04 09:50:02 +01:00
Adrian C. (anrxc) 6a44c60f4f Cleanup after revert of "Handle synthetic UnmapNotify events"
The revert accidentaly replaced window_state_get_reply and
window_state_get_unchecked calls in event.c with:
xwindow_get_state_reply/unchecked respectively.

Signed-off-by: Adrian C. (anrxc) <anrxc@sysphere.org>
Signed-off-by: Julien Danjou <julien@danjou.info>
2010-01-04 09:47:21 +01:00
Adrian C. (anrxc) 799c94ff48 awful.wibox: take wibox border into account when updating struts
Function wibox_update_strut would not take the border width into
account when calculating struts. When a wibox border was in use
clients would overlap the wibox. With a border of 1px we loose 1px of
the wibox, but as the wibox border increases it is "pushed" by the
border nearest the screen edge and clients steal more and more space.

Signed-off-by: Adrian C. (anrxc) <anrxc@sysphere.org>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-12-30 19:51:35 +01:00
Uli Schlachter 6cd4f9d11a Revert "Handle synthetic UnmapNotify events"
This reverts commit 8e672897cb.

Signed-off-by: Julien Danjou <julien@danjou.info>
2009-12-29 09:53:12 +01:00
Gwenhael Le Moine 407db4c0df build: fix typo
Signed-off-by: Gwenhael Le Moine <gwenhael.le.moine@gmail.com>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-12-29 09:52:43 +01:00
Julien Danjou 742d85dd0e Handle synthetic UnmapNotify events
According to the Inter-Client Communication Conventions Manual, if you want to
switch your window to withdrawn state, you unmap it and send a synthetic
UnmapNotify to the root window.

This synthetic event fixes a race condition. When you map and unmap a window
quickly, the map will generate a MapRequest for the WM but won't actually map
the window. Thus, the unmap will be discarded (-> window not yet mapped) and the
window stays map once the WM handles the MapRequest

Before this patch, awesome just ignored the synthetic unmap notify which caused
the bug to appear again. With this patch it doesn't happen anymore.

Signed-off-by: Uli Schlachter <psychon@znc.in>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-12-28 16:41:39 +01:00
Pierre Allegraud a4fb1e00f7 build: make manpage compression optional
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-12-28 10:44:10 +01:00
Uli Schlachter 531381fa6d Implement the GetCapabilities call in naughty
This call is required by the freedesktop specification.

Signed-off-by: Uli Schlachter <psychon@znc.in>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-12-28 10:42:06 +01:00
Julien Danjou 1e2fcadfd0 dbus: add support for array as returned type
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-12-28 10:39:51 +01:00
Julien Danjou b92c3735a1 dbus: move some convert code in a function
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-12-28 10:36:41 +01:00
Uli Schlachter 365e80c5bb Make it easier to change the default layout
In older versions of awesome, the first entry in the layouts table was the
default layout. Currently it's always the floating layout.

With this patch the default is again the first entry in the layouts table.  At
the same time, floating is moved to be the first entry, so this patch doesn't
change any behavior at all.

Signed-off-by: Uli Schlachter <psychon@znc.in>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-12-22 12:47:17 +01:00
Pierre Allegraud 1fd1155897 build: do not install .in files
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-12-22 12:46:29 +01:00
Pierre Allegraud 93fdc17799 fix build on NetBSD (FS#706)
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-12-21 08:48:21 +01:00
Julien Danjou f8984fc503 image: load with image
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-12-14 10:27:15 +01:00
Julien Danjou 4b622523eb image: Use imlib2's image cache
This makes imlib add images loaded from files to its image cache again. That way
we avoid loading the same image again and again (e.g. if you cycle through the
list layouts all the layout icons are loaded).

To not reintroduce FS#651 (fixed in 2dadce9b), we call
imlib_image_set_changes_on_disk(). This causes two stat() calls if the same file
is loaded again to check if the file's timestamps changed which is still less
expensive than loading the whole image again.

Signed-off-by: Uli Schlachter <psychon@znc.in>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-12-14 10:24:08 +01:00
Julien Danjou 84acfc4652 systray: fix screen number retrieval
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-12-10 10:10:20 +01:00
Sébastien Gross a8425df036 tooltip: force place() if tooltip is not visible
Commit 6c5d0ca9 introduced a side effect. If tooltip text isn't changed
place() function is not called. To prevent multiple place() set_geometry
calls that function when tooltip is not visible (before it appears to the
user).

Signed-off-by: Sébastien Gross <seb•ɱɩɲʋʃ•awesome•ɑƬ•chezwam•ɖɵʈ•org>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-12-03 14:22:21 +01:00
Adrian C. (anrxc) 878f9e7580 awful.menu: add keygrabber support to clients menu
Functions show() and toggle() accept a boolean parameter controlling
keyboard navigation. In case of the clients menu neither is called
directly, instead the clients menu is always re-created in case any
new clients appeard since the last invocation. This patch adds a
keygrabber parameter to the clients() function as well.

Signed-off-by: Adrian C. (anrxc) <anrxc@sysphere.org>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-12-03 14:22:15 +01:00
Uli Schlachter 3d60aa7d83 Fix a invalid pointer crash bug
This changes wibox_t::mouse_over to a proper reference. That way one can't
remove that widget from underneath us which would lead to an unprotected lua error.

Signed-off-by: Uli Schlachter <psychon@znc.in>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-12-02 09:33:09 +01:00
Robert Lehmann 7ea3c35cc2 naughty: fix CloseNotification argument usage
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-12-01 14:15:04 +01:00
Julien Danjou b45fd1f530 dbus: fix D-Bus documentation typo
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-12-01 10:01:50 +01:00
Julien Danjou dd7362157e change codename
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-11-26 20:03:25 +01:00
Julien Danjou 3ed302239e build: dist now build .xz instead of .gz
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-11-26 20:03:25 +01:00
Hiltjo Posthuma 4c2c741743 Rules: check if properties of a rule exist
Actually check if properties are set now, since we can also only
apply callbacks now.

Signed-off-by: Julien Danjou <julien@danjou.info>
2009-11-25 17:10:13 +01:00
perry 298f773357 Revert "awful.autofocus: fix multiple screens autofocus"
This reverts commit 7575f64993.

As seen on ML:

Switching tags with multiple heads causes focus to change
screens with this commit

Signed-off-by: perry <perry.hargrave@gmail.com>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-11-23 19:28:36 +01:00
Hiltjo Posthuma b097266925 awful.menu: use actual wibox border width
We check the wibox border width for inappropiate values now, if we set
border_width to a negative value (invalid) in our theme and draw it, the
actual border_width will be 0 so the menu will be drawn incorrectly.
This fixed this.

Signed-off-by: Hiltjo Posthuma <hiltjo@codemadness.org>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-11-21 10:48:10 +01:00