CloneSet124


Previous CloneSetNext CloneSetBack to Main Report
Clone
Mass
Clones in
CloneSet
Parameter
Count
Clone
Similarity
Syntax Category
[Sequence Length]
51220.979statement_sequence[10]
Clone AbstractionParameter Bindings
Clone Instance
(Click to see clone)
Line CountSource Line
Source File
151867
E:/TSE/Projects-CloneDR/jfreechart-1.0.10/src/org/jfree/chart/renderer/category/BarRenderer.java
251725
E:/TSE/Projects-CloneDR/jfreechart-1.0.10/src/org/jfree/chart/renderer/xy/XYBarRenderer.java
Next
Last
Clone Instance
1
Line Count
51
Source Line
867
Source File
E:/TSE/Projects-CloneDR/jfreechart-1.0.10/src/org/jfree/chart/renderer/category/BarRenderer.java

if (label == null) {
  return; // nothing to do
}
Font labelFont = getItemLabelFont(row, column);
g2.setFont(labelFont);
Paint paint = getItemLabelPaint(row, column);
g2.setPaint(paint);
// find out where to place the label...
ItemLabelPosition position = null;
if ( !negative) {
  position = getPositiveItemLabelPosition(row, column);
}
else {
  position = getNegativeItemLabelPosition(row, column);
}
// work out the label anchor point...
Point2D anchorPoint = calculateLabelAnchorPoint(position.getItemLabelAnchor(), bar, plot.getOrientation());
if (isInternalAnchor(position.getItemLabelAnchor())) {
  Shape bounds = TextUtilities.calculateRotatedStringBounds(label, g2, (float) anchorPoint.getX(), (float) anchorPoint.getY(), position.getTextAnchor(), position.getAngle(), position.getRotationAnchor());
  if (bounds != null) {
    if ( !bar.contains(bounds.getBounds2D())) {
      if ( !negative) {
        position = getPositiveItemLabelPositionFallback();
      }
      else {
        position = getNegativeItemLabelPositionFallback();
      }
      if (position != null) {
        anchorPoint = calculateLabelAnchorPoint(position.getItemLabelAnchor(), bar, plot.getOrientation());
      }
    }
  }
}
if (position != null) {
  TextUtilities.drawRotatedString(label, g2, (float) anchorPoint.getX(), (float) anchorPoint.getY(), position.getTextAnchor(), position.getAngle(), position.getRotationAnchor());
}


First
Previous
Clone Instance
2
Line Count
51
Source Line
725
Source File
E:/TSE/Projects-CloneDR/jfreechart-1.0.10/src/org/jfree/chart/renderer/xy/XYBarRenderer.java

if (label == null) {
  return; // nothing to do   
}
Font labelFont = getItemLabelFont(series, item);
g2.setFont(labelFont);
Paint paint = getItemLabelPaint(series, item);
g2.setPaint(paint);
// find out where to place the label...
ItemLabelPosition position = null;
if ( !negative) {
  position = getPositiveItemLabelPosition(series, item);
}
else {
  position = getNegativeItemLabelPosition(series, item);
}
// work out the label anchor point...
Point2D anchorPoint = calculateLabelAnchorPoint(position.getItemLabelAnchor(), bar, plot.getOrientation());
if (isInternalAnchor(position.getItemLabelAnchor())) {
  Shape bounds = TextUtilities.calculateRotatedStringBounds(label, g2, (float) anchorPoint.getX(), (float) anchorPoint.getY(), position.getTextAnchor(), position.getAngle(), position.getRotationAnchor());
  if (bounds != null) {
    if ( !bar.contains(bounds.getBounds2D())) {
      if ( !negative) {
        position = getPositiveItemLabelPositionFallback();
      }
      else {
        position = getNegativeItemLabelPositionFallback();
      }
      if (position != null) {
        anchorPoint = calculateLabelAnchorPoint(position.getItemLabelAnchor(), bar, plot.getOrientation());
      }
    }
  }
}
if (position != null) {
  TextUtilities.drawRotatedString(label, g2, (float) anchorPoint.getX(), (float) anchorPoint.getY(), position.getTextAnchor(), position.getAngle(), position.getRotationAnchor());
}


Clone AbstractionParameter Count: 2Parameter Bindings

if (label == null) {
  return; // nothing to do // nothing to do   
}
Font labelFont = getItemLabelFont( [[#variable1aa564a0]],  [[#variable1aa50da0]]);
g2.setFont(labelFont);
Paint paint = getItemLabelPaint( [[#variable1aa564a0]],  [[#variable1aa50da0]]);
g2.setPaint(paint);
// find out where to place the label...
ItemLabelPosition position = null;
if ( !negative) {
  position = getPositiveItemLabelPosition( [[#variable1aa564a0]],  [[#variable1aa50da0]]);
}
else {
  position = getNegativeItemLabelPosition( [[#variable1aa564a0]],  [[#variable1aa50da0]]);
}
// work out the label anchor point...
Point2D anchorPoint = calculateLabelAnchorPoint(position.getItemLabelAnchor(), bar, plot.getOrientation());
if (isInternalAnchor(position.getItemLabelAnchor())) {
  Shape bounds = TextUtilities.calculateRotatedStringBounds(label, g2, (float) anchorPoint.getX(), (float) anchorPoint.getY(), position.getTextAnchor(), position.getAngle(), position.getRotationAnchor());
  if (bounds != null) {
    if ( !bar.contains(bounds.getBounds2D())) {
      if ( !negative) {
        position = getPositiveItemLabelPositionFallback();
      }
      else {
        position = getNegativeItemLabelPositionFallback();
      }
      if (position != null) {
        anchorPoint = calculateLabelAnchorPoint(position.getItemLabelAnchor(), bar, plot.getOrientation());
      }
    }
  }
}
if (position != null) {
  TextUtilities.drawRotatedString(label, g2, (float) anchorPoint.getX(), (float) anchorPoint.getY(), position.getTextAnchor(), position.getAngle(), position.getRotationAnchor());
}
 

CloneAbstraction
Parameter Bindings
Parameter
Index
Clone
Instance
Parameter
Name
Value
11[[#1aa564a0]]
row 
12[[#1aa564a0]]
series 
21[[#1aa50da0]]
column 
22[[#1aa50da0]]
item