Search in sources :

Example 51 with JTextArea

use of javax.swing.JTextArea in project jmeter by apache.

the class RenderAsJsonRenderer method createJSonPathExtractorPanel.

/**
     * @return JSON PATH Tester panel
     */
private JPanel createJSonPathExtractorPanel() {
    jsonDataField = new JTextArea();
    jsonDataField.setEditable(false);
    jsonDataField.setLineWrap(true);
    jsonDataField.setWrapStyleWord(true);
    this.jsonDataPane = GuiUtils.makeScrollPane(jsonDataField);
    jsonDataPane.setPreferredSize(new Dimension(100, 200));
    JPanel panel = new JPanel(new BorderLayout(0, 5));
    JSplitPane mainSplit = new JSplitPane(JSplitPane.VERTICAL_SPLIT, jsonDataPane, createJSonPathExtractorTasksPanel());
    mainSplit.setDividerLocation(0.6d);
    mainSplit.setOneTouchExpandable(true);
    panel.add(mainSplit, BorderLayout.CENTER);
    return panel;
}
Also used : JPanel(javax.swing.JPanel) JTextArea(javax.swing.JTextArea) BorderLayout(java.awt.BorderLayout) Dimension(java.awt.Dimension) JSplitPane(javax.swing.JSplitPane)

Example 52 with JTextArea

use of javax.swing.JTextArea in project jmeter by apache.

the class RequestViewRaw method init.

/** request pane content */
/* (non-Javadoc)
     * @see org.apache.jmeter.visualizers.request.RequestView#init()
     */
@Override
public void init() {
    paneRaw = new JPanel(new BorderLayout(0, 5));
    sampleDataField = new JTextArea();
    sampleDataField.setEditable(false);
    sampleDataField.setLineWrap(true);
    sampleDataField.setWrapStyleWord(true);
    paneRaw.add(GuiUtils.makeScrollPane(sampleDataField));
}
Also used : JPanel(javax.swing.JPanel) JTextArea(javax.swing.JTextArea) BorderLayout(java.awt.BorderLayout)

Example 53 with JTextArea

use of javax.swing.JTextArea in project jmeter by apache.

the class RenderAsCssJQuery method createCssJqueryTasksPanel.

/**
     * Create the CssJquery task pane
     *
     * @return CssJquery task pane
     */
private JPanel createCssJqueryTasksPanel() {
    GridBagLayout g = new GridBagLayout();
    GridBagConstraints c = new GridBagConstraints();
    JPanel cssJqueryActionPanel = new JPanel();
    cssJqueryActionPanel.setLayout(g);
    Border margin = new EmptyBorder(5, 5, 0, 5);
    cssJqueryActionPanel.setBorder(margin);
    // $NON-NLS-1$
    cssJqueryField = new JLabeledTextField(JMeterUtils.getResString("cssjquery_tester_field"));
    c.fill = GridBagConstraints.HORIZONTAL;
    c.gridx = 0;
    c.gridy = 0;
    cssJqueryActionPanel.add(cssJqueryField, c);
    cssJqueryLabeledChoice = new JLabeledChoice(// $NON-NLS-1$
    JMeterUtils.getResString("cssjquery_impl"), getImplementations());
    c.fill = GridBagConstraints.HORIZONTAL;
    c.gridx = 1;
    c.gridy = 0;
    cssJqueryActionPanel.add(cssJqueryLabeledChoice, c);
    // $NON-NLS-1$
    attributeField = new JLabeledTextField(JMeterUtils.getResString("cssjquery_attribute"));
    c.fill = GridBagConstraints.HORIZONTAL;
    c.gridx = 0;
    c.gridy = 1;
    cssJqueryActionPanel.add(attributeField, c);
    // $NON-NLS-1$
    JButton cssJqueryTester = new JButton(JMeterUtils.getResString("cssjquery_tester_button_test"));
    cssJqueryTester.setActionCommand(CSSJQUEY_TESTER_COMMAND);
    cssJqueryTester.addActionListener(this);
    c.fill = GridBagConstraints.HORIZONTAL;
    c.gridx = 1;
    c.gridy = 1;
    cssJqueryActionPanel.add(cssJqueryTester, c);
    cssJqueryResultField = new JTextArea();
    cssJqueryResultField.setEditable(false);
    cssJqueryResultField.setLineWrap(true);
    cssJqueryResultField.setWrapStyleWord(true);
    JPanel cssJqueryTasksPanel = new JPanel(new BorderLayout(0, 5));
    cssJqueryTasksPanel.add(cssJqueryActionPanel, BorderLayout.NORTH);
    cssJqueryTasksPanel.add(GuiUtils.makeScrollPane(cssJqueryResultField), BorderLayout.CENTER);
    return cssJqueryTasksPanel;
}
Also used : JPanel(javax.swing.JPanel) JLabeledTextField(org.apache.jorphan.gui.JLabeledTextField) GridBagConstraints(java.awt.GridBagConstraints) JTextArea(javax.swing.JTextArea) GridBagLayout(java.awt.GridBagLayout) JLabeledChoice(org.apache.jorphan.gui.JLabeledChoice) BorderLayout(java.awt.BorderLayout) JButton(javax.swing.JButton) EmptyBorder(javax.swing.border.EmptyBorder) Border(javax.swing.border.Border) EmptyBorder(javax.swing.border.EmptyBorder)

