Commit Graph

95 Commits

Author SHA1 Message Date
Julien Danjou eb8c36b5c0 luaa: fix typo
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-09-22 11:11:34 +02:00
Julien Danjou 06905f515e awesome-client: read on !tty
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-09-22 11:10:07 +02:00
Nathan Weizenbaum 37f4fbfe39 awesome-client, socket, lua: make awesome-client into a true REPL
After recieving a command from awesome-client, awesome will send
the result of that command in return and awesome-client will print it out.

Signed-off-by: Nathan Weizenbaum <nex342@gmail.com>
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-09-22 11:03:56 +02:00
Julien Danjou b0ab2d4193 util: fix a_exec, use it for spawn
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-09-08 01:45:22 +02:00
Julien Danjou 11dfa832a8 factorize quit/exec elements, and reparent systray
That fixes FS#296.

Signed-off-by: Julien Danjou <julien@danjou.info>
2008-09-02 17:12:10 +02:00
Julien Danjou 5bb2277ef2 lua: snprintf include trailing \0 in size
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-08-27 17:15:47 +02:00
Julien Danjou dcbd7a7c14 socket, lua: use xcb_parse_display
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-08-27 17:14:47 +02:00
Julien Danjou 608b2e2647 dbus, lua: set CLOEXEC on fds
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-08-27 14:20:51 +02:00
Julien Danjou 87a89b6aa1 use xcb_flush; move refresh stuff in common function
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-08-26 19:35:37 +02:00
Julien Danjou 065d7f8a86 lua: otable can now be index by object values
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-08-17 07:52:04 +02:00
Julien Danjou df79115dd1 zaphod: restore support
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-08-15 00:31:32 +02:00
Julien Danjou 40c455046b screen: make tags array overwritable
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-08-13 10:33:15 +02:00
Arnaud Fontaine 193a73c5d9 draw: make xcolor_init() asynchronous. 2008-08-12 14:53:57 +02:00
Julien Danjou 125c259204 lua: remove spurious debug printf
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-08-12 11:46:45 +02:00
Julien Danjou ab66b87377 lua: fix otable __newindex
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-08-11 23:33:35 +02:00
Julien Danjou be2bfdcfc5 screen: introduce screen objects
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-08-11 17:14:02 +02:00
Julien Danjou 8b5f6266da lua: add support for __pairs and __next metamethods
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-08-10 16:15:15 +02:00
Julien Danjou 3814103a1e lua: implement objecttable
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-08-07 16:39:30 +02:00
Julien Danjou ebb9aba4e7 lua: refresh after cs event
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-08-06 20:58:27 +02:00
Kanru Chen cb9c8ef9f5 lua: refresh after calling timer hooks.
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-08-06 20:51:28 +02:00
Julien Danjou 88d9df6a09 lua: add ?/init.lua as valid lib path
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-08-01 19:10:25 +02:00
Julien Danjou 06fac9a151 lua: stop using version_string()
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-07-31 17:48:27 +02:00
Julien Danjou 4016877ad4 screen: move screen.focus to awful
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-07-31 17:30:03 +02:00
Julien Danjou 18fab522f9 lua: expand package.path more
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-07-30 18:20:19 +02:00
Julien Danjou 330f4304c0 lua: stop computing len twice
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-07-30 17:53:43 +02:00
Julien Danjou f16cedc650 lua: add workspace_get()
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-07-29 18:24:35 +02:00
Matthew William Cox 84796930b7 Fix default search path for configurations
Modified lookup of system configuration to accomodate the new XDG
locations.

Add an XDG_CONFIG_DIR variable to cmake to help find/set the system-wide
configuration location.

