Program: 69870
Project: 69870
Buggy source:
protected void drawCellDiagonal(CellArea cell){
  DiagonalInfo diagonalInfo=cell.getDiagonalInfo();
  if (diagonalInfo != null) {
    int startX=currentX + getX(cell);
    int startY=currentY + getY(cell);
    int width=getWidth(cell);
    int height=getHeight(cell);
    int dw=diagonalInfo.getDiagonalWidth();
    int ds=diagonalInfo.getDiagonalStyle();
    if (ds == DiagonalInfo.BORDER_STYLE_DOUBLE) {
      ds=DiagonalInfo.BORDER_STYLE_SOLID;
    }
switch (diagonalInfo.getDiagonalNumber()) {
case 2:
      pageGraphic.drawLine(startX,startY + dw / 2,startX + width,startY + height / 2 - dw / 2,getScaledValue(diagonalInfo.getDiagonalWidth()),diagonalInfo.getColor(),ds);
    pageGraphic.drawLine(startX,startY + dw / 2,startX + width / 2,startY + height - dw / 2,getScaledValue(dw),diagonalInfo.getColor(),ds);
  break;
case 3:
pageGraphic.drawLine(startX,startY + dw / 2,startX + width,startY + height - dw / 2,getScaledValue(dw),diagonalInfo.getColor(),ds);
pageGraphic.drawLine(startX,startY + dw / 2,startX + width,startY + height / 2 - dw / 2,getScaledValue(dw),diagonalInfo.getColor(),ds);
pageGraphic.drawLine(startX,startY + dw / 2,startX + width / 2,startY + height - dw / 2,getScaledValue(dw),diagonalInfo.getColor(),ds);
break;
default :
pageGraphic.drawLine(startX,startY + dw / 2,startX + width,startY + height - dw / 2,getScaledValue(dw),diagonalInfo.getColor(),ds);
break;
}
dw=diagonalInfo.getAntidiagonalWidth();
ds=diagonalInfo.getAntidiagonalStyle();
if (ds == DiagonalInfo.BORDER_STYLE_DOUBLE) {
ds=DiagonalInfo.BORDER_STYLE_SOLID;
}
switch (diagonalInfo.getAntidiagonalNumber()) {
case 2:
pageGraphic.drawLine(startX,startY + height - dw / 2,startX + width / 2,startY + dw / 2,getScaledValue(diagonalInfo.getAntidiagonalWidth()),diagonalInfo.getColor(),ds);
pageGraphic.drawLine(startX,startY + height - dw / 2,startX + width,startY + height / 2,getScaledValue(diagonalInfo.getAntidiagonalWidth()),diagonalInfo.getColor(),ds);
break;
case 3:
pageGraphic.drawLine(startX,startY + height - dw / 2,startX + width / 2,startY + dw / 2,getScaledValue(diagonalInfo.getAntidiagonalWidth()),diagonalInfo.getColor(),ds);
pageGraphic.drawLine(startX,startY + height - dw / 2,startX + width,startY + height / 2,getScaledValue(diagonalInfo.getAntidiagonalWidth()),diagonalInfo.getColor(),ds);
pageGraphic.drawLine(startX,startY + height - dw / 2,startX + width,startY + dw / 2,getScaledValue(diagonalInfo.getAntidiagonalWidth()),diagonalInfo.getColor(),ds);
break;
default :
pageGraphic.drawLine(startX,startY + height - dw / 2,startX + width,startY + dw / 2,getScaledValue(diagonalInfo.getAntidiagonalWidth()),diagonalInfo.getColor(),ds);
break;
}
}
}

Fixed version (ground truth):
protected void drawCellDiagonal(CellArea cell){
  DiagonalInfo diagonalInfo=cell.getDiagonalInfo();
  if (diagonalInfo != null) {
    int startX=currentX + getX(cell);
    int startY=currentY + getY(cell);
    int width=getWidth(cell);
    int height=getHeight(cell);
    int dw=diagonalInfo.getDiagonalWidth();
    int ds=diagonalInfo.getDiagonalStyle();
    if (ds == DiagonalInfo.BORDER_STYLE_DOUBLE) {
      ds=DiagonalInfo.BORDER_STYLE_SOLID;
    }
switch (diagonalInfo.getDiagonalNumber()) {
case 2:
      pageGraphic.drawLine(startX + width / 2,startY,startX + width,startY + height - dw / 2,getScaledValue(dw),diagonalInfo.getColor(),ds);
    pageGraphic.drawLine(startX,startY + height / 2,startX + width,startY + height - dw / 2,getScaledValue(dw),diagonalInfo.getColor(),ds);
  break;
case 3:
pageGraphic.drawLine(startX,startY + dw / 2,startX + width,startY + height - dw / 2,getScaledValue(dw),diagonalInfo.getColor(),ds);
pageGraphic.drawLine(startX + width / 2,startY + dw / 2,startX + width,startY + height - dw / 2,getScaledValue(dw),diagonalInfo.getColor(),ds);
pageGraphic.drawLine(startX,startY + height / 2,startX + width,startY + height - dw / 2,getScaledValue(dw),diagonalInfo.getColor(),ds);
break;
default :
pageGraphic.drawLine(startX,startY + dw / 2,startX + width,startY + height - dw / 2,getScaledValue(dw),diagonalInfo.getColor(),ds);
break;
}
}
}