Example 54 with JTextArea

use of javax.swing.JTextArea in project jmeter by apache.

the class RenderAsXPath method createXpathExtractorTasksPanel.

/**
     * Create the XPath task pane
     *
     * @return XPath task pane
     */
private JPanel createXpathExtractorTasksPanel() {
    Box xpathActionPanel = Box.createVerticalBox();
    Box selectorAndButton = Box.createHorizontalBox();
    Border margin = new EmptyBorder(5, 5, 0, 5);
    xpathActionPanel.setBorder(margin);
    // $NON-NLS-1$
    xpathExpressionField = new JLabeledTextField(JMeterUtils.getResString("xpath_tester_field"));
    // $NON-NLS-1$
    JButton xpathTester = new JButton(JMeterUtils.getResString("xpath_tester_button_test"));
    xpathTester.setActionCommand(XPATH_TESTER_COMMAND);
    xpathTester.addActionListener(this);
    selectorAndButton.add(xpathExpressionField);
    selectorAndButton.add(xpathTester);
    xpathActionPanel.add(selectorAndButton);
    xpathActionPanel.add(xmlConfPanel);
    xpathActionPanel.add(getFragment);
    xpathResultField = new JTextArea();
    xpathResultField.setEditable(false);
    xpathResultField.setLineWrap(true);
    xpathResultField.setWrapStyleWord(true);
    JPanel xpathTasksPanel = new JPanel(new BorderLayout(0, 5));
    xpathTasksPanel.add(xpathActionPanel, BorderLayout.NORTH);
    xpathTasksPanel.add(GuiUtils.makeScrollPane(xpathResultField), BorderLayout.CENTER);
    return xpathTasksPanel;
}
Also used : JLabeledTextField(org.apache.jorphan.gui.JLabeledTextField) JPanel(javax.swing.JPanel) JTextArea(javax.swing.JTextArea) BorderLayout(java.awt.BorderLayout) JButton(javax.swing.JButton) Box(javax.swing.Box) JCheckBox(javax.swing.JCheckBox) EmptyBorder(javax.swing.border.EmptyBorder) Border(javax.swing.border.Border) EmptyBorder(javax.swing.border.EmptyBorder)

Example 55 with JTextArea

use of javax.swing.JTextArea in project jadx by skylot.

the class Link method showUrlDialog.

private void showUrlDialog() {
    JTextArea urlArea = new JTextArea("Can't open browser. Please browse to:\n" + url);
    JOptionPane.showMessageDialog(null, urlArea);
}
Also used : JTextArea(javax.swing.JTextArea)

Aggregations

JTextArea (javax.swing.JTextArea)182 JScrollPane (javax.swing.JScrollPane)104 JPanel (javax.swing.JPanel)79 BorderLayout (java.awt.BorderLayout)60 JButton (javax.swing.JButton)59 JLabel (javax.swing.JLabel)59 Dimension (java.awt.Dimension)36 JTextField (javax.swing.JTextField)35 JFrame (javax.swing.JFrame)33 ActionEvent (java.awt.event.ActionEvent)26 Font (java.awt.Font)24 GridBagLayout (java.awt.GridBagLayout)23 GridBagConstraints (java.awt.GridBagConstraints)22 Insets (java.awt.Insets)22 ActionListener (java.awt.event.ActionListener)21 FlowLayout (java.awt.FlowLayout)20 Color (java.awt.Color)18 JCheckBox (javax.swing.JCheckBox)18 JSplitPane (javax.swing.JSplitPane)16 EmptyBorder (javax.swing.border.EmptyBorder)16