Generated Object

A javax.swing.border.EmptyBorder, a border whose margins are not painted with anything.

Value Argument

Either an Integer or an array of four Integers. 

A single integer is expanded to an array of four integers of the same value.

An array of four integers is used to generate the top, left, bottom, and right margins, respectively.

If a value argument is used then the top:, left:, bottom:, and right: attributes cannot be used. 


If any of top:, left:, bottom:, or right: are specified the all of them must be specified.


emptyBorder() is a leaf node, no child content is allowed.



panel {
    emptyBorder([6,6,3,3], parent:true)

emptyBorder(top:5, left:15, bottom:15, right:5) 


Do work:

border: BorderFactory.createEmptyBorder(0,3,0,3)
border: emptyBorder([0,3,0,3])
border: emptyBorder(top:0,left:3,bottom:0,right:3)

Does not work:

border: emptyBorder(0,3,0,3)
border: emptyBorder(top:3)