An excellent platform independent vector drawing gift for you!
Home | Products | Download | Documentations | Order Now | Contact |  
 
FAQs
Quick Install
Developer Guide
ScreenShots
Award
 
    Java.net
    AbleStable
    Softpedia
    FreeTrialSoft
    FreshMeat
    Download32
    More...
  Developer Guide(Reversed Colors) - JFImagine.com

[Prior]   [Top]   [Next]

5. A new look and feel drawing panel with reversed colors


        Make your graph drawing CAD like.

    If you need to draw white shapes on a totally black background, you'll get trouble in former version of JFDraw. But now you need only to turn off or turn on the reverse switch, there is almost no other things need to do!

         Sample codes of a reversed color DrawCanvas.

//Action: create a draw panel
//Desc: A DrawPane object packaged a vertical ruler, a horizontal ruler and a drawing canvas

DrawPane panel =new DrawPane();

//Action: get the draw canvas which is inside of a DrawPane object.
//Desc: A DrawCanvas object is used to draw all of the shapes

DrawCanvas canvas =panel.getDrawCanvas();

//set current canvas into a reverse color
canvas.setReverse(true);

         Screenshot of this sample.

    Now you can take a look at this reversed drawing canvas. Is it you wanted?

   

 

        To get full source code of this sample.

    You can download the full sample source code package here. Then open the file at sample3/Sample3.java for detail informations.

 

[Prior]   [Top]   [Next]