1 | XYPlot plot = (XYPlot) this.subplots.get(i);↵ | | 1 | CategoryPlot plot = (CategoryPlot) this.subplots.get(i);↵
|
|
2 | // calculate sub-plot area↵ | | 2 | // calculate sub-plot area↵
|
3 | if (orientation == PlotOrientation.HORIZONTAL) {↵ | | 3 | if (orientation == PlotOrientation.VERTICAL) {↵
|
4 | double w = usableSize * plot.getWeight() / this.totalWeight;↵ | | 4 | double w = usableSize * plot.getWeight() / this.totalWeight;↵
|
5 | this.subplotAreas[i] = new Rectangle2D.Double(x, y, w,↵ | | 5 | this.subplotArea[i] = new Rectangle2D.Double(x, y, w, ↵
|
6 | adjustedPlotArea.getHeight());↵ | | 6 | adjustedPlotArea.getHeight());↵
|
7 | x = x + w + this.gap;↵ | | 7 | x = x + w + this.gap;↵
|
8 | }↵ | | 8 | }↵
|
9 | else if (orientation == PlotOrientation.VERTICAL) {↵ | | 9 | else if (orientation == PlotOrientation.HORIZONTAL) {↵
|
10 | double h = usableSize * plot.getWeight() / this.totalWeight;↵ | | 10 | double h = usableSize * plot.getWeight() / this.totalWeight;↵
|
11 | this.subplotAreas[i] = new Rectangle2D.Double(x, y,↵ | | 11 | this.subplotArea[i] = new Rectangle2D.Double(x, y, ↵
|
12 | adjustedPlotArea.getWidth(), h);↵ | | 12 | adjustedPlotArea.getWidth(), h);↵
|
13 | y = y + h + this.gap;↵ | | 13 | y = y + h + this.gap;↵
|
14 | }↵ | | 14 | }↵
|
|
15 | AxisSpace subSpace = plot.calculateRangeAxisSpace(g2,↵ | | 15 | AxisSpace subSpace = plot.calculateDomainAxisSpace(g2, ↵
|
16 | this.subplotAreas[i], null);↵ | | 16 | this.subplotArea[i], null);↵
|
17 | space.ensureAtLeast(subSpace); | | 17 | space.ensureAtLeast(subSpace);
|