<! [CDATA [$min=49; # Valor mínim de color R, G o B $max=174; # Valor màxim de color R, G o B $step=5; # Increment a cada passa de color $sleeptime=15; # Interval en segons entre cada passa @ start = ($max, $min, $min); @ colour = @ start; while (1) {foreach (0.. 5) {my $which = $_% 3; # Quin color (R, G o B) canviar my $updown = $_% 2; # Indica si s' incrementa o disminueix el valor de color do {if ($updown == 0) {$colour[ $which] +=$step;} if ($updown == 1) {$colour[ $which] - =$step;} my $dcopcall=sprintf "dcop kdesktop KBackgroundIface setColor '#% x% x% x' true\", @ colour; system( $dcopcall); sleep $sleeptime;} while (($colour[ $which] > = $min) and ($colour[ $which] < = $max));}}]] >
< ![CDATA[ $min =49; # Minimum value of R, G, or B colour $max=174; # Maximum value of R, G, or B colour $step=5; # Amount to step colour by on each step $sleeptime=15; # Interval in seconds between each step @start = ($max, $min, $min); @colour = @start; while (1) {foreach (0..5) {my $which = $_% 3; # Which colour (R, G or B) to change my $updown = $_% 2; # Whether to increase or decrease the colour value do {if ($updown == 0) {$colour[$which]+=$step;} if ($updown == 1) {$colour[$which]-=$step;} my $dcopcall=sprintf "dcop kdesktop KBackgroundIface setColor '#%x%x%x' true\ ", @colour; system($dcopcall); sleep $sleeptime;} while (($colour[$which] > = $min) and ($colour[$which ]< = $max));}}]] >