Program: 98685
Project: 98685
Buggy source:
public void paintTransform(Transform t,boolean highlight,Graphics2D g){
  Rectangle unit=new Rectangle(getSize());
  Shape rect=t.getTransform().createTransformedShape(unit);
  if (highlight) {
    g.setPaint(new Color(Color.BLUE.getRed(),Color.BLUE.getGreen(),Color.BLUE.getBlue(),128));
  }
 else {
    g.setPaint(new Color(Color.GRAY.getRed(),Color.GRAY.getGreen(),Color.GRAY.getBlue(),128));
  }
  g.fill(rect);
  g.setPaint(Color.BLACK);
  if (highlight) {
    g.setStroke(new BasicStroke(3f,BasicStroke.CAP_SQUARE,BasicStroke.JOIN_MITER,10.0f,new float[]{10f,10f},0f));
  }
 else {
    g.setStroke(new BasicStroke(3f));
  }
  g.draw(rect);
  g.setStroke(new BasicStroke(3f));
  g.setPaint(Color.BLACK);
  int[] cornerX=new int[]{0,0,getWidth(),getWidth()};
  int[] cornerY=new int[]{0,getHeight(),getHeight(),0};
  for (int i=0; i < 4; i++) {
    Point center=new Point();
    t.getTransform().transform(new Point(cornerX[i],cornerY[i]),center);
    Rectangle corner=new Rectangle(center.x - 5,center.y - 5,10,10);
    g.fill(corner);
  }
  Graphics2D gr=(Graphics2D)g.create();
  if (highlight) {
    gr.setPaint(Color.BLACK);
  }
 else {
    gr.setPaint(new Color(Color.BLACK.getRed(),Color.BLACK.getGreen(),Color.BLACK.getBlue(),128));
  }
  gr.setFont(new Font("String_Node_Str",Font.BOLD,25));
  float[] first=new float[2];
  rect.getPathIterator(null).currentSegment(first);
  AffineTransform rotation=new AffineTransform();
  rotation.rotate(t.r,first[0],first[1]);
  gr.setTransform(rotation);
  gr.drawString(String.format("String_Node_Str",t.getId(),(highlight && rotate != null) ? String.format("String_Node_Str",(int)Math.toDegrees(t.r)) : "String_Node_Str"),first[0] + 5,first[1] + 25f);
  gr.dispose();
}

Fixed version (ground truth):
public void paintTransform(Transform t,boolean highlight,Graphics2D g){
  Rectangle unit=new Rectangle(getSize());
  Shape rect=t.getTransform().createTransformedShape(unit);
  if (highlight) {
    g.setPaint(new Color(Color.BLUE.getRed(),Color.BLUE.getGreen(),Color.BLUE.getBlue(),128));
  }
 else {
    g.setPaint(new Color(Color.GRAY.getRed(),Color.GRAY.getGreen(),Color.GRAY.getBlue(),128));
  }
  g.fill(rect);
  g.setPaint(Color.BLACK);
  if (highlight) {
    g.setStroke(new BasicStroke(3f,BasicStroke.CAP_SQUARE,BasicStroke.JOIN_MITER,10.0f,new float[]{10f,10f},0f));
  }
 else {
    g.setStroke(new BasicStroke(3f));
  }
  g.draw(rect);
  g.setStroke(new BasicStroke(3f));
  g.setPaint(Color.BLACK);
  int[] cornerX=new int[]{0,0,getWidth(),getWidth()};
  int[] cornerY=new int[]{0,getHeight(),getHeight(),0};
  for (int i=0; i < 4; i++) {
    Point center=new Point();
    t.getTransform().transform(new Point(cornerX[i],cornerY[i]),center);
    Rectangle corner=new Rectangle(center.x - 5,center.y - 5,10,10);
    g.fill(corner);
  }
  Graphics2D gr=(Graphics2D)g.create();
  if (highlight) {
    gr.setPaint(Color.BLACK);
  }
 else {
    gr.setPaint(new Color(Color.BLACK.getRed(),Color.BLACK.getGreen(),Color.BLACK.getBlue(),128));
  }
  gr.setFont(new Font("String_Node_Str",Font.BOLD,25));
  Point text=new Point();
  t.getTransform().transform(new Point(0,0),text);
  AffineTransform rotation=new AffineTransform();
  rotation.rotate(t.r,text.x,text.y);
  gr.setTransform(rotation);
  gr.drawString(String.format("String_Node_Str",t.getId(),(highlight && rotate != null) ? String.format("String_Node_Str",(int)Math.toDegrees(t.r)) : "String_Node_Str"),text.x + 5,text.y + 25);
  gr.dispose();
}