Thursday, August 7, 2008
Text as Background in GNOME
I am trying to find a way to set my todo.txt as my background in GNOME. I haven't looked at Devil's Pie yet since I am hoping there is an easier way to do it. Has anyone done this?
Subscribe to:
Post Comments (Atom)
Conky?
ReplyDeleteConky? gdesklets? both should have some support.
ReplyDeleteOtherwise you could make a transparent console, the only problem is you loose the ability to click though them to the desktop (although there may be a way around it using xwinwrap or something).
You may try torsmo or if you want something really simple go for root-tail
ReplyDeletebrutal solution: use imagemagick to create your new wallpaper, script it, cron it.
ReplyDeleteonce you got through the painful syntax, it's a breeze.
Overkill, but perhaps the Enlightenment (E17) tool for things like that (I forget what it is)
ReplyDeleteConky worked perfectly fine for me as a background information tool when I was using fluxbox as my desktop enviroment.
Using GNOME? The Imagemagick route is not that brutal. (Though, you'll need to monkey with the actual ImageMagick command to get what you want.)
ReplyDeletePut the following scripts in the same directory (say, ~/bin/). Put the first in your GNOME session startup.
#!/bin/sh
# todo_bg_startup.sh
# Where am I running?
PREFIX=`echo $0 | sed -e 's/xplanet-background.sh//g'`
killall todo_bg_set.sh
exec ${PREFIX}todo_bg_set.sh
... Which calls this one:
#!/bin/sh
# todo_bg_set.sh
#
# How often do you want to update the background?
DELAY=30m
# Place to stick the background graphic
PIXPATH=~/backgrounds
# A file name for the background and a prepend character for alternating updates.
# gconftool needs a new file name to actually make the change later.
FILE=_ToDo_background.png
PREPEND=_
if [ -e '$PIXPATH/$FILE' ]; then
PRIOR="$PIXPATH/$FILE"
FILE="$PREPEND$FILE"
else
PRIOR="$PIXPATH/$PREPEND$FILE"
fi
# Fiddle with Imagemagick to generate the graphic you want and place here
convert yadda yadda to "$PIXPATH/$FILE"
# Update the GNOME background
gconftool -t str -s /desktop/gnome/background/picture_filename "$PIXPATH/$FILE"
# Get rid of stale background
rm "$PRIOR"
sleep $DELAY
exec $0
This isn't very sophisticated, and certainly not very pretty, but you could try
ReplyDeletea2ps -B --font-size=32 --columns=1 \
in.txt -o in.ps ; convert in.ps out.gif
(sorry, there is a line wrap in there). check the man pages of a2ps and out.gif to modify and hopefully improve the output.
If a2ps is too ugly, and you don't want to mess around with imagemagick, set up a latex file, something along the lines of (once again, you will have to watch the wrap)
ReplyDelete%in.tex
\documentclass[20pt,dvips,landscape]{foils}
\usepackage[dvips]{color}
\usepackage{psfrag}
\usepackage{epsfig}
\usepackage{fancyhdr}
\usepackage{pstcol,pst-node}
\usepackage{graphics}
\definecolor{brown}{rgb}{0.2,0.0,0.4}
\newcommand{\brown}[1]{\textcolor{brown}{#1}}
\begin{document}
\brown{
\begin{enumerate}
\include{todo.txt}
\end{enumerate}
}
\end{document}
download a suitable foils.cls and foils.sty file from the internet; then use as your input script
#!/bin/sh
latex in.tex
latex in.tex
dvips -t landscape -o in.ps in.dvi
convert in.ps ~/wallpapers/out.jpg
Just put \item in front of every point in your todo.txt, and it should work well. And this will allow you to easily put in background images, tables and so on if you want to experiment
I second (or third) the suggestion of Conky. It's great for system info and email notification as well.
ReplyDeleteInstall ImageMagick
ReplyDelete$ display -window root todo.txt
Should work. You can use some other options for formatting and to set the size but that should do it.