MCDE screenshots: the full desktop, a palette per picture (t0301)
tools/mcde-shot.sh learns MCDE_SHOT_PALETTE (a palette from dt/palettes: its first colour is the background, the text is black) and MCDE_SHOT_FULL (dtsession starts the whole desktop). A holder client keeps the X server from resetting the resource database and the font path when xrdb and xset exit; the palette and share/fonts are in place before the first client starts, so dtwm, the bar and the program take them. The four desktop pictures are taken again with the bar (clock, sound, bluetooth, global menu, M menu), the front panel and the desktop icons, each in another palette: dtwm-4dwm-font.png IRIX, pointer-irix-xcursor.png Charcoal, pointer-solaris-cursors.png Desert, desktop-root-menu.png Default.
No files matched your search
|
Before Width: | Height: | Size: 34 KiB After Width: | Height: | Size: 34 KiB |
|
Before Width: | Height: | Size: 35 KiB After Width: | Height: | Size: 36 KiB |
|
Before Width: | Height: | Size: 37 KiB After Width: | Height: | Size: 37 KiB |
|
Before Width: | Height: | Size: 37 KiB After Width: | Height: | Size: 37 KiB |
@@ -71,6 +71,14 @@ export DISPLAY HOME PATH LD_LIBRARY_PATH XFILESEARCHPATH DTDATABASESEARCHPATH DT
|
||||
# and HOME of the session ("xdotool mousemove 205 212 click 1; xdotool key
|
||||
# space"); keys with a modifier or F-keys through tools/mcde-xkey.sh, not
|
||||
# `xdotool key' (it adds Alt on this keymap, see that script)
|
||||
#
|
||||
# MCDE_SHOT_FULL=1: the whole desktop -- dtsession starts the window manager,
|
||||
# the bar, the front panel, the desktop icons, the sound daemon and the
|
||||
# launcher (sessionetc.d) instead of ttsession+dtwm. MCDE_SHOT_PALETTE=NAME
|
||||
# (or NAME.dp): the palette of the picture, from dt/palettes; its first line
|
||||
# is the background and the text is black. The palette goes into the server's
|
||||
# resources before the clients start, so it works in both modes; a picture
|
||||
# without dtbar (MCDE_SHOT_EXTRA=dtbar) has no bar.
|
||||
if [ -n "${MCDE_SHOT_SETUP:-}" ]; then
|
||||
(cd "$H" && eval "$MCDE_SHOT_SETUP") || exit 1
|
||||
fi
|
||||
@@ -94,14 +102,75 @@ Session() {
|
||||
MCDE_PARENTAL_DEBUG="${MCDE_PARENTAL_DEBUG:-}" \
|
||||
MCDE_DEFAULTS_DEBUG="${MCDE_DEFAULTS_DEBUG:-}" "$@"
|
||||
}
|
||||
Session ttsession -s > "$OUT.log" 2>&1 &
|
||||
tpid=$!
|
||||
sleep 1
|
||||
# the window manager: dtfile waits for its workspace list (Desktop.c,
|
||||
# BuildDesktopLinks), and the frames belong in the picture
|
||||
Session dtwm >> "$OUT.log" 2>&1 &
|
||||
wpid=$!
|
||||
sleep 2
|
||||
# the palette of the picture: a palette file is eight RGB lines; the first is
|
||||
# the background of the colour set (dtsession's colour server writes it into
|
||||
# the server resources, SrvPalette.c writeXrdbColors) and the text is black.
|
||||
# One picture per palette, so the directory shows the range of the desktop.
|
||||
pal=
|
||||
if [ -n "${MCDE_SHOT_PALETTE:-}" ]; then
|
||||
pal=${MCDE_SHOT_PALETTE}
|
||||
case $pal in
|
||||
*.dp) ;;
|
||||
*) pal=$pal.dp ;;
|
||||
esac
|
||||
fi
|
||||
|
||||
tpid= wpid= spid= holdpid=
|
||||
# the palette and the core X fonts go into the server before the first client
|
||||
# of the session starts: a holder keeps the server from resetting the
|
||||
# resource database and the font path when xrdb and xset exit
|
||||
if command -v xprop > /dev/null 2>&1; then
|
||||
xprop -root -spy > /dev/null 2>&1 &
|
||||
holdpid=$!
|
||||
if [ -n "$pal" ]; then
|
||||
dppal=$R/dt/palettes/$pal
|
||||
[ -f "$dppal" ] || dppal=$pal
|
||||
if [ -f "$dppal" ]; then
|
||||
bg=$(sed -n 1p "$dppal")
|
||||
# the text colour of the palette's colour set is not its
|
||||
# second line (that is a shadow); the server picks a
|
||||
# readable foreground -- black on these light backgrounds
|
||||
printf '*background: %s\n*foreground: #000000000000\n' \
|
||||
"$bg" | xrdb -merge
|
||||
fi
|
||||
fi
|
||||
# the core X fonts of the installation: a session gets them from
|
||||
# dtlogin's fontPathTail (config/Xconfig). The -dt-interface aliases
|
||||
# are not added: their Lucida targets are not part of this host, and
|
||||
# the fallback fontset draws the bar's labels in CJK glyphs.
|
||||
if [ -d "$R/dt/share/fonts" ]; then
|
||||
xset fp+ "$R/dt/share/fonts" > /dev/null 2>&1
|
||||
xset fp rehash > /dev/null 2>&1
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ "${MCDE_SHOT_FULL:-0}" = 1 ]; then
|
||||
# the whole desktop: dtsession starts the window manager, the bar, the
|
||||
# front panel, the desktop icons, the sound daemon and the launcher
|
||||
# (sessionetc.d)
|
||||
Session dtsession >> "$OUT.log" 2>&1 &
|
||||
spid=$!
|
||||
sleep 6
|
||||
# a fresh home opens the help volume and a file manager window; the
|
||||
# picture is of the desktop
|
||||
if command -v xdotool > /dev/null 2>&1; then
|
||||
for name in "Help Viewer" "File Manager"; do
|
||||
xdotool search --name "$name" windowclose > /dev/null 2>&1
|
||||
done
|
||||
fi
|
||||
sleep 1
|
||||
else
|
||||
Session ttsession -s > "$OUT.log" 2>&1 &
|
||||
tpid=$!
|
||||
sleep 1
|
||||
# the window manager: dtfile waits for its workspace list (Desktop.c,
|
||||
# BuildDesktopLinks), and the frames belong in the picture
|
||||
Session dtwm >> "$OUT.log" 2>&1 &
|
||||
wpid=$!
|
||||
sleep 2
|
||||
fi
|
||||
[ -n "$holdpid" ] && kill "$holdpid" 2> /dev/null
|
||||
holdpid=
|
||||
Session "$prog" "$@" >> "$OUT.log" 2>&1 &
|
||||
ppid=$!
|
||||
epids=
|
||||
@@ -120,7 +189,7 @@ fi
|
||||
import -window root "$OUT"
|
||||
rc=$?
|
||||
|
||||
kill "$ppid" $epids "$wpid" "$tpid" 2> /dev/null
|
||||
kill "$ppid" $epids $wpid $tpid $spid $holdpid 2> /dev/null
|
||||
sleep 1
|
||||
kill "$xpid" 2> /dev/null
|
||||
wait 2> /dev/null
|
||||
|
||||