jDSGI - Java2D DATA Step Graphics Interface |
Back
-
Next
[ 10 of 27 ]
|
|
|
by Richard A. DeVenezia, Copyright 2004 |
HOME |
|
/*
* Richard A. DeVenezia
* June 1, 2004
*
* jDSGI test 10
*/
data _null_;
if symexist('goutpath') then goutpath=symget('goutpath'); else goutpath=pathname('WORK');
if symexist ('gsftype') then gsftype=symget('gsftype'); else gsftype='png';
gsf = cats(goutPath,"\","test10");
width = 500;
height = 500;
%canvas (_g, width, height, 0ffffffx)
%setColor (int(2**24 * ranuni(1)));
n = 20;
do i = 1 to n;
f = (i-1) / n;
x = width * f;
w = width * 1/n;
%fillRect (x,0,w,height);
if i < n/2
then %setColorDarker();
else %setColorBrighter();
end;
%canvas_saveAs (gsf, gsftype, savedAs);
%canvas_delete();
if savedAs ne '' then call system ("start " || savedAs);
run;