// Creating popup menu
final PopupMenuGenerator pmg = new PopupMenuGenerator ( "document-pane-menu" );
pmg.setIconSettings ( PaneData.class, "icons/menu/", ".png" );
pmg.setLanguagePrefix ( "weblaf.ex.docpane" );
pmg.addItem ( "close", "close", Hotkey.CTRL_W, csb, new ActionListener ()
{
@Override
public void actionPerformed ( final ActionEvent e )
{
close ( get ( index ) );