Commit Graph

539 Commits

Author SHA1 Message Date
Julien Danjou ff8603110a [util] Add name_func_rlookup()
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-23 16:53:37 +02:00
Julien Danjou a04417494b [mouse] Rename Button to button_t
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-23 15:12:01 +02:00
Julien Danjou b3f8464800 [draw] Make sure that font is not NULL before freeing
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-21 17:02:22 +02:00
Julien Danjou 680944d583 [build] Use autoheader & config.h
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-20 19:55:37 +02:00
Julien Danjou 1f046b3c9f [everything] Switch from libconfuse to Lua
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-20 18:01:15 +02:00
Julien Danjou 61d552a860 [draw] Inline draw_context_delete() and check that it's != NULL
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-14 15:22:31 +02:00
Julien Danjou e5ed2f2f1c [swindow] Permit to delete NULL swindow
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-13 18:56:33 +02:00
Julien Danjou e80e6a73c5 [draw] Remove useless default_screen
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-13 17:42:05 +02:00
Julien Danjou f824e383c9 [markup] Check that str is not NULL
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-11 16:23:05 +02:00
Arnaud Fontaine 162b8a690c [all] Implement an atom cache in xutil as an ordered linked-list 2008-05-11 01:10:37 +02:00
Julien Danjou 6a06e44461 [markup] Check for error before warning
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-10 10:37:12 +02:00
Julien Danjou c3e063d55e [config] Use a string array as args for uicb
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-04 12:47:16 +02:00
Julien Danjou f42f75468c [swindow] Add border manipulation function
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 15:17:46 +02:00
Julien Danjou 0e1747587c [swindow] Store border width
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:35 +02:00
Julien Danjou c57435c96d [util] Add a_strtobool() function
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:35 +02:00
Julien Danjou 03170abfe1 [config] Use golden ratio by default for mwfact
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:35 +02:00
Julien Danjou effaa99b91 [awesome] Remove useless includes
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:35 +02:00
Julien Danjou dc27cff8ab [awesome] Remove checking for value before p_delete()'ing memory
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:35 +02:00
Julien Danjou 5638661157 [markup] Fix memory leak
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:06 +02:00
Julien Danjou b142264787 [draw] Make draw_text using a const pointer to a style
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:06 +02:00
Julien Danjou de3fbffcf1 [xutil] Rewrite gettextprop() proto
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:06 +02:00
Julien Danjou ca4821fc9e [markup] Fix memory leak in text handling
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:06 +02:00
Julien Danjou f1ccb31bca [markup] Fix bad allocation size
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:06 +02:00
Julien Danjou 44890c7c33 [draw] Fix memory leak on bad markup parsing
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:06 +02:00
Julien Danjou e2bf0042fc [xutil] Convert len to signed size
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:05 +02:00
Julien Danjou 7a4237f34f [markup] Print the unparseable text on error
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:05 +02:00
Julien Danjou 547d72270b [markup] Re-escape text on re-insertion 2008-05-03 12:01:05 +02:00
Julien Danjou 7b8e7bc486 [markup] Simplify
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:05 +02:00
Julien Danjou 39364393f4 [markup] Escape text on reconstruct
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:05 +02:00
Julien Danjou 5397e10a0f [config] Do not set background by default
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:05 +02:00
Julien Danjou 8af24939bd [draw] Rework shadow
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:05 +02:00
Julien Danjou 04ea13c205 [screen] Rename ScreensInfo to screen_info_t
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:05 +02:00
Julien Danjou 33837d77a1 [draw] Rename DrawCtx to draw_context_t
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:05 +02:00
Julien Danjou f12f1798dd [draw] Add margin code inside markup string
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:05 +02:00
Julien Danjou 1fc2b7997a [taglist] Stop using styles, use markup string
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:05 +02:00
Julien Danjou 5c51759cca [draw] Make text_align part of markup format
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:05 +02:00
Julien Danjou eab7633675 [tasklist] Remove styles; use drawtext format
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:04 +02:00
Julien Danjou 26621fd598 [emptybox] Remove
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:04 +02:00
Julien Danjou 7a8e39b3e7 [markup] Add generic substitution of elements and use it for titlebar
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:04 +02:00
Julien Danjou a4159bbaf7 [draw] Implement a more generic markup parser
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:04 +02:00
Julien Danjou 1e7e4663a5 [draw] Simplify <markup> adding
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:04 +02:00
Julien Danjou 0552376dba [draw] Rebuild the pango markups while parsing ours
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:04 +02:00
Julien Danjou 4d3d97fd4f [xutil] Use a_strndup()
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:04 +02:00
Julien Danjou 5447001254 [draw] Handle error on end of feeding into XML parser
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:04 +02:00
Julien Danjou a3b1b3be0b [draw] Use g_markup API to parse bg elements
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:04 +02:00
Julien Danjou dd9cb9810b [draw] Draw style background in draw text if no bg in markup
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:04 +02:00
Julien Danjou 3965c1e1f0 [textbox] Clean things which became useless with markup
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:04 +02:00
Julien Danjou d3190fcf63 [draw] Tell pango about padding
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:04 +02:00
Julien Danjou 1185d8b156 [draw] Add support for bg in draw_text and use ellipsize from pango
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:04 +02:00
Julien Danjou ce8d1ff89e [titlebar] Add string to format
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:04 +02:00
Julien Danjou f5997892d2 [xutil] Use memcpy() instead of strncpy() for safety
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:04 +02:00
Julien Danjou 0642e415dd [util] Fix warning for position returning
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:03 +02:00
Julien Danjou 834f1f2424 [common] Add support for pango markup (FS#171)
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:03 +02:00
Julien Danjou ae1cea061c [util] Add position_to_str()
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:03 +02:00
Julien Danjou c3642713b9 [draw] Do not declare vars in blocs 2008-05-03 12:01:03 +02:00
Arnaud Fontaine 059829e37e [xutil] check whether the error code and request are actually defined 2008-05-03 12:01:03 +02:00
Julien Danjou e272000cc6 [util] Change Fuzzy type to fuzzy_t
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:03 +02:00
Julien Danjou bd18eb2018 [util] Change Position type to position_t
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:03 +02:00
Julien Danjou df7db5e86b [util] Change Alignment type to alignment_t
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:03 +02:00
Arnaud Fontaine 21141c0508 [xutil] Fix missing applied mask when getting request code in xutil_get_error().
Thanks to Matthieu Pasini.
2008-05-03 12:01:03 +02:00
Julien Danjou dba40b0ca4 [xutil] Make the request earlier
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:02 +02:00
Julien Danjou 521f7d58be [xutil] Do not use strncmp here
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:02 +02:00
Julien Danjou 97dc830db5 [util/rules] Move Fuzzy from rules to util
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:02 +02:00
Julien Danjou 70d26b5b36 [swindow] Free GC, make refresh inline
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:02 +02:00
Julien Danjou 32fc1a0a78 [draw] Build with GTK by default instead of Imlib2
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:02 +02:00
Julien Danjou e246410126 [swindow] Rename SimpleWindow to simple_window_t
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:02 +02:00
Julien Danjou a04395ddc9 [swindow] Store gc
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:02 +02:00
Julien Danjou 33709c62cd [xutil] Remove map_raised
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:01 +02:00
Julien Danjou 82f305b1b1 [xutil] Rework some stuff and rename xgettextprop()
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:01 +02:00
Julien Danjou 328a04fb17 [draw/config] Cosmetics
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:01 +02:00
Julien Danjou a664203639 [xutil/awesome] Cosmetic
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-05-03 12:01:01 +02:00
Arnaud Fontaine a541477e94 Cosmetic 2008-05-03 12:01:01 +02:00
Arnaud Fontaine d2d85941ad [common/xutil.c] Free ClassHint reply 2008-05-03 12:01:01 +02:00
Arnaud Fontaine d99586f68b [common/xutil.c] Rewrite xgettextprop properly for UTF8_STRING 2008-05-03 12:01:01 +02:00
Arnaud Fontaine 70dafae396 Move xcb_event_handler code to xutil 2008-05-03 12:01:00 +02:00
Arnaud Fontaine 71e9100927 Remove useless xutil_root_window() 2008-05-03 12:01:00 +02:00
Arnaud Fontaine da5236d57a Cosmetic 2008-05-03 12:01:00 +02:00
Arnaud Fontaine 02c99fccb8 Prefix xutil functions properly 2008-05-03 12:01:00 +02:00
Arnaud Fontaine 1eab0e44e7 * Make key symbols table, NumLock, ShiftLock and CapsLock global variables.
* Get CapsLock and ShiftLock masks properly and fix XLookupString() XCB equivalent.
2008-05-03 12:01:00 +02:00
Julien Danjou 3b295beaed Fix Xinerama detection 2008-05-03 12:01:00 +02:00
Arnaud Fontaine 64edc7c767 Allow to specify hexadecimal colors in configuration 2008-05-03 12:01:00 +02:00
Arnaud Fontaine 4a1720ddca Remove useless x_select_input() which leaded to useless requests 2008-05-03 12:01:00 +02:00
Arnaud Fontaine abcb60b9ea Fix x_get_transient_for_hint() based on XGetTransientForHint() 2008-05-03 12:01:00 +02:00
Arnaud Fontaine df3e102832 Rewrite code which query xinerama screens to fix a double free 2008-05-03 12:00:59 +02:00
Arnaud Fontaine 4bd034f768 Use unchecked instead of checked call because the error has to be in the error queue 2008-05-03 12:00:59 +02:00
Arnaud Fontaine 98091b2f1e Copy properly a window text property 2008-05-03 12:00:59 +02:00
Arnaud Fontaine dafafd077c Port Awesome to XCB 2008-05-03 12:00:59 +02:00
Julien Danjou e3496f7a25 [config] Enhance rules documentation a bit
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-04-30 11:11:32 +02:00
Julien Danjou 84df60e11b [draw] Check len while checking for UTF-8 chars
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-04-28 07:35:03 +02:00
Nikos Ntarmos ef60378754 [common] remove and getline and strndup usage
There is no getline() on FreeBSD, nor any strndup().

Signed-off-by: Julien Danjou <julien@danjou.info>
2008-04-19 23:08:18 +02:00
marco candrian 1b65a8acfd [draw] line-width increasing from 1.0 to 1.25 for line-style
1.25 figured out by testing...

Signed-off-by: Julien Danjou <julien@danjou.info>
2008-04-19 11:20:06 +02:00
marco candrian 37f05a8277 [draw] precise line drawing using antialiasing
Antialiasing also has the advantage, that the path get's drawn now precisely -
there have been some issues without ... depending on the line-angle, some
pixels weren't filled on some y coordinates etc.

Signed-off-by: Julien Danjou <julien@danjou.info>
2008-04-19 11:19:59 +02:00
marco candrian 2eb6fda36e [graph] simplify 'line' drawing; draw the border after the graph-drawing
Drawing the border after the graph-drawing, allows to draw down to the border itself
when 0 values occur.

Signed-off-by: Julien Danjou <julien@danjou.info>
2008-04-18 09:12:02 +02:00
marco candrian 84e8949860 [draw] draw_rectangle draws stuff inside the coordinates
E.g. to get single line (or rectangle with width = 1 etc), the path should go
through the center of the pixels (.5), when that path gets stroked finally, it
filles the pixels fully.

Signed-off-by: Julien Danjou <julien@danjou.info>
2008-04-17 19:10:24 +02:00
marco candrian 47495c50e3 [draw] provide the middle of a pixel to make sure it draws/fills that particular pixel/line
Fixes FS#162 now also on my PC in any way (it filled the pixels on the right
when a gradient was given, else the one on the left of x.

Signed-off-by: Julien Danjou <julien@danjou.info>
2008-04-17 09:46:23 +02:00
marco candrian bc7d9211ba [widgets/graph] offset fixed now.
In fact on my pc, when there is no fg_end or fg_center defined,
it draws it one pixel too much on the right.

On Gigamo's PC, that patch should work on any case.

It also 'should' work from what I guess!

For people having a problem, they could define fg_end to the same as fg.

Or when it's really serious (on not just here), that could be done inside
awesome.

(Finally somekind of little cairo bug, from my perspektive)
2008-04-14 04:21:52 +02:00
marco candrian 8277693ab4 [common/draw] no slightly diagonal gradient anymore (again)
that 'fix' didn't work out anyway properly.
Following patches should do a better job.
2008-04-14 04:18:40 +02:00
marco candrian fe07cd4f30 [draw] miter set to 10 is enough
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-04-13 14:18:29 +02:00
marco candrian 62ac090368 [common/draw] curious (cairo?) bug, sometimes draws the line 1 pixel to much on the right
happens only when creating a gradient, and not always, and
adding + 1 (creating a slightly diagonal gradient), seems to help a little bit).
2008-04-12 06:56:14 +00:00
marco candrian 727a42eb41 [common/draw] force the draw of the left bottom corner on rectangles
setting the miter limit to 100 works here. How to do it really properly, I won't know actually.

