1 | (Color.white);↵ | | 1 | (Color.white);↵
|
2 | yAxisLabel.setBackground(Color.white);↵ | | 2 | yAxisLabel.setBackground(Color.white);↵
|
|
3 | JLabel xLabel = new JLabel(JMeterUtils.getResString("report_chart_x_axis"));↵ | | 3 | JLabel xLabel = new JLabel(JMeterUtils.getResString("report_chart_x_axis"));↵
|
4 | HorizontalPanel xpanel = new HorizontalPanel(Color.white);↵ | | 4 | HorizontalPanel xpanel = new HorizontalPanel(Color.white);↵
|
5 | xLabel.setBorder(new EmptyBorder(5,2,5,2));↵ | | 5 | xLabel.setBorder(new EmptyBorder(5,2,5,2));↵
|
6 | xItems.setBackground(Color.white);↵ | | 6 | xItems.setBackground(Color.white);↵
|
7 | xItems.setValues(AbstractTable.xitems);↵ | | 7 | xItems.setValues(AbstractTable.xitems);↵
|
8 | xpanel.add(xLabel);↵ | | 8 | xpanel.add(xLabel);↵
|
9 | xpanel.add(xItems);↵ | | 9 | xpanel.add(xItems);↵
|
10 | options.add(xpanel);↵ | | 10 | options.add(xpanel);↵
|
|
11 | JLabel xALabel = new JLabel(JMeterUtils.getResString("report_chart_x_axis_label"));↵ | | 11 | JLabel xALabel = new JLabel(JMeterUtils.getResString("report_chart_x_axis_label"));↵
|
12 | HorizontalPanel xApanel = new HorizontalPanel(Color.white);↵ | | 12 | HorizontalPanel xApanel = new HorizontalPanel(Color.white);↵
|
13 | xALabel.setBorder(new EmptyBorder(5,2,5,2));↵ | | 13 | xALabel.setBorder(new EmptyBorder(5,2,5,2));↵
|
14 | xAxisLabel.setBackground(Color.white);↵ | | 14 | xAxisLabel.setBackground(Color.white);↵
|
15 | xAxisLabel.setValues(AbstractChart.X_LABELS);↵ | | 15 | xAxisLabel.setValues(AbstractChart.X_LABELS);↵
|
16 | xApanel.add(xALabel);↵ | | 16 | xApanel.add(xALabel);↵
|
17 | xApanel.add(xAxisLabel);↵ | | 17 | xApanel.add(xAxisLabel);↵
|
18 | options.add(xApanel);↵ | | 18 | options.add(xApanel);↵
|
19 | ↵ | | 19 | ↵
|
20 | JLabel yLabel = new JLabel(JMeterUtils.getResString("report_chart_y_axis"));↵ | | 20 | JLabel yLabel = new JLabel(JMeterUtils.getResString("report_chart_y_axis"));↵
|
21 | HorizontalPanel ypanel = new HorizontalPanel(Color.white);↵ | | 21 | HorizontalPanel ypanel = new HorizontalPanel(Color.white);↵
|
22 | yLabel.setBorder(new EmptyBorder(5,2,5,2));↵ | | 22 | yLabel.setBorder(new EmptyBorder(5,2,5,2));↵
|
23 | yItems.setBackground(Color.white);↵ | | 23 | yItems.setBackground(Color.white);↵
|
24 | yItems.setValues(AbstractTable.items);↵ | | 24 | yItems.setValues(AbstractTable.items);↵
|
25 | ypanel.add(yLabel);↵ | | 25 | ypanel.add(yLabel);↵
|
26 | ypanel.add(yItems);↵ | | 26 | ypanel.add(yItems);↵
|
27 | options.add(ypanel);↵ | | 27 | options.add(ypanel);↵
|
28 | options.add(yAxisLabel);↵ | | 28 | options.add(yAxisLabel);↵
|
29 | options.add(caption);↵ | | 29 | options.add(caption);↵
|
30 | options.add(urls);↵ | | 30 | options.add(url);↵
|
31 | ↵ | | 31 | ↵
|
32 | add(pane,BorderLayout.NORTH);↵ | | 32 | add(pane,BorderLayout.NORTH);↵
|
33 | add(options,BorderLayout.CENTER);↵ | | 33 | add(options,BorderLayout.CENTER);↵
|
34 | }↵ | | 34 | }↵
|
35 | ↵ | | 35 | ↵
|
36 | public TestElement createTestElement() {↵ | | 36 | public TestElement createTestElement() {↵
|
37 | LineChart element = new LineChart();↵ | | 37 | BarChart element = new BarChart();↵
|
38 | modifyTestElement(element);↵ | | 38 | modifyTestElement(element);↵
|
39 | return element;↵ | | 39 | return element;↵
|
40 | }↵ | | 40 | }↵
|
|
41 | public void modifyTestElement(TestElement element) {↵ | | 41 | public void modifyTestElement(TestElement element) {↵
|
42 | this.configureTestElement(element);↵ | | 42 | this.configureTestElement(element);↵
|
43 | LineChart bc = (LineChart)element;↵ | | 43 | BarChart bc = (BarChart)element;↵
|
44 | bc.setXAxis(xItems.getText());↵ | | 44 | bc.setXAxis(xItems.getText());↵
|
45 | bc.setYAxis(yItems.getText());↵ | | 45 | bc.setYAxis(yItems.getText());↵
|
46 | bc.setXLabel(xAxisLabel.getText());↵ | | 46 | bc.setXLabel(xAxisLabel.getText());↵
|
47 | bc.setYLabel(yAxisLabel.getText());↵ | | 47 | bc.setYLabel(yAxisLabel.getText());↵
|
48 | bc.setCaption(caption.getText());↵ | | 48 | bc.setCaption(caption.getText());↵
|
49 | bc.setURLs(urls.getText());↵ | | 49 | bc.setURL(url.getText());↵
|
50 | }↵ | | 50 | }↵
|
51 | ↵ | | 51 | ↵
|
52 | public void configure(TestElement element) {↵ | | 52 | public void configure(TestElement element) {↵
|
53 | super.configure(element);↵ | | 53 | super.configure(element);↵
|
54 | LineChart bc = (LineChart)element;↵ | | 54 | BarChart bc = (BarChart)element;↵
|
55 | xItems.setText(bc.getXAxis());↵ | | 55 | xItems.setText(bc.getXAxis());↵
|
56 | yItems.setText(bc.getYAxis());↵ | | 56 | yItems.setText(bc.getYAxis());↵
|
57 | xAxisLabel.setText(bc.getXLabel());↵ | | 57 | xAxisLabel.setText(bc.getXLabel());↵
|
58 | yAxisLabel.setText(bc.getYLabel());↵ | | 58 | yAxisLabel.setText(bc.getYLabel());↵
|
59 | caption.setText(bc.getCaption());↵ | | 59 | caption.setText(bc.getCaption());↵
|
60 | urls.setText(bc.getURLs());↵ | | 60 | url.setText(bc.getURL());↵
|
61 | | | 61 |
|