SpringGUI

introduction    download    reference    examples    faq


Reference

Name

addButton()

Examples

SpringGUI gui;
void setup() {
  size(200,200);
  gui = new SpringGUI(this); // initialise SpringGUI
  // Create a button named "myButton" at coordinates 10,10 with width 200px and height 25px...
  gui.addButton("myButton", "I am a button", 10, 10, 200, 25);
}

Description

Creates a Button element.

Syntax

gui.addButton(name, text, x, y, width, height);

Parameters

String name The name of the element. You can query and change the element's attributes later on by referring to this name.
String text The text to display on the Button.
int x, int y The x and y coordinates of the element's top left point.
int width, int height The size of the element.

Returns

nothing

Related

table of events


back to the top of the page


tinkering with codetools and docsscrapbookabout