http://cairographics.org/manual/cairo-cairo-t.html#cairo-set-miter-limit
2008-04-12 05:41:46 +00:00
Fabienne Ducroquet b12a5235a5 [doc] Fix some typos, modify a few descriptions
Before awesome 2.3 release, I've decided to look for typos in the
awesome* manpages, here is the result. I've also modified some options'
descriptions that I didn't find very clear, I hope I have not
added/missed too many mistakes as I'm not a native English speaker...

Signed-off-by: Julien Danjou <julien@danjou.info>
2008-04-11 07:34:45 +02:00
Julien Danjou 038e52c699 [draw] Allow more space for characters conversion
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-04-04 11:07:57 +02:00
Alex Cornejo cee3e9b60d [draw] Add option to link against GTK instead of Imlib2
I added an option to the configure script to link against gdk instead
of imlib2. Most people already have gdk installed so that way they can
use awesome without installing imlib2, and gdk's pixbuf was explicitly
designed to replace imlib2.

Also, a nice side effect is that GDK works directly with cairo
surfaces, so the process of loading images should be faster, although
since awesome does very little image loading it probably wont have a
noticable impact on performance, but it certainly won't hurt.

Signed-off-by: Julien Danjou <julien@danjou.info>
2008-04-03 09:16:58 +02:00
Julien Danjou ae096824d6 [draw] Better check for cairo version
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-04-02 17:14:09 +02:00
marco candrian 6d0040603f [config] minus values would be useful for the progressbar's gap option.
in order to get a single border for e.g. two bars. Looks more unified then.
2008-04-02 15:51:32 +02:00
Julien Danjou a79cb3f927 [config] Add a bunch of new checks in configuration file
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-04-02 09:17:25 +02:00
Martin Stubenschrott 8b7c8e3822 [draw] Better computation for vertical text centering
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-04-01 17:59:23 +02:00
Julien Danjou c4eaec5b82 [emptybox] Add alignment option
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-04-01 08:20:59 +02:00
Julien Danjou 2fd0b3c008 [widgets] New emptybox widget
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-31 10:15:38 +02:00
Julien Danjou c4cc8c5e04 [widgets] Remove paddings
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-31 10:04:03 +02:00
Julien Danjou fb36ccee49 [styles] Set shadow_offset to 0 by default
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-28 13:40:59 +01:00
Julien Danjou 18117e8495 [styles] Use 0xffffffff as auto value for shadow (FS#117)
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-28 12:13:16 +01:00
marco candrian 9db8635523 [config] add missing documentation 2008-03-28 09:53:50 +01:00
Julien Danjou 3692e5f251 [config] Add documentation for a bunch of options
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-27 18:31:55 +01:00
Julien Danjou 25b22a7cb9 [doc] Add autogeneration of options documentation
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-27 16:48:52 +01:00
marco candrian 89f4e22255 [widgets] new progressbar options
if a ticks_count is defined (!= 0), round the value to them ('ticks')
and draw finally some gaps.

Also an important issue: since the bar needs to be 'homogenous', they may won't
match a given height. Some value tweaking will be necessary then.

An alternative would be a not homogenous bar, what is worse I think.

The values, when there are 'ticks', get rounded up somebit. So they get turned on,
when half of them is reached - or so.

new options (see awesomerc.5.txt for a more detailed description):

border_width
border_padding
fg_off

ticks_count
ticks_gap

Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-26 10:02:37 +01:00
Julien Danjou f00b0b850e draw_textwidth() can use a const char *
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-25 15:55:45 +01:00
Julien Danjou da119cda7d Add alignment attribute to titlebar
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-24 17:42:45 +01:00
Julien Danjou c39d8c2a7e Add width and height option to titlebars
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-24 16:31:02 +01:00
Julien Danjou 60e36aee54 Add a workaround for cairo < 1.5
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-24 10:48:15 +01:00
Julien Danjou 8b411eb15d Use pre-multiplied alpha for cairo rendering
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-24 10:26:35 +01:00
Julien Danjou afa8591d50 Change opacity between 0 and 1 and update validation
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-24 07:47:07 +01:00
Julien Danjou ec96d4d1f8 Add and update doc for opacity_[un]focused, and switch to float
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-23 20:38:16 +01:00
Steffen Schulz 3b8cf66822 new directive opacity_focused=<int>
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-23 20:36:55 +01:00
marco candrian b92a292e43 additional line width argument to draw_rectangle[_gradient] in draw.c
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-23 15:52:22 +01:00
Julien Danjou de5d82b8c2 Use Imlib2 to load images
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-23 15:52:22 +01:00
Julien Danjou 1d468c5583 Lot of cosmetic changes: proto change, etc.
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-23 15:52:22 +01:00
Julien Danjou 8d0e5b29a6 Cosmetic formating changes
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-23 15:52:22 +01:00
Julien Danjou 2aebe166c7 Add support for styles in titlebar
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-23 15:52:22 +01:00
Julien Danjou 2473de53b7 Removed unused options for titlebar
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-23 15:52:22 +01:00
Julien Danjou 4a7e52cc27 Change draw_rotate() proto to directly render on the right Pixmap 2008-03-23 15:52:22 +01:00
Julien Danjou 098b5d40a5 Cosmetic 2008-03-23 15:52:22 +01:00
Julien Danjou a3f9eb7af9 Revert "Add preliminary support for XPM format"
This reverts commit 5f8b538a5e4eeea159b26c3d0b943cac745ffdce.
2008-03-23 15:52:22 +01:00
Julien Danjou df2555d9fe Add preliminary support for XPM format
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-23 15:52:22 +01:00
Julien Danjou 58402c9641 Add a_strcasecmp() function
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-23 15:52:22 +01:00
Julien Danjou c496df9fc6 Add support for mouse bindings on titlebars 2008-03-23 15:52:22 +01:00
Julien Danjou 393b6e1f88 Cosmetics
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-23 15:52:22 +01:00
Julien Danjou accf223bb1 Use warn() instead of perror()
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-23 15:52:21 +01:00
Julien Danjou 93c75433f9 Make icon in statusbar as CFG_ALIGNMENT 2008-03-23 15:52:21 +01:00
Julien Danjou 2a47aa7f0b Add cfg_getalignment() functions
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-23 15:52:21 +01:00
Julien Danjou 7b1ce042de Add cfg_getposition() and cie to ease libconfuse compatibility
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-23 15:52:21 +01:00
Julien Danjou 19656fc36d Add a CFG_ALIGNMENT type and use it
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-23 15:52:21 +01:00
Julien Danjou fe8bd0bb5b Implement a CFG_POSITION type and use it 2008-03-23 15:52:21 +01:00
Julien Danjou f01a2ad47d Check for alignment values in configuration file 2008-03-23 15:52:21 +01:00
Julien Danjou 532709ec3e Add validate functions for positions 2008-03-23 15:52:21 +01:00
Julien Danjou b748d114bf Use common validation infra for mwfact upper and lower limits values
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-23 15:52:21 +01:00
Julien Danjou d4f08ae5ae Force validation of some more values 2008-03-23 15:52:21 +01:00
Julien Danjou 9204066788 Begin to use validate function in config handling 2008-03-23 15:52:21 +01:00
marco candrian 214a5c4bfa new graph-widget option: grow = <{right, left}>
Signed-off-by: Marco Candrian <mac@calmar.ws>
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-23 15:52:21 +01:00
Julien Danjou 44824e9ac7 Draw buf, not text
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-23 15:52:21 +01:00
Arnaud Fontaine f75f16c325 Don't get ascent/descent informations about a font because it's not
useful at the moment (commented out).
2008-03-23 15:52:21 +01:00
Arnaud Fontaine 542a944361 Use Pango for fonts instead of Xft (which hasn't been ported yet to
XCB) to measure text.
2008-03-23 15:52:21 +01:00
marco candrian 29673467f9 change graph's style to draw_style
to prevent confusion with the other style {} sections,
and it might also better describes what is it used for..
2008-03-23 15:52:20 +01:00
marco candrian 0795334dd8 Font removed where style should be used now
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-23 15:52:19 +01:00
Julien Danjou bc6656320d Add support for text_align option in titlebars 2008-03-23 15:52:19 +01:00
Julien Danjou f9f75629e1 Rule for titlebar applies event if we restart; set default to auto, which means off 2008-03-23 15:52:19 +01:00
Julien Danjou cc56ccd2e9 Use section for titlebar parameters 2008-03-23 15:52:19 +01:00
Julien Danjou 8b217359e9 Rename Auto to Maybe in Fuzzy; add Auto as Position; add support for titlebar as rule 2008-03-23 15:52:19 +01:00
Julien Danjou 54c2170178 Add Auto value to Position 2008-03-23 15:52:19 +01:00
Julien Danjou 4cab3c2d05 Select for input in simplewindow 2008-03-23 15:52:19 +01:00
Julien Danjou ea88e324a0 First titlebar support 2008-03-23 15:52:18 +01:00
Julien Danjou aa5138bc1d Store phys_screen in SimpleWindow, and resize drawable on window resize 2008-03-23 15:52:18 +01:00
Julien Danjou d144c53395 Add simplewindow_move_resize() function 2008-03-23 15:52:18 +01:00
Julien Danjou 61f9ae172f Add simplewindow_resize() function 2008-03-23 15:52:18 +01:00
Julien Danjou c6eec955c8 Rename Area to area_t 2008-03-23 15:52:18 +01:00
Julien Danjou fa47024714 Change colors infrastructure to style: rename colors_ctx_t to style_t and add font in it 2008-03-23 15:52:18 +01:00
Julien Danjou 9dfd488dda Change colors handling 2008-03-23 15:52:18 +01:00
marco candrian 2e935ae1f6 vertical_gradient option for the graph widget
if true, the color values (fg, fg_center, fg_end) create a color gradient
from 0 to full value, instead of new values to old values.

each data{} can have it's own setting
2008-03-23 15:52:17 +01:00
Julien Danjou 6b4c9fed83 Remove useless ; after DO_SLIST macro 2008-03-23 15:52:17 +01:00
Julien Danjou 0a980095b3 Rework colors stuff, add a common colors_ctx_t containing colors and shadow options 2008-03-23 15:52:17 +01:00
Julien Danjou e8e02d5a5d Initialize a.prev to NULL 2008-03-23 15:52:17 +01:00
Julien Danjou 355b7d67b3 Change screen_get_bycoord() proto to take ScreensInfo as arg, and speed up things 2008-03-23 15:52:17 +01:00
Julien Danjou 0bde5c9e29 Move some screen functions from screen.c to new common/xscreen.c 2008-03-23 15:52:17 +01:00
Julien Danjou f3652aaca6 Add a pointer to SLIST struct to store previous element
This will make back cycling faster
2008-03-23 15:52:17 +01:00
Julien Danjou 8c901c8b1e Be more verbose about errors and warnings location
Print function name and line,
and also print a W: or E: in front of the warn/errors
2008-03-23 15:52:17 +01:00
Julien Danjou 1fb61f54df [awesome-menu] Remove command line option and add support for menu {} in conffile 2008-03-23 15:52:16 +01:00
marco candrian 04ff373a63 New progressbar option: vertical=<boolean>
if 'true', draws the whole progressbar-block vertically
instead of horizontally.
2008-03-23 15:52:16 +01:00
marco candrian 6216d25bc6 new progressbar option for reversing the drawing
inside a data section, with reverse=<boolean> it's possible to reverse the
drawing i.e instead of left to right, from right to left. etc.
2008-03-23 15:52:16 +01:00
marco candrian ce7f77c8c5 data{} sections needs a unique title now
so like: data title {}

Used for widget_tell to individually address/change them
2008-03-23 15:52:16 +01:00
Julien Danjou 8a685bf177 Add mwfact_lower_limit and mwfact_upper_limit to configure limits of mwfact value
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-03-23 15:52:16 +01:00
Julien Danjou 4451e9099e Add support for text shadow, add new text_shadow_offset option. 2008-03-23 15:52:15 +01:00
Julien Danjou e81bd8de02 Add a #prefix_list_next() function to lists functions
That may seem useless, but it's not.
2008-03-23 15:52:15 +01:00
Julien Danjou 867b2f0775 first version of awesome-menu 2008-03-23 15:52:15 +01:00
Julien Danjou 2b0de43885 Remove useless tab_border option. 2008-03-13 13:25:15 +01:00
Julien Danjou a9d7a08c2e Add support for ~ in include() from awesome 2008-03-09 20:01:32 +01:00
Julien Danjou 2fd1f0db66 Write our own cfg_awesome_include() function to do check before calling confuse's one 2008-03-09 18:31:16 +01:00
Julien Danjou 8b8fc8148f add comments for simplewindow functions 2008-03-01 11:25:04 +01:00
Julien Danjou 950c9b0820 support for include() in configuration file 2008-02-29 09:54:03 +01:00
Julien Danjou 46b80552c6 add support for flex -> AlignFlex 2008-02-28 16:19:26 +01:00
Julien Danjou 46742a56e4 documentation update and some cosmetic 2008-02-27 09:32:45 +01:00
Julien Danjou 11b0982a58 rename awclient.[ch] to socket.[ch] 2008-02-27 09:07:52 +01:00
Julien Danjou 6fd3801ef0 rename awesome-version.[ch] to version.[ch] 2008-02-27 09:04:17 +01:00
Julien Danjou c1f06b3d3f documentation update 2008-02-27 09:00:42 +01:00
Julien Danjou 328e5d0d4e rename screen to phys_screen to avoid confusion 2008-02-25 13:33:29 +01:00
marco candrian 73696a26a9 cairo_destroy() added
(at least partly related to: FS#68 - awesome eats cpu time)

Signed-off-by: Julien Danjou <julien@danjou.info>
2008-02-25 10:01:42 +01:00
Julien Danjou 1e3f3d9300 floating placement can be chosen by config 2008-02-13 18:04:20 +01:00
marco candrian 4ff0dae17e trailing whitespaces removed
like:
find . -iname "*.txt" -o -iname "*.c" -o -iname "*.h" | xargs sed -i 's/\s\+$//'

Signed-off-by: Julien Danjou <julien@danjou.info>
2008-02-13 09:05:10 +01:00
Julien Danjou ae75f55acd change draw_color_new() proto to fill the struct and return status 2008-02-13 08:58:21 +01:00
Julien Danjou 9390abcfb4 fix memory leak in smart_placement (with area_list_remove) and fix the algo 2008-02-11 17:15:28 +01:00
Julien Danjou e244210943 return the right buffer, iconv modify one 2008-02-11 10:52:05 +01:00
Julien Danjou 1a643a20bd simplify buf handling 2008-02-11 10:40:38 +01:00
Julien Danjou 321a481dce return good pointer and free good pointer 2008-02-11 09:21:09 +01:00
Julien Danjou fbce780003 check iso2utf8 return 2008-02-11 08:49:10 +01:00
Julien Danjou 44a0a1ee4e make draw_text multibyte UTF-8 aware 2008-02-09 16:23:16 +01:00
Julien Danjou 0bfa880b0f add align option to widget to specify their alignment 2008-02-08 10:59:55 +01:00
Julien Danjou 91f80b251c rename align to text_align 2008-02-08 09:58:36 +01:00
Julien Danjou 170ed9882a rename netwmicon to focusicon 2008-02-06 20:13:41 +01:00
Julien Danjou ffbcea0084 remove focustitle widget 2008-02-06 20:05:14 +01:00
Julien Danjou 528ff7316c tasklist can now show focused only client 2008-02-06 20:03:18 +01:00
marco candrian 8567009d22 rename of fg_middle/fg_half to fg_center and fg_full to fg_end
A hint from maxauthority. The names would be unified now in the progressbar
and the graph widget. And (hopefully) it's easier to guess what they mean now.

Signed-off-by: Julien Danjou <julien@danjou.info>
2008-02-06 07:32:22 +01:00
Julien Danjou befcf19ea2 introduce fuzzy logic: fix problem with not_master 2008-02-05 17:31:47 +01:00
marco candrian ff753f1f14 Adds fg_middle + fg_end color option for the graph widget
Draws a color-gradient beginning from fg and
if either fg_middle or fg_end is set, through them.

example config:

    graph gr_cpu
    {
      data { scale = false max = 100  style = bottom
             fg = "#cc6666" fg_half = "#cc6666" fg_full = "#998888"}
      ...
      ...
    }

Signed-off-by: Julien Danjou <julien@danjou.info>
2008-02-05 15:37:21 +01:00
marco candrian 09e60cb95e adds fg_half as an option to the progressbar
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-02-05 07:16:12 +01:00
Julien Danjou 06904cfcaa Revert "remove opacity_unfocused" 2008-02-04 14:54:50 +01:00
Julien Danjou 1b4a1e7c9e convert text to draw to UTF-8 2008-02-04 13:28:20 +01:00
marco candrian b024b0c0cf draw_rectangle_gradient() for the progressbar widget; + fg_full option
Adds an optional additional foreground color option to a bar: fg_full = <color>

A value of 0 represents the fg-color, and a value of 100 (a full graph) the
fg_full-color.

Example:

progressbar xy
{
  bar { fg = "#111155" fg_full = "#3333cc"  bg = "#000000" bordercolor = "#4444cc"}
  ....
}

Signed-off-by: Julien Danjou <julien@danjou.info>
2008-02-04 11:16:30 +01:00
Matthieu Pasini 49cda1814e modkey should not be required when not needed in key definition
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-02-02 09:33:14 +01:00
marco candrian 8d3c24e03e fix for cairo_arc
Without a new (sub)path, it joined the new circle to the old reference point,
what happend to be at the end of the title-text - therefore the line to it with
cairo_stroke()

Signed-off-by: Julien Danjou <julien@danjou.info>
2008-02-01 09:21:24 +01:00
marco candrian be0779d0fa graph widget adopted to the latest statusbar changes
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-01-31 20:43:42 +01:00
Julien Danjou a28876b5ce reuse cairo context stuff 2008-01-31 18:18:15 +01:00
Julien Danjou 4b412d86ff split out config stuff 2008-01-31 16:34:00 +01:00
Julien Danjou c78f77543f rename opts to awesome_opts 2008-01-31 11:45:10 +01:00
Julien Danjou 10f9106e4e add new awesome-check program to check configuration file syntax 2008-01-30 14:07:14 +01:00
Julien Danjou c02760531c change define 2008-01-30 09:36:52 +01:00
Julien Danjou ab8d95f13d rework include 2008-01-29 11:27:14 +01:00
Julien Danjou 31b5b709f6 remove unused function 2008-01-29 08:56:23 +01:00
Julien Danjou ea57fd8fc9 add support for smart windows placement in floating layout 2008-01-28 18:30:23 +01:00
Julien Danjou d48ad7e10a add area_match_coords() and area_match_area() 2008-01-28 11:56:42 +01:00
Julien Danjou 30eba52596 rename draw_get_context() to draw_context_new() 2008-01-27 19:02:08 +01:00
Julien Danjou b6642e45c8 rename initxcolor to draw_color_new() and move it to draw.c 2008-01-27 18:56:37 +01:00
Julien Danjou 416b9cfdb4 simplify header inclusion 2008-01-26 18:12:56 +01:00
Julien Danjou 780a9d087a clean some stuff 2008-01-26 18:00:47 +01:00
Julien Danjou c5f57d24d3 split out simple window handling 2008-01-26 17:58:01 +01:00
marco candrian 836942eb4c Fix for the problem that cairo draws over the given path on very sharp angles
Signed-off-by: Julien Danjou <julien@danjou.info>
2008-01-26 17:38:20 +01:00
marco candrian c73e0bd72e Additional graph widget options
There are the new styles:

bottom (fill the graph to the bottom of widget-square)
top (fill the graph to the top of the widget-square
line (just print a line representing the values)

E.g when there are multiple 'bottom'-style graphs, it will print the larger
part on top of the smaller.  When two values are the same, it will (actually)
just print it with one color (something to improve maybe).

bottom-style overdraws top-style, and line-style overdraws top and bottom style
(= gets drawn at the end)

An example configuration:

    graph gr_cpu
    {
      data { scale = false max = 100 fg = "#669966" style = bottom} # total
      data { scale = false max = 100 fg = "#cc9966" style = bottom} # user
      data { scale = false max = 100 fg = "#ffffff" style = bottom} # nice-processes
      width = 50
      height = "0.80"
      bg = "#000000"
      bordercolor = "#669966"
    }

With the 'line' style, there is a bug (draws sometimes over the rectangle).
I checked the values and didn't find any value what actually should do that.
So I have no idea why that is... needs a recheck, because it's not really nice..
Happens especially when scale=true and after a rescaling takes place.

Signed-off-by: Julien Danjou <julien@danjou.info>
2008-01-25 22:53:20 +01:00
Hans Ulrich Niedermann b457c4b4c9 Common version message for awesome and -client
At every build ("make", "make all"), if necessary, this
version message will be updated.

Note that "make awesome{,-client}" will NOT update the
version message.

Signed-off-by: Julien Danjou <julien@danjou.info>
2008-01-25 12:10:33 +01:00
Julien Danjou 2ac27fdac4 move draw files to common/ 2008-01-24 18:48:11 +01:00
Julien Danjou 197fabfa95 move awesome-client-common to common/ 2008-01-21 18:17:08 +01:00
Julien Danjou 668702b777 move list.h and util.[ch] to common/ 2008-01-21 18:14:59 +01:00