Java Swing TitledBorder createTitleBorder(final String title)

Here you can find the source of createTitleBorder(final String title)

Description

create Title Border

License

LGPL

Declaration

public static Border createTitleBorder(final String title) 

Method Source Code

//package com.java2s;

import javax.swing.BorderFactory;

import javax.swing.border.Border;

public class Main {
    public static Border createTitleBorder(final String title) {
        final Border tb = BorderFactory.createTitledBorder(title);
        final Border eb = BorderFactory.createEmptyBorder(0, 5, 5, 5);
        return BorderFactory.createCompoundBorder(tb, eb);
    }//w w w  .  j a va 2  s.c  o  m
}

Related

  1. createBorderedPanel(String title, int margin)
  2. createGroupBorder(String title)
  3. createGuiElementBorder(final String title)
  4. createInsetTitledBorder(String title)
  5. createStyleAttributeBorder(String title)
  6. createTitledBorder(final String title)
  7. createTitledBorder(String label)
  8. createTitledBorder(String name)
  9. createTitledBorder(String title)