Esempio n. 1
0
 public PropertyEditor(JFrame frame)
 {
   base.\u002Ector((Frame) frame, true);
   PropertyEditor propertyEditor = this;
   this.tableModel = new PropertyEditor.PropTableModel(this);
   PropertyEditor.PropertiesTable.__\u003Cclinit\u003E();
   this.table = (JTable) new PropertyEditor.PropertiesTable(this, (AbstractTableModel) this.tableModel);
   this.table.setGridColor((Color) Color.LIGHT_GRAY);
   this.table.setRowSelectionAllowed(false);
   JScrollPane.__\u003Cclinit\u003E();
   JScrollPane jscrollPane = new JScrollPane((Component) this.table);
   ((Window) this).setBounds(100, 100, 300, 400);
   this.getContentPane().setLayout((LayoutManager) new BorderLayout());
   this.getContentPane().add((Component) jscrollPane, (object) "Center");
 }
Esempio n. 2
0
 private JComponent getLogComponent()
 {
     var jpanel = new JPanel(new BorderLayout());
     var jtextarea = new JTextArea();
     logger.addHandler(new GuiLogOutputHandler(jtextarea));
     var jscrollpane = new JScrollPane(jtextarea, 22, 30);
     jtextarea.setEditable(false);
     var jtextfield = new JTextField();
     jtextfield.addActionListener(new ServerGuiCommandListener(this, jtextfield));
     jtextarea.addFocusListener(new ServerGuiFocusAdapter(this));
     jpanel.add(jscrollpane, "Center");
     jpanel.add(jtextfield, "South");
     jpanel.setBorder(new TitledBorder(new EtchedBorder(), "Log and chat"));
     return jpanel;
 }
Esempio n. 3
0
 private JComponent getPlayerListComponent()
 {
     var playerlistbox = new PlayerListBox(mcServer);
     var jscrollpane = new JScrollPane(playerlistbox, 22, 30);
     jscrollpane.setBorder(new TitledBorder(new EtchedBorder(), "Players"));
     return jscrollpane;
 }
 public FontChooserPanel(Font font)
 {
   base.\u002Ector();
   FontChooserPanel fontChooserPanel = this;
   string[] availableFontFamilyNames = GraphicsEnvironment.getLocalGraphicsEnvironment().getAvailableFontFamilyNames();
   ((Container) this).setLayout((LayoutManager) new BorderLayout());
   JPanel.__\u003Cclinit\u003E();
   JPanel jpanel1 = new JPanel((LayoutManager) new BorderLayout());
   JPanel.__\u003Cclinit\u003E();
   JPanel jpanel2 = new JPanel((LayoutManager) new BorderLayout());
   ((JComponent) jpanel2).setBorder((Border) BorderFactory.createTitledBorder(BorderFactory.createEtchedBorder(), FontChooserPanel.localizationResources.getString("Font")));
   this.fontlist = new JList((object[]) availableFontFamilyNames);
   JScrollPane.__\u003Cclinit\u003E();
   JScrollPane jscrollPane1 = new JScrollPane((Component) this.fontlist);
   ((JComponent) jscrollPane1).setBorder(BorderFactory.createEtchedBorder());
   ((Container) jpanel2).add((Component) jscrollPane1);
   ((Container) this).add((Component) jpanel2);
   JPanel.__\u003Cclinit\u003E();
   JPanel jpanel3 = new JPanel((LayoutManager) new BorderLayout());
   ((JComponent) jpanel3).setBorder((Border) BorderFactory.createTitledBorder(BorderFactory.createEtchedBorder(), FontChooserPanel.localizationResources.getString("Size")));
   JList.__\u003Cclinit\u003E();
   this.sizelist = new JList((object[]) FontChooserPanel.__\u003C\u003ESIZES);
   JScrollPane.__\u003Cclinit\u003E();
   JScrollPane jscrollPane2 = new JScrollPane((Component) this.sizelist);
   ((JComponent) jscrollPane2).setBorder(BorderFactory.createEtchedBorder());
   ((Container) jpanel3).add((Component) jscrollPane2);
   JPanel.__\u003Cclinit\u003E();
   JPanel jpanel4 = new JPanel((LayoutManager) new GridLayout(1, 2));
   JCheckBox.__\u003Cclinit\u003E();
   this.bold = new JCheckBox(FontChooserPanel.localizationResources.getString("Bold"));
   JCheckBox.__\u003Cclinit\u003E();
   this.italic = new JCheckBox(FontChooserPanel.localizationResources.getString("Italic"));
   ((Container) jpanel4).add((Component) this.bold);
   ((Container) jpanel4).add((Component) this.italic);
   ((JComponent) jpanel4).setBorder((Border) BorderFactory.createTitledBorder(BorderFactory.createEtchedBorder(), FontChooserPanel.localizationResources.getString("Attributes")));
   ((Container) jpanel1).add((Component) jpanel3, (object) "Center");
   ((Container) jpanel1).add((Component) jpanel4, (object) "South");
   ((Container) this).add((Component) jpanel1, (object) "East");
   this.setSelectedFont(font);
 }