View Single Post
  #6 (permalink)  
Old 05-12-2008, 03:39 PM
damounh damounh is offline
Member
 
Join Date: May 2008
Posts: 5
damounh is on a distinguished road
there are no functions that would draw a triangle for you, however you can use the polygon method in graphics to make any shape you like

heres how it works

Code:
int[] xPoints = {100,50,150}; int[] yPoints = {100,200,200}; g.drawPolygon(xPoints, yPoints, 3);
theres also fillPolygon in case you wish to color it in. You can find all the drawing methods here

i notice ur setting the background color to black, make sure you set the draw color to something else cuz by defaults its black.

Damoun.H.
Reply With Quote