![]() |
Bar graphs running under a seperate class
Hey everyone,
Having a little problem creating some bar graphs. What I am suppose to do is be able to create some bar for a bar graph, at different heights. With this when you click on it, the bar is select and you are able to change the height using a mouse interface. Also you can add more bars to the bar graph. This is using a gui interface. for my bar graphs, i need to use a class to create all the bars, but there is another class calling all of these methods. These methods are: the constructor public void setValuesAndLabels(double []values, String []labels, int nbr) public int getCurrentBar(int value) public void setCurrentBar(int value) public int getNbrBars() public int getMaxBars() public double getBarValue(int idx public void setBarValue(int idx, double value) public String getBarLabel(int idx) public void setBarLabel(int idx, String value) public void addBar(double val, String lbl) public void paintComponent(Graphics g) public Boolean addBarChartListener(BarChartListener b) Can anyone help?? -Master Chief will save us all- |
Show some code.
|
I need some help with the code
|
im going to be using a rectangle class for the bars, and seperate colors for each of the bars
|
| All times are GMT -5. The time now is 1:54 AM. |
Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC