axis_examplecompt_changesinfo-opsversion-1.30version-2.00version-3.01version-3.02
Last change
on this file since 8780cbec was
8780cbec,
checked in by Jay Jacobs <Jay.Jacobs@…>, 15 years ago
|
ABAC sources from Cobham
|
-
Property mode set to
100644
|
File size:
530 bytes
|
Line | |
---|
1 | package com.algomagic.atn; |
---|
2 | |
---|
3 | import javax.swing.*; |
---|
4 | import javax.swing.border.*; |
---|
5 | |
---|
6 | |
---|
7 | public class PanelHelper { |
---|
8 | |
---|
9 | public static void setBorder( JComponent comp, String label ) { |
---|
10 | Border empty = BorderFactory.createEmptyBorder( 0, 0, 0, 0 ); |
---|
11 | Border etched = BorderFactory.createEtchedBorder( ); |
---|
12 | |
---|
13 | TitledBorder title = BorderFactory.createTitledBorder( etched, label ); |
---|
14 | title.setTitleJustification( TitledBorder.RIGHT ); |
---|
15 | |
---|
16 | Border compound = BorderFactory.createCompoundBorder( title, empty ); |
---|
17 | comp.setBorder( compound ); |
---|
18 | } |
---|
19 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.