Nikolas Garofil
b206ecc93d
new should be combined with delete instead of free (to stop valgrind from complaining)
2010-02-11 14:44:15 +01:00
Pavel Labath
4a68be2494
include <config.h>
...
not that we need it much, but...
2010-02-11 01:43:48 +01:00
Nikolas Garofil
463836ebf9
Combine print_execp and print_exec as much as possible
2010-02-11 01:08:25 +01:00
Nikolas Garofil
f0ed783041
dog^H^H^Hcat should become cat in all exec-related vars
2010-02-10 23:31:35 +01:00
Nikolas Garofil
aea8d3ed52
Combine print_texeci and print_execi as much as possible
2010-02-10 21:23:21 +01:00
Pavel Labath
dfb106ac0e
Fix multiple definition error
2010-02-10 21:17:40 +01:00
Pavel Labath
90b30f14f9
Oops, forgot inclusion guards
2010-02-10 19:47:16 +01:00
Nikolas Garofil
c010d7cd00
Let execp use fill_p
2010-02-10 19:45:42 +01:00
Nikolas Garofil
36ad680a98
Let print_execi and print_texeci call fill_p for filling p
2010-02-10 19:04:31 +01:00
Pavel Labath
e4461782ef
C++ binding for lua, with some fancy features
...
such as being able to throw exceptions across c++-lua boundary. For more details, see comments
in the source code.
2010-02-10 17:34:09 +01:00
Nikolas Garofil
9fefa79551
Obsolete threaded_exec_caller with help of previous commit
2010-02-10 15:54:50 +01:00
Nikolas Garofil
e017870b58
Combine print_texeci and print_texecpi as much as possible
2010-02-10 15:21:00 +01:00
Nikolas Garofil
456142241c
Combine print_execi and print_execpi as much as possible
2010-02-10 15:02:00 +01:00
Nikolas Garofil
b601c21c04
cpp-ify eve.c
2010-02-09 23:12:10 +01:00
Nikolas Garofil
f0eec1e0c5
cpp-ify iconv_tools.c
2010-02-09 22:34:24 +01:00
Nikolas Garofil
886049122c
Add missing memory header needed by std::unique_ptr
2010-02-09 17:43:56 +01:00
Nikolas Garofil
332cf86b7b
Merge branch 'master' of ssh://git.omp.am/home/omp/git/conky
2010-02-09 16:49:31 +01:00
Pavel Labath
3d70f3a415
Fix `ISO C++ forbids variable length array' errors with maintainer mode enabled
2010-02-09 15:54:55 +01:00
Nikolas Garofil
325a29e438
cpp-ify prss.c
2010-02-09 15:24:58 +01:00
Nikolas Garofil
526e8d346e
cpp-ify xmms2.c
2010-02-09 13:38:12 +01:00
Nikolas Garofil
043b12b15a
cpp-ify a lot of files
2010-02-09 13:11:56 +01:00
Nikolas Garofil
66a63d9e87
cpp-ify timeinfo.c
2010-02-09 02:24:41 +01:00
Nikolas Garofil
196f6bc796
cpp-ify text_object.c
2010-02-09 02:15:32 +01:00
Nikolas Garofil
9544239a19
cpp-ify read_tcp.c
2010-02-09 02:02:00 +01:00
Nikolas Garofil
d0646bc4bb
cpp-ify mboxscan.c
2010-02-09 01:49:51 +01:00
Nikolas Garofil
b49ac8e6d3
cpp-ify template.c
2010-02-09 00:28:33 +01:00
Nikolas Garofil
a5ed45fc7b
put same stuff from print_texeci and print_texecpi in a separate function
2010-02-08 16:12:46 +01:00
Nikolas Garofil
223eefcdd7
Forgot one letter in previous commit...
2010-02-07 14:46:22 +01:00
Nikolas Garofil
01e3bb62a2
Implements texecpi variable
2010-02-07 10:29:43 +01:00
Pavel Labath
ff52605930
Fix compilation without --enable-argb
...
Bug reported by zaphire
2010-02-03 22:42:19 +01:00
Cesare Tirabassi
b1b91c80fa
Replaces commit 44e3708cdb
...
Thanks to ichelm610x for the patch.
I just added memoization to reduce the impact of the many system calls.
(cherry picked from commit 1eedf2633b
)
2010-01-31 21:01:08 +01:00
Cesare Tirabassi
80c56d099e
Modify last commit to keep compiler happy since it claims devbuf can never be null (should we really trust gcc that much?)
2010-01-30 19:17:17 +01:00
Cesare Tirabassi
ddec718a62
Fix diskio total computation for kernel > 2.6.31 (sf: #2942117 )
...
(cherry picked from commit 44e3708cdb
)
2010-01-30 14:32:05 +01:00
Brenden Matthews
a11cf38aaa
Only ever fork() once.
2010-01-26 13:06:17 -08:00
Brenden Matthews
5ed1f82ff5
Only pause during startup, not after reload.
2010-01-26 12:38:35 -08:00
Cesare Tirabassi
4264f759bb
Fix minor memory leak in mail.cc (see http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=566524 )
2010-01-24 22:15:52 +01:00
Pavel Labath
1de2a9e6c5
Add optional argument to $acpiacadapter
...
The exact location of the state information seems hardware dependent, so this adds the option to
specify it manually. (linux only)
2010-01-24 15:34:03 +01:00
Pavel Labath
6e89ed7e2d
Get $iconv vars working again
2010-01-20 18:17:30 +01:00
Pavel Labath
9bee219adf
Make conky not crash when drawing on root window
...
It was failing in XQueryColor because colourmap was NULL. This seemed to help.
2010-01-20 00:01:01 +01:00
Pavel Labath
ae4be102b6
Another off-by-one found by valgrind.
2010-01-17 19:51:17 +01:00
Nikolas Garofil
287c38a0b9
Added support for builtin config in cmake
2010-01-17 03:00:51 +01:00
Dmitry Marakasov
5664cc3d13
Add SMP support for FreeBSD.
...
Original patch written by Ivan Klymenko <fidaj@ukr.net>.
Signed-off-by: Brenden Matthews <brenden@diddyinc.com>
2010-01-16 10:55:20 -08:00
Pavel Labath
3a23eb5f6c
Fix "off-by-one" bug in hddtemp found by valgrind
2010-01-15 23:41:04 +01:00
Brenden Matthews
002685c0ce
Make timed-thread a lib, rename files.
2010-01-13 10:52:54 -08:00
Pavel Labath
b7028cb9e5
Make weather.cc more c++-ish (and get rid of a leak in the process)
2010-01-13 13:59:24 +01:00
Pavel Labath
c62266a5db
Make sure the $exec buffer is null-terminated
2010-01-13 13:34:14 +01:00
Pavel Labath
86e744d334
Fix slightly over-zealous s///
2010-01-13 10:49:36 +01:00
Brenden Matthews
081d04a059
Pass by value here too.
2010-01-12 10:38:30 -08:00
Brenden Matthews
e0502719a0
Pass function by value to timed_thread::create().
2010-01-12 10:30:37 -08:00
Pavel Labath
0f3a56ccbe
An attempt at making wifi work
...
Someone who has iwlib should really test this.
2010-01-11 01:13:42 +01:00
Pavel Labath
47509b38bd
An attempt at making lua bindings work
2010-01-11 00:35:22 +01:00
Phil Sutter
bdda06f4ea
fix segfaults in CRIT_ERR condition
...
- pthread_join() on uninitialised threads causes segfault
- XFreeFont() dislikes font being zero
2010-01-10 22:09:33 +01:00
Phil Sutter
3ab853af65
fix for a fatal X11 error (possible creation of zero-sized window)
2010-01-10 22:07:52 +01:00
Phil Sutter
0bdff28f69
fix smapi move to C++
2010-01-10 22:06:01 +01:00
Phil Sutter
081f5e1699
make imlib2.c a C++ source, as it uses the C++ symbol 'to_real_path()'
2010-01-10 22:04:15 +01:00
Pavel Labath
e554e6ff67
If we want a function to change the object, we need to pass it by reference
2010-01-07 19:50:00 +01:00
Pavel Labath
4c2d634f07
Unbreak weather and iostats
...
The weather still doesn't quite work for me though.
2010-01-07 19:14:53 +01:00
Brenden Matthews
3e3dd16367
Update modelines and stuff.
2010-01-06 19:45:19 -08:00
Brenden Matthews
7e78f036f0
Use consistent naming for build option macros.
...
Probably have broken some build features with this commit.
2010-01-06 18:39:44 -08:00
Pavel Labath
d61c545973
"Port" nvidia code to c++
2010-01-06 20:57:13 +01:00
Brenden Matthews
9b46a61ae6
Don't include non-existent files.
2010-01-06 11:33:42 -08:00
Brenden Matthews
5d20ed4b8c
Fix small logic error in diskio.
2010-01-06 10:18:32 -08:00
Cesare Tirabassi
2568030509
Fix sigsegv if cpu_usage has not yet been populated (seen on 1.8.0_rc1)
2010-01-05 16:59:50 +01:00
Brenden Matthews
7ff762e4af
Resolve issues with timed_thread rewrite WIP.
2010-01-04 19:21:12 -08:00
Brenden Matthews
620e9876a4
C++ conversions WIP.
...
Currently stuck on an issue with g++ and using '%lli' with printf/scanf.
2010-01-04 19:21:12 -08:00
Brenden Matthews
d3a8c4d22e
timed_thread
...
Convert everything (everything? maybe missed some stuff) from old
timed_thread to new timed_thread.
2010-01-04 19:21:12 -08:00
Brenden Matthews
01ac47d082
Implement timed_thread rewrite in C++.
...
Rewrote timed_thread library in C++ using fancy new C++0x features. The
main reason for this is to phase out poor encapsulation and C-style
function pointers.
2010-01-04 19:21:12 -08:00
Brenden Matthews
58cbbf57a3
Coulpe minor build fixes.
2010-01-04 18:43:40 -08:00
Brenden Matthews
b8a678728c
Remove automake build system, fix defconfig.h.
2010-01-04 18:07:49 -08:00
Cesare Tirabassi
36b6facaf5
Remove compiler warning about uninitialized variable
2010-01-03 18:52:22 +01:00
Brenden Matthews
9acf0bb4c0
Fix some minor memleaks, fix crash on reload.
...
It seems that closing xft fonts on reload is a bad idea, but this seems
to result in a memory leak. As far as I can tell, the leak doesn't grow
beyond the initial allocation however.
2010-01-02 14:44:20 -08:00
Brenden Matthews
39f01e216b
Added disable_auto_reload option, callback fixes.
...
There were some issues with reloading and the threaded callback
framework, which I think are mostly resolved now, but may need more
testing.
2010-01-02 14:44:12 -08:00
Brenden Matthews
19303af8da
Fix reload problem with ARGB.
2010-01-02 12:12:46 -08:00
Ben Kibbey
c00e7b0a42
Fixes $xmms2_percent and a couple other build fixes.
...
Signed-off-by: Brenden Matthews <brenden@diddyinc.com>
2010-01-02 11:50:53 -08:00
Ben Kibbey
ed5e86eb88
Fix the quiet command line option.
...
Signed-off-by: Brenden Matthews <brenden@diddyinc.com>
2010-01-02 11:48:50 -08:00
Brenden Matthews
0f5f2a1afe
Improve handling of ARGB visuals a bit.
...
Conflicts:
src/conky.cc
2010-01-02 11:43:29 -08:00
Brenden Matthews
2951f5571c
Add missing copyright notices.
2010-01-01 15:49:41 -08:00
Brenden Matthews
cf9e498b24
Update copyright notices.
2010-01-01 15:46:17 -08:00
danielb
6c5fa44660
Add ARGB visual support.
...
This patch adds the possibility to use a argb visual for the conky
window. Adding a boolean configuration entry 'own_window_argb_visual'.
the 'set_transparent_background' method sets the alpha bytes of the argb
color for transparency, instead of pseudo transparency. This patch
would close following feature request:
https://sourceforge.net/tracker/?func=detail&aid=1563931&group_id=143975&at
id=757311 and would be a workaround for some reported transparency bugs
(https://sourceforge.net/tracker/?func=detail&aid=1968923&group_id=143975&a
tid=757308 for example)
Signed-off-by: Brenden Matthews <brenden@diddyinc.com>
2010-01-01 15:03:40 -08:00
Ben Kibbey
87e422c224
$scroll fix for a text length <= length
...
This fixes $scroll to only scroll when the text length is greater than
the specified length; hopefully without breaking anything.
Signed-off-by: Brenden Matthews <brenden@diddyinc.com>
2010-01-01 14:51:46 -08:00
Ben Kibbey
6e6a1f59e8
Fix hddtemp with disabled drives.
...
Some drives are unable to return their temperature when in standby mode.
If there is more than one drive installed then other drives may not be
able to get parsed. This patch will skip over the unparsable output for
the current drive and let others get parsed.
Signed-off-by: Brenden Matthews <brenden@diddyinc.com>
2010-01-01 14:50:42 -08:00
Brenden Matthews
4d7d2b27f3
Minor build fix.
2010-01-01 13:45:16 -08:00
Cesare Tirabassi
72bbe51a8c
The HAPPY NEW YEAR commit
...
This should close sf #2850092 .
Basically, before this change, for strings which includes
SECRIT_MULTILINE_CHAR the computed maximum substring width was getting
summed to the width of the last substring.
The old behaviour is kept but for the case of strings including
SECRIT_MULTILINE_CHAR, for which now the maximum width of all substrings
is taken.
I don't think this will break anything else but blame me if it does ...
2009-12-31 23:49:02 +01:00
Phil Sutter
db2282968f
parse the -D flag as early as possible
...
In fact, this will make -D being parsed at least before the conkyrc is
being read, allowing for debug-output from inside the config-parser. :)
2009-12-29 00:18:12 +01:00
Phil Sutter
6f587402d8
cosmetic fixup session
...
- kill trailing whitespace (grep -n ' $' src/*.{c,cc,h})
- eliminate space before tab (grep -n ' ' src/*.{c,cc,h})
(insert tab by pressing CTRL-v first)
- little indenting fixup in configure.ac.in (we indent using tabs, not
spaces)
note: this should not change the actual code at all - if it does, feel
free to blame me personally ;)
2009-12-28 21:32:07 +01:00
Phil Sutter
7d92e46533
include llua.h where it's really needed
2009-12-28 21:31:49 +01:00
Phil Sutter
46bd87b05e
move extract_object_args_to_sub() to a more convenient place
2009-12-28 03:02:06 +01:00
Phil Sutter
c4c2377d0e
drop commas at end of enum in top.h
2009-12-28 03:02:06 +01:00
Phil Sutter
dcb35db39d
check return value of write()
2009-12-28 03:02:05 +01:00
Phil Sutter
e99118cf2e
fix for unused results in tailhead.c
2009-12-28 03:02:05 +01:00
Phil Sutter
1ff3f84068
fix for unused results in mboxscan.c
2009-12-28 03:02:05 +01:00
Phil Sutter
43ee33a28d
check return type of dup() in exec.c
2009-12-28 03:02:05 +01:00
Phil Sutter
ac8bb1489d
fix for unused results in eve.c
2009-12-28 03:02:05 +01:00
Phil Sutter
6e53e3278d
implement a safe_asprintf for timeinfo.c
2009-12-28 03:02:05 +01:00
Phil Sutter
aa95dde706
fix for unused results in smapi.c
2009-12-28 03:02:05 +01:00
Phil Sutter
8662e6630e
fix for unused results in linux.c
2009-12-28 03:02:05 +01:00
Phil Sutter
c986aa6346
fix unused result warnings in mail.c
2009-12-28 03:02:05 +01:00
Brenden Matthews
fb33419cd4
Add CMake build support for Lua bindings.
2009-12-17 19:46:26 -08:00
Brenden Matthews
32c5f451b9
Minor build fixes
2009-12-17 18:55:54 -08:00
Brenden Matthews
51ff65ede0
Merge branch 'master' of git.omp.am:/home/omp/git/conky
2009-12-17 18:52:05 -08:00
Phil Sutter
0522832350
cleanup apcupsd a bit, fix some whitespace errors
2009-12-17 23:07:15 +01:00
Phil Sutter
9b66a4715b
hide smapi internal functions and cleanup header
2009-12-17 22:45:00 +01:00
Phil Sutter
861988be24
font_h could be used uninitialised (so it says)
2009-12-17 22:42:52 +01:00
Phil Sutter
bf1e5108ab
we shall not ignore the return value of functions declared with warn_unused_result
2009-12-17 22:42:52 +01:00
Phil Sutter
1724a1fe49
ISO C++ forbids variable length arrays
2009-12-17 22:42:52 +01:00
Phil Sutter
de049dcbde
--enable-testing rejects commas at end of enumerator lists
2009-12-17 22:42:47 +01:00
Phil Sutter
4229fbd380
introduce a generic priority queue implementation
2009-12-13 17:10:45 +01:00
Phil Sutter
bb72583a95
simplify this conditional a bit
2009-12-13 03:42:14 +01:00
Phil Sutter
bad6d62b31
little header cleanup in conky.cc
2009-12-13 02:54:48 +01:00
Phil Sutter
8bc17ca311
top: add update callbacks conditionally, drop useless check
2009-12-12 19:50:36 +01:00
Phil Sutter
8045e7f714
drop enum text_object_type and all references to it's members
...
After some minor rewrite of the top parser (which was in fact the only
real user of the obj->type field left since introduction of text object
callbacks), there is no need for the obj->type field anymore.
2009-12-12 15:56:00 +01:00
Phil Sutter
5c86a80614
fix $scroll color reset (add missing callback)
2009-12-12 15:43:39 +01:00
Pavel Labath
52b5fe11ed
Fix race condition in update_stat()
2009-12-11 22:54:11 +01:00
Pavel Labath
a49000ba22
Eliminate warnings in mail.c
...
PS: functions pop3_thread and imap_thread look ridiculously similar. It may be worth merging them
at some point.
2009-12-11 21:34:41 +01:00
Nikolas Garofil
6d4ba8b2f4
Fix anonymous enum warning
2009-12-11 17:58:25 +01:00
Brenden Matthews
48e834d1eb
More work on CMake build system.
2009-12-10 20:37:56 -08:00
Brenden Matthews
07e2002b03
Build libtcp-portmon as a separate library.
2009-12-10 15:19:13 -08:00
Pavel Labath
316198a0c3
Explicitly cast NULL to the specific type for compilers that (for some unknown reason) require it
2009-12-10 23:42:22 +01:00
Pavel Labath
b4feb01818
Fix memory allocation problem in exec.c
...
Bug reported by c0nv1ct.
2009-12-10 23:09:56 +01:00
Brenden Matthews
b6331b4eb6
Switch some more bits to C++, more CMake changes.
2009-12-09 20:05:32 -08:00
Phil Sutter
475b00e709
drop local definitions of _GNU_SOURCE since it's passed to gcc
2009-12-10 02:03:56 +01:00
Pavel Labath
2790d35e06
Set CXXFLAGS in-line with current CFLAGS settings (autoconf)
...
Also, replaced #define _GNU_SOURCE (in config.h) with -D_GNU_SOURCE command-line parameter
because, for some reason g++ defines it implicitly and then complains about multiple definitions.
Also, removed -Winline from C(XX)FLAGS because it causes a lot of warnings for c++ code that
can't be easily removed and are not very significant.
2009-12-09 23:59:08 +01:00
Pavel Labath
78da8a1946
Update cmake to address portmon change.
2009-12-09 23:59:07 +01:00
Pavel Labath
e9d4e32f8f
Replace GHashTable with tr1::unordered_map in tcp_portmon
...
This means portmon no longer depends on glib.
2009-12-09 23:59:07 +01:00
Brenden Matthews
8c9ed7b109
Minor build fixes.
2009-12-07 21:16:11 -08:00
Brenden Matthews
11c76e4c0d
More CMake work.
2009-12-07 20:46:49 -08:00
Pavel Labath
b1cbc64f60
Remove some strange network related code
...
Reported by norsetto.
This code disallows network traffic to be 0.
Brenden says it once had a purpose, but noone can think of what would that be atm.
2009-12-07 21:13:04 +01:00
Brenden Matthews
d80cacd4b7
Handle build.h, too.
2009-12-07 11:51:00 -08:00
Brenden Matthews
c5cbb3c38f
Produce error if src/config.h exists.
2009-12-07 10:08:01 -08:00
Brenden Matthews
4dcce0b386
Improve platform stuff.
2009-12-07 09:35:43 -08:00
Phil Sutter
4baba32459
replace modulo by bitwise AND for hash table lookups
...
This operation is a lot faster, but depends on the hash table size
be a power of 2 (so HTABSIZE - 1 is a row of 1's). Also a define for the
magic value cleans things up a bit.
2009-12-06 21:49:27 +01:00
Phil Sutter
36f6af922b
improve hash_process() by inserting at bucket's top instead of bottom
2009-12-06 17:28:30 +01:00
Brenden Matthews
0406000351
More CMake build work, added Lua support.
2009-12-05 18:45:26 -08:00
Brenden Matthews
07cb6efdaf
More work on CMake build system (see README.cmake for instructions).
2009-12-05 12:00:10 -08:00
Phil Sutter
3764c883c7
convert mixer bars to double
2009-12-04 22:18:54 +01:00
Phil Sutter
1160e74d35
convert fs bars to double
2009-12-04 22:18:54 +01:00
Phil Sutter
361e5eba83
convert exec bars to double
2009-12-04 22:18:54 +01:00
Phil Sutter
b2c305a995
convert execbarval to double
2009-12-04 22:18:54 +01:00
Phil Sutter
3361ea907b
convert *speedgraphval to double
2009-12-04 22:18:54 +01:00
Phil Sutter
a68a523d40
convert diskiographval_* to double
2009-12-04 22:18:54 +01:00
Phil Sutter
1382915d1e
convert loadgraphval to double
2009-12-04 22:18:54 +01:00
Phil Sutter
f74ae19944
convert apcupsd_loadbarval to double
2009-12-04 22:18:54 +01:00
Phil Sutter
c52ee46cc3
convert entropy_barval to double
2009-12-04 22:18:54 +01:00
Phil Sutter
2fc1efa8d5
convert lua_barval to double
2009-12-04 22:18:54 +01:00
Phil Sutter
f1a57e40aa
convert audacious_barval to double
2009-12-04 22:18:53 +01:00
Phil Sutter
e2e7c47c48
convert xmms2_barval to double
2009-12-04 22:18:53 +01:00
Phil Sutter
202bbf01ff
convert mpd_barval to double
2009-12-04 22:18:53 +01:00
Phil Sutter
9e587ae6d5
convert smapi_bat_barval to double
2009-12-04 22:18:53 +01:00
Phil Sutter
db2b056969
convert swap_barval to double
2009-12-04 22:18:53 +01:00
Phil Sutter
c5a8949784
convert mem_barval to double
2009-12-04 22:18:53 +01:00
Phil Sutter
d46a2cb1b2
convert cpu_barval to double
2009-12-04 22:18:53 +01:00
Phil Sutter
bfd7eabc0f
convert get_battery_perct_bar to double
2009-12-04 22:18:53 +01:00
Phil Sutter
4133d8fdbe
convert wireless_link_barval to double
2009-12-04 22:18:53 +01:00
Phil Sutter
e5d32f4ad0
convert meter type object values from uint8_t to double
2009-12-04 22:17:40 +01:00
Phil Sutter
1e25633fc1
rename specials field "graph_scale" to a generic "scale"
2009-12-04 00:53:11 +01:00
Phil Sutter
82ef68aafa
hook in the scale value for bar and gauge objects
...
This patch already implements complete auto-scaling for bars and gauges,
therefore introducing a flags field in order to signal whether
auto-scaling is enabled (and the scale field contains just the max value
seen so far).
2009-12-04 00:50:13 +01:00
Phil Sutter
dae785e5d0
introduce scale field for bar and gauge specials
2009-12-02 01:36:22 +01:00
Phil Sutter
a49fb53ea3
fix scaling for exec*graph
2009-12-01 23:59:12 +01:00
Pavel Labath
018ca8e0ef
Fix $memgraph and $cpugraph in a way that doesn't break other things
2009-12-01 23:45:31 +01:00
Pavel Labath
24ebff6a62
Fix $memgraph (i think)
2009-12-01 14:20:35 +01:00
Nikolas Garofil
e24bc153b3
Fix building without X11
2009-12-01 14:07:22 +01:00
Nikolas Garofil
a2c9ac648d
Fix compiling without C99
2009-12-01 12:35:23 +01:00
Phil Sutter
d3aafc4a75
reenable top for all target OS's
...
Occurs to work fine on FreeBSD, the other BSD's probably need more work,
anyway.
2009-12-01 00:45:17 +01:00
Phil Sutter
d4bc07b1f1
fix for compiling on freebsd
2009-12-01 00:32:33 +01:00
Phil Sutter
b6a57a8f77
cleanup free_text_objects()
2009-12-01 00:32:33 +01:00
Phil Sutter
3f00e817c5
free desktop information where it should be done
2009-12-01 00:32:33 +01:00
Phil Sutter
5ed38bfe0d
convert top objects to callbacks.free
2009-12-01 00:32:33 +01:00
Phil Sutter
ba47b49d88
move free_all_processes() to where it really should be
2009-12-01 00:32:33 +01:00
Phil Sutter
8ef2f13e9d
convert xmms2 objects to callbacks.free
2009-12-01 00:32:33 +01:00
Phil Sutter
6fb5302778
convert mpd objects to callbacks.free
2009-12-01 00:32:33 +01:00
Phil Sutter
4c4a7c4096
convert nameserver to callbacks.free
2009-12-01 00:32:33 +01:00
Phil Sutter
781bc7b024
convert gateway objects to callbacks.free
2009-12-01 00:32:33 +01:00
Phil Sutter
93c2079af0
generically free obj->sub if non-zero in free_text_objects()
2009-12-01 00:32:33 +01:00
Phil Sutter
87472a3daa
convert cmdline_to_pid to callbacks.free
2009-12-01 00:32:33 +01:00
Phil Sutter
ede0838e17
drop struct information parameter from generate_text_internal()
2009-12-01 00:32:33 +01:00
Phil Sutter
0f8b7d1186
cleanup generate_text_internal()
2009-12-01 00:32:33 +01:00
Phil Sutter
92ae6fab8a
replace substitute_newlines() object typecheck with object field
...
This is the more generic way, although I doubt this is really error
preventing. To me, it's not totally clear as to when
substitute_newlines() is forbidden and when not. Maybe someone (the
author?) can shed light on the internal algorithm of this feature.
2009-12-01 00:32:33 +01:00
Phil Sutter
c9f1c318aa
convert OBJ_text to callbacks
...
This is tricky: there is no such thing as $text. In fact, everything
below TEXT in the conkyrc which is NOT a text object will become one of
type OBJ_text.
To make life easy, introduce a function obj_be_plain_text() converting a
given object to the given plain text.
2009-12-01 00:32:33 +01:00
Phil Sutter
e569803324
convert if_updatenr to callbacks.iftest
2009-12-01 00:32:33 +01:00
Phil Sutter
841a3814c8
convert $updates to callbacks.print
2009-12-01 00:32:32 +01:00
Phil Sutter
ffec9dd50c
font: convert to callbacks.print
2009-12-01 00:32:32 +01:00
Phil Sutter
95b92d6cff
new_font: convert to common signature
2009-12-01 00:32:32 +01:00
Phil Sutter
e5b25fd30a
unconditionally call load_fonts()
...
Since load_fonts() iterates over font_count fonts which is initially -1,
it turns into a NOP when no fonts where added.
2009-12-01 00:32:32 +01:00
Phil Sutter
68a09f7a02
gid_name, uid_name: outsource sub object parsing and convert to callbacks.print
2009-12-01 00:32:32 +01:00
Phil Sutter
4ba0f9ff4f
pid objects: convert to callbacks.print
2009-12-01 00:32:32 +01:00
Phil Sutter
5b686294f3
pid objects: outsource sub object evaluation
2009-12-01 00:32:32 +01:00
Phil Sutter
057855442c
cleanup proc.c obj->data mess
...
Use a local variable named 'pathbuf' of sufficient size to hold the
generated path name.
2009-12-01 00:32:32 +01:00
Phil Sutter
d9dbd528c4
simplify iconv_convert() a bit (exit early on error)
2009-12-01 00:32:32 +01:00
Phil Sutter
938af98ff3
convert iconv objects to callbacks
2009-12-01 00:32:32 +01:00
Phil Sutter
b8e600b9a4
convert bsd apm objects to callbacks.print
2009-12-01 00:32:32 +01:00
Phil Sutter
d48c2f143c
convert $include to callbacks.print
2009-12-01 00:32:32 +01:00
Phil Sutter
3ed82a34dd
convert blink to callbacks.print
2009-12-01 00:32:32 +01:00
Phil Sutter
dc0af635d6
convert to_bytes to callbacks.print
2009-12-01 00:32:32 +01:00
Phil Sutter
8da8b26ddf
use gen_print_nothing for $apcupsd
2009-12-01 00:32:32 +01:00
Phil Sutter
37cbdcf89b
convert $endif to callbacks.print
2009-12-01 00:32:32 +01:00
Phil Sutter
718ed9d280
convert $else to callbacks.iftest
2009-12-01 00:32:32 +01:00
Phil Sutter
f1454767b2
convert image to callbacks.print
2009-12-01 00:32:32 +01:00
Phil Sutter
3fa5c55933
convert some non-openbsd objects to callbacks.{print,iftest}
2009-12-01 00:32:32 +01:00
Phil Sutter
c652427aed
convert freq and freq_g to callbacks.print
2009-12-01 00:32:32 +01:00
Phil Sutter
31c3734cc8
convert acpitemp to callbacks.{print,free}
2009-12-01 00:32:32 +01:00
Phil Sutter
a67ab7a3c8
convert some ifblock objects to callbacks.iftest
2009-12-01 00:32:32 +01:00
Phil Sutter
721cdbdd30
convert eval to callbacks.print
2009-12-01 00:32:32 +01:00
Phil Sutter
f5596a6505
trivial conversion of cmdline_to_pid to callbacks.print
2009-12-01 00:32:32 +01:00
Phil Sutter
871c4b2d02
convert buffers and cached to callbacks.print
2009-12-01 00:32:32 +01:00
Phil Sutter
1f8bafbcfc
convert processes and threads objects to callbacks.print
2009-12-01 00:32:32 +01:00
Phil Sutter
82d6d349ba
convert user objects to callbacks.{print,free}
2009-12-01 00:32:32 +01:00
Phil Sutter
b4aa2328d7
convert uptime objects to callbacks.print
2009-12-01 00:32:32 +01:00
Phil Sutter
cce12efda7
convert sysname to callbacks.print
2009-12-01 00:32:31 +01:00
Phil Sutter
e9dde6293b
convert nodename to callbacks.print
2009-12-01 00:32:31 +01:00
Phil Sutter
d9e2f687b6
convert format_time to callbacks.print
2009-12-01 00:32:31 +01:00
Phil Sutter
f84b14904c
convert kernel and machine to callbacks.print
2009-12-01 00:32:31 +01:00
Phil Sutter
177da5ffbb
convert mem and swap objects to callbacks.print
2009-12-01 00:32:31 +01:00
Phil Sutter
ef60b7eb8a
drop update_x11info()
...
instead:
- call XDefaultScreen() and XScreenCount() directly from the print
callback
- have no update callback at all for the desktop objects (seems to work
well without)
2009-12-01 00:32:31 +01:00
Phil Sutter
6004ab961a
convert desktop and monitor objects to callbacks.print
2009-12-01 00:32:31 +01:00
Phil Sutter
2dca262c00
convert if_smapi_bat_installed to callbacks.iftest
2009-12-01 00:32:31 +01:00
Phil Sutter
9887bfdfdf
convert smapi_bat_perc to callbacks.percentage
2009-12-01 00:32:31 +01:00
Phil Sutter
bc1b82771f
convert mpd_percent to callbacks.percentage
2009-12-01 00:32:31 +01:00
Phil Sutter
61591def8e
convert mixer values to callbacks.percentage
2009-12-01 00:32:31 +01:00
Phil Sutter
36a202091e
convert fs_*_perc to callbacks.percentage
2009-12-01 00:32:31 +01:00
Phil Sutter
61c4efb305
convert entropy_perc to callbacks.percentage
2009-12-01 00:32:31 +01:00
Phil Sutter
0631b2ab2e
convert swapperc to callbacks.percentage
2009-12-01 00:32:22 +01:00
Phil Sutter
feba298efa
convert memperc to callbacks.percentage
2009-12-01 00:31:09 +01:00
Phil Sutter
07f82f5cb6
convert cpu to callbacks.percentage
2009-12-01 00:29:28 +01:00
Phil Sutter
79f5726832
merge loadgraph to callbacks.graphval
2009-12-01 00:29:28 +01:00
Phil Sutter
bd752e8506
merge {down,up}speedgraph to callbacks.graphval
2009-12-01 00:29:28 +01:00
Phil Sutter
fe05542318
merge diskiographs to callbacks.graphval
2009-12-01 00:29:28 +01:00
Phil Sutter
9581914f7d
reuse barval callbacks where applicable
2009-12-01 00:28:53 +01:00
Phil Sutter
cba2460397
merge apcupsd_loadbar to callbacks.barval
2009-12-01 00:07:07 +01:00
Phil Sutter
4988947829
convert xmms2_bar to callbacks.barval
2009-12-01 00:06:23 +01:00
Phil Sutter
997805c46b
convert smapi_bat_bar to callbacks.barval
2009-12-01 00:05:20 +01:00
Phil Sutter
fcd3d58960
convert mpd_bar to callbacks.barval
2009-12-01 00:04:35 +01:00
Phil Sutter
f79c58ef47
merge mixer bars to callbacks.barval
2009-12-01 00:02:48 +01:00
Phil Sutter
4d7f2e720d
merge lua_bar to callbacks.barval
2009-12-01 00:02:04 +01:00
Phil Sutter
4f8e700d64
convert fs bars to callbacks.barval
2009-12-01 00:01:04 +01:00
Phil Sutter
a5ff5d39d0
merge execibar to callbacks.barval
2009-11-30 23:59:13 +01:00
Phil Sutter
95fbecc385
merge entropy_bar to callbacks.barval
2009-11-30 23:58:09 +01:00
Phil Sutter
b78664d8c5
merge audacious_bar to callbacks.barval
2009-11-30 23:57:04 +01:00
Phil Sutter
086829b017
convert swapbar to callbacks
2009-11-30 23:55:48 +01:00
Phil Sutter
d2f3ae7e15
convert mem{gauge,graph,bar} to callbacks
2009-11-30 23:54:52 +01:00
Phil Sutter
b2b9155514
fix execigauge conversion to callbacks
2009-11-30 23:49:58 +01:00
Phil Sutter
685d4ca4e8
fix execbar merge to callbacks
2009-11-30 23:48:54 +01:00
Phil Sutter
4e63422d10
battery_bar: convert to callbacks.barval
2009-11-30 23:48:04 +01:00
Phil Sutter
a11a1a1253
wireless_link_bar: convert to callbacks.barval
2009-11-30 23:35:49 +01:00
Phil Sutter
c85295202b
convert cpubar to callbacks.barval
2009-11-30 23:34:20 +01:00
Phil Sutter
06a4650f60
if_xmms2_connected: convert to callbacks.iftest
2009-11-29 22:21:49 +01:00
Phil Sutter
cec0f3b8c6
cleanup mpd code
2009-11-29 22:21:49 +01:00
Phil Sutter
41f32f8766
if_mpd_playing: convert to callbacks.iftest
2009-11-29 22:21:49 +01:00
Phil Sutter
482f2d50b4
if_mixer_mute: convert to callbacks.iftest
2009-11-29 22:21:49 +01:00
Phil Sutter
5249c9da04
if_mounted: convert to callbacks.iftest
2009-11-29 22:21:49 +01:00
Phil Sutter
9af79a4907
if_up: convert to callbacks.iftest
2009-11-29 22:21:49 +01:00
Phil Sutter
27c1207cd1
if_gw: convert to callbacks.iftest
2009-11-29 22:21:49 +01:00
Phil Sutter
bb70c21c36
nvidia: convert to callbacks.print
2009-11-29 22:21:49 +01:00
Phil Sutter
0188eb0aaa
top: convert to callbacks.print
2009-11-29 22:21:49 +01:00
Phil Sutter
1832cf79c9
ioscheduler: convert to callbacks.print
2009-11-29 22:21:49 +01:00
Phil Sutter
712caa8ab3
convert obsd_* to callbacks.print (completely untested)
2009-11-29 22:21:49 +01:00
Phil Sutter
a249b9bc44
convert disk_protect to callbacks.print
2009-11-29 22:21:49 +01:00
Phil Sutter
2660cb7590
convert execpi to callbacks.print
2009-11-29 22:21:49 +01:00
Phil Sutter
60ad080d1d
convert pb_battery to callbacks.print
2009-11-29 22:21:49 +01:00
Phil Sutter
3f83bd34f4
convert laptop_mode to callbacks.print
2009-11-29 22:21:49 +01:00
Phil Sutter
f3cafc6a7c
convert gw_* objects to callbacks.print
2009-11-29 22:21:49 +01:00
Phil Sutter
faa47450ad
convert sony_fanspeed to callbacks.print
2009-11-29 22:21:49 +01:00
Phil Sutter
42b71217e3
loadgraph: convert to callbacks.print
2009-11-29 22:21:49 +01:00
Phil Sutter
ee40c63542
xmms2: outsource code and convert to callbacks.print
2009-11-29 22:21:48 +01:00
Phil Sutter
6bf79b7ebe
combine: convert to callbacks.print
2009-11-29 22:21:48 +01:00
Phil Sutter
65effae144
scroll: convert to callbacks.print
2009-11-29 22:21:48 +01:00
Phil Sutter
67559fdaca
moc: convert to callbacks.print and callbacks.free
2009-11-29 22:21:48 +01:00
Phil Sutter
dd8ec48fcb
bmpx: convert to callbacks.print
...
While here, also drop those calls to memset, as the whole info object is
being zeroed at the beginning of main(). (Probably this is useful upon
config reload, too.)
2009-11-29 22:21:48 +01:00
Phil Sutter
6371551153
audacious: convert to callbacks.print
2009-11-29 22:21:48 +01:00
Phil Sutter
974d28a667
apcupsd: convert to callbacks.print
2009-11-29 22:21:48 +01:00
Phil Sutter
ac80e6f55f
hddtemp: convert to callbacks.print
2009-11-29 22:21:48 +01:00
Phil Sutter
49cacbbc91
offset, align, tailhead: convert to callbacks.print
2009-11-29 22:21:48 +01:00
Phil Sutter
e0a3a82932
fs objects: convert to callbacks.print
2009-11-29 22:21:48 +01:00
Phil Sutter
18d2319d73
tcp-portmon: convert to callbacks.print
2009-11-29 22:21:48 +01:00
Phil Sutter
d0a2c51f4b
font: convert scan_font to match common signature
2009-11-29 22:21:48 +01:00
Phil Sutter
9247d838c3
hddtemp: convert to callbacks.free
2009-11-29 22:21:48 +01:00
Phil Sutter
eb612dfcb0
hr, stippled_hr: convert to callbacks.print
2009-11-29 22:21:48 +01:00
Phil Sutter
4927eb85a2
goto, tab: convert to callbacks.print
2009-11-29 22:21:48 +01:00
Phil Sutter
9c8805ee7b
shadecolor: convert to callbacks.print
2009-11-29 22:21:48 +01:00
Phil Sutter
f9036f58a2
outlinecolor: convert to callbacks.print
2009-11-29 22:21:48 +01:00
Phil Sutter
1a6803454c
color: convert to callbacks.print
2009-11-29 22:21:48 +01:00
Phil Sutter
08122354a9
convert some special printing functions to common signature
...
Also add a little hack to $scroll to omit the need to call new_fg() from
inside print_scroll(). Instead of inserting a new special after printing
the scrolled text, insert a new object after the scroll object when
parsing text objects to handle the color reset.
2009-11-29 22:21:48 +01:00
Phil Sutter
2e83ff05c5
text object list: allow appending a list of objects
2009-11-29 22:21:11 +01:00
Phil Sutter
02d104cc6a
free_text_objects: drop empty switch cases
2009-11-29 21:40:48 +01:00
Phil Sutter
9cf2b88242
bunch of trivial conversions to gen_free_opaque()
2009-11-29 21:40:48 +01:00
Phil Sutter
697e64272e
text_object: provide generic object free routine
...
This is a valid replacement to a custom routine for objects using data.s
or data.opaque to point to dynamically allocated data.
2009-11-29 21:40:48 +01:00
Phil Sutter
fa3118993e
huge bunch of trivial conversions to obj->callbacks
2009-11-29 21:40:38 +01:00
Phil Sutter
7b05bdd665
text_object: introduce text_object_callbacks
...
The callback functions are:
print - to be called from generate_text_internal()
iftest - same as print for ifblock objects (triggers jumping)
barval - same as above for bar objects (returns current bar value)
gaugeval - same as above for gauge objects
graphval - same as above for graph objects
percentage - for percentage objects, returns actual percentage
free - called in free_text_objects()
Until conversion is complete, if the function pointer is NULL the old
lookup by type is being done.
Note that it's possible to assign both 'print' and 'iftest' callbacks.
In this case, the code simply ignores the 'iftest' callback, though this
could easily be changed (always calling DO_JUMP at last, of course) in
order to allow ifblock objects to print something in addition to jumping
somewhere (or not).
2009-11-29 21:33:30 +01:00
Phil Sutter
d989f5b34a
cleanup exec.c
2009-11-29 21:28:58 +01:00
Brenden Matthews
f36f747aca
Add (broken) cmake build stuff.
2009-11-26 11:25:32 -08:00
Nikolas Garofil
4652e834b1
Add support for max_text_width configuration setting
2009-11-25 16:04:49 +01:00
Nikolas Garofil
4c4770eb77
Fix: $scroll,$if_running and $apcupsd_lastxfer can now have long arguments if text_buffer_size is increased
2009-11-24 13:23:58 +01:00
Nikolas Garofil
b2987b9354
Fix: Templates only work when they end with a space or a }
2009-11-23 12:58:20 +01:00
Nikolas Garofil
fb3c59baec
Fix building with --disable-x11
2009-11-22 23:05:08 +01:00
Phil Sutter
970420106c
fix new_graph parameters
...
One should never print into buffers without knowing their size. Although
new_graph consumes only a single char, this may already be too much.
2009-11-22 21:12:54 +01:00
Phil Sutter
346b4cfbc1
move get_x11_color() to colours.c
2009-11-22 21:07:42 +01:00
Nikolas Garofil
6ee76e5c55
Fix compiling with --disable-x11
2009-11-22 14:05:11 +01:00
Phil Sutter
66df73f74a
implement ASCII gauge and enable all gauge objects for use with no X
2009-11-22 02:09:46 +01:00
Phil Sutter
c2eb77c3f0
realise seamless integration of new_bar_in_shell
...
The decision about whether to print ASCII or X11 bar is done from within
specials.c, so all those #ifdef + if () blocks can be dropped. This also
implicitly enables the ASCII bar for some bar printing objects which where
forgotten before.
2009-11-22 02:09:46 +01:00
Nikolas Garofil
c131c1d129
Bugfix: letting XmbSetWMProperties set the windowtitle causes a memleak with some versions of Xlib
2009-11-21 23:58:02 +01:00
Nikolas Garofil
20a7f5eb72
Merge branch 'master' of ssh://git.omp.am/home/omp/git/conky
2009-11-21 15:50:35 +01:00
Nikolas Garofil
567a86f99a
Fix segfault in X11-related code
...
Conky sometimes tries to clears part of a window before it's created,
this breaks closing the displaying. For example with this config:
TEXT
$lua
2009-11-21 15:45:00 +01:00
Phil Sutter
d7f9e64824
allow AF_INET6 in libmpdclient since mpd supports it
...
Thanks to Kaleb Elwert (belak, IRC) who reported the problem and tested
the fix.
2009-11-20 23:00:47 +01:00
Nikolas Garofil
b85b0d5aab
Bugfix: Sx in $format_time prints out wrong values when number of seconds ends with a zero and has no numbers behind the point
2009-11-20 15:23:54 +01:00
Phil Sutter
7291184783
simplify conky_version and co. a bit
2009-11-20 00:03:15 +01:00
Phil Sutter
c8bed3a28d
voltage: outsource printing code
2009-11-20 00:02:42 +01:00
Phil Sutter
b25be92273
xmms2: do 'gg=G' in vim :)
2009-11-20 00:01:47 +01:00
Phil Sutter
c439c8e7b6
mpd: outsource printing code
...
In order to make life a bit easier, the struct mpd_s field "volume" has
been renamed to just "vol" to match the object's name (mpd_vol).
Although format_media_player_time() is probably meant to be used by all
supported media players, it's currently being used by mpd only. So for
now this function can reside statically in mpd.c
2009-11-20 00:01:33 +01:00
Phil Sutter
87873bceeb
lines, words: outsource code
2009-11-19 23:59:50 +01:00
Phil Sutter
ea22f21252
smapi: outsource printing code
2009-11-19 23:57:38 +01:00
Phil Sutter
bb35c25284
ibm: convert to common signature
2009-11-19 23:57:16 +01:00
Phil Sutter
91b0c66617
mixer: convert to common signature
2009-11-19 23:56:01 +01:00
Phil Sutter
80e41032cd
{down,up}speedgraph: convert to match common signature
2009-11-19 23:52:39 +01:00
Phil Sutter
80114f3b1e
diskio: convert print functions to match common signature
2009-11-19 23:51:13 +01:00
Phil Sutter
b9f1dc7283
cleanup times_in_seconds enhancement
...
This also adds code to unset the variable before reloading the config.
2009-11-19 23:39:08 +01:00
Phil Sutter
45a183d840
xlib: do exit() on IOError instead of abort()
...
The IOError happens every time I close conky's normal own window, so I
guess the situation is not as abnormal as abort() indicates. Calling
exit() instead should really suffice and give the process a chance to
clean up (by calling destructor routines for instance).
2009-11-19 23:04:09 +01:00
Phil Sutter
6f9bfe970a
fix potential buffer overflow when printing top values
2009-11-19 23:04:09 +01:00
Phil Sutter
9efa384bbc
lua: outsource code
2009-11-19 23:04:09 +01:00
Phil Sutter
b6d1ff6c42
i8k: outsource code
2009-11-19 23:04:09 +01:00
Nikolas Garofil
fe1d7da3d5
Add support for $pid_read and $pid_write
2009-11-19 12:32:14 +01:00
Nikolas Garofil
f8bae62234
$format_time treats ( and ) as special chars
2009-11-19 00:21:49 +01:00
Nikolas Garofil
59594e70d2
Added support for \Sx to $format_time
2009-11-19 00:04:49 +01:00
Nikolas Garofil
4a1be880d3
Make $user_time, $mpd_elapsed and $mpd_length compatible with times_in_seconds
2009-11-18 21:25:05 +01:00
Nikolas Garofil
d9ad73af65
Make sure $format_time only works when times_in_seconds is enabled
2009-11-18 20:27:53 +01:00
Nikolas Garofil
8f42831a62
Add support for time_in_seconds configuration setting
2009-11-18 20:07:47 +01:00
Nikolas Garofil
4cfb042df9
Fix bug in $pid_cmdline
2009-11-18 18:02:10 +01:00
Nikolas Garofil
6046198053
Fix bug in $pid_nice, $pid_priority, $pid_time, $pid_time_kernelmode and $pid_time_usermode
2009-11-18 17:13:20 +01:00
Nikolas Garofil
0215298c27
Added support for $format_time
2009-11-18 15:35:35 +01:00
Nikolas Garofil
90f5701f3e
Bugfix: crash when apcupsd isnt running
2009-11-16 20:19:57 +01:00
Phil Sutter
a1ddcc0786
fix potential buffer overflow in parse_conky_vars()
2009-11-16 19:52:48 +01:00
Phil Sutter
70e5afe5ac
ifblock: fix clash with specials when freeing objects
...
Murphy hit me again: in my naive attempt to fix the clash between
ifblocks and objects parsing text objects due to the double use of the
'sub' field, I overlooked this problem with reusing the 'special_data'
field. So here comes the real thing (TM), donating ifblocks their own
field for pointing to the jump target.
2009-11-16 19:52:12 +01:00
Phil Sutter
44f76f4876
drop leftover freq_dynamic code in freebsd.c and openbsd.c
...
As the comment states, those functions were originally copied from
linux.c; in fact just the code which has been removed due to licensing
issues.
2009-11-16 19:41:06 +01:00
Pavel Labath
e97b67aa20
IPv6 support for $tcp_portmon
...
In theory, this may fail to compile on ancient systems that don't have IPv6 types (struct
sockaddr_in6 et al.) available. If it turns out that such systems are still in use, the best way
to solve it would be to provide dummy declarations via configure tests.
2009-11-16 18:17:16 +01:00
Nikolas Garofil
84d6095c40
Use seconds instead of centiseconds as unit for $pid_time_kernelmode, $pid_time_usermode and $pid_time
2009-11-16 16:59:41 +01:00
Nikolas Garofil
7b05f78de8
Added support for $pid_time_usermode, $pid_time_kernelmode and $pid_time
2009-11-16 15:30:57 +01:00
Nikolas Garofil
015d275098
Add support for $pid_nice and $pid_priority
2009-11-16 15:01:43 +01:00
Nikolas Garofil
f93aa2a68d
Added support for $pid_threads and $pid_thread_list
2009-11-16 09:54:17 +01:00
Nikolas Garofil
f3e250df55
Bugfix: make sure $else works correct and without memleaks
2009-11-16 08:39:05 +01:00
Nikolas Garofil
5eebf1c516
Fix invalid free for all $if_-vars
2009-11-16 00:21:49 +01:00
Nikolas Garofil
f0211cd43d
fix invalid free in if_up
2009-11-15 23:45:33 +01:00
Pavel Labath
ec879680d2
Forgot to set top_running when $running_processes is used
2009-11-15 23:00:14 +01:00
Nikolas Garofil
2ed76a345f
Added support for $pid_vmpeak, $pid_vmsize, $pid_vmlck, $pid_vmhwm, $pid_vmrss, $pid_vmdata, $pid_vmstk, $pid_vmexe, $pid_vmlib, $pid_vmpte
2009-11-15 19:44:37 +01:00
Pavel Labath
72412c463b
Rename $running_processes to $running_threads, implement real $running_processes
2009-11-15 17:55:03 +01:00
Nikolas Garofil
2c2e87061b
Added support for $gid_name
2009-11-15 17:46:41 +01:00
Nikolas Garofil
3fa868f35b
Added support for $uid_name
2009-11-15 17:21:55 +01:00
Nikolas Garofil
d38049fb96
Added support for $pid_uid, $pid_euid, $pid_suid, $pid_fsuid, $pid_gid, $pid_egid, $pid_sgid and $pid_fsgid
2009-11-15 14:49:55 +01:00
Nikolas Garofil
b8e6b1a58d
Add support for $pid_parent
2009-11-15 13:26:40 +01:00
Phil Sutter
68278e4a45
yet another fix for FreeBSD (somehow sneaked through last time)
2009-11-14 16:47:30 +01:00
Phil Sutter
40792b7d05
fix compiling for freebsd
...
Tested using default options, lua disabled as only lua50 available in
7.2-RELEASE.
2009-11-15 01:36:17 +01:00
Phil Sutter
8f1eae1b94
add generated files for profiling to clean list
2009-11-15 01:36:17 +01:00
Nikolas Garofil
038e182c38
argument of $cmdline_to_pid doesnt have to be the full commandline
2009-11-15 00:51:38 +01:00
Nikolas Garofil
7b6e01b869
fix last commit
2009-11-14 22:17:41 +01:00
Nikolas Garofil
fa459f0539
Make it possible to use other vars as arguments for the $pid-vars, add support for $pid_state_short, add support for $cmdline_to_pid
2009-11-14 22:07:54 +01:00
Cesare Tirabassi
e582acf1a0
Merge branch 'master' of git.omp.am:/home/omp/git/conky
2009-11-14 15:58:06 +01:00
Cesare Tirabassi
0ee5e9935a
Refactoring of commit 363cf1ab73
...
The problem with the original commit was that some session-managers set
stdin to /dev/null for the processes they launch, therefore the variable
wasn't very effective.
This commit change the variable conky_user_time to user_time.
This variable has a mandatory argument, a console identifier
(eg. tty7, pts/0, etc.).
Once called, this will list how long the user for the given console has been
logged in for.
This commit also allows multiple user_time to be specified for different
consoles, as well as correctly handle a conky restart.
2009-11-14 15:57:45 +01:00
Nikolas Garofil
1a4c2c61e8
Shrink proc.c
2009-11-14 15:08:41 +01:00
Nikolas Garofil
44de7fe6be
Support for $pid_state
2009-11-14 13:58:07 +01:00
Pavel Labath
6db3b5809d
Add middle_middle alignment, mostly for completeness
2009-11-13 21:35:49 +01:00
Nikolas Garofil
ab0b80e495
Added support for $pid_chroot
2009-11-13 16:54:40 +01:00
Cesare Tirabassi
f1272dbd31
Merge branch 'master' of git.omp.am:/home/omp/git/conky
2009-11-13 16:36:49 +01:00
Cesare Tirabassi
363cf1ab73
Add $conky_user_time (sf.net #2830919 )
...
The bug reporter asks if it is possible to add a variable giving the "current
user time" only, since the variable user_times reports the times for ALL
logged users.
AFAIK, the only info one can gather inside conky, is the login time for the
tty connected to conky's standard input.
This commit adds support for it (it should work on any posix compliant *nix).
Note that in coherence with the definition, the variable is called
conky_user_time (for a single user stand-alone machine used as a desktop
this would be the "current" user time).
2009-11-13 16:30:04 +01:00
Nikolas Garofil
e9d92ae717
Fix bug in $pid_openfiles
2009-11-13 16:29:44 +01:00
Phil Sutter
bde5845077
drop adt746x objects
...
This was really creepy stuff. Last updated in April, 2006 to work with
kernels > 2.6.12. I consider this "fobar" (fscking obsolete beyond all
recognition) and doubt anyone still uses this. If you do, blame me. :)
2009-11-13 00:47:23 +01:00
Nikolas Garofil
52df1d2bf2
Merge branch 'master' of ssh://git.omp.am/home/omp/git/conky
2009-11-13 00:38:13 +01:00
Nikolas Garofil
52629bef61
Added support for $pid_openfiles
2009-11-13 00:36:46 +01:00
Phil Sutter
8922603b91
entropy: outsource code
...
This patch ought to be small and simple ...
The reason why it's not is me wanting the entropy data out of struct
information. This means update_entropy() can not be used anymore, as it
uses this globally available object.
The solution I am presenting here is quite messy regarding header
includes. Hopefully this will go away soon as I plan on creating some
sort of "OS library" containing all OS specific routines and defining
macros for easier capability checking in the non-specific code. This on
the other hand means we'll need "wrappers" around OS specific objects,
but that's not as bad as it seems - having non-specific text objects
only will definitely clean up the code, and capabilities can be checked
where they should be.
2009-11-13 00:02:16 +01:00
Phil Sutter
e787870eb4
top: fix segfault for $if_running
...
The "name" field may be zero, which makes strcmp() freak out.
2009-11-13 00:02:16 +01:00
Nikolas Garofil
e26c9977f2
fix potential bugs in snprintf
2009-11-12 21:48:15 +01:00
Nikolas Garofil
1d0b68e60d
Fix building without C99
2009-11-12 21:33:57 +01:00
Nikolas Garofil
6c4f069f00
Added support for $pid_exe and $pid_stdin, $pid_stdout and $pid_stderr
2009-11-12 20:34:43 +01:00
Nikolas Garofil
6b20156a1b
Added support for $pid_environ_list
2009-11-12 15:42:18 +01:00
Nikolas Garofil
d595a65077
Add support for $pid_environ
2009-11-11 22:56:12 +01:00
Nikolas Garofil
cb96b3bcca
Add cwd to $pid and split into $pid_cmdline and $pid_cwd
2009-11-11 16:27:19 +01:00
Nikolas Garofil
aa761584db
fix previous commit
2009-11-11 13:44:50 +01:00
Nikolas Garofil
db99693091
fix tiny compile problem
2009-11-11 13:43:14 +01:00
Nikolas Garofil
65cf0439a0
Fix memleak and change literals to defines
2009-11-11 13:23:05 +01:00
Nikolas Garofil
8276da8777
Add proc.c and proc.h
2009-11-11 11:33:28 +01:00
Nikolas Garofil
46dd6ca513
Add support for ${pid cmdline}
2009-11-11 10:55:25 +01:00
Nikolas Garofil
827be3bde8
Fix $if_mpd_playing and $mpd_percent when you stop playing a song, thanks Sakari Matikka
2009-11-10 13:23:00 +01:00
Nikolas Garofil
ccbaf9ea89
Fix memleak
2009-11-10 00:15:30 +01:00
Nikolas Garofil
7025477402
Fix $scroll only scrolls once
2009-11-09 02:38:20 +01:00
Nikolas Garofil
e292dd5e28
Fix segfault and memleaks in curl
2009-11-08 21:49:28 +01:00
Phil Sutter
37071ccd8e
ifblock objects: fix bug for sub-object parsing ifblocks
...
When dropping the ifblock field of struct text_object, I short-sightedly
reused the sub field for holding the pointer to the matching else/endif.
This however doesn't work for objects parsing their own object list, as
they need the sub field for themselfs.
Since we have it, simply reuse the special_data field instead and hope
there won't ever be an object which is both special and ifblock. ;)
2009-11-08 20:20:47 +01:00
Phil Sutter
581c86f070
fix conversion bug when freeing exec objects
2009-11-08 20:20:47 +01:00
Nikolas Garofil
a1e199c85a
Fix building with metar but without xoap
2009-11-08 18:00:13 +01:00
Nikolas Garofil
ce99d1a782
Use a define for the maximum number of network devices
2009-11-07 23:46:46 +01:00
Nikolas Garofil
aad43bea8d
Added support for $threads and fixed $processes on Linux
2009-11-07 18:14:04 +01:00
Nikolas Garofil
1ed564fd0b
Revert "Added support for and fixed on Linux"
...
This reverts commit 43c7c0373b
.
2009-11-07 18:13:21 +01:00
Nikolas Garofil
43c7c0373b
Added support for and fixed on Linux
2009-11-07 18:06:07 +01:00
Nikolas Garofil
ff1fab20c2
Fix building with --disable-xft and add ncurses to the -v option
2009-11-07 15:32:03 +01:00
Nikolas Garofil
68ca9485da
Fix building with --disable-iostats
2009-11-07 13:21:47 +01:00
Nikolas Garofil
74145a7fef
Fix building with --disable-x11 --disable-lua --disable-ncurses
2009-11-07 12:21:48 +01:00
Phil Sutter
e909cdd4eb
scan_graph: allow giving a "hint" about a good scale value
...
This is more or less a temporary fix to restore the former behaviour. In
the long term objects will define a max value, which will be of use for
all kinds of meters.
2009-11-06 00:10:00 +01:00
Phil Sutter
c88d01af95
weather: fix this embarrassing bug
2009-11-05 22:27:34 +01:00
Phil Sutter
556751c8c9
top: drop problematic field totalmem
...
The field totalmem was formerly used to hold the percentage of used mem
by a process. So at update time, the field info.memmax was being
addressed, which is potentially being updated at the same time, As all
updating routines potentially run in parallel. Though there is an
(quite) easy fix for this: calculate the percentage upon object
printing. This works because conky synchronises all update routines
right before printing the result. (To omit locking on it's own.)
2009-11-03 23:24:09 +01:00
Phil Sutter
e08bc8fad7
enum special_types: define nonspecial for completeness
2009-11-03 23:23:23 +01:00
Phil Sutter
4dd54b3df6
if_gw: no need to free unused obj->data.s
2009-11-03 23:23:23 +01:00
Phil Sutter
f61d8d108f
text_object: completely remove the need for data.ifblock
2009-11-03 23:23:23 +01:00
Phil Sutter
9a770295d1
drop useless ifblock.str
2009-11-03 23:23:23 +01:00
Phil Sutter
66c187e7a1
no need to save the args passed to if_empty and if_match
2009-11-03 23:23:23 +01:00
Phil Sutter
7304378d73
drop a few unused fields from struct text_object
2009-11-03 23:23:23 +01:00
Phil Sutter
d9ec45b25d
drop struct text_object field pair, since it got unused due to latest commits
2009-11-03 23:23:23 +01:00
Phil Sutter
76b433c809
drop struct text_object field f
2009-11-03 23:23:23 +01:00
Phil Sutter
f98a360089
drop now unused SIZE_DEFAULTS macro
2009-11-03 23:23:23 +01:00
Phil Sutter
041059f1c2
specials: convert stippled_hr object to new style
2009-11-03 23:23:23 +01:00
Phil Sutter
3458db80aa
specials: convert tab object to new style
2009-11-03 23:23:23 +01:00
Phil Sutter
50e2b5961a
specials: convert gauge objects to new style
2009-11-03 23:23:23 +01:00
Phil Sutter
bbec0db498
specials: convert graph objects to new style
2009-11-03 23:23:23 +01:00
Phil Sutter
a4777c7c55
misc smaller fixes
2009-11-03 23:23:23 +01:00
Phil Sutter
22251dca51
specials: introduce dedicated per-object data and merge graph objects
2009-11-03 23:23:23 +01:00
Phil Sutter
0bed05997b
review load* code
2009-11-03 23:23:23 +01:00
Phil Sutter
42dfb7ac69
move loadavg and loadgraph code to common.c
2009-11-03 23:23:23 +01:00
Phil Sutter
63079a2075
local_mails: convert to generic object payload
...
This also includes a little header include cleanup.
2009-11-03 23:23:22 +01:00
Phil Sutter
90ed7d8a2c
mail: convert to generic object payload
2009-11-03 23:23:22 +01:00
Phil Sutter
35ecbb3330
mail: use a private common struct mail_s instead of info.mail
2009-11-03 23:23:22 +01:00
Phil Sutter
ac99833646
text_object: use field i instead of cpu_index
2009-11-03 23:23:22 +01:00
Phil Sutter
3a365bcd33
if_up: convert to generic object payload
2009-11-03 23:23:22 +01:00
Phil Sutter
2112b1f0ee
drop now unused sensor field
2009-11-03 23:23:22 +01:00
Phil Sutter
0de0047bdc
obsd_sensors: cleanup code (untested)
2009-11-03 23:23:22 +01:00
Phil Sutter
f2188a67a1
ibm: convert to generic object payload
2009-11-03 23:23:22 +01:00
Phil Sutter
c8f07daceb
net_stats: convert to generic object payload
2009-11-03 23:23:22 +01:00
Phil Sutter
0740e91911
diskio: convert to generic object payload
2009-11-03 23:23:22 +01:00
Phil Sutter
aa4d61d3d7
combine: convert to generic object payload
2009-11-03 23:23:22 +01:00
Phil Sutter
64ec783475
scroll: convert to generic object payload
2009-11-03 23:23:22 +01:00
Phil Sutter
bf9263bc5e
read_tcp: convert to generic object payload
2009-11-03 23:23:22 +01:00
Phil Sutter
b74e0494de
exec: convert to generic object payload
2009-11-03 23:23:22 +01:00
Phil Sutter
0dc60481cf
top: convert to generic object payload
2009-11-03 23:23:22 +01:00
Phil Sutter
4b0c1d3226
mboxscan: convert to generic object payload
2009-11-03 23:23:22 +01:00
Phil Sutter
dd36fc4caa
mixer: convert to generic object payload
2009-11-03 23:23:22 +01:00
Phil Sutter
c45decda5e
curl: convert to generic object payload
2009-11-03 23:23:22 +01:00
Phil Sutter
4716969cc6
weather objects: convert to generic object payload
2009-11-03 23:23:22 +01:00
Phil Sutter
046ae1dd61
rss: convert to generic object payload
2009-11-03 23:23:22 +01:00
Phil Sutter
9202a9da87
eve: convert to generic object payload
2009-11-03 23:23:22 +01:00
Phil Sutter
94ac89e091
sysfs objects: convert to generic object payload
2009-11-03 23:23:22 +01:00
Phil Sutter
d2be5980ca
tcp_portmon: convert to generic object payload
2009-11-03 23:23:22 +01:00
Phil Sutter
8d1640f30b
fs_*: convert to generic object payload
2009-11-03 23:23:22 +01:00
Phil Sutter
f31e5cefe7
fs_bar, fs_bar_free: convert to generic object payload
2009-11-03 23:23:22 +01:00
Phil Sutter
f6942c8c98
tailhead: convert to generic object payload
2009-11-03 23:23:22 +01:00
Phil Sutter
1d73d82b87
convert tztime to generic object payload
2009-11-03 23:23:22 +01:00
Phil Sutter
8165a91f0a
nvidia: convert to generic text object payload
2009-11-03 23:23:22 +01:00
Phil Sutter
eff3f75014
text_object: introduce a generic payload pointer
2009-11-03 23:23:22 +01:00
Phil Sutter
d1b2c7eac3
local_mails: put code to where it belongs
...
Note that the code does not only use a pre-processor generator for
defining the print functions, but also for their prototypes. Sadly, this
generated a conflict in mboxscan.c which this patch resolves, too.
2009-11-03 01:50:28 +01:00
Phil Sutter
fa9135f9df
mail: put imap and pop3 code to where it belongs
2009-11-03 01:50:28 +01:00
Phil Sutter
8b76d8fb60
net_stats: outsource network-related objects
2009-11-03 01:50:28 +01:00
Phil Sutter
9efa29be28
combine: outsource code
2009-11-03 01:50:28 +01:00
Phil Sutter
37658b540b
scroll: outsource code
2009-11-03 01:50:28 +01:00
Phil Sutter
24d9e8bf24
read_tcp: outsource code
2009-11-03 01:50:28 +01:00
Phil Sutter
7a168c377b
exec: put all exec-related stuff into it's own file
...
While here, also merge the execi and texeci fields of struct
text_object, so more common code can be shared in between.
2009-11-03 01:50:28 +01:00
Phil Sutter
2631f42820
ibm: put specific code to where it belongs
2009-11-03 01:50:28 +01:00
Phil Sutter
7fc1c801aa
gw_info: move code to where it belongs
2009-11-03 01:50:28 +01:00
Cesare Tirabassi
27a2a253a8
Fix indenting of last commit
2009-11-01 18:42:29 +01:00
Cesare Tirabassi
4ea99e27f1
Fix hwmon location for kernel >= 2.6.31 (closes sf: #2865628 )
...
In the linux kernel 2.6.31 and above, device data can either be in
/sys/class/hwmon/hwmonDEV or /sys/class/hwmon/hwmonDEV/device.
Just stat'ing for the latter doesn't work since it can exist but not contain
the required data (see https://bugs.launchpad.net/bugs/435571 for details).
The patch could be improved to keep in memory the right location of the data
on the user's system instead of trying each time, but, is it worth doing it?
2009-11-01 18:37:48 +01:00
Phil Sutter
f7f3b37807
rss.h: drop useless header include
2009-10-12 23:04:41 +02:00
Phil Sutter
d1ed9c8399
fix compiling in a messy way
...
A cleaner but more ugly solution would be to include text_object.h in
every header containing struct text_object definitions. But this
apparently triggers a big mess, since text_object.h itself includes
custom headers. Forward defining struct text_object is obviously the
mostly simple solution until there is a bigger header include review
cleaning it all up.
2009-10-12 23:00:06 +02:00
Phil Sutter
a106b52698
curl: put init and print code to where it belongs
...
This also fixes a bug in arg parsing, effectively forcing an interval to
be specified.
2009-10-12 21:33:02 +02:00
Phil Sutter
ad8dd36cb7
weather objects: move init and print code to weather.c
2009-10-12 21:33:02 +02:00
Phil Sutter
6a2f58a25c
rss: move init and print code into rss.c
2009-10-12 21:33:02 +02:00
Phil Sutter
ddca4aac68
spend some time with eve.{c,h}
...
* minimise core code hooks
* drop useless exporting of private functions (and make them static)
* reorder functions in eve.c so no prototypes are needed
* drop massive header include and add double include barrier in eve.h
2009-10-12 21:33:02 +02:00
Phil Sutter
700a32b2e7
sysfs objects: merge init and print routines
2009-10-12 21:33:02 +02:00
Phil Sutter
da7876468f
tcp_portmon: drop useless function pointer cast, use OBJ_ARG
2009-10-12 21:33:02 +02:00
Phil Sutter
4d70cf07b8
fs_bar, fs_bar_free: merge init and print routines
2009-10-12 21:33:02 +02:00
Phil Sutter
b9a28c37a8
tail, head: use OBJ_ARG to simplify code
2009-10-12 21:33:02 +02:00
Phil Sutter
a529ac52de
hddtemp: drop dead code (custom per-object data)
2009-10-12 21:33:02 +02:00
Cesare Tirabassi
066af067f0
Fix global info.desktop variables were incorrectly freed, sf #2876647
2009-10-12 13:38:48 +02:00
Phil Sutter
ea92e63a44
tztime: fix argument parsing bug, clarify docs
2009-10-04 04:03:21 +02:00
Phil Sutter
1e893ec6e3
iconv: outsource code into it's own file
...
While testing, I found two already existing bugs:
* the variable 'a' passed to iconv_convert() needs to be passed by
reference in order to allow for the desired side effect.
* Somehow the trailing junk after an iconv_conversion to a shorter
string messes things up (and gets printed!). I couldn't exactly find
out why this happens, but setting (*p) = 0; solves this problem.
2009-10-04 03:41:45 +02:00
Phil Sutter
adf9d23927
outsource time, utime and tztime into a separate file
2009-10-04 03:24:04 +02:00
Phil Sutter
e3e77ce75e
move the SIZE_DEFAULTS() macro to where it belongs to
2009-10-04 03:24:04 +02:00
Brenden Matthews
584d05d2ad
Add the -p/--pause command line option.
2009-10-03 14:26:39 -07:00
Brenden Matthews
88a8799bf5
Improve IMAP/POP3 code, fix compiler error.
2009-09-30 18:06:18 -07:00
Brenden Matthews
7fc4d40eb2
Allow spaces in mail folder names for pop/imap.
...
For example, you can specify "-f '[Gmail]/All Mail'" in your mail args
to view all mails in your Google mail IMAP folder.
2009-09-27 10:40:06 -07:00
Brenden Matthews
4a0676d4d0
Fix IMAP IDLE with Google's IMAP service.
2009-09-26 18:38:55 -07:00
Pavel Labath
28978461a7
Put OBJ(image) in $ifdefs
...
so that conky produces more meaningful error message when compiled without imlib
2009-09-25 14:43:46 +02:00
Pavel Labath
bfda285567
Make -d switch work again
...
-d was broken because fork-to-background was done after the update thread creation, so the
threads ended up in the wrong process. This delays the thread creation until after the fork.
2009-09-22 18:19:08 +02:00
Phil Sutter
cfccea4079
do not block when reading inotify_fd
...
Originally, I was experiencing sporadic lockups when reading inotify_fd;
which is strange, since it is protected by select(). This should fix it
despite of the original problem.
2009-09-20 19:04:45 +02:00
Phil Sutter
d163293f66
index processes in a hash table for faster lookup
2009-09-20 16:10:05 +02:00
Pavel Labath
596449c902
It feels much better to let the thread exit voluntarily instead of violently killing it
2009-09-20 14:38:57 +02:00
Phil Sutter
d45aa362b0
fixup for ncurses output
2009-09-20 13:52:46 +02:00
Phil Sutter
4823b1f428
drop duplicate code
2009-09-20 13:18:10 +02:00
Phil Sutter
3569ece513
minor indentation fixup
2009-09-20 13:16:43 +02:00
Phil Sutter
e391fa40a9
this was looking wrong
2009-09-20 13:16:43 +02:00
Phil Sutter
15e262a3ca
minor simplification of get_string_width_special()
2009-09-20 13:16:20 +02:00
Phil Sutter
4840de39cd
update machinery: keep threads persistent
...
Create each thread upon registration of the callback function, then use
semaphores to signal when it's time to update and when updating is
finished.
Many thanks to pavelo who originally came up with the idea for this.
2009-09-20 13:14:08 +02:00
Phil Sutter
2cb45085e0
simplify get_string_width() a bit
2009-09-20 13:12:56 +02:00
Pavel Labath
7ad3e34e34
OBJ -> OBJ_ARG; apparently forgotten in 9f22ba
2009-09-15 23:54:31 +02:00
Phil Sutter
fea72bd8f8
top.c: fix for unsigned underflow
...
Yes, I also thought these are monotonic counters. But it seems like they
are not, at least sometimes the value decreases by 1 leading to a very
very high cpu usage percentage being printed.
2009-09-15 23:16:39 +02:00
Phil Sutter
7fa59c6c90
better zero out allocated memory
2009-09-15 23:16:39 +02:00
Phil Sutter
b7b9329e38
update machinery: run each update callback in it's own thread
2009-09-15 23:16:39 +02:00
Phil Sutter
925ac2b7ba
read_tcp: get rid of heavy indenting
2009-09-15 23:16:35 +02:00
Phil Sutter
9f22bab657
core: add OBJ_ARG() and OBJ_IF_ARG() to force arguments
...
These macros can be used just like their OBJ() and OBJ_IF()
counterparts, just that they bail out hard when arg is unset. While
here, also cleanup the macro definition by using __* macros and fully
cleanup the macro namespace when the job is done.
Although this makes conky kind of less robust when it comes to
configuration errors, aborting is the right thing to do to avoid
ambiguity between unknown text objects.
2009-09-15 23:12:15 +02:00
Phil Sutter
77cc646080
imlib2: don't flood warnings on non-existing images
2009-09-15 23:12:15 +02:00
Phil Sutter
f33affdc03
do not unconditionally overwrite a variable after conditionally setting it
2009-09-15 23:12:15 +02:00
Phil Sutter
ed3d73c094
minor indenting fixup
2009-09-15 23:12:15 +02:00
Phil Sutter
fa896bec98
apcupsd: drop init_apcupsd() since it was called at the wrong place
...
Normally, this is not enough reason to remove code, but in this case it
means that either the tester always had $nvidia (if enabled) or $combine
also in her setup, or it was working without (which I guess, since there
is duplicate code in update_apcupsd()).
2009-09-15 23:12:15 +02:00
Phil Sutter
9dd360ecdb
update machinery: add some documentation
2009-09-15 23:12:15 +02:00
Pavel Labath
09c0bccf55
Move vi modelines closer to the beginning, so they're more likely to be actually used.
2009-09-12 12:50:51 +02:00
Phil Sutter
a00bd4ad5e
update machinery: fix accidential naming conflict
2009-09-09 22:56:10 +02:00
Phil Sutter
466a253a8c
update machinery: fix for update_stat() on linux
2009-09-09 22:52:09 +02:00
Pavel Labath
3736b141aa
Fix window width calculation when $lua returns newlines
...
I just hope it doesn't break anything.
2009-09-09 21:15:18 +02:00
Phil Sutter
f33bcb36ef
update machinery: fix top objects
...
This is a bit messy, but since the top update stuff could use a rewrite
anyway, this should do.
2009-09-07 01:49:44 +02:00
Phil Sutter
d32879faaa
update machinery: let CALLBACK() die again
...
There are no INFO_* variables any more, so the argument passed to OBJ()
is always a function pointer or zero. By checking the argument passed in
add_update_callback(), the branch in the OBJ() macro can be dropped,
too.
2009-09-07 01:22:16 +02:00
Phil Sutter
e83fb84c55
update machinery: clean up
...
* Remove leftover INFO_* values from object definitions which didn't
trigger anything.
* Drop the whole INFO_* enum as it's values are not used anymore.
2009-09-07 01:12:11 +02:00
Phil Sutter
e044093735
update machinery: complete transition
...
* Drop all need_mask alterations (no idea why there were here at all,
but surely not sane since they are missing in the non-linux
functions).
* Drop the update delay for update_meminfo(), as parsing /proc should
not lead to abnormal overhead.
* Check for x_initialised from inside update_x11info(), so we can call
it unconditionally.
2009-09-07 01:05:33 +02:00
Phil Sutter
d7c7f06aca
rework the update machinery to use callbacks
...
Besides improving performance when updating stuff, we ideally have no
text object specific code in update_stuff() anymore (aside some
leftovers).
The macros in construct_text_object() have gotten a bit crazier than
they were before:
* using CALLBACK(&func) instead of an INFO_* parameter to OBJ() will
make it add the given callback to the list of callbacks to be iterated
over at each update interval.
* BEWARE: the above assumes function pointer values to be > 0!
* This implicitly fixes a bug in the code: passing 0 as INFO_* value
led to selecting INFO_MAIL (1 << 0 == 1).
* Now it would select INFO_CPU (== 0), which got unused and therefore is
not a problem at all (the 0 value should be unused in enums anyway).
This needs some more work, then we should be able to drop the whole
INFO_* enum. Then CALLBACK() can die again and with it goes the ugly
casting stuff done to distinguish callbacks from INFO_* values.
2009-09-07 00:36:02 +02:00
Phil Sutter
8cf8c4dac3
move the static last_*_update variables into the function
2009-09-06 21:57:19 +02:00
Phil Sutter
5a3b7c074b
Rewrite hddtemp support for better scaling
...
Instead of connecting once for each object, have a central update
routine (limiting support to only a single hddtemp daemon to connect
to).
2009-09-06 21:53:53 +02:00
Phil Sutter
56142a7cd4
cleanup src/Makefile.am
...
Since the files mentioned in conky_SOURCES are already included in the
distfile, no need to specify them again in EXTRA_DIST.
2009-09-05 03:30:12 +02:00
Phil Sutter
12ab00cd2e
move the ncurses.h include from conky.h to core.c
...
Fixes some namespace error with libmpdclient.c.
2009-09-04 00:08:57 +02:00
Phil Sutter
ff199355f6
outsource the whole template object machinery
2009-09-04 00:08:17 +02:00
Cesare Tirabassi
75ce3b259b
Fix if_running not working on linux when a top flavour is not running
2009-09-03 23:13:14 +02:00
Cesare Tirabassi
08e40c1fe8
Don't abort diskio objects initialisation if the given device doesn't exist, we could have these objects iffed; closes LP: #405188
2009-08-14 18:32:39 +02:00
Cesare Tirabassi
bf1dea5e4e
Precised last two weather_forecast xpaths
2009-08-11 16:10:35 +02:00
Cesare Tirabassi
141c229afc
Add day and date data_type to
2009-08-10 22:46:21 +02:00
Nikolas Garofil
bfb065502d
Add global ncurses headerfile and make sure timeout in mailcode doesn't clash with timeout from ncurses
2009-08-08 03:20:47 +02:00
Nikolas Garofil
74b61f9730
Undo adding local ncurses.h header-file added by b4b0228d09
.
...
The headerfile used globally should be used instead of one in the local dir.
If conky can't find it, it should be fixed in configure.ac.in or Makefile.am,
and not in the code.
2009-08-08 02:54:07 +02:00
Nikolas Garofil
834804c265
Fix: Add header needed for read_tcp
2009-08-08 02:49:28 +02:00
Phil Sutter
b4b0228d09
include ncurses.h in core.c
2009-08-08 00:28:26 +02:00
Brenden Matthews
043cf686c6
Revert "Uhh..ansohus"
...
This reverts commit 9827726ae5
.
Or this.
2009-08-07 01:24:24 -06:00
Brenden Matthews
d7838b87bf
Revert "Merge branch 'master' of git.omp.am:/home/omp/git/conky"
...
This reverts commit d710ea8b9d
, reversing
changes made to 9827726ae5
.
Also didn't meant to push this.
2009-08-07 01:23:27 -06:00
Brenden Matthews
098e28598f
Revert "auesnthaeou"
...
This reverts commit 70adc04fc2
.
Oops, didn't mean to push this. I'll start a new branch now (so I don't
do this again...).
2009-08-07 01:21:56 -06:00
Brenden Matthews
70adc04fc2
auesnthaeou
2009-08-06 21:56:40 -06:00
Brenden Matthews
d710ea8b9d
Merge branch 'master' of git.omp.am:/home/omp/git/conky
...
Conflicts:
src/conky.h
2009-08-06 14:21:50 -06:00
Nikolas Garofil
db1c0061b0
Fix: rename timeout in mpdcode to prevent clashes with timeout in ncurses
2009-08-06 16:35:06 +02:00
Nikolas Garofil
157537fc30
Fix buildproblems introduced by 3f4127080e
. inet.h is used by read_tcp and timeout is renamed to prevent clashes with timeout in ncurses
2009-08-06 15:28:07 +02:00
Brenden Matthews
9827726ae5
Uhh..ansohus
2009-08-06 00:54:40 -06:00
Brenden Matthews
3f4127080e
Started on breaking up conky.c.
...
These changes will likely result in breakage, particularly with
different features enabled/disabled.
2009-08-05 16:46:51 -06:00
Brenden Matthews
c29301d02a
Move xdbe swap stuff into x11.c.
2009-08-05 15:41:56 -06:00
Brenden Matthews
4e88abde40
Finish c60209f6d0
.
2009-08-05 15:33:41 -06:00
Brenden Matthews
c60209f6d0
Swap Xdbe buffers when resizing window.
2009-08-05 15:21:59 -06:00
Brenden Matthews
2904720a58
Don't clear entire X window, just drawing area.
2009-08-05 14:40:53 -06:00
Brenden Matthews
7b93ad8071
Don't pass mouse clicks when window is desktop type.
2009-08-05 14:35:33 -06:00
Brenden Matthews
2115d925e4
Code formatting.
2009-08-05 14:35:20 -06:00
Cesare Tirabassi
4d35595e5e
fix compilation error due to initial declaration in for loop being not compliant with C99
2009-08-05 17:55:09 +02:00
Cesare Tirabassi
0cd29676c0
Add xoap error handler to weather-forecast too
2009-08-05 17:50:24 +02:00
Cesare Tirabassi
e16511be02
Set refresh period for the 5 days forecast to 3 and a half hours, in accordance to Exhibit B of EULA
2009-08-05 17:26:25 +02:00
Brenden Matthews
f10ffe07c4
Fix invalid call to close().
2009-08-04 23:06:13 -06:00
Brenden Matthews
fbf746e53c
Fix broken RSS code.
2009-08-04 22:56:19 -06:00
Brenden Matthews
e41f3e4f7b
Fix parsing of XOAP xml.
...
Also made the XOAP cloud condition match that of the NOAA stuff
(lowercase).
2009-08-04 21:15:08 -06:00
Nikolas Garofil
c99e092246
Gcc complains too much when build without X11 and NCurses
2009-08-04 22:13:06 +02:00
Cesare Tirabassi
fc54981da8
Fix major memory leak in prss.c
2009-08-04 14:28:24 +02:00
Nikolas Garofil
d69b3b56f0
Fix: reloading turned ncurses off
2009-08-04 13:46:59 +02:00
Brenden Matthews
aec2ac5448
Let's try __attribute__ this time for unused vars.
2009-08-03 13:48:18 -06:00
Brenden Matthews
3b13ae971e
Do the UNUSED() thing another way.
2009-08-03 13:34:47 -06:00
Brenden Matthews
581f59528b
Spell 'of' correctly.
2009-08-03 12:57:22 -06:00
Brenden Matthews
efa5a211b7
Better fix for unused var problem.
2009-08-03 12:56:41 -06:00
Brenden Matthews
ecfcfacce3
Fix compiler warning.
2009-08-03 12:54:21 -06:00
Brenden Matthews
aa142b0941
Revert "Compilation fix for weather stuff."
...
This reverts commit 63229dac63
.
2009-08-03 12:52:10 -06:00
Brenden Matthews
63229dac63
Compilation fix for weather stuff.
2009-08-03 12:48:52 -06:00
Brenden Matthews
05330f24a3
Merge branch 'master' of git.omp.am:/home/omp/git/conky
...
Conflicts:
src/conky.c
2009-08-03 12:41:07 -06:00
Brenden Matthews
51ddee12dd
Fix imlib2 context.
2009-08-03 12:39:44 -06:00
Cesare Tirabassi
2118fc5889
Merge branch 'master' into weather-forecast
2009-08-03 19:59:36 +02:00
Cesare Tirabassi
36ae626ab8
Add parser initialisation and cleanup
2009-08-03 19:58:21 +02:00
Nikolas Garofil
37e2bb471b
Support for in ncurses
2009-08-03 19:36:47 +02:00
Cesare Tirabassi
4fe70ad0e6
weather: change hardcoded constant 5 to FORECAST_DAYS macro
2009-08-03 11:49:26 +02:00
Cesare Tirabassi
d707d536bb
Fix bad memory allocation
2009-08-03 00:24:39 +02:00
Cesare Tirabassi
14b7acdab6
Add weather_forecast object
2009-08-02 23:54:44 +02:00
Brenden Matthews
dbf3448031
Update conky_window Lua table when it changes.
2009-08-01 15:11:18 -06:00
Brenden Matthews
47b2869028
Code formatting.
2009-08-01 15:01:00 -06:00
Brenden Matthews
358a2b989e
Add lua_startup_hook.
2009-08-01 14:36:38 -06:00
Brenden Matthews
41aed41e35
Add lua_shutdown_hook.
2009-08-01 14:30:14 -06:00
Nikolas Garofil
44b82311b9
Added support for out_to_ncurses
...
All ERR()'s are renamed to NORM_ERR() and box to mbox so that they don't
clash with things in ncurses.h .
Ncurses is enabled by default when building conky but can be disabled with
--disable-ncurses .
At the moment configure doesn't check if ncurses is actually available.
I'm adding support for ncurses so that we can make as much things as possible
that are only available in X11 also available in console in the future.
2009-08-01 20:45:43 +02:00
Nikolas Garofil
763ae568a7
Fix reloading config after 7ff2a71aa0
2009-08-01 12:14:10 +02:00
Cesare Tirabassi
01e66c7f8c
Bug fix: make -X,--display actually work, improve error message if display not found
2009-08-01 09:34:21 +02:00
Nikolas Garofil
7ff2a71aa0
Added $include var to load configfiles inside of other configfiles
2009-07-31 15:28:55 +02:00
Cesare Tirabassi
8af1f24624
minor fix to allow out-of-tree builds
2009-07-31 13:50:33 +02:00
Brenden Matthews
be145bd55d
Removed alias config option due to brokenness.
...
The alias option was broken by fb8ccd7a05
,
and it seems like trying to make it work again will only result in
breakage for env var substitution anyway.
2009-07-31 00:33:06 -06:00
Cesare Tirabassi
38e544ee25
weather: add icon data_type for xoap
2009-07-29 22:22:24 +02:00
Nikolas Garofil
8f3150d8f6
Merge branch 'master' of ssh://git.omp.am/home/omp/git/conky
2009-07-29 21:27:19 +02:00
Nikolas Garofil
9ad3b9d8bc
Fix: make sure 51c928a8ef
works when programs terminate by themselves
2009-07-29 21:27:00 +02:00
Cesare Tirabassi
7bfff20e5d
Merge branch 'master' of git.omp.am:/home/omp/git/conky
2009-07-29 18:04:57 +02:00
Cesare Tirabassi
580fa3a52d
correct typo in error message
2009-07-29 18:04:34 +02:00
Nikolas Garofil
51c928a8ef
Fix: kill zombies without breaking b963c2827f
2009-07-29 11:43:16 +02:00
Cesare Tirabassi
81c691d15a
add emacs indentation variables to source files in line with current vim settings
2009-07-28 23:44:22 +02:00
Brenden Matthews
ec517ecb26
Remove deprecated stuff from docs and conky.c (for 1.7.3).
2009-07-28 12:43:45 -06:00
Brenden Matthews
da4b542ae6
Added some Lua API stuff.
...
Added conky_set_update_interval() API call, which allows you to change
Conky's update interval from a Lua script. Added the 'conky_info' table
to global Lua context, which still needs populating with stuff (right
now it only contains the current update interval and the system uptime).
2009-07-28 12:38:43 -06:00
Nikolas Garofil
e124064892
Fix: Always include stuff that used to use popen because it's now using pid_popen
2009-07-28 15:59:17 +02:00
Brenden Matthews
6c6711aa6d
Fix problem with invalid window props?
...
We should check to make sure the atom actually exists before trying to
retrieve the property.
2009-07-27 21:01:55 -06:00
Brenden Matthews
73eaf0cfc3
Clean up x11.c a bit.
2009-07-27 15:34:06 -06:00
Cesare Tirabassi
da06200e43
Fix user_times bug (launchpad #405188 ).
2009-07-27 15:09:18 -06:00
Brenden Matthews
dd6133b055
Fix linking error with Lua extras disabled.
2009-07-27 15:03:21 -06:00
Brenden Matthews
d97cd93a1c
Add vim modelines.
2009-07-27 14:47:31 -06:00
Brenden Matthews
73d36a59c0
Be more intelligent about handling tolua++ user types.
2009-07-27 14:07:36 -06:00
Nikolas Garofil
ca0f8f8712
Fix: If there is no battery then we don't care about the status
2009-07-27 13:34:20 +02:00
Nikolas Garofil
3e41b36fdf
use EXIT_SUCCESS and EXIT_FAILURE instead of 0 and 1 when calling exit
2009-07-27 01:29:57 +02:00
Cesare Tirabassi
ffe5d5f104
Merge branch 'master' of git.omp.am:/home/omp/git/conky
2009-07-26 13:04:11 +02:00
Cesare Tirabassi
94cd289aec
clean the stack when llua_update_window_table is called with a window table not yet populated
2009-07-26 13:03:41 +02:00
Nikolas Garofil
b963c2827f
Fix: conky waited indefinitely on programs started with \$exec-alike vars if those programs don't quit.
...
Conky now kills the program when it should start the next update, this makes using things like tail with
the -f option possible in a \$exec.
I am not pushing this to 1.7.2 because this is a pretty big change in the code and it is not really
a bugfix but more a usability-problem-fix (if that term would exist).
2009-07-26 02:26:22 +02:00
Nikolas Garofil
4d37d021e1
Handle if popen should fail
2009-07-25 14:36:55 +02:00
Nikolas Garofil
febc5306e2
Don't place conky_ in front of lua functionnames if it's already there
2009-07-25 12:03:09 +02:00
Nikolas Garofil
7ce38ecf09
Fix: Make sure lua works without X11
2009-07-25 02:42:31 +02:00
Nikolas Garofil
ca04b9a3c7
just making bdf5e87c92
easier to read
2009-07-24 16:17:03 +02:00
Cesare Tirabassi
bdf5e87c92
workaround to fix feed_title being processed when not yet parsed
2009-07-24 14:48:54 +02:00
Cesare Tirabassi
0be6e37e07
Fixed parsing of rss parameters (last 2 are optional) and typo in rss.c; there is still a problem with feed_titlesince data->title doesn't get filled before processing
2009-07-24 13:07:20 +02:00
Nikolas Garofil
381b47a0a9
Don't do useless checks
2009-07-24 12:39:48 +02:00
Nikolas Garofil
875c7c3129
Support for update_interval_on_battery
2009-07-24 12:06:44 +02:00
Nikolas Garofil
ce8d124ce6
Merge branch 'master' of ssh://git.omp.am/home/omp/git/conky
2009-07-24 11:45:33 +02:00
Nikolas Garofil
44ca4647b8
bugfix
2009-07-24 11:44:17 +02:00
Cesare Tirabassi
0081fcab60
Merge branch 'master' of git.omp.am:/home/omp/git/conky
2009-07-24 11:32:02 +02:00
Cesare Tirabassi
f5c8964510
Revert "the why recasting when you can simply declare it commit ..."
...
This reverts commit b2a30ea478
.
2009-07-24 11:30:27 +02:00
Nikolas Garofil
3322b2a9a9
Merge branch 'master' of ssh://git.omp.am/home/omp/git/conky
2009-07-24 11:12:35 +02:00
Nikolas Garofil
feedc8e7fa
Fix unclosed file in get_battery_stuff
2009-07-24 11:09:00 +02:00
Cesare Tirabassi
b2a30ea478
the why recasting when you can simply declare it commit ...
2009-07-23 23:58:27 +02:00
Cesare Tirabassi
d349fe56b2
Changed xoap parsing method to xpath, in preparation to include forecast data
2009-07-23 23:46:23 +02:00
Nikolas Garofil
922db9af82
Fix CRIT_ERR everywhere
2009-07-23 20:30:53 +02:00
Nikolas Garofil
7e7a193b74
Fix memleak in $weather
2009-07-23 18:50:39 +02:00
Nikolas Garofil
03a0e8ae19
Fix bug SF ID 2814810 (wrong output with execp and execpi)
2009-07-23 13:33:49 +02:00
Nikolas Garofil
ccd51857c1
Let $tail and $head work with FIFOs again (was disabled by commit 41a7cffbe7
), and fix memory bug when to_real_path is used in init_tailhead
2009-07-22 22:08:31 +02:00
Nikolas Garofil
41a7cffbe7
Fix bug with SF id 2808272 (tail and head)
...
To fix this bug the tail and head code was rewritten, everything should still
work except tailing a FIFO instead of a normal head.
2009-07-21 23:41:47 +02:00
Nikolas Garofil
caf0731565
Fix multiline stuff when build with X11 but output_to_x turned off.
...
This commit reverts 725a3ba43a
and fixes 5967d28511
2009-07-21 12:39:09 +02:00
Brenden Matthews
e973de66cf
Fix multiline stuff without X11.
2009-07-20 20:11:33 -06:00
Brenden Matthews
725a3ba43a
Revert "Fix multiline strings displayed on 1 line when output to x is not used"
...
This reverts commit 5967d28511
.
2009-07-20 17:46:22 -06:00
Nikolas Garofil
5967d28511
Fix multiline strings displayed on 1 line when output to x is not used
2009-07-21 00:47:02 +02:00
Brenden Matthews
9cda78c023
Clarify weather opts, refactor some weather code.
2009-07-20 13:17:44 -06:00
Brenden Matthews
f169e0e071
Actually apply c1cf1232e0
.
2009-07-20 12:40:32 -06:00
Brenden Matthews
38015c6600
Document curl stuff better.
2009-07-20 12:04:53 -06:00
Nikos Ntarmos
739e47f9ec
Teach freebsd.c to use the new CRIT_ERR format
...
Signed-off-by: Nikos Ntarmos <ntarmos@cs.uoi.gr>
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-07-20 11:51:02 -06:00
Brenden Matthews
d3013bc410
Better argument handling for rss/curl/weather.
2009-07-20 09:59:31 -06:00
Nikolas Garofil
911eb4dc59
Include timed_thread.h when needed
2009-07-20 17:42:17 +02:00
Brenden Matthews
961274bc56
Oops, add missing files.
2009-07-20 09:21:33 -06:00
Brenden Matthews
f46eb1b6cb
Fix minor memleak.
2009-07-20 00:40:23 -06:00
Brenden Matthews
64394fa7da
Merge branch 'master' of git.omp.am:/home/omp/git/conky
...
Conflicts:
configure.ac.in
2009-07-19 23:45:55 -06:00
Brenden Matthews
c05c157ead
Overhauled RSS and weather, added $curl.
...
I've taken the curl stuff out of weather and RSS and moved it into it's
own entity. It should be easier to create curl-based objects if needed
now.
2009-07-19 23:43:36 -06:00
Nikolas Garofil
09d41cb0b6
Fix building without X11 support broke after commits f1c47e5fc4
and 670e9a0eb1
2009-07-20 01:02:27 +02:00
Cesare Tirabassi
ba414d8ab8
fix out-of-tree builds
2009-07-20 00:43:41 +02:00
Brenden Matthews
80a71ea8bd
Handle curl errors better (in weather and rss).
2009-07-19 15:28:19 -06:00
Brenden Matthews
e76f0c8587
Exit properly when forking.
2009-07-19 14:55:41 -06:00
Nikolas Garofil
4c41ec843a
fix hardcoding
2009-07-19 21:56:07 +02:00
Nikolas Garofil
f1c47e5fc4
Fix instead of workaround for d0edfa7004
2009-07-19 21:28:14 +02:00
Brenden Matthews
4139ec096f
Code formatting.
2009-07-19 12:12:42 -06:00
Brenden Matthews
90932b87e1
Update MPD elapsed/progress when stopped.
2009-07-19 11:59:20 -06:00
Cesare Tirabassi
50fd16d8bd
add XOAP to list of compiled-in features, if enabled
2009-07-19 18:14:22 +02:00
Nikolas Garofil
d0edfa7004
Workaround for bug SF id 2819128 ($color inside $scroll disabled)
2009-07-19 00:36:05 +02:00
Brenden Matthews
1f1b846a2d
Specials can be within multi-line objects.
2009-07-18 14:25:57 -06:00
Brenden Matthews
52ad674e51
Substitute newlines for everything but text.
2009-07-18 14:00:02 -06:00
Brenden Matthews
9c4ebef376
Oops, fix multiline stuff.
2009-07-18 13:49:52 -06:00
Brenden Matthews
670e9a0eb1
Multiline alignment support, some other misc stuff.
...
Added support for X alignment across multi-lined objects (i.e., using
$alignr with $exec). This may be a bit buggy. Disabled OpenMP code
until GCC's implementation stabilizes (it's causing too many problems).
A couple Lua API changes.
2009-07-18 13:46:36 -06:00
Cesare Tirabassi
5eef83d90a
add compilation switch --enable-xoap to be able to use www.weather.com as a source of weather data
2009-07-18 21:29:27 +02:00
Cesare Tirabassi
3bb9b4b6b5
Revert "Undid last 3 commits, see rest of the comment for the reason:"
...
First of all, we may or may not agree, but I consider reverting my
commits without prior discussion as a minimum unpolite.
I also don't like sites that oblige to register, thats the very reason
why I went with noaa first (and why I use that myself).
Howver, weather.com has a couple of nice features forom an user
viewpoint:
1. Their icons can be used to add a visual quality to the weather
report.
2. They have forecast data, which is not possible to have with noaa
(using TAF its an option, but its going to be very difficult and will
be limited in time and scope).
Nobody is obliged to do anything, people who likes noaa will use noaa,
people that don't mind register or wants the additional benefit will use
weather.com.
Having libxms2 as a dragged depends is, first of all, also with other
options (rss and eve), second we can try to work around it with an
additional compilation flag if really deemed necessary.
This reverts commit d872562942
.
2009-07-18 19:13:37 +02:00
Nikolas Garofil
d872562942
Undid last 3 commits, see rest of the comment for the reason:
...
I am not really comfortable with adding support to the conky-code
for sites that only work when you register, that's more something
for in a script.
But the biggest reason I undid the commits is that it is now
impossible to compile conky with support for weather if you don't
have the xml libs installed. Users used to be able to compile with
support for weather (using the other site) without xml2.
If you really want to include this other site in the conky code
then split WEATHER in WEATHERCOM and WEATHERNOAA (altough my personal
opinion is that weather.com should only be supported with scripts)
2009-07-18 16:22:43 +02:00
Cesare Tirabassi
7b38e810f2
add one missing ifdef to conditionally compile weather code
2009-07-18 16:07:17 +02:00
Cesare Tirabassi
806b840646
Merge branch 'master' of git.omp.am:/home/omp/git/conky
2009-07-18 16:00:49 +02:00
Cesare Tirabassi
46fc4a0564
Added www.weather.com as an additional source of weather data
2009-07-18 15:59:43 +02:00
Nikolas Garofil
4284490080
If nothing is read, n1 and n2 are not guaranteed to be 0
2009-07-18 11:37:15 +02:00
Nikolas Garofil
b94569b27b
Fix reloading config without X11
2009-07-18 10:49:16 +02:00
Cesare Tirabassi
cba36f279b
weather: use expf if --enable_math is given, otherwise use fast 3rd order approximation
2009-07-18 07:57:04 +02:00
Nikolas Garofil
85deafa500
Fix bug in $scroll (if there were only 2 args the 2nd couldn't be numerical)
2009-07-18 01:15:09 +02:00
Nikolas Garofil
e905c7d4f1
Fix building without X11 after commit 20d4c4370a
2009-07-17 18:37:46 +02:00
Nikolas Garofil
20d4c4370a
Fix memleaks when reloading configuration and place same parts of main() and reload_config() in a seperate function
2009-07-17 18:01:41 +02:00
Nikolas Garofil
06de5573e8
Fix a lot of unimportant memleaks caused by a CRIT_ERR
2009-07-16 20:28:23 +02:00
Nikolas Garofil
63a8c677b3
Show warnings when not running in X and vars like desktop or monitor are used
2009-07-16 00:31:22 +02:00
Nikolas Garofil
4ec308ef12
Fix freeing unregistered mem when build when running without X
2009-07-15 23:55:22 +02:00
Nikolas Garofil
4c241bbf16
Fix all memleaks that are clearly visible,
...
the default config should now run without memleaks, valgrind will
still report memleaks caused by the own_window-lines and the xft-lines
(in some cases) but those are caused by code that's not part of conky
2009-07-15 16:33:18 +02:00
Nikolas Garofil
4addf71241
Make 16768a5ad4
C90-compliant
2009-07-14 19:17:14 +02:00
Cesare Tirabassi
1e5bc370e4
Merge branch 'master' of git.omp.am:/home/omp/git/conky
2009-07-14 18:47:00 +02:00
Cesare Tirabassi
16768a5ad4
Fix Property Change Events are passes also to OWN_WINDOW
2009-07-14 18:46:15 +02:00
Nikolas Garofil
cd92949e67
Fix strange effects on desktop caused by 4a14668772
2009-07-14 18:10:43 +02:00
Nikolas Garofil
cfa94a967b
Fix memleaks introduced by g7bbde2b
2009-07-14 18:05:49 +02:00
Nikolas Garofil
d75fb18bf8
Fix building with strict compilers
2009-07-14 17:43:27 +02:00
Cesare Tirabassi
7bbde2be73
refactored desktop info code so that its only called on X property events; TO DO doesn't work with own_window
2009-07-14 16:57:51 +02:00
Nikolas Garofil
4a14668772
Fix a part of the memleaks in the X-related code,
...
if you remove all lines above TEXT in defconfig.h,
then it should run without memleaks.
2009-07-14 16:07:33 +02:00
Nikolas Garofil
c924bbe194
Fix memleaks when running with total_run_times
2009-07-14 12:47:24 +02:00
Brenden Matthews
0352b96f39
Use OBJ_THREAD() for weather, get rid of pointless return.
2009-07-13 16:11:21 -06:00
Brenden Matthews
73194dee89
Merge branch 'master' of git.omp.am:/home/omp/git/conky
2009-07-13 15:21:42 -06:00
Brenden Matthews
74c19cf8e4
Fix minor $weather memleak.
2009-07-13 15:21:25 -06:00
Cesare Tirabassi
602edfea15
Fix compilation with --disable-own-window (sf.net #2820716 )
2009-07-13 23:19:32 +02:00
Nikolas Garofil
ed4d2ce0b1
Remove old,unused desktop-finding code
2009-07-13 17:32:33 +02:00
Nikolas Garofil
448476317f
Fix minor memleak (fonts)
2009-07-13 15:04:57 +02:00
Cesare Tirabassi
6793959916
weather: removed constraints of 3 locations per uri from docs; corrected possible buffer overflow
2009-07-13 11:31:20 +02:00
Brenden Matthews
e1011c0d13
Refactor some of the new weather code, fix docs.
...
I moved the weather stuff into its own thread, and also fixed up some
abuse of <simplelist> formatting throughout the docs. Hopefully we can
keep things a little more uniform from now on.
2009-07-12 23:31:57 -06:00
Brenden Matthews
ee64345f7c
Fix Lua window table segfault.
2009-07-12 21:38:35 -06:00
Cesare Tirabassi
d3f1e6288c
Merge branch 'master' of git.omp.am:/home/omp/git/conky
2009-07-12 21:18:28 +02:00
Nikolas Garofil
d6525d8790
Fix minor memleak
2009-07-12 20:01:31 +02:00
Nikolas Garofil
dc9e6436cc
fix: segfault when TEXT is missing and build with x11
2009-07-12 19:42:10 +02:00
Cesare Tirabassi
14c30feaea
Merge branch 'master' of git.omp.am:/home/omp/git/conky
2009-07-12 18:46:07 +02:00
Nikolas Garofil
ef13d53938
Fix: free_fonts tries sometimes tries to free much
...
When build with support for x11 and ran with a empty config this resulted in a segfault.
2009-07-12 18:29:50 +02:00
Nikolas Garofil
f6472cbbb5
Fix memleak when build with X11 but turned off in config
2009-07-12 14:52:58 +02:00
Nikolas Garofil
dc4087fcff
Ugly workaround for segfaults when build with x11 and lua
2009-07-12 12:28:22 +02:00
Cesare Tirabassi
e11015528e
free info.x11.desktop.name in free_text_objects()
2009-07-12 11:58:34 +02:00
Cesare Tirabassi
df17a54301
Merge branch 'master' of git.omp.am:/home/omp/git/conky
2009-07-12 11:45:33 +02:00
Nikolas Garofil
9e6fb9c2fe
Fix building without math but with X11
2009-07-12 00:51:17 +02:00
Nikolas Garofil
f4fd1648e9
Fix: reading mem after its freed (current_config)
2009-07-12 00:05:53 +02:00
Cesare Tirabassi
88ae603cf5
Add support for $desktop, $desktop_number and $desktop_name
...
Should work with any window manager that supports the
freedesktop.org Window Manager Specification
(see http://www.freedesktop.org/wiki/Specifications/wm-spec ).
I have tested succesfully with openbox but some more testing with other
wm would be needed!
Support is built-in; if it is not acceptable to loose cpu cycles for this
at every conky refresh step than it should be conditionally compiled.
2009-07-11 10:50:02 +02:00
Brenden Matthews
c494feafe1
Fix build errors with --disable-x11.
2009-07-10 10:07:39 -06:00
Brenden Matthews
2fa5f97edb
A whole bunch of changes, mostly Lua related.
...
Improved Lua API (lua_read_parse has been removed in favour of the
conky_parse() Lua API call). The docs have been improved to reflect the
recent Lua API stuff as well. Introduced new Lua Cairo and Imlib2
bindings, which require the tolua++ tool. Fixed some other
miscellaneous doc related things.
2009-07-09 22:47:41 -06:00
Nikolas Garofil
9065d1f422
Added support for swapfree
2009-07-09 20:12:52 +02:00
Nikolas Garofil
3659131192
Fix memleaks in CRIT_ERR
2009-07-08 15:51:08 +02:00
Brenden Matthews
def86cbb35
Merge branch 'master' of git.omp.am:/home/omp/git/conky
2009-07-07 17:34:02 -06:00
Brenden Matthews
ce19f6ee6a
Handle thread death better (sf.net #2818145 ).
2009-07-07 17:33:38 -06:00
Nikolas Garofil
553528cb3d
Fix memleak triggered by (and others)
2009-07-08 00:35:20 +02:00
Cesare Tirabassi
18ecbef1ae
weather: lets make this compliant to prehistoric standards and at the same time working ...
2009-07-07 18:08:54 +02:00
Nikolas Garofil
ce9d9e3298
fix minor memleak when closing conky
2009-07-07 17:27:57 +02:00
Nikolas Garofil
1070c60768
Fixed mixed code and declarations (not allowed in some C standards, like C90)
2009-07-07 15:38:13 +02:00
Cesare Tirabassi
09e55bcc7e
weather: add more weather modifiers
2009-07-07 12:08:24 +02:00
Cesare Tirabassi
15be8ad175
weather: corrected typo
2009-07-07 11:16:25 +02:00
Cesare Tirabassi
476296be5c
weather: changed ifs in parsing routine to switch/case and corrected TCU handling
2009-07-07 11:13:07 +02:00
Cesare Tirabassi
1171ab38a5
Added support for $weather (experimental).
...
Download, parse and display METAR data from the NWS.
icao must be a valid icao for the required location
(see for instance https://pilotweb.nas.faa.gov/qryhtml/icao/ ).
data_type must be one of the following:
last_update : display the date (yyyy/mm/dd) and time (UTC)
of the last update.
temperature_C : display air temperature in degree Celsius.
temperature_F : display air temperature in degree Fahrenheit.
cloud_cover : display the highest cloud cover status.
pressure : display air pressure in millibar.
wind_speed : display wind speed in km/hour.
wind_dir : display wind direction.
wind_dir_DEG : display compass wind direction.
humidity : display relative humidity in %.
weather : display any relevant weather event (rain, snow, etc.).
delay_in_minutes (optional, default 30) cannot be lower than 30 min.
Up to 3 stations can be simultaneously queried.
Use --enable-weather to compile this in.
2009-07-07 00:20:12 +02:00
Brenden Matthews
ae6c02b0c8
Improve docs and parsing of graph args further.
2009-07-04 22:03:12 -06:00
Brenden Matthews
52c68c094c
Improved parsing of graph arguments.
...
Removed "log"|"normal" arguments in favour of -l switch.
2009-07-04 21:43:45 -06:00
Brenden Matthews
14d90ad7d1
Fix some minor leaky code.
2009-07-04 21:13:00 -06:00
Brenden Matthews
e2caa58923
Remove newline with comment only lines in TEXT.
2009-07-04 20:57:41 -06:00
Nils Schweinsberg
aaca08fc97
Fix escaping of comments in TEXT (sf.net #2813390 , thanks Nils).
2009-07-02 00:36:37 -06:00
Nikolas Garofil
c84d9f8b26
Fix segfault in to_real_path
2009-06-29 16:04:00 +02:00
Phil Sutter
775d591a68
fix a few memleaks
2009-06-22 02:00:11 +02:00
Phil Sutter
867a842b3f
fix for testing and debug on FreeBSD
...
(Probably not complete yet)
2009-06-22 02:00:11 +02:00
Phil Sutter
912ed67d03
fix conf_cookie for FreeBSD
...
While here, also clean up the #ifdef mess created
around the whole config output support.
2009-06-22 01:59:26 +02:00
Phil Sutter
c6a5a060cf
Use the internal process list for if_running on Linux
2009-06-20 01:46:59 +02:00
Phil Sutter
98e6f41bfa
exiting early on error definitely sanitises indenting here
2009-06-20 01:45:05 +02:00
Brenden Matthews
11d5286a40
Some Imlib2 refactoring.
2009-06-14 21:05:11 -06:00
Ole Christian Tvedt
5f31a052bb
Fixed $if_mpd_playing. Would not return false after true.
...
Previously, is_playing was never returned to 0 even if a song stopped
playing.
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-06-14 20:07:59 -06:00
Ole Christian Tvedt
9048af353a
Read MPD connection data from environment.
...
Most MPD clients read the MPD_HOST and MPD_PORT
environment variables. Now, conky will too.
MPD_HOST can be either "hostname" or "password@hostname".
If a user specifies a host in the configuration, the
password set in MPD_HOST will be ignored. This is to
prevent the password from being sent to the wrong host.
In other words, if the host is specified in the conky
configuration, the password must be too (if there is
one).
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-06-14 20:07:59 -06:00
Brenden Matthews
8b9f0b6851
Fixup some imlib2 flush interval stuff.
2009-06-14 16:12:12 -06:00
Brenden Matthews
b78650d29a
Approach the per-image cache control another way.
2009-06-14 14:50:30 -06:00
Brenden Matthews
be75e07c9d
Increase backwards compat for border_margin.
...
Even though border_margin is deprecated, we'll set border_inner_margin
anyway so lazy people won't complain too much.
2009-06-14 12:24:18 -06:00
Lassi Selander
b4f88ff319
Fix XMMS2 related crash (sf.net #2806111 and #2805310 , thanks Lassi).
2009-06-14 12:03:50 -06:00
Ole Christian Tvedt
23e89dca08
Added own_window_type panel
...
The panel type reserves space along the edge of the
screen, just like regular DE panels, taskbars and the
like. I have tested it for several hours now with lots
of different settings, and it seems to be working fine.
Works especially well with alignment top_??? or
bottom_??? and single-line output. Something like
this:
own_window yes
own_window_type panel
alignment bottom_left
maximum_width 1680
minimum_size 1680
gap_x 0
gap_y 0
stippled_borders 1
draw_borders yes
update_interval 3.0
TEXT
$nodename $tab $freq_g ${color grey}GHz$color $tab $memperc% ${color grey}RAM$color $tab $cpu% ${color grey}CPU $tab etc...etc...$alignr${time %F %R}
The line after TEXT is supposed to be on one line,
just in case some channel has messed it up.
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-06-13 17:46:09 -06:00
Pavel Labath
9e976d9dc4
Better parsing of process names containing funky chars
2009-06-14 00:02:50 +02:00
Nikolas Garofil
f2176e6f54
Added support for blink
2009-06-13 23:52:41 +02:00
Brenden Matthews
9ce2c8ba07
Fix regression in Lua inotify stuff.
2009-06-13 13:40:27 -06:00
Ole Christian Tvedt
74340eaa9c
A mainly cosmetic update.
...
One useless "if (own_window)" check was removed. It is already inside another
identical check, and so will always evaluate to true.
One strncmp against the word "dock" was limited to four characters instead of
seven, for consistency with the other checks in the configuration parsing code.
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-06-13 13:21:38 -06:00
Brenden Matthews
26d7547c1e
Ugh...finish ca340d2643
.
2009-06-13 13:19:40 -06:00
Brenden Matthews
ca340d2643
Fix inotify segfault (sf.net #2804886 ).
...
Fix segfault due to bad checking of return values for inotify code
(sf.net #2804886 )
2009-06-13 13:17:18 -06:00
Nikolas Garofil
0108d14e68
Added
2009-06-13 01:48:54 +02:00
Pavel Labath
c0d1c313e9
Support for per-task I/O statistics - $top_io
...
Basically, I just added three new process properties (io_read, io_write, io_perc - representing
the amount of I/O done by the process during the update interval) and $top_io, that sorts
processes based on io_perc.
Atm, it's completely #ifdef'd, since it requires kernel support. But that creates some wierd
looking syntax at some places, so it may be better to remove some ifdefs. It even may be
possible to completely remove the ifdefs (ie. convert them to #ifdef linux) since the code will
compile just fine even if the kernel doesn't support I/O accounting. I'll leave that for someone
else to decide.
2009-06-12 19:39:45 +02:00
Brenden Matthews
d114bcf58a
Pixel perfect borders?
2009-06-11 22:35:19 -06:00
Brenden Matthews
e45db41a9d
Added border_inner_margin and border_outer_margin.
...
The border_margin config option is now deprecated. This also resolves
an issue with weird border_margin values causing X to crash.
2009-06-11 19:07:21 -06:00
Brenden Matthews
357901e6f2
Apply fs stat changes to fs_free_perc also (thanks Cesare).
2009-06-11 01:28:11 -06:00
Brenden Matthews
8e55089537
Revert b6e691e8ac
, fix original problem.
2009-06-10 14:13:17 -06:00
Brenden Matthews
eb722bf30d
Revert "Clarify fs free stats."
...
This reverts commit da65a4bcf8
.
2009-06-10 14:09:34 -06:00
Brenden Matthews
1571bb1aad
Fix regression with loading of non-Xft fonts (sf.net #2804324 ).
2009-06-10 14:08:39 -06:00
Brenden Matthews
da65a4bcf8
Clarify fs free stats.
2009-06-10 11:31:24 -06:00
Brenden Matthews
2469b9bea9
Fixed a regression with font rendering.
...
Fixed a regression which causes fonts to not be rendered properly with
certain types of windows.
2009-06-09 18:39:26 -06:00
Pavel Labath
6586d47813
Fix comments in TEXT section
...
When a '#' is found in TEXT, section remove_comments() is called. However, that function doesn't
limit itself to removing that particular comment. Instead, it greedily removes all "comments" from
the string, including those in ${color $abcdef} constructs. This, obviously, makes a mess of
things.
Solution: I added a new function, remove_comment(), that only removes the current comment.
Note: Atm, the function doesn't delete the newline, since that was the current behavior, and is
the natural one for the config section. However, for the TEXT it seems better to delete the \n
too, to avoid blank lines.
Note2: this also fixes the bug in strfold(), which incorectly copied the string, truncating it by
one byte.
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-06-09 14:56:19 -06:00
Vincent Breitmoser
f3aa025872
Added format_human_readable option (sf.net #2803345 , thanks Vincent).
2009-06-09 14:52:18 -06:00
Nikolas Garofil
c392152d3a
extra displayoptions for battery_short and make sure full isn't handled as unknown
2009-06-08 21:15:18 +02:00
Nikos Ntarmos
3361596592
Include sys/param.h for FreeBSD
...
We need this on FreeBSD as some of the constants used in ucred.h and
mount.h are defined there.
Signed-off-by: Nikos Ntarmos <ntarmos@cs.uoi.gr>
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-06-08 13:05:20 -06:00
Nikos Ntarmos
d934d11e48
Check for deleted and not expunged emails
...
This should fix bug #2802529 . I've also revamped the X-Mozilla-Status
header handling which was kind of fishy till now.
Disclaimer: I have no mbox folders around to test it.
Signed-off-by: Nikos Ntarmos <ntarmos@cs.uoi.gr>
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-06-08 13:05:20 -06:00
Nikolas Garofil
25e46ca341
Fix compiling without X11
2009-06-07 18:41:10 +02:00
Nikolas Garofil
b11f2466af
need_to_load_fonts shouldn't be used without X11
2009-06-07 15:01:48 +02:00
Brenden Matthews
a9c8ae4145
Make device argument optional for most net stats.
...
We can use DEFAULTNETDEV for more than just up/downspeedgraph.
2009-06-06 22:56:29 -06:00
Brenden Matthews
00e559aef8
reload_config() fix, fix default net graph args.
...
Closing the X display on reload caused some weirdness. We can just
leave it open between reloads. For whatever reason we had a macro
inside quotes for the default net device.
2009-06-06 22:53:40 -06:00
Brenden Matthews
815dcf872d
Update command opts docs.
2009-06-06 18:10:20 -06:00
Brenden Matthews
e5abd481cd
Fix some stupidity in 33754ecebe
.
2009-06-06 17:42:02 -06:00
Brenden Matthews
33754ecebe
Let lua_graph behave more like other graphs.
...
Changed llua_getinteger() to llua_getnumber() returning a double, so
that you can use floating point values in graphs etc. Lua graph will
scale like other graphs (except execgraph) by default now, and you can
manually set a scale with the scale argument.
2009-06-06 17:25:34 -06:00
Brenden Matthews
8e81d4e816
Merge branch 'master' of git.omp.am:/home/omp/git/conky
2009-06-06 12:20:13 -06:00
Pavel Labath
aa68da1ce6
Fix bug in template code.
...
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-06-06 12:18:46 -06:00
Nikolas Garofil
e4934b9f08
Let wireless_link_bar work in shell
2009-06-06 20:04:20 +02:00
Phil Sutter
3170b5191a
Add a better fix for the $addr update problem
...
In general, initialising last_update_time to next_update_time upon
startup doesn't make sense, as some update functions check for the
distance between the two being higher than a given epsilon to prevent
updating too often. This means that they won't trigger when
update_stuff() is being run for the first time.
2009-06-06 18:18:31 +02:00
Phil Sutter
26ecdcf562
Revert "Bugfix: $addr and $addrs couldn't find ip's before the first update."
...
This reverts commit 8ffb8b238d
.
Surely, there is a better solution for that.
2009-06-06 18:14:06 +02:00
Nikolas Garofil
8ffb8b238d
Bugfix: $addr and $addrs couldn't find ip's before the first update.
...
When you started "$updates|${addr eth0}" displayed "0|No Address",
after the first update you got something normal like "1|192.168.0.1"
This patch should fix this.
2009-06-06 17:41:51 +02:00
Brenden Matthews
22733a0b4a
Fix 6994caa18b
.
...
Introduced a regression with commit
6994caa18b
by getting too happy with
OpenMP.
2009-06-06 03:56:22 -06:00
Brenden Matthews
384a41cb6e
Unbreak $combine.
2009-06-06 03:04:36 -06:00
Brenden Matthews
4b35fe5db4
s/IMLIB2/Imlib2/g
2009-06-06 02:32:51 -06:00
Brenden Matthews
8686ce0347
Apparently some people want more than 64 fonts.
2009-06-06 02:13:42 -06:00
Pavel Labath
c76b7f577d
A couple more fixes for the template machinery
...
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-06-05 21:07:32 -06:00
Phil Sutter
20e4e19f83
add entropy_perc
...
There is no rounding done, so e.g. 3.6% get 3%. But double casting and
calling round_to_int() is just too ugly.
2009-06-04 22:51:25 +02:00
Phil Sutter
9d7fc86275
branch conditionally
...
In case of undefined MATH there were empty branches which could lead to
decreased performance in totally unoptimised code. ;)
2009-06-04 22:00:52 +02:00
Phil Sutter
8407d6b3c9
clarify what the preprocessor define does here
2009-06-04 21:46:45 +02:00
Nikolas Garofil
f3fd389ea0
read_tcp werkt maar moet nog stresstesten ondergaan
2009-06-04 19:39:18 +02:00
Nikolas Garofil
25a6fca902
Let entropy_bar, mpd_bar and apcupsd_loadbar work in shell
2009-06-04 18:45:58 +02:00
Brenden Matthews
ff57d1a85e
Make Imlib2 global cache flushing actually work.
2009-06-03 13:31:16 -06:00
Brenden Matthews
904354f93b
Added some better cache control options for Imlib2.
2009-06-03 13:24:53 -06:00
Nikolas Garofil
3656bced46
some c standards only allow initialisations at the start of a function
2009-06-03 19:17:45 +02:00
Nikolas Garofil
1085ec48cc
Make it possible to compile without C99
2009-06-03 18:24:48 +02:00
Nikolas Garofil
5388fc33f6
Let lua_bar work in shell
2009-06-03 17:58:00 +02:00
Toni Spets
09ac517343
Merge OpenBSD patches from ports
2009-06-03 09:16:23 +03:00
Brenden Matthews
6994caa18b
Minor refactoring for template code.
2009-06-02 14:51:46 -06:00
Pavel Labath
44ead331cd
Make templates work with --disable-x11
...
part of the template-handling code was in #ifdef X11, which caused conky to dump core when
compiled without x11.
as a bonus, I changed tests !=' ' to !isspace in two places as it was causing strange effects
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-06-02 14:48:59 -06:00
Pavel Labath
8540821323
Fix core dumps while handling templates
...
Conky would dump core when encountering templates with no parameters (both $templateX and
${templateX}) and when the line contained improperly nested {}.
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-06-02 14:48:59 -06:00
Nikolas Garofil
abf515d901
Let execibar work in shell
2009-06-02 21:23:00 +02:00
Nikolas Garofil
7807d369ad
Let battery_bar work in shell
2009-06-02 19:16:21 +02:00
Nikolas Garofil
1a9d0bdccd
Let fs_bar and fs_bar_free work in shell
2009-06-01 16:09:34 +02:00
Nikolas Garofil
faa9086168
Let cpubar work in shell
2009-06-01 15:07:24 +02:00
Nikolas Garofil
0b8b6ccbae
Let swapbar work in shell
2009-06-01 13:48:04 +02:00
Nikolas Garofil
bfc791f08b
Let membar work in shell
2009-06-01 12:19:25 +02:00
Pavel Labath
0cb91fc3db
Fix mouse click coordinates forwarded to the desktop window
...
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-05-31 22:18:12 -06:00
Nikolas Garofil
c3df719716
Created a function to call bars in shell (not only execbar)
...
TODO use this function in other places
2009-06-01 02:23:47 +02:00
Nikolas Garofil
c91e2ed38e
Make sure that no X11 stuff is in the binary when not requested
2009-05-31 16:48:16 +02:00
Nikolas Garofil
01bc44aaf6
Don't check if output to X is requested when compiled without X
2009-05-31 16:29:12 +02:00
Brenden Matthews
295203dd4c
Fix an issue with reload_config()?
2009-05-30 21:06:49 -06:00
Phil Sutter
533075032a
Fix hostname resolution for mpd_host
...
When getaddrinfo() returns an IPv6 address, connect() fails since mpd
does not support IPv6. Reproduced by adding the name "localhost" to the
"::1" entry in /etc/hosts.
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-05-30 19:55:06 -06:00
Alexander Graf
0632693be7
Fix if_existing
...
The if_existing with 2 arguments checking whether a file contains a specified
string did not work. This is fixed by this patch.
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-05-30 16:21:42 -06:00
Brenden Matthews
39071d28e8
Be more graceful when handling IMAP problems.
2009-05-29 23:31:03 -06:00
Brenden Matthews
a31efb7fbe
Fix default sizing for bars/graphs/gauges.
...
Conflicts:
src/conky.c
2009-05-29 14:05:10 -06:00
Nikos Ntarmos
15eb14da5c
conf_cookie is there for kFreeBSD as well
...
Signed-off-by: Nikos Ntarmos <ntarmos@cs.uoi.gr>
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-05-29 10:57:17 -06:00
Nikos Ntarmos
8553e33763
Include bsd/bsd.h on kFreeBSD
...
Signed-off-by: Nikos Ntarmos <ntarmos@cs.uoi.gr>
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-05-29 10:57:17 -06:00
Brenden Matthews
650c39b602
Compilation fixes, fix a segfault on shutdown.
...
There was a missing 'break' in a switch/case statement which caused a
segfault on shutdown when using $if_up.
2009-05-28 21:27:56 -06:00
Nikos Ntarmos
b51d06d178
Gracefully exit from main_loop()
...
Signed-off-by: Nikos Ntarmos <ntarmos@cs.uoi.gr>
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-05-28 21:27:56 -06:00
Nikos Ntarmos
c03655bdfa
free(3) previously strdup(3)'ed disp
...
Signed-off-by: Nikos Ntarmos <ntarmos@cs.uoi.gr>
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-05-28 21:27:56 -06:00
Nikos Ntarmos
613a440fdc
XDestroyRegion(3) only for non-NULL regions
...
Signed-off-by: Nikos Ntarmos <ntarmos@cs.uoi.gr>
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-05-28 21:27:55 -06:00
Nikos Ntarmos
0c62f02553
XCloseDisplay(3) on re-init_X11()
...
Signed-off-by: Nikos Ntarmos <ntarmos@cs.uoi.gr>
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-05-28 21:27:55 -06:00
Nikos Ntarmos
ff72a55691
No need to check for loop variable value
...
If the first for-loop succedds in finding the desired interface, it will return to its caller. The only way we drop to the second for-loop is if nothing is found thus far, so no need to check for (i == 16).
Signed-off-by: Nikos Ntarmos <ntarmos@cs.uoi.gr>
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-05-28 21:27:55 -06:00
Nikos Ntarmos
33451a9420
free(3) previously strndup(3)'ed diskio.dev
...
Signed-off-by: Nikos Ntarmos <ntarmos@cs.uoi.gr>
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-05-28 21:27:55 -06:00
Nikos Ntarmos
dc2a8e1de8
free(3) strdup(3)'ed templates array
...
Signed-off-by: Nikos Ntarmos <ntarmos@cs.uoi.gr>
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-05-28 21:27:55 -06:00
Nikos Ntarmos
a8300acbc5
free(3) previously strndup(3)'ed netstats.dev
...
Signed-off-by: Nikos Ntarmos <ntarmos@cs.uoi.gr>
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-05-28 21:27:55 -06:00
Brenden Matthews
ed5dbc02bb
Simplify graph gradient stuff.
2009-05-26 11:44:16 -06:00
Brenden Matthews
d65c33146e
OMPtimize the gradient stuff.
2009-05-26 03:14:52 -06:00
Brenden Matthews
b0f37a63e8
Let the graphs be bigger.
2009-05-24 23:31:35 -06:00
Brenden Matthews
35a72f5a95
Fix some minor graph related bugs.
2009-05-24 23:16:36 -06:00
Brenden Matthews
d03df4a367
Allow ~/... and $HOME/... paths for more stuff.
2009-05-24 22:33:47 -06:00
Brenden Matthews
f1cc5cf032
Actually fix hddtemp parsing.
2009-05-24 18:15:05 -06:00
Brenden Matthews
1c4044252c
Revert "Fix array bounds problem in hddtemp code."
...
This reverts commit d0de7cbd63
.
2009-05-24 18:02:46 -06:00
Brenden Matthews
c92272a943
Fix segfault on reload.
2009-05-24 17:49:50 -06:00
Brenden Matthews
d0de7cbd63
Fix array bounds problem in hddtemp code.
2009-05-24 17:09:38 -06:00
Brenden Matthews
4a08fab0e6
Fix clipping, enable alpha for imlib2.
2009-05-24 16:52:48 -06:00
Brenden Matthews
4ec728fa42
Added fancy new 'temperature gradients' feature.
...
See docs for more details on 'temperature gradients', which can be
turned on with the -t switch on graphs. Also improved parsing of
options with $execgraph and $execigraph, but may cause some breakage.
2009-05-24 15:53:32 -06:00
Brenden Matthews
ee9364522a
Some OpenMP related fixes.
...
Fixes for commit 9c331dce49
.
2009-05-24 14:02:33 -06:00
Brenden Matthews
19ca4c071a
Merge branch 'master' of git.omp.am:/home/omp/git/conky
2009-05-24 13:48:10 -06:00
Brenden Matthews
4bfd545d2f
Clip out imlib2 buffer properly.
2009-05-24 13:47:44 -06:00
Joe Myre
7b7d038035
Merge branch 'master' of git.omp.am:/home/omp/git/conky
2009-05-24 14:24:07 -05:00
Brenden Matthews
06044bf7e5
Try and fix weirdness with hwmon/i2c/platform options.
2009-05-24 13:07:27 -06:00
Joe Myre
9c331dce49
omped it up
2009-05-24 10:41:35 -05:00
Brenden Matthews
bf2d9de16a
Add OpenMP to list of compiled in features (for -v).
2009-05-23 21:18:06 -06:00
Nikos Ntarmos
45e403f553
Allow src/apcupsd.c to compile cleanly on FreeBSD.
...
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-05-23 21:08:32 -06:00
Nikos Ntarmos
12d0d1477f
Integrate FreeBSD diskio support.
...
This diff moves Linux-specific parts of diskio.c into linux.c and uses
the remaining diskio functions to correctly implement this functionality
for FreeBSD. It also hooks diskio.c to the FreeBSD build.
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-05-23 21:08:32 -06:00
Nikos Ntarmos
0880c1722d
Remove unused variables and rearrange includes.
...
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-05-23 21:08:31 -06:00
Nikos Ntarmos
38d4030e65
conf_cookie valid only for Linux.
...
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-05-23 21:08:31 -06:00
Brenden Matthews
396494d4a0
Fixed parsing of $hwmon?
2009-05-23 21:01:59 -06:00
Brenden Matthews
c9951a3bac
Better checking for cases when inotify doesn't work.
2009-05-22 12:48:46 -06:00
Brenden Matthews
0dc7041e6f
Fix other parsing bug with hwmon.
2009-05-22 12:30:09 -06:00
Brenden Matthews
1779ef3efd
Fix (possibly overkill) hwmon parsing bug.
2009-05-22 12:29:41 -06:00
Brenden Matthews
7f0929d03c
Fix imlib2 cache setting.
2009-05-22 11:23:05 -06:00
Brenden Matthews
445fde109c
Fix backwards width/height args for image drawing.
2009-05-22 01:39:38 -06:00
Brenden Matthews
3ad217e447
Use original image size when not specified.
2009-05-22 01:18:07 -06:00
Brenden Matthews
b6dea2fce6
Oops, null pointer.
2009-05-20 11:53:43 -06:00
Brenden Matthews
a25e030036
Oh yeah, make sure it compiles without inotify.
...
Also removed BSD licensing stuff that pertains to old torsmo code.
2009-05-19 22:56:33 -06:00
Brenden Matthews
75d1a054be
Add message to show the Lua script was reloaded.
2009-05-19 22:51:50 -06:00
Brenden Matthews
011e52650b
Added inotify support for reloading Lua scripts automagically.
2009-05-19 22:49:42 -06:00
Brenden Matthews
dd5fbeb41b
Improve reload_config() window destruction/creation.
2009-05-19 21:34:43 -06:00
Brenden Matthews
baaba76678
Handle inotify stuff a bit better.
2009-05-19 20:35:02 -06:00
Brenden Matthews
0d3726d352
Oops, remove printf().
2009-05-19 20:23:44 -06:00
Brenden Matthews
ba0eb5d85d
Inotify support.
...
Added inotify support to reload the config when modified automatically
on systems that support it
2009-05-19 17:14:34 -06:00
Brenden Matthews
e05fc3ba38
Don't need a prev ptr in this list.
2009-05-18 15:49:40 -06:00
Filipe Ferreira
5552f4135e
Patch to fix rounding error with CPU values.
2009-05-17 23:30:10 -06:00
Brenden Matthews
6477962dc9
Added support for rending images by way of IMLIB2.
2009-05-17 23:11:22 -06:00
Brenden Matthews
ddcc8ceb70
Merge branch 'master' into imlib2
...
Conflicts:
extras/nano/conky.nanorc
extras/vim/syntax/conkyrc.vim
2009-05-17 22:11:40 -06:00
Brenden Matthews
6abbbd50f0
Merge branch 'lua'
...
Conflicts:
src/specials.c
2009-05-17 22:00:44 -06:00
Brenden Matthews
e7bf480d48
Fix null pointer boog in $top stuff.
2009-05-17 21:59:05 -06:00
Brenden Matthews
694b736f64
Merge branch 'master' into lua
2009-05-17 20:58:13 -06:00
Nikolas Garofil
914af765e4
execbar can now be used in the shell even when compiled with x11 support
2009-05-17 13:38:51 +02:00
Brenden Matthews
353f0b6ad7
More work on imlib2 stuff.
...
Seems to be some rendering corruption which I'm not sure the reason for,
but other than that I think it works okay.
2009-05-16 23:47:02 -06:00
Brenden Matthews
1dc7731f6d
Merge branch 'master' into imlib2
2009-05-16 22:24:45 -06:00
Brenden Matthews
41e46ffe41
Oops, remove debug printf().
2009-05-16 22:24:22 -06:00
Brenden Matthews
d26b946b7b
Merge branch 'master' into imlib2
2009-05-16 18:37:11 -06:00
Brenden Matthews
72d15db78a
Merge branch 'master' into lua
2009-05-16 18:37:04 -06:00
Brenden Matthews
344fa8498d
Merge branch 'master' of git.omp.am:/home/omp/git/conky
2009-05-16 18:28:19 -06:00
Brenden Matthews
d642a3f659
Fixed comment stuff for real this time?
2009-05-16 18:28:04 -06:00
Nikolas Garofil
94d75cc494
add missing var
2009-05-17 01:33:43 +02:00
Brenden Matthews
f2a69f37ad
Merge branch 'master' into lua
2009-05-16 17:08:50 -06:00
Brenden Matthews
debf4ec597
Remove unused var.
2009-05-16 17:08:37 -06:00
Brenden Matthews
dd606eb5ae
Merge branch 'master' of git.omp.am:/home/omp/git/conky into lua
...
Conflicts:
src/specials.c
2009-05-16 17:05:30 -06:00
Brenden Matthews
b661dbf5a7
More lua stuff.
2009-05-16 17:04:26 -06:00