[CSC 204] Re: Line Thickness
Andrew J. Pounds
pounds at theochem.mercer.edu
Sun Jan 30 08:15:47 EST 2011
> Hey Dr. Pounds,
>
> I am finishing up my MercMan Lab and I am a little confused about
> adjusting the line thickness. I looked online and saw that I am
> supposed to have a "setThickness" in my program but I am not sure how
> to put it in.
>
>
What you need is the setStroke method. In my code I call
g2.setStroke(new BasicStroke(20));
before I draw it with the call...
Line2D.Double leftArm = new Line2D.Double( .... arguments... )
g2.draw(leftArm);
then when I want to draw something "thicker" I do a
g2.setStroke(new BasicStroke(40));
before I draw it
Let me know what other questions you have or what difficulties you are
experiencing.
--
Andrew J. Pounds, Ph.D. (pounds at theochem.mercer.edu)
Associate Professor of Chemistry and Computer Science
Mercer University, Macon, GA 31207 (478) 301-5627
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://theochem.mercer.edu/pipermail/csc204/attachments/20110130/2ce7b019/attachment.html
More information about the csc204
mailing list