unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* battery status in modeline
@ 2010-04-16  9:54 Andrea Crotti
  2010-04-16 10:35 ` Eli Zaretskii
  2010-04-16 11:09 ` Richard Riley
  0 siblings, 2 replies; 9+ messages in thread
From: Andrea Crotti @ 2010-04-16  9:54 UTC (permalink / raw)
  To: help-gnu-emacs

The only real reason to run X on my little dell 10 is because I know how
much battery I have left.
But now I've done this

--8<---------------cut here---------------start------------->8---
(defun bat()
  (interactive)
  (shell-command "grep 'present rate' /proc/acpi/battery/BAT1/state"))
--8<---------------cut here---------------end--------------->8---

And maybe I don't need it anymore, it would be really nice to show in
the modeline how much battery power I have left.

Given that the modeline is already crowded also I could show it only
when reaching a certain threshold.  Is there anything like that already
done?





^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2010-04-16 17:51 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-04-16  9:54 battery status in modeline Andrea Crotti
2010-04-16 10:35 ` Eli Zaretskii
2010-04-16 12:16   ` Andrea Crotti
2010-04-16 12:19   ` Andrea Crotti
2010-04-16 12:44     ` Richard Riley
2010-04-16 15:19     ` Peter Dyballa
2010-04-16 16:30       ` Johan Busk Eriksson
2010-04-16 17:51         ` Peter Dyballa
2010-04-16 11:09 ` Richard Riley

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).