Commit Graph

4484 Commits

Author SHA1 Message Date
Julien Danjou 301affeaed image: cleanup header declaration
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-11 11:50:55 +02:00
Julien Danjou 46ce0c1da1 widget: remove useless widget_calculate_offset()
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-11 11:50:12 +02:00
Gregor Best 680e51049e naughty: add opacity option
Signed-off-by: Gregor Best <farhaven@googlemail.com>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-10 23:18:51 +02:00
Julien Danjou e24df900bb luaa: fix luaA_getopt_*
We let an element on the stack, that's bad.

Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-10 18:50:23 +02:00
Uli Schlachter 2a6d5d207d client_stack(): Only stack windows once per mainloop
I was creating 2000 wiboxes in a loop (don't ask) and creating them took
forever. According to callgrind, there were about 2 million calls to
xcb_configure_window() and most (if not all) of them were from client_stack().
Awesome spent 70% of its cpu time in these client_stack() calls.

client_stack() is O(N^2) on the number of clients (it walks the list of clients
itself twice and each call to client_stack_above() walks the list too) and O(N)
on the number of wiboxes (it walks the wibox list twice). So obviously calls to
it should be rare.

This patch makes client_stack() only set a flag which is later checked. This
should reduce the number of restacks to the bare minimum. With this patch,
neither xcb_configure_window() nor anything else client_stack() related shows
up as having a lot of calls or using much cpu time.

Signed-off-by: Uli Schlachter <psychon@znc.in>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-10 18:15:48 +02:00
Uli Schlachter 4b82608952 Remove the argument to awesome_refresh()
awesome_refresh() had a xcb_connection_t as first argument. Since there is
only one connection to the X server, this argument doesn't really have any
alternatives to globalconf.connection and thus makes no sense.

Signed-off-by: Uli Schlachter <psychon@znc.in>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-10 18:02:49 +02:00
Uli Schlachter 95457c5ab7 Move the definition of globalconf into a header file
Pretty much every single source file needs this struct, so it makes sense to
define it in a common header instead of in every single .c file.

Signed-off-by: Uli Schlachter <psychon@znc.in>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-10 16:32:42 +02:00
Julien Danjou 82329ad78a dbus: refresh everything after message has been handled
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-10 13:57:27 +02:00
Uli Schlachter a076806ce0 Rename LAYER_OUTOFSPACE to LAYER_COUNT
The name LAYER_OUTOFSPACE suggests that this is a real layer on which windows
can be put, but it's only used as an integer which describes the maximum
allowed / used layer.
Therefor, renaming it to LAYER_COUNT and adding a comment which describes this
might make sense.

Signed-off-by: Uli Schlachter <psychon@znc.in>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-10 13:35:26 +02:00
koniu 8f5f965fab screen: do not hardcode the 'default' tag
Signed-off-by: koniu <gkusnierz@gmail.com>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-10 11:00:06 +02:00
Julien Danjou 7fa363d3fe default theme: add fullscreen layout icons
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-08 20:32:55 +02:00
Julien Danjou a1280fe02a build: stop checking for readline
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-08 20:07:45 +02:00
Julien Danjou ae1fb5ab68 update AUTHORS
* Nikos is back
* Update years of Damien and Gregor
* Add Maarten

Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-08 19:01:20 +02:00
Julien Danjou 09b166d71e version: remove product name
We only ship one binary now.

Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-08 18:53:53 +02:00
Julien Danjou c95e73ee61 buffer: remove useless buffer_add_xmlescaped()
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-08 18:08:44 +02:00
Julien Danjou 7dbb02adf3 awesome-client: remove socket code
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-08 17:56:25 +02:00
Julien Danjou f79cd42c33 import new awesome-client using D-Bus
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-08 17:30:18 +02:00
Julien Danjou 36f4e6cb8a awful.remote: import with remote eval
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-08 17:08:26 +02:00
Julien Danjou f7bca3271c luaa: use only one xdgHandle for all
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-08 15:47:31 +02:00
Uli Schlachter 62397eac95 wibox: add wibox_need_update()
This moves some common code into the new function wibox_need_update().

This patch is based on a patch from Julien Danjou.

Signed-off-by: Uli Schlachter <psychon@znc.in>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-07 18:25:37 +02:00
Julien Danjou d441254412 util: remove a_strsplit()
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-07 18:00:55 +02:00
Julien Danjou 7af34ed244 luaa: use libxdg-basedir instead of our code
This is clearly more clear and portable.

Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-07 17:59:39 +02:00
Julien Danjou e53c77540d client: move window function into window.c
This should light client.c a bit.

Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-07 15:58:09 +02:00
Mariusz Ceier 904502552f Focus events handlers
- We are tracking focus, using FocusIn/FocusOut events handlers, so user
  should never be confused about which client has focus
- window_setfocus function generates focus change requests to the X server
- client_focus uses window_setfocus to set input focus
- revert_to when setting input focus set to Parent, compliant with
  ICCCM convention ([1])
- DEBUG flag for those who want to debug focus handlers

Most of the changes, are compliant with X11 handbook ([0]), but some
where obtained experimentally.

Kudos to Maarten Maathuis who helped a lot with this.

[0]
http://cgit.freedesktop.org/xorg/doc/xorg-docs/plain/hardcopy/X11/xlib.PS.gz

[1] http://tronche.com/gui/x/icccm/sec-4.html#s-4.2.7

Signed-off-by: Maarten Maathuis <madman2003@gmail.com>
Signed-off-by: Mariusz Ceier <mceier@gmail.com>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-07 15:42:25 +02:00
Julien Danjou 4d6bf949a8 Revert "event: add FocusOut handler"
This reverts commit 31ba962065.
2009-04-06 13:27:53 +02:00
Julien Danjou 63f2dd3908 build: do not depends on glib directly
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-04 16:42:08 +02:00
Maarten Maathuis 97fb463e76 event: also filter leave notify events
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-04 16:32:54 +02:00
Maarten Maathuis 31ba962065 event: add FocusOut handler
- I don't see why we should guess about what we recieved and whatnot.

Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-04 16:32:46 +02:00
Julien Danjou 0d6d6c4fa7 client: store class and instance
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-04 13:54:51 +02:00
Julien Danjou 208406ea90 client: free icon name
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-04 13:03:15 +02:00
Julien Danjou eaec928b8c client: remove useless icon_path
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-04 13:02:30 +02:00
Julien Danjou b14b52b60c awful.mouse: set the default cursor
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-03 17:15:14 +02:00
Julien Danjou 97baf01cec luaa: add root.cursor()
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-03 17:13:30 +02:00
Julien Danjou e4b9b2b2b4 luaa: documentation fix
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-03 17:06:44 +02:00
Mariusz Ceier c40609642b Fix for FocusIn event handler
10.7.1 chapter of X11 ([0]) describes many cases when FocusIn event is
generated. We are interested only in one FocusIn event type - the one
that is sent to window that gains focus.
Previous 'if' failed in some cases ([1]), this one should be better.

[0]
http://cgit.freedesktop.org/xorg/doc/xorg-docs/plain/hardcopy/X11/xlib.PS.gz
page 211

[1] http://www.mail-archive.com/awesome-devel@naquadah.org/msg01958.html

Signed-off-by: Mariusz Ceier <mceier@gmail.com>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-03 13:10:02 +02:00
Julien Danjou cbf55449a3 luaa: split spawn() into spawn.c
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-03 13:09:17 +02:00
Julien Danjou 16606c6744 luaa: only handle tables in loop check
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-03 11:44:08 +02:00
Julien Danjou c036c8d234 luaa: pop pushed value
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-03 11:25:10 +02:00
Julien Danjou 4605bf5d55 luaa: change looping detection algo (FS#488)
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-03 11:07:18 +02:00
Julien Danjou 3bf7d2ba2b struct: add void array
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-03 11:07:04 +02:00
Julien Danjou 992ee7e304 build: depends on x11
at least for XStringToKeysym()

Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-02 17:33:55 +02:00
Uli Schlachter 24a506e3c5 luaa: close accepted socket on exec
Signed-off-by: Uli Schlachter <psychon@znc.in>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-02 13:45:02 +02:00
Uli Schlachter 4722ba6c10 socket: set close on exec
Signed-off-by: Uli Schlachter <psychon@znc.in>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-02 13:43:18 +02:00
Julien Danjou 9a7381d02a util: add fd_set_close_on_exec()
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-02 13:41:06 +02:00
Julien Danjou 40d821354a awful.prompt: close file after reading
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-02 13:39:52 +02:00
Nikos Ntarmos f24f652962 build: prepend ${PREFIX} to SYSCONFDIR if not set (FS#468)
Also fixes what seemed like a typo in the env checking for
XDG_CONFIG_DIR.

Signed-off-by: Julien Danjou <julien@danjou.info>
2009-04-01 17:56:20 +02:00
Maarten Maathuis db68ae2ebe screen, client: clamp strut size to relevant dimension
- gnome-panel (for example) requests the space for all it's windows
- this approach can never work for multiple applications, so we clamp it

Signed-off-by: Julien Danjou <julien@danjou.info>
2009-03-31 09:17:37 +02:00
Maarten Maathuis 264a81f3fb client: handle struts (a lot) better
- WINDOW_TYPE_DOCK are chosen first.
- Top/Bottom take precedence over Left/Right.
- Struts are automatically updated.
- Automatically avoid overlap with other struts or wibox'es.

Signed-off-by: Julien Danjou <julien@danjou.info>
2009-03-31 09:17:36 +02:00
Gregor Best addfd7b39f awful.menu: fix custom keybindings
Signed-off-by: Gregor Best <farhaven@googlemail.com>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-03-31 09:08:11 +02:00
Gregor Best e9acefa24e awful.menu: fix error when using the keyboard to navigate on an empty menu
Signed-off-by: Gregor Best <farhaven@googlemail.com>
Signed-off-by: Julien Danjou <julien@danjou.info>
2009-03-31 09:08:10 +02:00