Skip to content

Commit

Permalink
Fix bug in old table renderer (coloring option)
Browse files Browse the repository at this point in the history
  • Loading branch information
edubecks committed Aug 20, 2012
1 parent 54f395b commit 45af1fe
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ protected void createTableImage(Graphics2D graphics, AffineTransform arrangeTran
*/
protected void drawCellColoring(Graphics2D graphics, Integer x, Integer y, Integer width, Integer height, String value, Float valueNormalized, Color color) {
int x1 = x;
int y2 = (int) (height * Float.parseFloat(value));
int y2 = (int) (height * valueNormalized);
int y1 = (y + height) - y2;
int x2 = width - 1;
graphics.setColor(color);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ public String getDisplayName() {
@Override
protected void renderToGraphics(Graphics2D graphics2D, AffineTransform origin, Integer width, Integer height) {

// creating dataset forjreechart
// creating dataset for jreechart
DefaultPieDataset dataset = new DefaultPieDataset();
for (int i = 0; i < values.size(); i++) {
dataset.setValue(labels.get(i).toString(), values.get(i));
Expand Down

0 comments on commit 45af1fe

Please sign in to comment.