Author Topic: Windowmaker & (x)vim For Pdaxrom?  (Read 28651 times)

dtruchan

  • Jr. Member
  • **
  • Posts: 89
    • View Profile
    • http://
Windowmaker & (x)vim For Pdaxrom?
« Reply #15 on: December 02, 2005, 08:15:55 pm »
Quote
Thanks for your handy tips, dtruchan!  Now I feel much safer safe to plunge into different interesting wm.

BTW here is my screenshot mimicking the one in TUX.   

 [ Invalid Attachment ]
[div align=\"right\"][a href=\"index.php?act=findpost&pid=105743\"][{POST_SNAPBACK}][/a][/div]

No problem.
Looks great!
860 Debian EABI
Lexar Cards
WCF11 v2.5
Mittoni SD-CF Adapter
Gentoo

ZDevil

  • Hero Member
  • *****
  • Posts: 1998
    • View Profile
    • http://
Windowmaker & (x)vim For Pdaxrom?
« Reply #16 on: December 03, 2005, 10:18:19 pm »
Howdy,

I compiled asclock (originally included in windowmaker but was then left out) with a little tweaking  so that it can be added to the dock with all information (time, week, day, month) intact.  You may wish to  take a look at the top right corner of the following screenshot to see if it fits your need:  



Edited: Forgot to say: To make asclock dockable, launch it from the terminal using:
Code: [Select]
asclock -d &and then drag and drop the icon to desired empty space in the dock.  
Have fun!  
« Last Edit: December 04, 2005, 05:17:11 am by ZDevil »

Life is too precious for hacking *too much*
Visit my Z screencap gallery[/color]
My EeePC 701 Black = Debian (Lenny) on IceRocks + Transcend SDHC Class6 8GB + 2GB RAM
My Zaurus SL-C3200 = Debian EABI (kernel 2.6.24.3-yonggun) on a swapped internal Sandisk Extreme III CF 16gb
My Debian EABI feed: http://matrixmen.free.fr/zaurus/debian/
My OpenBSD/Zaurus feeds:  Link1, Link2
[/i][/font][/color][/size]

john4

  • Newbie
  • *
  • Posts: 41
    • View Profile
Windowmaker & (x)vim For Pdaxrom?
« Reply #17 on: December 06, 2005, 04:49:57 am »
Thank u very much!It is great and smart!
But how can I add the CF-SD card monitor on the desktop?just like it in Matchbox.
The same problem for Volume control.
Is there any suggestion?

iamphet

  • Jr. Member
  • **
  • Posts: 51
    • View Profile
    • http://iamphet.nm.ru
Windowmaker & (x)vim For Pdaxrom?
« Reply #18 on: December 06, 2005, 05:31:41 am »
Quote
But how can I add the CF-SD card monitor on the desktop?just like it in Matchbox.
The same problem for Volume control.
Is there any suggestion?
Yeah, this is the main reason why I coded wmzmon. It can monitor cards and monitor/change sound volume.
Run wmzmon and you will see two rectangles at the bottom. They show the state of your SD/CF cards.
There is a grey column with a black head at the right. Click on its bottom half and you will decrease the volume by 25%, click on its top and try and guess what you get  
You can change layout by editing ~/.wmzmon.xpm or supplying new template at command line (see wmzom --help for detail)
You can switch between normal and alternate layouts with right-clicking on wmzmon's icon.

It seems I have to get down to writing some docs. Although I'm unsure how usable they will be with my English  

john4

  • Newbie
  • *
  • Posts: 41
    • View Profile
Windowmaker & (x)vim For Pdaxrom?
« Reply #19 on: December 07, 2005, 12:50:11 am »
Thank you!I find that WMZOM is very useful.
is there a application use under WM to help to mount or unmount cards visible?

iamphet

  • Jr. Member
  • **
  • Posts: 51
    • View Profile
    • http://iamphet.nm.ru
Windowmaker & (x)vim For Pdaxrom?
« Reply #20 on: December 07, 2005, 02:05:00 am »
Quote
is there a application use under WM to help to mount or unmount cards visible?
Did I understand you correctly you want to mount/unmount cards with stylus "clicks"?
It's fairly easy to add this feature to wmzmon. I'll do it when I find a bit of free time (estimation is a couple of days).

miskinis

  • Sr. Member
  • ****
  • Posts: 348
    • View Profile
    • http://
Windowmaker & (x)vim For Pdaxrom?
« Reply #21 on: December 12, 2005, 02:02:27 pm »
Wow, lots of great stuff here, Thanks!  I have been away from my SL-6000 for
a couple months, and just flashed RC12, and look forward to checking out
wmaker.

As far as VI and VIM, I always seem to run into screen display problems
when using the stock vi to edit the config files after a flash.  It seems to be a lot
better in aterm than the non-X console, but I must be missing some
terminal binding or environment variable to make it update the screen
properly all the time when editing.

If anyone knows how to fix this, please let me know, and thanks again
for all these ipks!

John
_John Miskinis_

iamphet

  • Jr. Member
  • **
  • Posts: 51
    • View Profile
    • http://iamphet.nm.ru
Windowmaker & (x)vim For Pdaxrom?
« Reply #22 on: December 13, 2005, 04:14:50 am »
Quote
I always seem to run into screen display problems
when using the stock vi to edit the config files after a flash
It seems pdaxrom vi is broken (or oriented towards some specific terminal, this is almost the same). My solution is always use Vim: never had any problems with neither pure console nor xterm/rxvt.

Whom it may concern
Here is a new version of wmzmon: I added SD/CF card mount/unmount on click. Version 0.3 will have some documentation... definitely.
« Last Edit: December 13, 2005, 04:17:08 am by iamphet »

ZDevil

  • Hero Member
  • *****
  • Posts: 1998
    • View Profile
    • http://
Windowmaker & (x)vim For Pdaxrom?
« Reply #23 on: December 15, 2005, 05:40:28 pm »
Thanks for the new wmzmon package, iamphet.  It works just fine.
It would be even nicer if there is some minimal usage guide for which color bar corresponds to which function, and how to play with each of them.  
By the way looking at your screenshots again I notice that date and time are already showing in wmzmon.  But I just couldn't find the way to get them shown in it, which is the reason why I compiled asclock.  Or is there actually a trick or command to put them up in wmzmon?  
« Last Edit: December 15, 2005, 05:45:56 pm by ZDevil »

Life is too precious for hacking *too much*
Visit my Z screencap gallery[/color]
My EeePC 701 Black = Debian (Lenny) on IceRocks + Transcend SDHC Class6 8GB + 2GB RAM
My Zaurus SL-C3200 = Debian EABI (kernel 2.6.24.3-yonggun) on a swapped internal Sandisk Extreme III CF 16gb
My Debian EABI feed: http://matrixmen.free.fr/zaurus/debian/
My OpenBSD/Zaurus feeds:  Link1, Link2
[/i][/font][/color][/size]

iamphet

  • Jr. Member
  • **
  • Posts: 51
    • View Profile
    • http://iamphet.nm.ru
Windowmaker & (x)vim For Pdaxrom?
« Reply #24 on: December 16, 2005, 02:11:59 am »
Quote
Thanks for the new wmzmon package, iamphet.  It works just fine.
It would be even nicer if there is some minimal usage guide for which color bar corresponds to which function, and how to play with each of them. 
By the way looking at your screenshots again I notice that date and time are already showing in wmzmon.  But I just couldn't find the way to get them shown in it, which is the reason why I compiled asclock.

You can change the layout by editing your /.wmzmon.xpm. Basically, its format is quite simple, sorta plain vanilla ASCII art.
First section is a legend which correlates letters and colors with monitored events. In the next two sections you can draw two layouts (main and alternate) with letters. To switch to alternate layout either right-click the wmzmon icon or run it with "-a" command-line argument. Default alternate layout has clock in it.
I hope I'll find spare time this weekend to write a piece of documentation. Especially because there are other people besides me interested in wmzmon.

ZDevil

  • Hero Member
  • *****
  • Posts: 1998
    • View Profile
    • http://
Windowmaker & (x)vim For Pdaxrom?
« Reply #25 on: December 16, 2005, 04:47:14 am »
Quote
You can change the layout by editing your /.wmzmon.xpm. Basically, its format is quite simple, sorta plain vanilla ASCII art.
First section is a legend which correlates letters and colors with monitored events. In the next two sections you can draw two layouts (main and alternate) with letters. To switch to alternate layout either right-click the wmzmon icon or run it with "-a" command-line argument. Default alternate layout has clock in it.
I hope I'll find spare time this weekend to write a piece of documentation. Especially because there are other people besides me interested in wmzmon.

Thanks. In my case it is middle click (shift-tap) and not right click (set to Fn-tap) that swap the layout.  Still date and time don't show in the layout.  Lines 91 and 92 of .wmzmon.xpm read:

"Time -*-helvetica-bold-r-normal--11-*-*-*-*-*-*",
"Date -*-helvetica-medium-r-normal--11-*-*-*-*-*-*",

but in the terminal i see this error whenever I switch to the alternative layout that is supposed to show time and date:
Code: [Select]
wmzmon: Warning: Cannot load font -*-helvetica-bold-r-normal--11-*-*-*-*-*-*
wmzmon: Warning: Cannot load font -*-helvetica-medium-r-normal--11-*-*-*-*-*-*
And i can only see two pairs of grey empty rectangular bars on the top corresponding to the time and data in your screenshot.  Changed the font to verdana but still no luck.  Any idea of how to get it to work?  
« Last Edit: December 16, 2005, 04:49:26 am by ZDevil »

Life is too precious for hacking *too much*
Visit my Z screencap gallery[/color]
My EeePC 701 Black = Debian (Lenny) on IceRocks + Transcend SDHC Class6 8GB + 2GB RAM
My Zaurus SL-C3200 = Debian EABI (kernel 2.6.24.3-yonggun) on a swapped internal Sandisk Extreme III CF 16gb
My Debian EABI feed: http://matrixmen.free.fr/zaurus/debian/
My OpenBSD/Zaurus feeds:  Link1, Link2
[/i][/font][/color][/size]

iamphet

  • Jr. Member
  • **
  • Posts: 51
    • View Profile
    • http://iamphet.nm.ru
Windowmaker & (x)vim For Pdaxrom?
« Reply #26 on: December 16, 2005, 05:11:54 am »
Quote
Thanks. In my case it is middle click (shift-tap) and not right click (set to Fn-tap) that swap the layout.  Still date and time don't show in the layout.  Lines 91 and 92 of .wmzmon.xpm read:

"Time -*-helvetica-bold-r-normal--11-*-*-*-*-*-*",
"Date -*-helvetica-medium-r-normal--11-*-*-*-*-*-*",

but in the terminal i see this error whenever I switch to the alternative layout that is supposed to show time and date:
Changed the font to verdana but still no luck. Any idea of how to get it to work?
I can't remember which click I use to switch between layouts so definitely you are right  
I afraid you can't use TTF fonts like verdana at the moment because I wanted to use as few system resources as possible (and to study as little X11 as posssible as well   ).
I'd suggest you to try xfontsel to build a desired font name or just chose one from the xlsfonts output. Hint: --11- is the font size.

john4

  • Newbie
  • *
  • Posts: 41
    • View Profile
Windowmaker & (x)vim For Pdaxrom?
« Reply #27 on: December 16, 2005, 05:55:42 am »
U r the best !

iamphet

  • Jr. Member
  • **
  • Posts: 51
    • View Profile
    • http://iamphet.nm.ru
Windowmaker & (x)vim For Pdaxrom?
« Reply #28 on: December 19, 2005, 02:27:53 am »
I've added some documentation tp /usr/local/share/wmzmon.txt. Also wmzmon.xpm is a little bit more commented as well.
Quoted here for your convenience
Code: [Select]
Introduction
------------

Wmzmon is a customisable dockable system monitor created for WindowMaker
running on Sharp Zaurus.

The available charts are:
    cpu usage
    cpu usage in the form of diagram
    battery status
    memory usage
    swap usage
    sound volume
    SD and CF card
    current date and time

Wmzmon also allows you to change sound volume and mount/unmount SD/CF cards

Each layout (template) can have two variants: normal and alternative.



Invocation
----------

Execute "wmzmon --help" command to get a list of available options.



Interface
---------

Default layout is               Default alternativelayout is
+----------------------+----+   +---------------------------+
|       CPU Load       |Grip|   |         Date              |
|     Memory Usage     +----+   |         Time         +----+
|     Swapfile Usage   | S  |   |     Battery Status   | S  |
|     Battery Status   | o  |   |     Memory Usage     | o  |
|       CPU Graph      | u  |   |     Swapfile Usage   | u  |
+----------+-----------+ n  |   +----------------------+ n  |
|   SD     |     CF    | d  |   |        CPU Graph     | d  |
+----------+-----------+----+   +----------------------+----+

To switch between normal and alternative layouts click the middle "mouse"
button on wmzmon graph.

To mount SD/CF cards you can click on corresponding rectangles.
Grip can be used to drag the wmzmon icon (or just Alt+Click anywhere
on the icon).
Click on top/bottom half of the "Sound" chart to increase/decrease
sound volume.



Customisation
-------------

To change layout you can either supply new one with -t command-line option or
edit the ~/.wmzmon.xpm file.

Since it is just XPM file it can be edited with editor. It's recommended to
manually edit a template because its format is fairly simple and you will not
lose any detail in that way.

Notes on sections (see /usr/local/share/wmzmon.xpm or ~/.wmzmon.xpm for more
detail):
*Legend of colors* contains colors for monitored values
*Template* is a template. You can "draw" here with letters from previous
section. Wmzmon detects rectangle bounds by extreme points, so theoretically
you can supply only top-left and right-bottom point. Although it may be too
unclear :)
*Parameters* is a container for wmzmon parameters.

wmzmon.xpm:

Code: [Select]
/* XPM */
static char * wmzmon_xpm[] = {

/* ----- IMAGE INFORMATION ----- */
/* width height ncolors chars_per_pixel */
"48 48 20 1 0 0 XPMEXT",

/* ----- LEGEND OF COLORS ----- */
/* format:
 * c s
 * is either name or #RRGGBB value
 * you can change only and
 * please DONOT change the order of symbolic names and DON'T remove them!
 * If you need more colors append them to the end*/
/* Processor colors */
"P    c Red s CpuSystem",
"p    c Green s CpuUser",
/* Memory colors */
"M    c Red s RamUsed",
"u    c BlueViolet s RamBuffers",
"c    c Magenta s RamCached",
/* Swap colors */
"S    c Red s Swap",
/* Battery colors */
"B    c Cyan s BatteryOk",
"b    c Gray30 s BatteryCharging",
/* SD Card colors */
"D    c Blue s SdMounted",
/* CF Card colors */
"F    c Blue s CfMounted",
/* Sound volume */
"V    c Gray30 s SoundVolume",
/* CPU Graph colors */
"G    c Red s CpuGraphSystem",
"g    c Green s CpuGraphUser",
/* Date and time */
"I    c Black s TimeForeground",
":    c Gray50 s TimeBackground",
"A    c Black s DateForeground",
"-    c Gray50 s DateBackground",
/* Decorations colors */
".    c Gray50 s Background",
/* You can move an icon without a grip with Alt + mouse combo */
"R    c Gray s Grip", /* actual color doesn't matter */
"+    c Black s Fill",

/* ----- TEMPLATE ----- */
"................................................",
"..++++++++++++++++++++++++++++++++++++...RRRRRR.",
".++PPPPPPPPPPPPPPPPPPPPPPPPPP+++++++P++..RRRRRR.",
".++PPPPPPPPPPPPPPPPPPPPPPPPPP+++++++P++..RRRRRR.",
"..++++++++++++++++++++++++++++++++++++...RRRRRR.",
"................................................",
"................................................",
"..++++++++++++++++++++++++++++++++++++...++++++.",
".++MMMMMMMMMMMMMMMMMMMuuuuucccccccMMM++..+VVVV+.",
".++MMMMMMMMMMMMMMMMMMMuuuuucccccccMMM++..+VVVV+.",
"..++++++++++++++++++++++++++++++++++++...+VVVV+.",
".........................................+VVVV+.",
".........................................+VVVV+.",
"..++++++++++++++++++++++++++++++++++++...+VVVV+.",
".++SSSSSSS++++++++++++++++++++++++++S++..+VVVV+.",
".++SSSSSSS++++++++++++++++++++++++++S++..+VVVV+.",
"..++++++++++++++++++++++++++++++++++++...+VVVV+.",
".........................................+VVVV+.",
".........................................+VVVV+.",
".+++++++++++++++++++++++++++++++++++++...+VVVV+.",
".+BBBBBBBBBBBBBBBBBBBBBBBBBBB+++++++b++..+VVVV+.",
".+BBBBBBBBBBBBBBBBBBBBBBBBBBB+++++++b++..+VVVV+.",
".+BBBBBBBBBBBBBBBBBBBBBBBBBBB+++++++b++..+VVVV+.",
".+BBBBBBBBBBBBBBBBBBBBBBBBBBB+++++++b++..+VVVV+.",
".+++++++++++++++++++++++++++++++++++++...+VVVV+.",
".........................................+VVVV+.",
".........................................+VVVV+.",
".g+++++++++++++++++++++++++++++++++++++..+VVVV+.",
".g+++++++++++++++++++++++++++++++++++++..+VVVV+.",
".gg++++++++++++++++++++++++++++++++++++..+VVVV+.",
".gg++++++++++++++++++++++++++++++++++++..+VVVV+.",
".Gg++++++++++++++++++++++++++++++++++++..+VVVV+.",
".GGg+++++++++++++++++++++++++++++++++++..+VVVV+.",
".GGg++g++++++++++++++++++++++++++++++++..+VVVV+.",
".GGGggggg+++++++++++++++gg++++++g++++++..+VVVV+.",
".GGGggGggg+++g+++++++++ggg++++gggg+++++..+VVVV+.",
".GGGgGGGGggggggg+++gggggggggggggggggggg..+VVVV+.",
".GGGGGGGGGggggggg++ggggGGgggggGGggggggg..+VVVV+.",
".GGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGG..+VVVV+.",
".........................................+VVVV+.",
".++++++++++++++++++++++++++++++++++++++..+VVVV+.",
".+DDDDDDDDDDDDDDDDD++FFFFFFFFFFFFFFFFF+..+VVVV+.",
".+DDDDDDDDDDDDDDDDD++FFFFFFFFFFFFFFFFF+..+VVVV+.",
".+DDDDDDDDDDDDDDDDD++FFFFFFFFFFFFFFFFF+..+VVVV+.",
".+DDDDDDDDDDDDDDDDD++FFFFFFFFFFFFFFFFF+..+VVVV+.",
".++++++++++++++++++++++++++++++++++++++..++++++.",
"................................................",
"................................................",

/* ----- PARAMETERS ----- */
/* --- Misc --- */
"XPMEXT WMZmon.Parameters",
"RefreshInterval 1000", /* Polling interval in milliseconds */
"CpuGraphColumnWidth 2",
/* --- Fonts --- */
/* TTF fonts are not supported
 * use `xfontsel' and `xlsfonts' to get available fonts */
"XPMEXT WMZmon.Fonts",
"Time -*-helvetica-bold-r-normal--11-*-*-*-*-*-*",
"Date -*-helvetica-medium-r-normal--11-*-*-*-*-*-*",
/* --- Formats --- */
/* date/time format, the same as in date(1) and strftime(3) */
"XPMEXT WMZmon.Formats",
"Time %H:%M",
"Date %d-%b-%y",

/* ------ ALTERNATIVE TEMPLATE ----- */
/* use middle mouse button click to switch */
"XPMEXT WMZmon.Alternative",
"................................................",
".----------------------------------------------.",
".-AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA-.",
".-A------------------------------------------A-.",
".-A------------------------------------------A-.",
".-A------------------------------------------A-.",
".-AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA-.",
".-A------------------------------------------A-.",
".-A------------------------------------------A-.",
".-A------------------------------------------A-.",
".-AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA-.",
".----------------------------------------------.",
"................................................",
".::::::::::::::::::::::::::::::::::::::..++++++.",
".:IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII..+VVVV+.",
".:I:::::::::::::::::::::::::::::::::::I..+....+.",
".:I:::::::::::::::::::::::::::::::::::I..+....+.",
".:I:::::::::::::::::::::::::::::::::::I..+....+.",
".:IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII..+....+.",
".:I:::::::::::::::::::::::::::::::::::I..+....+.",
".:I:::::::::::::::::::::::::::::::::::I..+....+.",
".:I:::::::::::::::::::::::::::::::::::I..+....+.",
".:IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII..+....+.",
".::::::::::::::::::::::::::::::::::::::..+....+.",
".........................................+....+.",
".........................................+....+.",
".+++++++++++++++++++++++++++++++++++++...+VVVV+.",
".+BBBBBBBBBBBBBBBBBBBBBBBBBBB+++++++b++..+VVVV+.",
".+BBBBBBBBBBBBBBBBBBBBBBBBBBB+++++++b++..+VVVV+.",
".+++++++++++++++++++++++++++++++++++++...+VVVV+.",
".........................................+....+.",
"..++++++++++++++++++++++++++++++++++++...++++++.",
".++MMMMMMMMMMMMMMMMMMMuuuuucccccccMMM++..+VVVV+.",
".++MMMMMMMMMMMMMMMMMMMuuuuucccccccMMM++..+VVVV+.",
"..++++++++++++++++++++++++++++++++++++...+VVVV+.",
".........................................+....+.",
"..++++++++++++++++++++++++++++++++++++...+VVVV+.",
".++SSSSSSSSSSSSSSSSSSSSSSSSSS+++++++S++..+VVVV+.",
".++SSSSSSSSSSSSSSSSSSSSSSSSSS+++++++S++..+VVVV+.",
"..++++++++++++++++++++++++++++++++++++...+VVVV+.",
".........................................+....+.",
".GGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGG...+VVVV+.",
".GGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGG...+VVVV+.",
".GGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGG...+VVVV+.",
".GGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGG...+VVVV+.",
".GGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGG...+VVVV+.",
".GGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGG...++++++.",
"................................................",
"XPMENDEXT"
};

ZDevil

  • Hero Member
  • *****
  • Posts: 1998
    • View Profile
    • http://
Windowmaker & (x)vim For Pdaxrom?
« Reply #29 on: December 19, 2005, 09:31:30 am »
That's so nice.  Thank you again!  

Perhaps it would be helpful for those who want to have time and date shown by including a brief how-to for using "xfontsel to build a desired font name or just chose one from the xlsfonts output. Hint: --11- is the font size" as you suggested earlier on, because it seems the date and time cannot be displayed straightaway without this tweaking?  (well i'm still in the middle of it...  )

Life is too precious for hacking *too much*
Visit my Z screencap gallery[/color]
My EeePC 701 Black = Debian (Lenny) on IceRocks + Transcend SDHC Class6 8GB + 2GB RAM
My Zaurus SL-C3200 = Debian EABI (kernel 2.6.24.3-yonggun) on a swapped internal Sandisk Extreme III CF 16gb
My Debian EABI feed: http://matrixmen.free.fr/zaurus/debian/
My OpenBSD/Zaurus feeds:  Link1, Link2
[/i][/font][/color][/size]