[Image] [Image]

www.ArminHanisch.de

You are here: 

MOCwall

4/6/2003

Description

Use mocwall to generate a background bitmap for the desktop and optionally set this bitmap as the active wallpaper. Mocwall has been designed during
my time as MCT for our setup systems in the training center. We had to incorporate the company logo, some machine data like IP addr and hostname
as well as the course number.

To generate a wallpaper, you use a definition file in text form, which can easily be generated from another program to support the shell concept of
command chaining. To create the wallpaper, execute Mocwall with the name of the definition file as the first parameter. The program runs on Windows NT4/2000/XP/2003. No installation necessary, just copy the executable anywhere you like it. The program doens not use
the registry or needs any runtime. Uninstall is easy - just delete the executable and your done.

Download the software here.

Usage:

mocwall <filename> [ <options> ]

<filename> = file containing the wallpaper definition

<options> = -set set as active wallpaper
-expand expand environment variable names in definition file
-expnice same as -expand, but trim and lowecase variable content

Format of definition file:

All lines starting with a ";" are comments and will be ignored. Command lines are one or more occurences of ons of these commands:

color <name> <r>, <g>, <b>
Defines an alias for a color, e.g. color blue 0, 0, 255

wall <with>, <height>, <bpp>, <filename>
Defines the dimension of the wallpaper, color depth and its file name
e.g. wall 1024, 768, 16, "c:\windows\wall.bmp"

rect <x1>, <y1>, <x2>, <y2>, <color_alias>
Generate a filled rectangle, use 0 to specify wallpaper size,
e.g. rect 0, 0, 0, 0, blue will file the complete wallpaper with blue

frame <x1>, <y1>, <x2>, <y2>, <color_alias>, <width>
Generate a rectangular frame with <width> pxiels brush width
use 0 to specify wallpaper size (see rect)

pict <x>, <y>, <filename>
Insert picture at <x>, <y>, <filename> has to specify a valid
bitmap (.BMP) file

Text <x>, <y>, <font>, <size>, <fore>, <back>, <style>, <text>
Display text at location <x>, <y>
<font> is the font name in double quotes (e.g. "Tahoma")
<size> is the size in points
<fore> is the foreground color alias
<back> is the background color alias or the reserved word transparent
for no background color
<style> is a string in double quotes, either empty ("") or a combination
of the letters "u" (underline), "i" (italic) or "b" (boldface)
<text> well, the text you'd like to diplay (in double quotes)

Example: Text 20, 400, "Verdana", 24, black, transparent, "b", "Armin"

If you would like to generate right-aligned text, or bottom-aligned text, you can use negative values to specify the distance from the lower or right
screen border.

Example of a definition file

color Schwarz 0, 0, 0
color Weiss 255, 255, 255
color Orange 255, 153, 51
color Hellblau 51, 153, 255
color Rot 255,0,0
; rect x1, y1, x2 | -1 (max), y2 | -1 (max), red, green, blue
; 0 is allowed for wall size = will detect current screen resolution
Wall 1024, 768, 24, ".\wall.bmp"
Rect 0, 0, 0, 0, hellblau
; 0 for x2 or y2 means size of screen
; neagtive values means dist from lower right border
Rect 0, 0, 90, 0, weiss
;Pict 150, 300, "c:\temp\seattle.bmp"
Text -20, 50, "Arial", 36, orange, hellblau, "", "|%WINDIR%|"
Text 250, 100, "Verdana", 127, schwarz, weiss, "b", "EN"
Text -20, 200, "Verdana", 240, orange, transparent, "b", "Training"
; if background color name is "transparent", background will be transparent
Text -20, 400, "Verdana", 24, schwarz, transparent, "b", "Armin"
; negative values means dist from lower right corner
Frame 300, 300, 400, 400, rot, 4

Feedback

I would like to know if you find the program useful or if there is a bug. Please visit www.ArminHanisch.de/contact.html to get the current eMail address. Although there are currently no plans for further development, if will try to find the time and fix any bugs still in the program.

License / legalese stuff

Copyright (c) 2002 by Armin Hanisch / Midnight! Software This tool is freeware and may be distributed freely, provided this text will be in the archive. You may use it in commercial environments. While this program has been extensively testes, there is a possibility that the code stills contains errors. Usage
of the software is granted on as "as is" basis. All I can guarantee ist that the program will take up disk space on your machine. I can give no individual free support for the software, everything a user needs ot know is contianed in this document. New versions due to bugfixes will be made available at www.ArminHanisch.de/software/