Signed-off-by: Julien Danjou <julien@danjou.info>
2008-07-24 20:10:13 +02:00
Julien Danjou 8502eb3299 lua: fix color string push
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-07-24 17:56:42 +02:00
Michael Gehring 0400df279d lua: lua_open is deprecated in 5.1. use luaL_newstate 2008-07-23 09:42:04 +02:00
Kanru Chen 700ace5197 length of static string s should be sizeof(s)-1
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-07-22 10:30:53 +02:00
Kristof Provost 30aeb3f311 Reload awesome on SIGHUP
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-07-22 10:23:07 +02:00
Julien Danjou 36fd44d1a0 draw: add char len as arg of xcolor_init()
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-07-10 15:30:16 +02:00
Julien Danjou 41d66ebf29 lua: optimize docmd, don't check len and use const
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-07-10 15:11:23 +02:00
Julien Danjou 3f46ec2152 tasklist: use a callback for label
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-07-09 12:12:52 +02:00
Julien Danjou 5072484f93 hooks: init correctly to REFNIL and factorize set
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-07-09 11:51:08 +02:00
Julien Danjou 58eac8af1c config: fix load paths
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-07-09 08:15:17 +02:00
Julien Danjou 845685ed18 lua: fix bug when $XDG_CONFIG_HOME is set
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-07-08 19:27:16 +02:00
Julien Danjou fb13bff697 config: use XDG for loading config
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-07-08 14:07:56 +02:00
Pierre Habouzit 46ea7c45aa Get rid of the color name, and generate a #RGBA value on the fly if needed.
Signed-off-by: Pierre Habouzit <madcoder@debian.org>
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-07-02 11:09:10 +02:00
Pierre Habouzit 924078c898 Streamline xcolor_t.
Do not have a ->name char * field, but a char[32] instead.  This isn't a
big problem, the longest color in /etc/X11/rgb.txt is 23 chars long, and
if it becomes a problem one day, one could just strip the name and
generate an hexadecimal representation on the fly instead. But allocating
the name is asking for a lot of trouble.

Since we do not allocate anything anymore, just don't allocate anything
anymore at all, it avoids the mess of xcolor_copy/_wipe and fixes a lot of
sleeping bugs (p_dup were used e.g., which is wrong).

Pass xcolor_t *, xcolor_t becomes too big to be passed by value. Add
consts at some places.

xcolor_new allocates nothing, hence is renamed xcolor_init, has xcolor_t
as a first argument (OO-style, this is self), and doesn't touch the
structure at all if it returns false, which allow us to skip a lot of
intermediates values.

Signed-off-by: Pierre Habouzit <madcoder@debian.org>
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-07-02 10:36:46 +02:00
Julien Danjou 1437f68ae1 lua: move padding to screen
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-07-01 22:37:35 +02:00
Julien Danjou 9b74cdbc0a draw: iso2utf now gets len as arg
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-07-01 14:44:19 +02:00
Julien Danjou 35e948f53b draw: xcolor_t store color name
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-06-28 13:30:17 +02:00
Pierre Habouzit 577cec41b1 Allow modules to have their own __index for magic purposes.
Also fix stack leaks.

Signed-off-by: Julien Danjou <julien@danjou.info>
2008-06-28 07:56:38 +02:00
Julien Danjou 013b2afe62 remove useless #include
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-06-26 18:10:45 +02:00
Julien Danjou db88877587 lua: split getopt_string/getopt_lstring; fix mouse corner
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-06-25 17:33:05 +02:00
Julien Danjou 6ec76c3b97 client: honor size hints is now by client
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-06-25 15:42:07 +02:00
Pierre Habouzit 0f23ce88cb Divert lua string.len to a multibyte aware implementation.
Signed-off-by: Pierre Habouzit <madcoder@debian.org>
2008-06-25 11:42:06 +02:00
Julien Danjou 38c48cf374 lua: remap on restart
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-06-24 17:39:06 +02:00
Pierre Habouzit 14f4e02e66 Replace tag_t lists with arrays.
This improves lots of code efficiency (we *know* how many tags we have
now, YA'RLY).

Also fix a \todo in client.c: since knowing the number of tags is cheap,
ignore props that don't match it.

Use many p_alloca for things that depends on the number of tags (no sane
user will have *thousands* of tags. This saves a few more mallocs.

Signed-off-by: Pierre Habouzit <madcoder@debian.org>
2008-06-23 17:37:19 +02:00