ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/rxvt-unicode/src/perl/background
(Generate patch)

Comparing rxvt-unicode/src/perl/background (file contents):
Revision 1.77 by root, Tue Sep 4 11:21:11 2012 UTC vs.
Revision 1.82 by sf-exg, Sat Jan 19 10:04:34 2013 UTC

4#:META:X_RESOURCE:%.border:boolean:respect the terminal border 4#:META:X_RESOURCE:%.border:boolean:respect the terminal border
5#:META:X_RESOURCE:%.interval:seconds:minimum time between updates 5#:META:X_RESOURCE:%.interval:seconds:minimum time between updates
6 6
7=head1 NAME 7=head1 NAME
8 8
9 background - manage terminal background 9background - manage terminal background
10 10
11=head1 SYNOPSIS 11=head1 SYNOPSIS
12 12
13 urxvt --background-expr 'background expression' 13 urxvt --background-expr 'background expression'
14 --background-border 14 --background-border
613Clips an image to the given rectangle. If the rectangle is outside the 613Clips an image to the given rectangle. If the rectangle is outside the
614image area (e.g. when C<$x> or C<$y> are negative) or the rectangle is 614image area (e.g. when C<$x> or C<$y> are negative) or the rectangle is
615larger than the image, then the tiling mode defines how the extra pixels 615larger than the image, then the tiling mode defines how the extra pixels
616will be filled. 616will be filled.
617 617
618If C<$x> an C<$y> are missing, then C<0> is assumed for both. 618If C<$x> and C<$y> are missing, then C<0> is assumed for both.
619 619
620If C<$width> and C<$height> are missing, then the window size will be 620If C<$width> and C<$height> are missing, then the window size will be
621assumed. 621assumed.
622 622
623Example: load an image, blur it, and clip it to the window size to save 623Example: load an image, blur it, and clip it to the window size to save
641=item scale $width_factor, $height_factor, $img 641=item scale $width_factor, $height_factor, $img
642 642
643Scales the image by the given factors in horizontal 643Scales the image by the given factors in horizontal
644(C<$width>) and vertical (C<$height>) direction. 644(C<$width>) and vertical (C<$height>) direction.
645 645
646If only one factor is give, it is used for both directions. 646If only one factor is given, it is used for both directions.
647 647
648If no factors are given, scales the image to the window size without 648If no factors are given, scales the image to the window size without
649keeping aspect. 649keeping aspect.
650 650
651=item resize $width, $height, $img 651=item resize $width, $height, $img
776=item rotate $center_x, $center_y, $degrees, $img 776=item rotate $center_x, $center_y, $degrees, $img
777 777
778Rotates the image clockwise by C<$degrees> degrees, around the point at 778Rotates the image clockwise by C<$degrees> degrees, around the point at
779C<$center_x> and C<$center_y> (specified as factor of image width/height). 779C<$center_x> and C<$center_y> (specified as factor of image width/height).
780 780
781Example: rotate the image by 90 degrees around it's center. 781Example: rotate the image by 90 degrees around its center.
782 782
783 rotate 0.5, 0.5, 90, keep { load "$HOME/mybg.png" } 783 rotate 0.5, 0.5, 90, keep { load "$HOME/mybg.png" }
784 784
785=cut 785=cut
786 786
817 817
818 sub tint($$) { 818 sub tint($$) {
819 $_[1]->tint ($_[0]) 819 $_[1]->tint ($_[0])
820 } 820 }
821 821
822=item shade $factor, $img
823
824Shade the image by the given factor.
825
826=cut
827
828 sub shade($$) {
829 $_[1]->shade ($_[0])
830 }
831
822=item contrast $factor, $img 832=item contrast $factor, $img
823 833
824=item contrast $r, $g, $b, $img 834=item contrast $r, $g, $b, $img
825 835
826=item contrast $r, $g, $b, $a, $img 836=item contrast $r, $g, $b, $a, $img
885 $img 895 $img
886 } 896 }
887 897
888=item muladd $mul, $add, $img # EXPERIMENTAL 898=item muladd $mul, $add, $img # EXPERIMENTAL
889 899
890First multipliesthe pixels by C<$mul>, then adds C<$add>. This cna be used 900First multiplies the pixels by C<$mul>, then adds C<$add>. This can be used
891to implement brightness and contrast at the same time, with a wider value 901to implement brightness and contrast at the same time, with a wider value
892range than contrast and brightness operators. 902range than contrast and brightness operators.
893 903
894Due to numerous bugs in XRender implementations, it can also introduce a 904Due to numerous bugs in XRender implementations, it can also introduce a
895number of visual artifacts. 905number of visual artifacts.

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines