Package org.apache.jmeter.gui.util

Examples of org.apache.jmeter.gui.util.HorizontalPanel


    JLabel label = new JLabel(JMeterUtils.getResString("port")); // $NON-NLS-1$
    label.setLabelFor(portField);

   
    HorizontalPanel panel = new HorizontalPanel();
    panel.add(label);
    panel.add(portField);

    panel.add(Box.createHorizontalStrut(10));

    return panel;
  }
View Full Code Here


    // OPTIONAL TASKS
      JPanel optionalTasksPanel = new VerticalPanel();
    optionalTasksPanel.setBorder(BorderFactory.createTitledBorder(BorderFactory.createEtchedBorder(), JMeterUtils
        .getResString("optional_tasks"))); // $NON-NLS-1$

    JPanel checkBoxPanel = new HorizontalPanel();
    // RETRIEVE IMAGES
    getImages = new JCheckBox(JMeterUtils.getResString("web_testing_retrieve_images")); // $NON-NLS-1$
    // Is monitor
    isMon = new JCheckBox(JMeterUtils.getResString("monitor_is_title")); // $NON-NLS-1$
        // Use MD5
        useMD5 = new JCheckBox(JMeterUtils.getResString("response_save_as_md5")); // $NON-NLS-1$

        checkBoxPanel.add(getImages);
    checkBoxPanel.add(isMon);
        checkBoxPanel.add(useMD5);
        optionalTasksPanel.add(checkBoxPanel);

    // Embedded URL match regex
    embeddedRE = new JLabeledTextField(JMeterUtils.getResString("web_testing_embedded_url_pattern"),30); // $NON-NLS-1$
    optionalTasksPanel.add(embeddedRE);
View Full Code Here

    folderBox = new JTextField(INBOX, 10);
    folderPanel.add(folderLabel);
    folderPanel.add(folderBox);
    add(folderPanel);

    HorizontalPanel numMessagesPanel = new HorizontalPanel();
    numMessagesPanel.add(new JLabel(NumMessagesLabel));
    ButtonGroup nmbg = new ButtonGroup();
    allMessagesButton = new JRadioButton(AllMessagesLabel);
    allMessagesButton.addChangeListener(new ChangeListener() {
      public void stateChanged(ChangeEvent e) {
        if (allMessagesButton.isSelected()) {
          someMessagesField.setEnabled(false);
        }
      }
    });
    someMessagesButton = new JRadioButton();
    someMessagesButton.addChangeListener(new ChangeListener() {
      public void stateChanged(ChangeEvent e) {
        if (someMessagesButton.isSelected()) {
          someMessagesField.setEnabled(true);
        }
      }
    });
    nmbg.add(allMessagesButton);
    nmbg.add(someMessagesButton);
    someMessagesField = new JTextField(5);
    allMessagesButton.setSelected(true);
    numMessagesPanel.add(allMessagesButton);
    numMessagesPanel.add(someMessagesButton);
    numMessagesPanel.add(someMessagesField);
    add(numMessagesPanel);

    deleteBox = new JCheckBox(DeleteLabel);
    add(deleteBox);
  }
View Full Code Here

        VerticalPanel options = new VerticalPanel(Color.white);
        xAxisLabel.setBackground(Color.white);
        yAxisLabel.setBackground(Color.white);

        JLabel xLabel = new JLabel(JMeterUtils.getResString("report_chart_x_axis"));
    HorizontalPanel xpanel = new HorizontalPanel(Color.white);
    xLabel.setBorder(new EmptyBorder(5,2,5,2));
        xItems.setBackground(Color.white);
        xItems.setValues(AbstractTable.xitems);
        xpanel.add(xLabel);
        xpanel.add(xItems);
        options.add(xpanel);

        JLabel xALabel = new JLabel(JMeterUtils.getResString("report_chart_x_axis_label"));
        HorizontalPanel xApanel = new HorizontalPanel(Color.white);
        xALabel.setBorder(new EmptyBorder(5,2,5,2));
        xAxisLabel.setBackground(Color.white);
        xAxisLabel.setValues(AbstractChart.X_LABELS);
        xApanel.add(xALabel);
        xApanel.add(xAxisLabel);
        options.add(xApanel);
       
    JLabel yLabel = new JLabel(JMeterUtils.getResString("report_chart_y_axis"));
    HorizontalPanel ypanel = new HorizontalPanel(Color.white);
    yLabel.setBorder(new EmptyBorder(5,2,5,2));
        yItems.setBackground(Color.white);
        yItems.setValues(AbstractTable.items);
        ypanel.add(yLabel);
        ypanel.add(yItems);
        options.add(ypanel);
        options.add(yAxisLabel);
        options.add(caption);
        options.add(url);
       
View Full Code Here

       
        VerticalPanel options = new VerticalPanel(Color.white);
        yAxisLabel.setBackground(Color.white);

        JLabel xLabel = new JLabel(JMeterUtils.getResString("report_chart_x_axis"));
    HorizontalPanel xpanel = new HorizontalPanel(Color.white);
    xLabel.setBorder(new EmptyBorder(5,2,5,2));
        xItems.setBackground(Color.white);
        xItems.setValues(AbstractTable.xitems);
        xpanel.add(xLabel);
        xpanel.add(xItems);
        options.add(xpanel);

        JLabel xALabel = new JLabel(JMeterUtils.getResString("report_chart_x_axis_label"));
        HorizontalPanel xApanel = new HorizontalPanel(Color.white);
        xALabel.setBorder(new EmptyBorder(5,2,5,2));
        xAxisLabel.setBackground(Color.white);
        xAxisLabel.setValues(AbstractChart.X_LABELS);
        xApanel.add(xALabel);
        xApanel.add(xAxisLabel);
        options.add(xApanel);
       
    JLabel yLabel = new JLabel(JMeterUtils.getResString("report_chart_y_axis"));
    HorizontalPanel ypanel = new HorizontalPanel(Color.white);
    yLabel.setBorder(new EmptyBorder(5,2,5,2));
        yItems.setBackground(Color.white);
        yItems.setValues(AbstractTable.items);
        ypanel.add(yLabel);
        ypanel.add(yItems);
        options.add(ypanel);
        options.add(yAxisLabel);
        options.add(caption);
        options.add(urls);
       
View Full Code Here

    classnameCombo.addActionListener(this);
    classnameCombo.setName(CLASSNAMECOMBO);
    classnameCombo.setEditable(false);
    label.setLabelFor(classnameCombo);

    HorizontalPanel panel = new HorizontalPanel();
    panel.add(label);
    panel.add(classnameCombo);

    return panel;
  }
View Full Code Here

    setLayout(new VerticalLayout(5, VerticalLayout.BOTH, VerticalLayout.TOP));
    setBorder(makeBorder());
    add(makeTitlePanel());

    // Target
    HorizontalPanel targetPanel = new HorizontalPanel();
    targetPanel.add(new JLabel(targetLabel));
    DefaultComboBoxModel targetModel = new DefaultComboBoxModel();
    targetModel.addElement(threadTarget);
    targetModel.addElement(testTarget);
    targetBox = new JComboBox(targetModel);
    targetBox.addActionListener(new ActionListener() {
      public void actionPerformed(ActionEvent e) {
        if (((String) targetBox.getSelectedItem()).equals(threadTarget)) {
          target = TestAction.THREAD;
        } else {
          target = TestAction.TEST;
        }
      }
    });
    targetPanel.add(targetBox);
    add(targetPanel);

    // Action
    HorizontalPanel actionPanel = new HorizontalPanel();
    ButtonGroup actionButtons = new ButtonGroup();
    pauseButton = new JRadioButton(pauseAction, true);
    pauseButton.addChangeListener(new ChangeListener() {
      public void stateChanged(ChangeEvent e) {
        if (pauseButton.isSelected()) {
          action = TestAction.PAUSE;
          durationField.setEnabled(true);
        }

      }
    });
    stopButton = new JRadioButton(stopAction, false);
    stopButton.addChangeListener(new ChangeListener() {
      public void stateChanged(ChangeEvent e) {
        if (stopButton.isSelected()) {
          action = TestAction.STOP;
          durationField.setEnabled(false);
        }
      }
    });
    actionButtons.add(pauseButton);
    actionButtons.add(stopButton);
    actionPanel.add(new JLabel(actionLabel));
    actionPanel.add(pauseButton);
    actionPanel.add(stopButton);
    add(actionPanel);

    // Duration
    HorizontalPanel durationPanel = new HorizontalPanel();
    durationField = new JTextField(15);
    durationField.setText("");
    durationField.addFocusListener(new FocusListener() {
      public void focusLost(FocusEvent e) {
        durationString = durationField.getText();
      }

      public void focusGained(FocusEvent e) {
      }
    });
    durationPanel.add(new JLabel(durationLabel));
    durationPanel.add(durationField);
    add(durationPanel);
  }
View Full Code Here

    // USER_INPUT
    VerticalPanel assertionPanel = new VerticalPanel();
    assertionPanel.setBorder(BorderFactory.createTitledBorder(BorderFactory.createEtchedBorder(), "Tidy Settings"));

    // doctype
    HorizontalPanel docTypePanel = new HorizontalPanel();
    docTypeBox = new JComboBox(new Object[] { "omit", "auto", "strict", "loose" });
    // docTypePanel.add(new
    // JLabel(JMeterUtils.getResString("duration_assertion_label"))); //$NON-NLS-1$
    docTypePanel.add(new JLabel("Doctype:"));
    docTypePanel.add(docTypeBox);
    assertionPanel.add(docTypePanel);

    // format (HMTL, XHTML, XML)
    VerticalPanel formatPanel = new VerticalPanel();
    formatPanel.setBorder(BorderFactory.createTitledBorder(BorderFactory.createEtchedBorder(), "Format"));
    htmlRadioButton = new JRadioButton("HTML", true); //$NON-NLS-1$
    xhtmlRadioButton = new JRadioButton("XHTML", false); //$NON-NLS-1$
    xmlRadioButton = new JRadioButton("XML", false); //$NON-NLS-1$
    ButtonGroup buttonGroup = new ButtonGroup();
    buttonGroup.add(htmlRadioButton);
    buttonGroup.add(xhtmlRadioButton);
    buttonGroup.add(xmlRadioButton);
    formatPanel.add(htmlRadioButton);
    formatPanel.add(xhtmlRadioButton);
    formatPanel.add(xmlRadioButton);
    assertionPanel.add(formatPanel);

    // errors only
    errorsOnly = new JCheckBox("Errors only", false);
    errorsOnly.addActionListener(this);
    assertionPanel.add(errorsOnly);

    // thresholds
    HorizontalPanel thresholdPanel = new HorizontalPanel();
    thresholdPanel.add(new JLabel("Error threshold:"));
    errorThresholdField = new JTextField("0", 5); // $NON-NLS-1$
    errorThresholdField.setName(ERROR_THRESHOLD_FIELD);
    errorThresholdField.addKeyListener(this);
    thresholdPanel.add(errorThresholdField);
    thresholdPanel.add(new JLabel("Warning threshold:"));
    warningThresholdField = new JTextField("0", 5); // $NON-NLS-1$
    warningThresholdField.setName(WARNING_THRESHOLD_FIELD);
    warningThresholdField.addKeyListener(this);
    thresholdPanel.add(warningThresholdField);
    assertionPanel.add(thresholdPanel);

    // file panel
    filePanel = new FilePanel(JMeterUtils.getResString("html_assertion_file"), ".txt"); //$NON-NLS-1$ //$NON-NLS-2$
    assertionPanel.add(filePanel);
View Full Code Here

        JLabel graphLabel = new JLabel(JMeterUtils.getResString("aggregate_graph")); //$NON-NLS-1$
        graphPanel = new AxisGraph();
        graphPanel.setPreferredSize(new Dimension(defaultWidth,defaultHeight));

        // horizontal panel for the buttons
        HorizontalPanel buttonpanel = new HorizontalPanel();
        buttonpanel.add(columns);
        buttonpanel.add(displayButton);
        buttonpanel.add(saveGraph);
        buttonpanel.add(saveTable);
        buttonpanel.add(saveHeaders);
       
        graph.add(graphLabel);
        graph.add(graphTitle);
        graph.add(maxLengthXAxisLabel);
        graph.add(graphWidth);
View Full Code Here

    httpsMatch.setName(ENABLE_RESTART);

    JLabel matchlabel = new JLabel(JMeterUtils.getResString("proxy_httpsspoofing_match")); // $NON-NLS-1$
    matchlabel.setLabelFor(httpsMatch);
   
    HorizontalPanel panel = new HorizontalPanel();
    panel.add(label);
    panel.add(portField);

    panel.add(Box.createHorizontalStrut(10));
    panel.add(httpsSpoof);

    panel.add(matchlabel);
    panel.add(httpsMatch);
   
    return panel;
  }
View Full Code Here

TOP

Related Classes of org.apache.jmeter.gui.util.HorizontalPanel

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.