Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 4.0
Table of Contents
maxLevel3
indent0px

(Automatically generated from BeanInfo)

Generated Object

A java.awt.GridLayout is returned, unless the user passes in a subclass of GridLayout as the value argument, in which case the value argument is returned.

Attributes

Declared in java.awt.GridLayout

  • columns <int>
  • hgap <int>
  • rows <int>
  • vgap <int>

Events

Content

Usage

Examples

Code Block
java
java
import groovy.swing.SwingBuilder
import java.awt.GridLayout
import javax.swing.JFrame

SwingBuilder swing = new SwingBuilder()
swing.frame(defaultCloseOperation: JFrame.EXIT_ON_CLOSE, pack: true, show: true) {
  panel(layout: gridLayout(cols: 2, rows: 5)) {

    (0..<10).each {
      println it
      swing.label it.toString()
    }

  }
}