source: trunk/util/arb_xpm

Last change on this file was 9777, checked in by westram, 12 years ago

reintegrated branch 'xpmfix'

  • Property svn:executable set to *
File size: 727 bytes
Line 
1#!/bin/bash
2
3editlines() {
4    IFS=" "
5    read XPM
6    while [ ! -z "$XPM" ]; do
7        # echo "XPM='$XPM'"
8        pixmap -f $XPM -geometry 1000x800-0-0 &
9        read XPM
10    done
11}
12
13expandxpm() {
14    local XNAME=${1%.xpm}.xpm
15    find $ARBHOME/lib/pixmaps -name "$XNAME"
16}
17
18expandxpms() {
19    expandxpm $1
20    shift
21    if [ ! -z "$1" ]; then
22        expandxpms $*
23    fi
24}
25
26
27if [ -z "$ARBHOME" ]; then
28    echo '$ARBHOME not set'
29else
30    if [ -z "$1" ]; then
31        echo "Usage: arb_xpm [xxx[.xpm]]+"
32        echo "Edit all given xpms using pixmap"
33        echo "If a xpm occurs multiple times, all get edited"
34    else
35        expandxpms $* | editlines
36        XPM=`find $ARBHOME/lib/pixmaps -name "$XNAME"`
37    fi
38fi
Note: See TracBrowser for help on using the repository browser.