Codota Logo
Spinner
Code IndexAdd Codota to your IDE (free)

How to use
Spinner
in
org.jfree.ui

Best Java code snippets using org.jfree.ui.Spinner (Showing top 6 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
ScheduledThreadPoolExecutor s =
  • Codota Iconnew ScheduledThreadPoolExecutor(corePoolSize)
  • Codota IconThreadFactory threadFactory;new ScheduledThreadPoolExecutor(corePoolSize, threadFactory)
  • Codota IconString str;new ScheduledThreadPoolExecutor(1, new ThreadFactoryBuilder().setNameFormat(str).build())
  • Smart code suggestions by Codota
}
origin: jfree/jcommon

/**
 * Receives notification of mouse clicks.
 *
 * @param e  the mouse event.
 */
public void mouseClicked(final MouseEvent e) {
  if (e.getSource() == this.upButton) {
    this.value++;
    this.textField.setText(Integer.toString(this.value));
    firePropertyChange("value", this.value - 1, this.value);
  }
  else if (e.getSource() == this.downButton) {
    this.value--;
    this.textField.setText(Integer.toString(this.value));
    firePropertyChange("value", this.value + 1, this.value);
  }
}
origin: org.jfree/jcommon

/**
 * Creates a new spinner.
 *
 * @param value  the initial value.
 */
public Spinner(final int value) {
  super(new BorderLayout());
  this.value = value;
  this.textField = new JTextField(Integer.toString(this.value));
  this.textField.setHorizontalAlignment(SwingConstants.RIGHT);
  add(this.textField);
  this.buttonPanel = new JPanel(new GridLayout(2, 1, 0, 1));
  this.upButton = new ArrowPanel(ArrowPanel.UP);
  this.upButton.addMouseListener(this);
  this.downButton = new ArrowPanel(ArrowPanel.DOWN);
  this.downButton.addMouseListener(this);
  this.buttonPanel.add(this.upButton);
  this.buttonPanel.add(this.downButton);
  add(this.buttonPanel, BorderLayout.EAST);
}
origin: org.jfree/com.springsource.org.jfree

/**
 * Creates a new spinner.
 *
 * @param value  the initial value.
 */
public Spinner(final int value) {
  super(new BorderLayout());
  this.value = value;
  this.textField = new JTextField(Integer.toString(this.value));
  this.textField.setHorizontalAlignment(SwingConstants.RIGHT);
  add(this.textField);
  this.buttonPanel = new JPanel(new GridLayout(2, 1, 0, 1));
  this.upButton = new ArrowPanel(ArrowPanel.UP);
  this.upButton.addMouseListener(this);
  this.downButton = new ArrowPanel(ArrowPanel.DOWN);
  this.downButton.addMouseListener(this);
  this.buttonPanel.add(this.upButton);
  this.buttonPanel.add(this.downButton);
  add(this.buttonPanel, BorderLayout.EAST);
}
origin: org.jfree/jcommon

/**
 * Receives notification of mouse clicks.
 *
 * @param e  the mouse event.
 */
public void mouseClicked(final MouseEvent e) {
  if (e.getSource() == this.upButton) {
    this.value++;
    this.textField.setText(Integer.toString(this.value));
    firePropertyChange("value", this.value - 1, this.value);
  }
  else if (e.getSource() == this.downButton) {
    this.value--;
    this.textField.setText(Integer.toString(this.value));
    firePropertyChange("value", this.value + 1, this.value);
  }
}
origin: jfree/jcommon

/**
 * Creates a new spinner.
 *
 * @param value  the initial value.
 */
public Spinner(final int value) {
  super(new BorderLayout());
  this.value = value;
  this.textField = new JTextField(Integer.toString(this.value));
  this.textField.setHorizontalAlignment(SwingConstants.RIGHT);
  add(this.textField);
  this.buttonPanel = new JPanel(new GridLayout(2, 1, 0, 1));
  this.upButton = new ArrowPanel(ArrowPanel.UP);
  this.upButton.addMouseListener(this);
  this.downButton = new ArrowPanel(ArrowPanel.DOWN);
  this.downButton.addMouseListener(this);
  this.buttonPanel.add(this.upButton);
  this.buttonPanel.add(this.downButton);
  add(this.buttonPanel, BorderLayout.EAST);
}
origin: org.jfree/com.springsource.org.jfree

/**
 * Receives notification of mouse clicks.
 *
 * @param e  the mouse event.
 */
public void mouseClicked(final MouseEvent e) {
  if (e.getSource() == this.upButton) {
    this.value++;
    this.textField.setText(Integer.toString(this.value));
    firePropertyChange("value", this.value - 1, this.value);
  }
  else if (e.getSource() == this.downButton) {
    this.value--;
    this.textField.setText(Integer.toString(this.value));
    firePropertyChange("value", this.value + 1, this.value);
  }
}
org.jfree.uiSpinner

Javadoc

A very basic spinner component, used for demo purposes only.

Most used methods

  • add
  • firePropertyChange

Popular in Java

  • Making http requests using okhttp
  • compareTo (BigDecimal)
  • getSharedPreferences (Context)
  • orElseThrow (Optional)
  • MalformedURLException (java.net)
    Thrown to indicate that a malformed URL has occurred. Either no legal protocol could be found in a s
  • Socket (java.net)
    Provides a client-side TCP socket.
  • Selector (java.nio.channels)
    A controller for the selection of SelectableChannel objects. Selectable channels can be registered w
  • DateFormat (java.text)
    Formats or parses dates and times.This class provides factories for obtaining instances configured f
  • ConcurrentHashMap (java.util.concurrent)
    A hash table supporting full concurrency of retrievals and adjustable expected concurrency for updat
  • Notification (javax.management)
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now