Need help with a netmonitor script.

Hi!
I made several scripts to monitor my system: date, free space on partitions, cpu load, etc.
All of them are embedded in a FvwmButtons module. The result looks like this:

The code of the FvwmButton is:

Module FvwmButtons LowerBar
Style "LowerBar" NoTitle, Sticky
*LowerBar: Fore #0081c4
*LowerBar: Back #000000
*LowerBar: Geometry 798x19+0-0
*LowerBar: Rows 1
*LowerBar: BoxSize fixed
*LowerBar: Frame 0
*LowerBar: Padding 0 0
*LowerBar: Font -adobe-helvetica-medium-r-normal-*-*-100-*-*-p-*-iso8859-1
*LowerBar: (Left, 70x1, Swallow FvwmApplet-clock `FvwmScript /home/franco/.fvwm/clock`, Action Function calendar)
*LowerBar: (Fore #ffffff, 20x1, Title (right) "linux:")
*LowerBar: (Left, 30x1, Swallow FvwmApplet-splinux `FvwmScript /home/franco/.fvwm/splinux`)
*LowerBar: (Fore #ffffff, 30x1, Title (right) "windows:")
*LowerBar: (Left, 30x1, Swallow FvwmApplet-spwin `FvwmScript /home/franco/.fvwm/spwin`)
*LowerBar: (Fore #ffffff, 20x1, Title (right) "ext1:")
*LowerBar: (Left, 30x1, Swallow FvwmApplet-spext1 `FvwmScript /home/franco/.fvwm/spext1`)
*LowerBar: (Fore #ffffff, 20x1, Title (right) "ext2:")
*LowerBar: (Left, 30x1, Swallow FvwmApplet-spext2 `FvwmScript /home/franco/.fvwm/spext2`)
*LowerBar: (Fore #ffffff, 25x1, Title (right) "usbpen:", Action Function usbpenfunc)
*LowerBar: (Left, 30x1, Swallow FvwmApplet-spusbpen `FvwmScript /home/franco/.fvwm/spusbpen`)
*LowerBar: (Fore #ffffff, 20x1, Title (right) "cpu:")
*LowerBar: (Left, 25x1, Swallow FvwmApplet-cpu `FvwmScript /home/franco/.fvwm/cpu`)
*LowerBar: (Fore #ffffff, 20x1, Title (right) "net:", Action Function netfunc)
*LowerBar: (Left, 80x1, Swallow FvwmApplet-net `FvwmScript /home/franco/.fvwm/net`)
*LowerBar: (Left, 20x1, Swallow FvwmApplet-sound `FvwmScript /home/franco/.fvwm/sound`, Action Function soundfunc
)

The FvwmScript called “net” is the one I need help with. Its source is:

WindowTitle {FvwmApplet-net}
WindowSize  120 13
WindowPosition 0 0
Font -adobe-helvetica-medium-r-normal-*-*-100-*-*-p-*-iso8859-1

Init
 Begin
 End

PeriodicTasks
 Begin 
  If (RemainderOfDiv (GetTime) 3)==0 Then
  Begin
   Set $sp = (GetOutput { [[ -n $(ifconfig|grep ppp0) ]] && echo "in=$(ifconfig|tail -n 2 |head -n 1|(read x y x;
 echo $y|cut -c 7-)) out=$(ifconfig|tail -n 2 |head -n 1|(read x x x x x y x; echo $y|cut -c 7-))" || echo "not c
onnected" } 1 -1)
   ChangeTitle 1 $sp
  End
 End

Widget 1
Property
 Position 0 0
 Size 120 11
 Type ItemDraw
 Flags NoReliefString NoFocus Left
 Title {}
Main
 Case message of
  SingleClic :
  Begin
  End
End

I wish to change it in a way that it displays the speed of connection, instead of the amount of datas, but I don’t know how to write it.
I thought of putting in a variable the value of bytes transmitted in a certain time and compare when the task is re-executed, but the variable is cleared so there is nothing to compare to!
A solution could be writing the data in a file, but it would produce too much reading-writing on the hard disk, so any idea how to do?

I solved using Conky and swallowing it in the LowerBar.
This is how it looks like now:

Would be nice if u could post all needed scripts and configs.

Merry xmas.

Of course. :slight_smile:
This is my .fvwm2rc:

#############################################################################################
#                                WIREFRAME-0081C4 for Fvwm 2.4.15                           #
#                       by Francesco Guarino -  francescogua@tiscali.it                     #
#############################################################################################
# This configuration has been inspired by the WireFrame theme for gkrellm.                  #
# I changed main color to cyan (#0081c4) and developed all elements after it.               #
# How it works:                                                                             #
# It was meant to work on my 800x600 notebook.                                              #
# Every operation on windows can be achieved via shortcut:                                  #
# Alt+F3 resizes window                                                                     #
# Alt+F4 closes it                                                                          #
# Alt+F5 moves it                                                                           #
# Alt+F6 maximizes it and                                                                   #
# Alt+F7 iconifies it.                                                                      #
# Pressing Alt+Control+Shift+k, you can kill the window, just in case "Close" doesn't work. #
#############################################################################################


EdgeResistance 150 10
EdgeScroll 0 0
ClickTime 750


DeskTopSize 3x4

TitleStyle ActiveUp (VGradient 10 2 #000000 90 #000000 10 #0081c4 -- Flat)
TitleStyle ActiveDown (VGradient 10 2 #000000 90 #000000 10 #0081c4 -- Flat)
TitleStyle Inactive (VGradient 10 2 #000000 90 #000000 10 #0081c4 -- Flat)

Style * ForeColor #444444, BackColor #0081c4
Style * HilightFore #0081c4, HilightBack #0081c4
Style * MouseFocus, GrabFocus, TitleAtTop
Style * Font -adobe-helvetica-medium-r-normal-*-*-140-*-*-p-*-iso8859-1
Style * BorderWidth 0, HandleWidth 1


MenuStyle * Foreground #0081c4, Background #000000
MenuStyle * HilightBack #0056bf, ActiveFore #ffffff
MenuStyle * BorderWidth 1, Hilight3DOff, Animation
MenuStyle * PopupImmediately, PopdownImmediately
MenuStyle * PopupOffset 0 100, TitleWarp, SeparatorsShort, TrianglesSolid
MenuStyle * ItemFormat "%10.10c%>"
MenuStyle * Font -adobe-helvetica-medium-r-normal-*-*-100-*-*-p-*-iso8859-1


Style "Fvwm*"       BorderWidth 2, CirculateSkipIcon, CirculateSkip
Style "Fvwm*"       NoTitle,  Sticky, WindowListSkip, NeverFocus
Style "*conky*"       NoTitle, WindowListSkip
Style "FvwmWinList"	StaysOnTop, IgnoreRestack
Style "FvwmPager"	StaysOnTop, IgnoreRestack
Style "LowerBar"	StaysOnTop, IgnoreRestack
Style "XMMS_Playlist"	WindowListSkip, FvwmWinListSkip
Style "XMMS_Equalizer"	WindowListSkip, FvwmWinListSkip
Style "xmms"		NoTitle
Style "xterm"		NoTitle, StaysOnTop, WindowListSkip
Style "gkrellm"		Sticky, WindowListSkip, CirculateSkip, NoTitle
Style "aterm"		NoTitle
Style "MPlayer"		NoTitle

Key Next	A	M	Next [*] Focus
Key Prior	A	M	Prev [*] Focus
Key Menu	A	N	Menu RootMenu Nop

Key Left	A	MC	Scroll -100 0
Key Right	A	MC	Scroll +100 +0
Key Up		A	MC	Scroll +0   -100
Key Down	A	MC	Scroll +0   +100

Key Left        A       SC      CursorMove -1 0
Key Right       A       SC      CursorMove +1 +0
Key Up          A       SC      CursorMove +0   -1
Key Down        A       SC      CursorMove +0   +1
Key Left        A       SM      CursorMove -10 +0
Key Right       A       SM      CursorMove +10 +0
Key Up          A       SM      CursorMove +0   -10
Key Down        A       SM      CursorMove +0   +10
Key Up		A	C	Move 0 w-600p
Key Down	A	C	Move 0 w+600p
Key Left	A	C	Move w-800p 0
Key Right	A	C	Move w+800p 0

Key Tab A M WindowList Root c c NoDeskSort

Key F4		A	M	Close
Key F3		A	M	Resize
Key F5		A	M	Move
Key F6		A	M	Maximize-Func
Key F7		A	M	Iconify
Key Super_L	A	A	Menu Preferiti
Key Super_R	A	A	Menu RootMenu
Key Escape	A	C	Menu Preferiti
Key k		A	SCM	Destroy
key Super_R	A	S	Menu Mount-menu
Key g		A	CM	Exec gprs
Key g		A	SCM	Exec gprsclose
Key Alt_L	A	C	Function hidebuttons
Key Control_L	A	M	Function hidebuttons

AddToFunc hidebuttons
+ I All (CurrentDesk, !Transient) ThisWindow ("FvwmPager") WindowShade False
+ I All (CurrentDesk, !Transient) ThisWindow ("FvwmWinList") WindowShade False
+ I All (CurrentDesk, !Transient) ThisWindow ("FvwmPager") Schedule 2000 WindowShade SE
+ I All (CurrentDesk, !Transient) ThisWindow ("FvwmWinList") Schedule 2000 WindowShade SE



Mouse 3	R   	A       Menu RootMenu
Mouse 1	R    	A      	Menu Preferiti
Mouse 2	R    	A      	WindowList

Mouse 0	T    	A      	Menu Window-Ops

Mouse 1	F	A	Resize-or-Raise

Mouse 1	TS	A	Move-or-Raise
Mouse 1	I	A	Move-or-Iconify
Mouse 2	I	A	Iconify
Mouse 2	FST	A	Menu Window-Ops
Mouse 3	TSIF	A	RaiseLower




AddToFunc InitFunction
+			"I" exec xsetroot -bg black -fg grey30 -mod 4 4 &
+			"I" Module FvwmWinList
+			"I" Module FvwmPager
+			"I" Module LowerBar
+			"I" exec conky

AddToFunc RestartFunction
+			"I" Module FvwmWinList
+			"I" Module FvwmPager
+			"I" Module LowerBar
+			"I" exec conky

AddToFunc soundfunc
+ I	Exec if [[ $(aumix -q|grep vol | (read x x b; echo $b)) == 0 ]]; then aumix -v 100; aumix -p 60; elif [[ $(aumix -q |grep "speaker" |(read x x b; echo $b)) == 0 ]]; then aumix -v 0; aumix -p 0; else aumix -v 100; aumix -p 0; fi

AddToFunc netfunc
+ I	Exec if [[ $(ifconfig|grep ppp0) == "" ]]; then gprs; else gprsclose; fi

AddToFunc usbpenfunc
+ I	Exec if [[ -z $(cat /etc/fstab|grep "usbpen") ]]; then automount p; else automount -up; fi

AddToFunc calendar
+ I	Exec xterm -geometry 20x9+0-20 -e "echocyan $(cal|head -n 1); echocyan $(cal|head -n 2|tail -n 1); cal|tail -n +3; read -t 10 -n 1 aux"

AddToMenu RootMenu
+ "Fvwm Window Ops"		Popup Window-Ops
+ "Fvwm Simple Config Ops"	Popup Misc-Ops
+ "Monta/Smonta dev"		Popup Mount-menu
+ ""				Nop
+ "Spegni"			Exec sudo halt
+ "Riavvia"			Exec sudo reboot
+ ""				Nop
+ "Exit Fvmw"			Quit
+ "Restart Fvwm2"		Restart


AddToMenu Preferiti
+ "aterm"	Exec aterm -g 113x41+0+0 -tr -sh 40% -sr -trsb +sb -bg black -fg white -sl 1000
+ "HOW-TO"	Exec aterm -g 113x41+0+0 -tr -sh 20% +sb -bg black -fg white -e lynx -nopause -nocolor /usr/share/doc/HOWTO/en-txt
+ "Worker"	Exec worker
+ "The Gimp"	Exec gimp
+ "Gqview"	Exec gqview
+ "Gostview"	Exec gv
+ "Xfig"	Exec xfig
+ "Tgif"	Exec tgif
+ "Lynx"	Exec aterm -g 113x41+0+0 -tr -sh 20% +sb -bg black -fg white -e lynx -nopause -nocolor ~
+ "Firefox"	Exec firefox
+ "Pulisci Cache"	Exec puliscicache&
+ "Xmms"	Exec xmms
+ "Aumix"	Exec aumix
+ "Xclipboard"	Exec xclipboard
+ "Xscanimage"	Exec xscanimage

AddToMenu Mount-menu
+ "cdrom1"	Exec if [[ $(cat /etc/mtab|grep cdrom1) ]]; then umount /mnt/cdrom1; eject; else mount /mnt/cdrom1; cd /mnt/cdrom1; aterm -g 113x41+0+0 -tr -sh 40% -sr -trsb +sb -bg black -fg white -sl 1000; fi
+ "usbpen"	Exec if [[ $(cat /etc/mtab|grep usbpen) ]]; then umount /mnt/usbpen; else mount /mnt/usbpen; cd /mnt/usbpen; aterm -g 113x41+0+0 -tr -sh 40% -sr -trsb +sb -bg black -fg white -sl 1000; fi
+ "cdrom0"	Exec if [[ $(cat /etc/mtab|grep cdrom0) ]]; then umount /mnt/cdrom0; else mount /mnt/cdrom0; cd /mnt/cdrom0; aterm -g 113x41+0+0 -tr -sh 40% -sr -trsb +sb -bg black -fg white -sl 1000; fi
+ "floppy"	Exec if [[ $(cat /etc/mtab|grep floppy) ]]; then umount /mnt/floppy; else mount /mnt/floppy; cd /mnt/floppy; aterm -g 113x41+0+0 -tr -sh 40% -sr -trsb +sb -bg black -fg white -sl 1000; fi



AddToMenu Misc-Ops
+	"Sloppy Focus"			ChangeDefaultFocus SloppyFocus
+	"Click To Focus"		ChangeDefaultFocus ClickToFocus
+	"Focus Follows Mouse"		ChangeDefaultFocus FocusFollowsMouse
+	"" 				Nop
+	"Colormap Follows Mouse"	ColormapFocus FollowsMouse
+	"Colormap Follows Focus"	ColormapFocus FollowsFocus
+	""				Nop
+	"Full Paging ON"		EdgeScroll 100 100
+	"All Paging OFF"		EdgeScroll 0 0
+	"Horizontal Paging Only"	EdgeScroll 100 0
+	"Vertical Paging Only"		EdgeScroll 0 100
+	"Partial Paging"		EdgeScroll 50 50
+	"Full Paging && Edge Wrap"	EdgeScroll 100000 100000

AddToMenu Window-Ops
+	"Alt+F3_&Resize"		Resize
+	"Alt+F4_&Close"			Close
+	"Alt+F5_&Move"			Move
+	"Alt+F6_(Un)Ma&ximize"		Maximize
+	"Alt+F7_(De)&Iconify"		Iconify 	
+	"Alt+Shift+Ctrl+k_&Destroy"	Destroy 	
+	"640x320"			Maximize640
+	"800x600"			Maximize800
+	"1024x768"			Maximize1024
+	"1280x1024"			Maximize1280

AddToFunc Move-or-Raise	
+	"I" Raise
+	"M" Move
+  	"D" Lower

AddToFunc Maximize-Func
+	"I" Maximize	 800p -20p

AddToFunc Maximize640
+	"I" Maximize	 640p 480p

AddToFunc Maximize800
+	"I" Maximize	 800p 600p

AddToFunc Maximize1024
+	"I" Maximize	 1024p 768p

AddToFunc Maximize1280
+	"I" Maximize	 1280p 1024p


AddToFunc Move-or-Iconify
+	"I" Raise
+	"M" Move
+	"D" Iconify

AddToFunc Resize-or-Raise
+	"I" Raise
+	"M" Resize
+	"D" Lower



*FvwmWinList: Back #000000
*FvwmWinList: Fore #0081c4
*FvwmWinList: FocusBack #0056bf
*FvwmWinList: FocusFore #ffffff
*FvwmWinList: DontDepressFocus
*FvwmWinList: ButtonFrameWidth 0
*FvwmWinList: Font -adobe-helvetica-medium-r-normal-*-*-100-*-*-p-*-iso8859-1
*FvwmWinList: Action Click1 Iconify -1,Focus
*FvwmWinList: Action Click2 Iconify
*FvwmWinList: Action Click3 Module "FvwmIdent" FvwmIdent
*FvwmWinList: Geometry -0-67
*FvwmWinList: MinWidth 62
*FvwmWinList: MaxWidth 62
*FvwmWinList: UseSkipList

*FvwmPager: Geometry 62x47-0-20
*FvwmPager: Font none
*FvwmPager: Back #000000
*FvwmPager: Fore #0081c4
*FvwmPager: Hilight #0081c4
*FvwmPager: WindowColors #000000 #0056bf #000000 #ffffff
*FvwmPager: Balloons
*FvwmPager: BalloonFore #0081c4
*FvwmPager: BalloonBack #000000
*FvwmPager: BalloonBorderColor #0081c4


*FvwmScript: DefaultFont -adobe-helvetica-medium-r-normal-*-*-100-*-*-p-*-iso8859-1
*FvwmScript: DefaultFore #0081c4
*FvwmScript: DefaultBack #000000


Module FvwmButtons LowerBar
Style "LowerBar" NoTitle, Sticky
*LowerBar: Fore #0081c4
*LowerBar: Back #000000
*LowerBar: Geometry 798x19+0-0
*LowerBar: Rows 1
*LowerBar: BoxSize fixed
*LowerBar: Frame 0
*LowerBar: Padding 0 0
*LowerBar: Font -adobe-helvetica-medium-r-normal-*-*-100-*-*-p-*-iso8859-1
*LowerBar: (Left, 60x1, Swallow FvwmApplet-clock `FvwmScript /home/franco/.fvwm/clock`, Action Function calendar)
*LowerBar: (Fore #ffffff, 20x1, Title (right) "linux:")
*LowerBar: (Left, 30x1, Swallow FvwmApplet-splinux `FvwmScript /home/franco/.fvwm/splinux`)
*LowerBar: (Fore #ffffff, 20x1, Title (right) "win:")
*LowerBar: (Left, 30x1, Swallow FvwmApplet-spwin `FvwmScript /home/franco/.fvwm/spwin`)
*LowerBar: (Fore #ffffff, 20x1, Title (right) "ext1:")
*LowerBar: (Left, 30x1, Swallow FvwmApplet-spext1 `FvwmScript /home/franco/.fvwm/spext1`)
*LowerBar: (Fore #ffffff, 20x1, Title (right) "ext2:")
*LowerBar: (Left, 30x1, Swallow FvwmApplet-spext2 `FvwmScript /home/franco/.fvwm/spext2`)
*LowerBar: (Fore #ffffff, 25x1, Title (right) "usbpen:", Action Function usbpenfunc)
*LowerBar: (Left, 30x1, Swallow FvwmApplet-spusbpen `FvwmScript /home/franco/.fvwm/spusbpen`)
*LowerBar: (Left, 165x1, Swallow conky)
*LowerBar: (Left, 20x1, Swallow FvwmApplet-sound `FvwmScript /home/franco/.fvwm/sound`, Action Function soundfunc)

Now on with the FvwmScripts:
.fvwm/clock (if you click on it a mini-xterm window pops up showing cal).

WindowTitle {FvwmApplet-clock}
WindowSize  95 17
Font -adobe-helvetica-medium-r-normal-*-*-100-*-*-p-*-iso8859-1

Init
 Begin
  Set $tmp = (GetOutput {date "+%a %d %b - %H:%M"} 1 -1)
  ChangeTitle 1 $tmp
End

PeriodicTasks
 Begin 
  If (RemainderOfDiv (GetTime) 10)==0 Then
  Begin
    Set $tmp = (GetOutput {date "+%a %d %b - %H:%M"} 1 -1)
    ChangeTitle  1 $tmp
  End
End

Widget 1
Property
 Position 3 0
 Size 90 15
 Type ItemDraw
 Flags NoReliefString
 Title {}
Main
 Case message of
  SingleClic :
  Begin
  End
End

.fvwm/splinux

WindowTitle {FvwmApplet-splinux}
WindowSize  40 13		# Taille
Font -adobe-helvetica-medium-r-normal-*-*-100-*-*-p-*-iso8859-1

Init
 Begin
  Set $sp = (GetOutput {exec df -h| grep /dev/hda3|(read x x x y x; echo $y)} 1 -1)
  ChangeTitle 1 $sp
End

PeriodicTasks
 Begin 
  If (RemainderOfDiv (GetTime) 5)==0 Then
  Begin
    Set $sp = (GetOutput {exec df -h |grep /dev/hda3|(read x x x y x; echo $y)} 1 -1)
    ChangeTitle  1 $sp
  End
End

Widget 1
Property
 Position 0 0
 Size 50 11
 Type ItemDraw
 Flags NoReliefString
 Title {}
Main
 Case message of
  SingleClic :
  Begin
  End
End

spwin,spext1,spext2 are similar to splinux. The only difference is /dev/hda1,etc. instead of /dev/hda3.

.fvwm/spusbpen

WindowTitle {FvwmApplet-spusbpen}
WindowSize  40 13		# Taille
Font -adobe-helvetica-medium-r-normal-*-*-100-*-*-p-*-iso8859-1

Init
 Begin
  Set $sp = (GetOutput {aux=$(df -h |grep "/mnt/usbpen"|(read x x x y x; echo $y)); if [[ -n $aux ]]; then echo "$aux"; else echo "n mnt"; fi} 1 -1)
  ChangeTitle 1 $sp
End

PeriodicTasks
 Begin 
  If (RemainderOfDiv (GetTime) 5)==0 Then
  Begin
    Set $sp = (GetOutput {aux=$(df -h |grep "/mnt/usbpen"|(read x x x y x; echo $y)); if [[ -n $aux ]]; then echo "$aux"; else echo "n mnt"; fi} 1 -1)
    ChangeTitle  1 $sp
  End
End

Widget 1
Property
 Position 0 0
 Size 50 11
 Type ItemDraw
 Flags NoReliefString
 Title {}
Main
 Case message of
  SingleClic :
  Begin
  End
End

.fvwm/sound (it’s just a switch with three stages: “snd” (vol and spkr are set to 100), “nospkr” (vol set to 100 and spkr to 0), “nosnd” (vol and spkr zeroed).

WindowTitle {FvwmApplet-sound}
WindowSize  35 13
Font -adobe-helvetica-medium-r-normal-*-*-100-*-*-p-*-iso8859-1

Init
 Begin
  Set $tmp = (GetOutput {a=$(aumix -q|grep vol | (read x x b; echo $b)); if [[ $a == 0 ]]; then echo "nosnd"; elif [[ $(aumix -q|grep "speaker"|(read x x b; echo $b)) == 0 ]]; then echo "nospkr"; else echo "snd"; fi} 1 -1)
  ChangeTitle 1 $tmp
End

PeriodicTasks
 Begin 
  If (RemainderOfDiv (GetTime) 3)==0 Then
  Begin
    Set $tmp = (GetOutput {a=$(aumix -q|grep vol | (read x x b; echo $b)); if [[ $a == 0 ]]; then echo "nosnd"; elif [[ $(aumix -q|grep "speaker"|(read x x b; echo $b)) == 0 ]]; then echo "nospkr"; else echo "snd"; fi} 1 -1)
    ChangeTitle 1 $tmp
  End
End

Widget 1
Property
 Position 0 0
 Size 35 11
 Type ItemDraw
 Flags NoReliefString
 Title {}
Main
 Case message of
  SingleClic :
  Begin
  End
End

.conkyrc

# set to yes if you want Conky to be forked in the background
background no

# X font when Xft is disabled, you can pick one with program xfontsel
#font 5x7
#font 6x10
#font 7x13
#font 8x13
#font 9x15
#font *mintsmild.se*
#font -adobe-helvetica-medium-r-normal-*-*-60-*-*-p-*-iso8859-1


# Use Xft?
use_xft yes

# Set conky on the bottom of all other applications
on_bottom no

# Xft font when Xft is enabled
xftfont Bitstream Vera Sans Mono:size=5

# Text alpha when using Xft
xftalpha 0.8

# Print everything to stdout?
# out_to_console no

# MPD host/port
# mpd_host localhost
# mpd_port 6600
# mpd_password tinker_bell

# Print everything to console?
# out_to_console no

# mail spool
#mail_spool $MAIL

# Update interval in seconds
update_interval 3.0

# This is the number of times Conky will update before quitting.
# Set to zero to run forever.
total_run_times 0

# Create own window instead of using desktop (required in nautilus)
own_window yes

# Use pseudo transparency with own_window?
own_window_transparent no

# If own_window_transparent is set to no, you can set the background colour here
own_window_colour black

# Use double buffering (reduces flicker, may not work for everyone)
double_buffer yes

# Minimum size of text area
minimum_size 0 0

# Draw shades?
draw_shades no

# Draw outlines?
draw_outline no

# Draw borders around text
draw_borders no

# Stippled borders?
stippled_borders 0

# border margins
border_margin 0

# border width
border_width 0

# Default colors and also border colors
default_color black
default_shade_color black
default_outline_color black

# Text alignment, other possible values are commented
alignment top_left
#alignment top_right
#alignment bottom_left
#alignment bottom_right
#alignment none

# Gap between borders of screen and text
# same thing as passing -x at command line
gap_x 0
gap_y 0

# Subtract file system buffers from used memory?
no_buffers yes

# set to yes if you want all text to be in uppercase
uppercase no

# number of cpu samples to average
# set to 1 to disable averaging
cpu_avg_samples 2

# number of net samples to average
# set to 1 to disable averaging
net_avg_samples 2

# Force UTF8? note that UTF8 support required XFT
override_utf8_locale no


# Add spaces to keep things from moving about?  This only affects certain objects.
use_spacer no

#   mldonkey_hostname     Hostname for mldonkey stuff, defaults to localhost
#   mldonkey_port         Mldonkey port, 4001 default
#   mldonkey_login        Mldonkey login, default none
#   mldonkey_password     Mldonkey password, default none

# boinc (seti) dir
# seti_dir /opt/seti

# Allow for the creation of at least this number of port monitors (if 0 or not set, default is 16) 
#min_port_monitors 16

# Allow each port monitor to track at least this many connections (if 0 or not set, default is 256)
#min_port_monitor_connections 256

# variable is given either in format $variable or in ${variable}. Latter
# allows characters right after the variable and must be used in network
# stuff because of an argument

# stuff after 'TEXT' will be formatted on screen

TEXT
${color #ffffff}cpu:${color #0081c4}${cpubar 5,96}${if_running pppd}${color #00ff00}$else${color #ff0000}$endif net:${voffset -3}${color #0081c4}${downspeedgraph ppp0 16,100}
${color #ffffff}${voffset -13}ram:${color #0081c4}${membar 5,30} ${color #ffffff}swap:${color #0081c4}${swapbar 5,30} ${color #ffffff}${exec [[ -n $(ifconfig|grep ppp0) ]] && echo on || echo off}

Merry Christmas to you all![/list]