[bglug] ArchiLinux goes KDE4.1

k|b|s kbs@bglug.it
Mer 30 Lug 2008 16:04:37 CEST


jimmi wrote:
> In GNOME funziona alla grande! In KDE4 no :(
In kde3 c'era un hack. Per il 4 non so. 
Prova a cercare in giro.

Usi ancora mutt? Prenditi questa novizia:
!!cat ~/bin/xfaceunicode

--8<-- CUT HERE --8<-- 
#! /bin/bash
#
# Read a mail message on stdin and output X-Face using unicode block
# characters.  Makes the output a 24x24 text block.
# You obviously need a font that supports those.
#
# Created by Patrice Levesque in 2008, donated to the public domain.

# Set this to 0 or 1 depending on your preference
INVERSE=0

UNCOMPFACE=`which uncompface` || exit
PRINTF=`which printf` || exit
SED=`which sed` || exit
SEQ=`which seq` || exit
CUT=`which cut` || exit

COUNT=0;
for i in 00a0 259d 2598 2580 2597 2590 259a 259c 2596 259e 258c 259b 2584 259f 2599 2588; do
	UNICHAR[$COUNT]=`${PRINTF} "\u$i"`
	let "COUNT += 1"
done

ODDLINES=
EVENLINES=
TOTALCOUNT=0
ARRAYCOUNT=0

for i in `cat "$@" \
| ${SED} -n -e '/^X-Face:/,/^[^ \t]/ p' \
| ${SED} -n -e 's/^X-Face://' -e '/^[ \t]/ p' \
| ${SED} -e 's/^[ \t]\+//' \
| { ${UNCOMPFACE}; }`; do
	if [ $(( $TOTALCOUNT % 2 )) -eq 0 ]; then
		EVENLINES[$ARRAYCOUNT]="$i";
	else
		ODDLINES[$ARRAYCOUNT]="$i";
		let "ARRAYCOUNT += 1"
	fi
	let "TOTALCOUNT += 1"
done

for line in `${SEQ} 0 23`; do
	for word in `${SEQ} 1 3`; do
		EVEN=$( ${PRINTF} "%d" `echo ${EVENLINES[$line]} | ${CUT} -d, -f$word` )
		ODD=$( ${PRINTF} "%d" `echo ${ODDLINES[$line]} | ${CUT} -d, -f$word` )
		# We need two bits.  Shift then OR, then merge the two lines
		for i in `${SEQ} 14 -2 0`; do
			T=$((((($ODD >> $i ) & 3) << 2) + (($EVEN >> $i) & 3)))
			[[ ${INVERSE} -eq 1 ]] && let "T ^= 15"
			echo -n ${UNICHAR[$T]}
		done;
	done;
	echo
done
--8<-- CUT HERE --8<-- 


-- 
Produci, consuma, crepa
echo 8507882250504719905049564247050P | dc



Maggiori informazioni sulla lista bglug