Sunday 4th September 2016. Updated to 0.8
This is a simple program written in C to generate wallpapers. It was designed to be used in the woof build process but works in a normal puppy (and maybe any linux) environment.
There was something missing with this so I decided to add it - icons or png image on the wallpaper.
The latest version mkwallpaper-0.8 adds this capability. Screen shot below.
Here are the pets built in slacko (latest alpha so may need recompiling for older pups - post pets and I'll link to them - source code is below)
For 32 bit
http://distro.ibiblio.org/puppylinux/pe ... 6_s700.pet
For 64 bit
http://distro.ibiblio.org/puppylinux/pe ... 4_s700.pet
---------------------------------------------------------------------------------------------------
Previous version
Due to user requests I have updated mkwallpaper to 0.7
Changes
- custom save directory
- custom placement - with left,right,center justification
- font style option [B] [I]
- minor bugfixes
Here is a simple version test:
Code: Select all
# read -r a <<< `./mkwallpaper|head -1`
# echo ${a#*-}
Packages are attached below. Included in the source package are a couple of test scripts showing off the new features.
Usage:
Code: Select all
# ./mkwallpaper
mkwallpaper-0.7
Generate SVG or PNG Linux wallpapers. SVG is default.
Usage :
mkwallpaper [-l, -n, -f, -p, -s, -x, -y, -r, -d, -j, -k, -z, -o, -a, -b, -h]
-n [string] image file name
-l [string] label for an image, up to 36 chars
-f [string] a TTF font family
-i ["0|1|2"] integer from 0 - 2 to align text left, centre or right
-p ["png|svg"] "png" or "svg" format
-x [int] width of image in pixels
-y [int] height of image in pixels
-s [int] font size in pixels
-k "yes" : embossed effect on font
-j [tl|bl|tr|br] : (default - br [bottom-right])
-z ["float float float"] floating point RGB, quoted,
space delimited values for colour
(mandatory!) eg: -z "0.1 0.2 0.3"
-o [float] offset: floating point value from 0.0 to 1.0
for the gradient offset
-a [int] angle: integer value from 0 to 20 for the gradient angle
-d [/path/to/directory] destination directory: (default: $HOME)
-b [string] font-style: accepted values are "n" (normal) [the default],
"b" (bold), "i" (italic), "o" (bold-italic).
-h : show this help and exit
------------------------------------
Older 0.6 stuff (NOTE- script won't work correctly with 0.7)
It now does a slight shadow of text with the '-k yes' option
If you are root backgrounds go to /usr/share/backgrounds
If you are unprivileged user they go to $HOME/.local/share/backgrounds (so maybe it works in slackware/ubuntu/debian/arch/distro-of-choice)
Source code <-- https://github.com/puppylinux-woof-CE/p ... kwallpaper
Usage:
Code: Select all
# mkwallpaper
mkwallpaper-0.6
Generate SVG or PNG Puppy Linux wallpapers. SVG is default.
Usage :
mkwallpaper [-l, -n, -f, -p, -s, -x, -y, -r, -w, -h]
-n : image name
-l : label for an image, up to 36 chars
-f : a TTF font family
-p : "png" or "svg" format
-x : width of image in pixels
-y : height of image in pixels
-s : font size in pixels
-k : "yes" : embossed effect on font
-z : floating point RGB, quoted, space delimited values for colour
(mandatory arg!) eg: -z "0.1 0.2 0.3"
-o [offset] floating point value from 0.0 to 1.0 for the gradient offset
-a [angle] integer value from 0 to 20 for the gradient angle
-w : "woof" : FOR WOOF USE ONLY!!!
-h : show this help and exit.
Code: Select all
#!/bin/sh
. /etc/DISTRO_SPECS
x=0
while [ $x -lt 50 ]; do #change the 50 to whatever number you want to try.. but bear in mind you need the space
off="0.${RANDOM}"
ang=($[ 1 + $[ RANDOM % 20 ]])
r="0.${RANDOM}"
g="0.${RANDOM}"
b="0.${RANDOM}"
echo -n "$r $g $b : "
mkwallpaper -n ${DISTRO_FILE_PREFIX}-wall${x} -l "$DISTRO_FILE_PREFIX" -x1024 -y768 -z "$r $g $b" -o"$off" -a"$ang" #-ppng # uncomment if you want png
unset off ang r g b
x=$(($x + 1))
done
Note that these are just simple gradients with the text of your choice (or possibly no text if you use a blank string - eg -l '' - didn't try).
Again.. SVG you say? "But my wallpaper setter only works with 'bla' type images.."
SVG ready wallpaper setter attached.
PETS linked are built in latest slacko betas so won't work in some puppies but I'll build ones for older versions soon. PET attached is built in older slacko-5.7.
NOTE: probably won't work in puppy 4.x as gtk is too old, and maybe rox is too old in some others.
Have fun!
DOWNLOAD
32 bit http://distro.ibiblio.org/puppylinux/pe ... 6_s630.pet
64 bit http://distro.ibiblio.org/puppylinux/pe ... 4_s630.pet