List of usage examples for com.jgoodies.forms.layout Sizes DEFAULT
ComponentSize DEFAULT
To view the source code for com.jgoodies.forms.layout Sizes DEFAULT.
Click Source Link
From source file:org.archiviststoolkit.dialog.JiraReportDialog.java
License:Open Source License
private void initComponents() { // JFormDesigner - Component initialization - DO NOT MODIFY //GEN-BEGIN:initComponents // Generated using JFormDesigner non-commercial license dialogPane = new JPanel(); contentPanel = new JPanel(); panel2 = new JPanel(); label3 = new JLabel(); label4 = new JLabel(); label1 = new JLabel(); summary = new JTextField(); label2 = new JLabel(); scrollPane1 = new JScrollPane(); detailedDescription = new JTextArea(); panel1 = new JPanel(); label5 = new JLabel(); emailAddress = new JTextField(); label6 = new JLabel(); fullName = new JTextField(); buttonBar = new JPanel(); cancelButton = new JButton(); sendButton = new JButton(); CellConstraints cc = new CellConstraints(); //======== this ======== setModal(true);/*from w ww. j a va 2 s . c om*/ setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); Container contentPane = getContentPane(); contentPane.setLayout(new BorderLayout()); //======== dialogPane ======== { dialogPane.setBorder(Borders.DIALOG_BORDER); dialogPane.setBackground(new Color(200, 205, 232)); dialogPane.setLayout(new BorderLayout()); //======== contentPanel ======== { contentPanel.setOpaque(false); contentPanel.setLayout(new FormLayout(ColumnSpec.decodeSpecs("max(default;600px):grow"), new RowSpec[] { FormFactory.DEFAULT_ROWSPEC, FormFactory.UNRELATED_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC })); //======== panel2 ======== { panel2.setOpaque(false); panel2.setLayout( new FormLayout( new ColumnSpec[] { FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.DEFAULT_COLSPEC }, RowSpec.decodeSpecs("default"))); //---- label3 ---- label3.setIcon(new ImageIcon( getClass().getResource("/org/archiviststoolkit/resources/images/bug.png"))); panel2.add(label3, cc.xy(1, 1)); //---- label4 ---- label4.setText("Bug Reporter"); label4.setFont(new Font("Lucida Grande", Font.PLAIN, 15)); panel2.add(label4, cc.xywh(3, 1, 1, 1, CellConstraints.DEFAULT, CellConstraints.TOP)); } contentPanel.add(panel2, cc.xy(1, 1)); //---- label1 ---- label1.setText("Please enter a brief summary..."); label1.setFont(new Font("Trebuchet MS", Font.PLAIN, 13)); contentPanel.add(label1, cc.xy(1, 3)); contentPanel.add(summary, cc.xy(1, 5)); //---- label2 ---- label2.setText("...and a detailed description"); label2.setFont(new Font("Trebuchet MS", Font.PLAIN, 13)); contentPanel.add(label2, cc.xy(1, 7)); //======== scrollPane1 ======== { scrollPane1.setVerticalScrollBarPolicy(ScrollPaneConstants.VERTICAL_SCROLLBAR_ALWAYS); //---- detailedDescription ---- detailedDescription.setRows(20); detailedDescription.setLineWrap(true); scrollPane1.setViewportView(detailedDescription); } contentPanel.add(scrollPane1, cc.xy(1, 9)); //======== panel1 ======== { panel1.setOpaque(false); panel1.setLayout(new FormLayout( new ColumnSpec[] { FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, new RowSpec[] { FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC })); //---- label5 ---- label5.setText("Email Address"); panel1.add(label5, cc.xy(1, 1)); panel1.add(emailAddress, cc.xy(3, 1)); //---- label6 ---- label6.setText("Full Name"); panel1.add(label6, cc.xy(1, 3)); panel1.add(fullName, cc.xy(3, 3)); } contentPanel.add(panel1, cc.xy(1, 11)); } dialogPane.add(contentPanel, BorderLayout.CENTER); //======== buttonBar ======== { buttonBar.setBorder(Borders.BUTTON_BAR_GAP_BORDER); buttonBar.setOpaque(false); buttonBar.setLayout(new FormLayout( new ColumnSpec[] { FormFactory.GLUE_COLSPEC, FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.BUTTON_COLSPEC }, RowSpec.decodeSpecs("pref"))); //---- cancelButton ---- cancelButton.setText("Cancel"); cancelButton.setOpaque(false); cancelButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { cancelButtonActionPerformed(e); } }); buttonBar.add(cancelButton, cc.xy(4, 1)); //---- sendButton ---- sendButton.setText("Send"); sendButton.setOpaque(false); sendButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { sendButtonActionPerformed(e); } }); buttonBar.add(sendButton, cc.xy(6, 1)); } dialogPane.add(buttonBar, BorderLayout.SOUTH); } contentPane.add(dialogPane, BorderLayout.CENTER); pack(); setLocationRelativeTo(getOwner()); // JFormDesigner - End of component initialization //GEN-END:initComponents }
From source file:org.archiviststoolkit.dialog.LocationAssignmentAccessions.java
License:Open Source License
private void initComponents() { // JFormDesigner - Component initialization - DO NOT MODIFY //GEN-BEGIN:initComponents // Generated using JFormDesigner non-commercial license dialogPane = new JPanel(); HeaderPanel = new JPanel(); mainHeaderPanel = new JPanel(); mainHeaderLabel = new JLabel(); panel3 = new JPanel(); subHeaderLabel = new JLabel(); contentPane = new JPanel(); label1 = new JLabel(); filterField = new JTextField(); scrollPane1 = new JScrollPane(); locationLookupTable = new DomainSortableTable(Locations.class, filterField); linkingPanel = new JPanel(); label3 = new JLabel(); label4 = new JLabel(); noteContainerLabel = new JTextField(); note = new JTextField(); buttonBar = new JPanel(); linkLocationButton = new JButton(); createLocationButton = new JButton(); doneButton = new JButton(); selectPanel = new JPanel(); buttonBar2 = new JPanel(); selectButton = new JButton(); cancelButton = new JButton(); CellConstraints cc = new CellConstraints(); //======== this ======== setModal(true);/*from ww w . ja v a 2s . c om*/ Container contentPane2 = getContentPane(); contentPane2.setLayout(new BorderLayout()); //======== dialogPane ======== { dialogPane.setBorder(null); dialogPane.setBackground(new Color(200, 205, 232)); dialogPane.setLayout(new BorderLayout()); //======== HeaderPanel ======== { HeaderPanel.setBackground(new Color(80, 69, 57)); HeaderPanel.setOpaque(false); HeaderPanel.setFont(new Font("Trebuchet MS", Font.PLAIN, 13)); HeaderPanel .setLayout(new FormLayout( new ColumnSpec[] { new ColumnSpec( Sizes.bounded(Sizes.MINIMUM, Sizes.dluX(100), Sizes.dluX(200))), new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, RowSpec.decodeSpecs("default"))); //======== mainHeaderPanel ======== { mainHeaderPanel.setBackground(new Color(80, 69, 57)); mainHeaderPanel.setFont(new Font("Trebuchet MS", Font.PLAIN, 13)); mainHeaderPanel .setLayout( new FormLayout( new ColumnSpec[] { FormFactory.RELATED_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, new RowSpec[] { FormFactory.RELATED_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.RELATED_GAP_ROWSPEC })); //---- mainHeaderLabel ---- mainHeaderLabel.setText("Main Header"); mainHeaderLabel.setFont(new Font("Trebuchet MS", Font.PLAIN, 18)); mainHeaderLabel.setForeground(Color.white); mainHeaderPanel.add(mainHeaderLabel, cc.xy(2, 2)); } HeaderPanel.add(mainHeaderPanel, cc.xy(1, 1)); //======== panel3 ======== { panel3.setBackground(new Color(66, 60, 111)); panel3.setFont(new Font("Trebuchet MS", Font.PLAIN, 13)); panel3.setLayout(new FormLayout( new ColumnSpec[] { FormFactory.RELATED_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, new RowSpec[] { FormFactory.RELATED_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.RELATED_GAP_ROWSPEC })); //---- subHeaderLabel ---- subHeaderLabel.setText("Location Lookup"); subHeaderLabel.setFont(new Font("Trebuchet MS", Font.PLAIN, 18)); subHeaderLabel.setForeground(Color.white); panel3.add(subHeaderLabel, cc.xy(2, 2)); } HeaderPanel.add(panel3, cc.xy(2, 1)); } dialogPane.add(HeaderPanel, BorderLayout.NORTH); //======== contentPane ======== { contentPane.setBackground(new Color(231, 188, 251)); contentPane.setOpaque(false); contentPane .setLayout( new FormLayout( new ColumnSpec[] { FormFactory.UNRELATED_GAP_COLSPEC, FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW), FormFactory.UNRELATED_GAP_COLSPEC }, new RowSpec[] { FormFactory.UNRELATED_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, new RowSpec(RowSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW), FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.UNRELATED_GAP_ROWSPEC })); //---- label1 ---- label1.setText("Filter:"); contentPane.add(label1, cc.xy(2, 2)); contentPane.add(filterField, cc.xy(4, 2)); //======== scrollPane1 ======== { scrollPane1.setVerticalScrollBarPolicy(ScrollPaneConstants.VERTICAL_SCROLLBAR_ALWAYS); //---- locationLookupTable ---- locationLookupTable.setPreferredScrollableViewportSize(new Dimension(450, 300)); locationLookupTable.addMouseListener(new MouseAdapter() { @Override public void mouseClicked(MouseEvent e) { subjectLookupTableMouseClicked(e); } }); locationLookupTable.addKeyListener(new KeyAdapter() { @Override public void keyTyped(KeyEvent e) { locationLookupTableKeyTyped(e); } }); scrollPane1.setViewportView(locationLookupTable); } contentPane.add(scrollPane1, cc.xywh(2, 4, 3, 1)); //======== linkingPanel ======== { linkingPanel.setOpaque(false); linkingPanel.setLayout(new FormLayout(ColumnSpec.decodeSpecs("default:grow"), new RowSpec[] { FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.UNRELATED_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC })); //---- label3 ---- label3.setText("Double click on a Location to add it to the record."); linkingPanel.add(label3, cc.xy(1, 1)); //---- label4 ---- label4.setText("Or hit enter if a Location is highlighted."); linkingPanel.add(label4, cc.xy(1, 3)); //---- noteContainerLabel ---- noteContainerLabel.setText("Note/Container information"); noteContainerLabel.setOpaque(false); noteContainerLabel.setBorder(null); linkingPanel.add(noteContainerLabel, cc.xy(1, 5)); linkingPanel.add(note, cc.xy(1, 7)); //======== buttonBar ======== { buttonBar.setBorder(Borders.BUTTON_BAR_GAP_BORDER); buttonBar.setBackground(new Color(231, 188, 251)); buttonBar.setOpaque(false); buttonBar.setLayout(new FormLayout( new ColumnSpec[] { FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.BUTTON_COLSPEC, FormFactory.RELATED_GAP_COLSPEC, FormFactory.BUTTON_COLSPEC }, RowSpec.decodeSpecs("pref"))); //---- linkLocationButton ---- linkLocationButton.setText("Link"); linkLocationButton.setOpaque(false); linkLocationButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { linkLocationButtonActionPerformed(); } }); buttonBar.add(linkLocationButton, cc.xy(1, 1)); //---- createLocationButton ---- createLocationButton.setText("Create Location"); createLocationButton.setBackground(new Color(231, 188, 251)); createLocationButton.setOpaque(false); createLocationButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { createLocationButtonActionPerformed(e); } }); buttonBar.add(createLocationButton, cc.xy(3, 1)); //---- doneButton ---- doneButton.setText("Close Window"); doneButton.setBackground(new Color(231, 188, 251)); doneButton.setOpaque(false); doneButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { doneButtonActionPerformed(e); } }); buttonBar.add(doneButton, cc.xy(5, 1)); } linkingPanel.add(buttonBar, cc.xywh(1, 9, 1, 1, CellConstraints.RIGHT, CellConstraints.DEFAULT)); } contentPane.add(linkingPanel, cc.xywh(2, 6, 3, 1)); //======== selectPanel ======== { selectPanel.setOpaque(false); selectPanel.setLayout(new FormLayout("default:grow", "default")); //======== buttonBar2 ======== { buttonBar2.setBorder(Borders.BUTTON_BAR_GAP_BORDER); buttonBar2.setBackground(new Color(231, 188, 251)); buttonBar2.setOpaque(false); buttonBar2 .setLayout(new FormLayout( new ColumnSpec[] { FormFactory.BUTTON_COLSPEC, FormFactory.RELATED_GAP_COLSPEC, FormFactory.BUTTON_COLSPEC }, RowSpec.decodeSpecs("pref"))); //---- selectButton ---- selectButton.setText("Select"); selectButton.setOpaque(false); selectButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { selectButtonActionPerformed(); } }); buttonBar2.add(selectButton, cc.xy(1, 1)); //---- cancelButton ---- cancelButton.setText("Cancel"); cancelButton.setOpaque(false); cancelButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { doneButtonActionPerformed(e); } }); buttonBar2.add(cancelButton, cc.xy(3, 1)); } selectPanel.add(buttonBar2, cc.xywh(1, 1, 1, 1, CellConstraints.RIGHT, CellConstraints.DEFAULT)); } contentPane.add(selectPanel, cc.xywh(2, 8, 3, 1)); } dialogPane.add(contentPane, BorderLayout.CENTER); } contentPane2.add(dialogPane, BorderLayout.CENTER); pack(); setLocationRelativeTo(getOwner()); // JFormDesigner - End of component initialization //GEN-END:initComponents }
From source file:org.archiviststoolkit.dialog.LocationAssignmentResources.java
License:Open Source License
private void initComponents() { // JFormDesigner - Component initialization - DO NOT MODIFY //GEN-BEGIN:initComponents // Generated using JFormDesigner non-commercial license dialogPane = new JPanel(); HeaderPanel = new JPanel(); panel2 = new JPanel(); mainHeaderLabel = new JLabel(); panel3 = new JPanel(); subHeaderLabel = new JLabel(); contentPane = new JPanel(); label3 = new JLabel(); scrollPane1 = new JScrollPane(); containerList = new JList(); separator5 = new JSeparator(); label1 = new JLabel(); panel1 = new JPanel(); label2 = new JLabel(); filterField = new JTextField(); scrollPane2 = new JScrollPane(); locationLookupTable = new DomainSortableTable(Locations.class, filterField); buttonBar = new JPanel(); assignLocation = new JButton(); removeAssignedLocationButton = new JButton(); createLocationButton = new JButton(); doneButton = new JButton(); CellConstraints cc = new CellConstraints(); //======== this ======== setModal(true);//from w ww . j a va 2 s .c om Container contentPane2 = getContentPane(); contentPane2.setLayout(new BorderLayout()); //======== dialogPane ======== { dialogPane.setBorder(null); dialogPane.setBackground(new Color(200, 205, 232)); dialogPane.setMinimumSize(new Dimension(640, 836)); dialogPane.setLayout(new BorderLayout()); //======== HeaderPanel ======== { HeaderPanel.setBackground(new Color(80, 69, 57)); HeaderPanel.setOpaque(false); HeaderPanel.setFont(new Font("Trebuchet MS", Font.PLAIN, 13)); HeaderPanel .setLayout(new FormLayout( new ColumnSpec[] { new ColumnSpec( Sizes.bounded(Sizes.MINIMUM, Sizes.dluX(100), Sizes.dluX(200))), new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, RowSpec.decodeSpecs("default"))); //======== panel2 ======== { panel2.setBackground(new Color(73, 43, 104)); panel2.setFont(new Font("Trebuchet MS", Font.PLAIN, 13)); panel2.setLayout(new FormLayout( new ColumnSpec[] { FormFactory.RELATED_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, new RowSpec[] { FormFactory.RELATED_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.RELATED_GAP_ROWSPEC })); //---- mainHeaderLabel ---- mainHeaderLabel.setText("Resources"); mainHeaderLabel.setFont(new Font("Trebuchet MS", Font.PLAIN, 18)); mainHeaderLabel.setForeground(Color.white); panel2.add(mainHeaderLabel, cc.xy(2, 2)); } HeaderPanel.add(panel2, cc.xy(1, 1)); //======== panel3 ======== { panel3.setBackground(new Color(66, 60, 111)); panel3.setFont(new Font("Trebuchet MS", Font.PLAIN, 13)); panel3.setLayout(new FormLayout( new ColumnSpec[] { FormFactory.RELATED_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, new RowSpec[] { FormFactory.RELATED_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.RELATED_GAP_ROWSPEC })); //---- subHeaderLabel ---- subHeaderLabel.setText("Assign Locations"); subHeaderLabel.setFont(new Font("Trebuchet MS", Font.PLAIN, 18)); subHeaderLabel.setForeground(Color.white); panel3.add(subHeaderLabel, cc.xy(2, 2)); } HeaderPanel.add(panel3, cc.xy(2, 1)); } dialogPane.add(HeaderPanel, BorderLayout.NORTH); //======== contentPane ======== { contentPane.setBackground(new Color(231, 188, 251)); contentPane.setMinimumSize(new Dimension(600, 600)); contentPane.setOpaque(false); contentPane .setLayout( new FormLayout( new ColumnSpec[] { FormFactory.UNRELATED_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW), FormFactory.UNRELATED_GAP_COLSPEC }, new RowSpec[] { FormFactory.UNRELATED_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, new RowSpec(RowSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW), FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, new RowSpec(RowSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW), FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.UNRELATED_GAP_ROWSPEC })); //---- label3 ---- label3.setText("Containers"); contentPane.add(label3, cc.xy(2, 2)); //======== scrollPane1 ======== { scrollPane1.setVerticalScrollBarPolicy(ScrollPaneConstants.VERTICAL_SCROLLBAR_ALWAYS); scrollPane1.setPreferredSize(new Dimension(600, 300)); //---- containerList ---- containerList.setVisibleRowCount(20); scrollPane1.setViewportView(containerList); } contentPane.add(scrollPane1, cc.xy(2, 4)); //---- separator5 ---- separator5.setBackground(new Color(220, 220, 232)); separator5.setForeground(new Color(147, 131, 86)); separator5.setMinimumSize(new Dimension(1, 10)); separator5.setFont(new Font("Trebuchet MS", Font.PLAIN, 13)); contentPane.add(separator5, cc.xywh(1, 6, 3, 1)); //---- label1 ---- label1.setText("Locations"); contentPane.add(label1, cc.xy(2, 7)); //======== panel1 ======== { panel1.setOpaque(false); panel1.setLayout(new FormLayout( new ColumnSpec[] { FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, RowSpec.decodeSpecs("default"))); //---- label2 ---- label2.setText("Filter:"); panel1.add(label2, cc.xy(1, 1)); panel1.add(filterField, cc.xy(3, 1)); } contentPane.add(panel1, cc.xy(2, 9)); //======== scrollPane2 ======== { scrollPane2.setVerticalScrollBarPolicy(ScrollPaneConstants.VERTICAL_SCROLLBAR_ALWAYS); scrollPane2.setPreferredSize(new Dimension(600, 300)); //---- locationLookupTable ---- locationLookupTable.setPreferredScrollableViewportSize(new Dimension(450, 300)); scrollPane2.setViewportView(locationLookupTable); } contentPane.add(scrollPane2, cc.xy(2, 11)); //======== buttonBar ======== { buttonBar.setBorder(Borders.BUTTON_BAR_GAP_BORDER); buttonBar.setBackground(new Color(231, 188, 251)); buttonBar.setOpaque(false); buttonBar.setLayout(new FormLayout( new ColumnSpec[] { FormFactory.GLUE_COLSPEC, FormFactory.BUTTON_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.DEFAULT_COLSPEC, FormFactory.RELATED_GAP_COLSPEC, FormFactory.BUTTON_COLSPEC }, RowSpec.decodeSpecs("pref"))); //---- assignLocation ---- assignLocation.setText("Add Location Link"); assignLocation.setBackground(new Color(231, 188, 251)); assignLocation.setOpaque(false); assignLocation.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { assignLocationButtonActionPerformed(e); } }); buttonBar.add(assignLocation, cc.xy(2, 1)); //---- removeAssignedLocationButton ---- removeAssignedLocationButton.setText("Remove Location Link"); removeAssignedLocationButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { removeAssignedLocationButtonActionPerformed(e); } }); buttonBar.add(removeAssignedLocationButton, cc.xy(4, 1)); //---- createLocationButton ---- createLocationButton.setText("Create Location"); createLocationButton.setBackground(new Color(231, 188, 251)); createLocationButton.setOpaque(false); createLocationButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { createLocationButtonActionPerformed(e); } }); buttonBar.add(createLocationButton, cc.xy(6, 1)); //---- doneButton ---- doneButton.setText("Done"); doneButton.setBackground(new Color(231, 188, 251)); doneButton.setOpaque(false); doneButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { doneButtonActionPerformed(e); } }); buttonBar.add(doneButton, cc.xy(8, 1)); } contentPane.add(buttonBar, cc.xywh(1, 13, 3, 1, CellConstraints.CENTER, CellConstraints.DEFAULT)); } dialogPane.add(contentPane, BorderLayout.CENTER); } contentPane2.add(dialogPane, BorderLayout.CENTER); pack(); setLocationRelativeTo(getOwner()); // JFormDesigner - End of component initialization //GEN-END:initComponents }
From source file:org.archiviststoolkit.dialog.LocationManagement.java
License:Open Source License
private void initComponents() { // JFormDesigner - Component initialization - DO NOT MODIFY //GEN-BEGIN:initComponents // Generated using JFormDesigner non-commercial license dialogPane = new JPanel(); HeaderPanel = new JPanel(); panel2 = new JPanel(); mainHeaderLabel = new JLabel(); panel3 = new JPanel(); subHeaderLabel = new JLabel(); contentPanel = new JPanel(); panel1 = new JPanel(); label2 = new JLabel(); filterField = new JTextField(); scrollPane1 = new JScrollPane(); contentTable = new DomainSortableTable(Locations.class, filterField); buttonBar = new JPanel(); reportsButton = new JButton(); batchAddButton = new JButton(); addRecordButton = new JButton(); removeRecordButton = new JButton(); doneButton = new JButton(); CellConstraints cc = new CellConstraints(); //======== this ======== setModal(true);//from w ww .j a v a 2s . c om Container contentPane = getContentPane(); contentPane.setLayout(new BorderLayout()); //======== dialogPane ======== { dialogPane.setBorder(null); dialogPane.setBackground(new Color(200, 205, 232)); dialogPane.setLayout(new BorderLayout()); //======== HeaderPanel ======== { HeaderPanel.setBackground(new Color(80, 69, 57)); HeaderPanel.setOpaque(false); HeaderPanel.setFont(new Font("Trebuchet MS", Font.PLAIN, 13)); HeaderPanel .setLayout(new FormLayout( new ColumnSpec[] { new ColumnSpec( Sizes.bounded(Sizes.MINIMUM, Sizes.dluX(100), Sizes.dluX(200))), new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, RowSpec.decodeSpecs("default"))); //======== panel2 ======== { panel2.setBackground(new Color(80, 69, 57)); panel2.setFont(new Font("Trebuchet MS", Font.PLAIN, 13)); panel2.setLayout(new FormLayout( new ColumnSpec[] { FormFactory.RELATED_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, new RowSpec[] { FormFactory.RELATED_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.RELATED_GAP_ROWSPEC })); //---- mainHeaderLabel ---- mainHeaderLabel.setText("Administration"); mainHeaderLabel.setFont(new Font("Trebuchet MS", Font.PLAIN, 18)); mainHeaderLabel.setForeground(Color.white); panel2.add(mainHeaderLabel, cc.xy(2, 2)); } HeaderPanel.add(panel2, cc.xy(1, 1)); //======== panel3 ======== { panel3.setBackground(new Color(66, 60, 111)); panel3.setFont(new Font("Trebuchet MS", Font.PLAIN, 13)); panel3.setLayout(new FormLayout( new ColumnSpec[] { FormFactory.RELATED_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, new RowSpec[] { FormFactory.RELATED_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.RELATED_GAP_ROWSPEC })); //---- subHeaderLabel ---- subHeaderLabel.setText("Location Management"); subHeaderLabel.setFont(new Font("Trebuchet MS", Font.PLAIN, 18)); subHeaderLabel.setForeground(Color.white); panel3.add(subHeaderLabel, cc.xy(2, 2)); } HeaderPanel.add(panel3, cc.xy(2, 1)); } dialogPane.add(HeaderPanel, BorderLayout.NORTH); //======== contentPanel ======== { contentPanel.setOpaque(false); contentPanel .setLayout( new FormLayout( new ColumnSpec[] { FormFactory.RELATED_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW), FormFactory.RELATED_GAP_COLSPEC }, new RowSpec[] { FormFactory.UNRELATED_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, new RowSpec(RowSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW), FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.UNRELATED_GAP_ROWSPEC })); //======== panel1 ======== { panel1.setOpaque(false); panel1.setLayout(new FormLayout( new ColumnSpec[] { FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, RowSpec.decodeSpecs("default"))); //---- label2 ---- label2.setText("Filter:"); panel1.add(label2, cc.xy(1, 1)); panel1.add(filterField, cc.xy(3, 1)); } contentPanel.add(panel1, cc.xy(2, 2)); //======== scrollPane1 ======== { //---- contentTable ---- contentTable.addMouseListener(new MouseAdapter() { @Override public void mouseClicked(MouseEvent e) { contentTableMouseClicked(e); } }); scrollPane1.setViewportView(contentTable); } contentPanel.add(scrollPane1, cc.xy(2, 4)); //======== buttonBar ======== { buttonBar.setBorder(Borders.BUTTON_BAR_GAP_BORDER); buttonBar.setOpaque(false); buttonBar.setLayout(new FormLayout( new ColumnSpec[] { FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.UNRELATED_GAP_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.BUTTON_COLSPEC }, RowSpec.decodeSpecs("pref"))); //---- reportsButton ---- reportsButton.setText("Reports"); reportsButton.setOpaque(false); reportsButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { reportButtonActionPerformed(e); } }); buttonBar.add(reportsButton, cc.xy(2, 1)); //---- batchAddButton ---- batchAddButton.setText("Batch Add"); batchAddButton.setOpaque(false); batchAddButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { batchAddButtonActionPerformed(e); } }); buttonBar.add(batchAddButton, cc.xy(6, 1)); //---- addRecordButton ---- addRecordButton.setText("Add Record"); addRecordButton.setOpaque(false); addRecordButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { addRecordButtonActionPerformed(e); } }); buttonBar.add(addRecordButton, cc.xy(8, 1)); //---- removeRecordButton ---- removeRecordButton.setText("Remove Record"); removeRecordButton.setOpaque(false); removeRecordButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { removeRecordButtonActionPerformed(e); } }); buttonBar.add(removeRecordButton, cc.xy(10, 1)); //---- doneButton ---- doneButton.setText("Done"); doneButton.setOpaque(false); doneButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { doneButtonActionPerformed(e); } }); buttonBar.add(doneButton, cc.xy(14, 1)); } contentPanel.add(buttonBar, cc.xy(2, 6)); } dialogPane.add(contentPanel, BorderLayout.CENTER); } contentPane.add(dialogPane, BorderLayout.CENTER); pack(); setLocationRelativeTo(getOwner()); // JFormDesigner - End of component initialization //GEN-END:initComponents }
From source file:org.archiviststoolkit.dialog.LookupListItemsDialog.java
License:Open Source License
private void initComponents() { // JFormDesigner - Component initialization - DO NOT MODIFY //GEN-BEGIN:initComponents // Generated using JFormDesigner non-commercial license dialogPane = new JPanel(); contentPanel = new JPanel(); label1 = new JLabel(); value = new JTextField(); codeLabel = new JLabel(); code = new JTextField(); buttonBar = new JPanel(); okButton = new JButton(); cancelButton = new JButton(); CellConstraints cc = new CellConstraints(); //======== this ======== setTitle("Lookup List Items"); setModal(true);//from w w w .j a v a2 s .c o m Container contentPane = getContentPane(); contentPane.setLayout(new BorderLayout()); //======== dialogPane ======== { dialogPane.setBorder(Borders.DIALOG_BORDER); dialogPane.setBackground(new Color(200, 205, 232)); dialogPane.setLayout(new BorderLayout()); //======== contentPanel ======== { contentPanel.setOpaque(false); contentPanel .setLayout( new FormLayout( new ColumnSpec[] { FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, new RowSpec[] { FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC })); //---- label1 ---- label1.setText("Value"); contentPanel.add(label1, cc.xy(1, 1)); //---- value ---- value.setPreferredSize(new Dimension(400, 22)); contentPanel.add(value, cc.xy(3, 1)); //---- codeLabel ---- codeLabel.setText("Code"); contentPanel.add(codeLabel, cc.xy(1, 3)); contentPanel.add(code, cc.xy(3, 3)); } dialogPane.add(contentPanel, BorderLayout.CENTER); //======== buttonBar ======== { buttonBar.setBorder(Borders.BUTTON_BAR_GAP_BORDER); buttonBar.setOpaque(false); buttonBar.setLayout(new FormLayout( new ColumnSpec[] { FormFactory.GLUE_COLSPEC, FormFactory.BUTTON_COLSPEC, FormFactory.RELATED_GAP_COLSPEC, FormFactory.BUTTON_COLSPEC }, RowSpec.decodeSpecs("pref"))); //---- okButton ---- okButton.setText("OK"); okButton.setOpaque(false); okButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { okButtonActionPerformed(e); } }); buttonBar.add(okButton, cc.xy(2, 1)); //---- cancelButton ---- cancelButton.setText("Cancel"); cancelButton.setOpaque(false); cancelButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { cancelButtonActionPerformed(e); } }); buttonBar.add(cancelButton, cc.xy(4, 1)); } dialogPane.add(buttonBar, BorderLayout.SOUTH); } contentPane.add(dialogPane, BorderLayout.CENTER); pack(); setLocationRelativeTo(getOwner()); // JFormDesigner - End of component initialization //GEN-END:initComponents }
From source file:org.archiviststoolkit.dialog.NameAuthorityLookup.java
License:Open Source License
private void initComponents() { setModal(true);//from ww w . ja va 2s . c om // JFormDesigner - Component initialization - DO NOT MODIFY //GEN-BEGIN:initComponents // Generated using JFormDesigner non-commercial license dialogPane = new JPanel(); HeaderPanel = new JPanel(); mainHeaderPanel = new JPanel(); mainHeaderLabel = new JLabel(); panel3 = new JPanel(); subHeaderLabel = new JLabel(); contentPane = new JPanel(); label1 = new JLabel(); nameLookup = new JTextField(); scrollPane1 = new JScrollPane(); namesLookupTable = new DomainSortableTable(Names.class, nameLookup); linkingPanel = new JPanel(); label4 = new JLabel(); label3 = new JLabel(); label_function = new JLabel(); function = new JComboBox(); label_role = new JLabel(); role = new JComboBox(); label_form = new JLabel(); form = new JComboBox(); buttonBarLinking = new JPanel(); linkButton = new JButton(); createName = new JButton(); doneButton = new JButton(); selectPanel = new JPanel(); selectButton = new JButton(); doneButton2 = new JButton(); CellConstraints cc = new CellConstraints(); //======== this ======== Container contentPane2 = getContentPane(); contentPane2.setLayout(new BorderLayout()); //======== dialogPane ======== { dialogPane.setBorder(null); dialogPane.setBackground(new Color(200, 205, 232)); dialogPane.setLayout(new BorderLayout()); //======== HeaderPanel ======== { HeaderPanel.setBackground(new Color(80, 69, 57)); HeaderPanel.setOpaque(false); HeaderPanel.setFont(new Font("Trebuchet MS", Font.PLAIN, 13)); HeaderPanel .setLayout(new FormLayout( new ColumnSpec[] { new ColumnSpec( Sizes.bounded(Sizes.MINIMUM, Sizes.dluX(100), Sizes.dluX(200))), new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, RowSpec.decodeSpecs("default"))); //======== mainHeaderPanel ======== { mainHeaderPanel.setBackground(new Color(80, 69, 57)); mainHeaderPanel.setFont(new Font("Trebuchet MS", Font.PLAIN, 13)); mainHeaderPanel .setLayout( new FormLayout( new ColumnSpec[] { FormFactory.RELATED_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, new RowSpec[] { FormFactory.RELATED_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.RELATED_GAP_ROWSPEC })); //---- mainHeaderLabel ---- mainHeaderLabel.setText("Main Header"); mainHeaderLabel.setFont(new Font("Trebuchet MS", Font.PLAIN, 18)); mainHeaderLabel.setForeground(Color.white); mainHeaderPanel.add(mainHeaderLabel, cc.xy(2, 2)); } HeaderPanel.add(mainHeaderPanel, cc.xy(1, 1)); //======== panel3 ======== { panel3.setBackground(new Color(66, 60, 111)); panel3.setFont(new Font("Trebuchet MS", Font.PLAIN, 13)); panel3.setLayout(new FormLayout( new ColumnSpec[] { FormFactory.RELATED_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, new RowSpec[] { FormFactory.RELATED_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.RELATED_GAP_ROWSPEC })); //---- subHeaderLabel ---- subHeaderLabel.setText("Name Lookup"); subHeaderLabel.setFont(new Font("Trebuchet MS", Font.PLAIN, 18)); subHeaderLabel.setForeground(Color.white); panel3.add(subHeaderLabel, cc.xy(2, 2)); } HeaderPanel.add(panel3, cc.xy(2, 1)); } dialogPane.add(HeaderPanel, BorderLayout.NORTH); //======== contentPane ======== { contentPane.setOpaque(false); contentPane .setLayout( new FormLayout( new ColumnSpec[] { FormFactory.UNRELATED_GAP_COLSPEC, FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW), FormFactory.UNRELATED_GAP_COLSPEC }, new RowSpec[] { FormFactory.UNRELATED_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, new RowSpec(RowSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW), FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.UNRELATED_GAP_ROWSPEC })); //---- label1 ---- label1.setText("Filter:"); contentPane.add(label1, cc.xy(2, 2)); contentPane.add(nameLookup, cc.xy(4, 2)); //======== scrollPane1 ======== { scrollPane1.setVerticalScrollBarPolicy(ScrollPaneConstants.VERTICAL_SCROLLBAR_ALWAYS); //---- namesLookupTable ---- namesLookupTable.setPreferredScrollableViewportSize(new Dimension(450, 300)); namesLookupTable.addMouseListener(new MouseAdapter() { @Override public void mouseClicked(MouseEvent e) { namesLookupTableMouseClicked(e); } }); namesLookupTable.addKeyListener(new KeyAdapter() { @Override public void keyTyped(KeyEvent e) { namesLookupTableKeyTyped(e); } }); scrollPane1.setViewportView(namesLookupTable); } contentPane.add(scrollPane1, cc.xywh(2, 4, 3, 1)); //======== linkingPanel ======== { linkingPanel.setOpaque(false); linkingPanel .setLayout( new FormLayout( new ColumnSpec[] { FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, new RowSpec[] { FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC })); //---- label4 ---- label4.setText("Double click on a Name to add it to the record."); linkingPanel.add(label4, cc.xywh(1, 1, 3, 1)); //---- label3 ---- label3.setText("Or hit enter if a Term is highlighted."); linkingPanel.add(label3, cc.xywh(1, 3, 3, 1)); //---- label_function ---- label_function.setText("Function"); linkingPanel.add(label_function, cc.xy(1, 5)); //---- function ---- function.setOpaque(false); function.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { functionActionPerformed(e); } }); linkingPanel.add(function, cc.xywh(3, 5, 1, 1, CellConstraints.LEFT, CellConstraints.DEFAULT)); //---- label_role ---- label_role.setText("Role"); linkingPanel.add(label_role, cc.xy(1, 7)); //---- role ---- role.setOpaque(false); linkingPanel.add(role, cc.xywh(3, 7, 1, 1, CellConstraints.LEFT, CellConstraints.DEFAULT)); //---- label_form ---- label_form.setText("Form Subdivision"); linkingPanel.add(label_form, cc.xy(1, 9)); //---- form ---- form.setOpaque(false); linkingPanel.add(form, cc.xywh(3, 9, 1, 1, CellConstraints.LEFT, CellConstraints.DEFAULT)); //======== buttonBarLinking ======== { buttonBarLinking.setBorder(Borders.BUTTON_BAR_GAP_BORDER); buttonBarLinking.setBackground(new Color(231, 188, 251)); buttonBarLinking.setOpaque(false); buttonBarLinking.setLayout(new FormLayout( new ColumnSpec[] { FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.BUTTON_COLSPEC, FormFactory.RELATED_GAP_COLSPEC, FormFactory.BUTTON_COLSPEC }, RowSpec.decodeSpecs("pref"))); //---- linkButton ---- linkButton.setText("Link"); linkButton.setOpaque(false); linkButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { linkButtonActionPerformed(); } }); buttonBarLinking.add(linkButton, cc.xy(1, 1)); //---- createName ---- createName.setText("Create Name"); createName.setBackground(new Color(231, 188, 251)); createName.setOpaque(false); createName.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { createNameActionPerformed(e); } }); buttonBarLinking.add(createName, cc.xy(3, 1)); //---- doneButton ---- doneButton.setText("Close Window"); doneButton.setBackground(new Color(231, 188, 251)); doneButton.setOpaque(false); doneButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { doneButtonActionPerformed(e); } }); buttonBarLinking.add(doneButton, cc.xy(5, 1)); } linkingPanel.add(buttonBarLinking, cc.xywh(1, 11, 3, 1, CellConstraints.RIGHT, CellConstraints.DEFAULT)); } contentPane.add(linkingPanel, cc.xywh(2, 6, 3, 1)); //======== selectPanel ======== { selectPanel.setBorder(Borders.BUTTON_BAR_GAP_BORDER); selectPanel.setBackground(new Color(231, 188, 251)); selectPanel.setOpaque(false); selectPanel .setLayout(new FormLayout( new ColumnSpec[] { FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.BUTTON_COLSPEC, FormFactory.RELATED_GAP_COLSPEC, FormFactory.BUTTON_COLSPEC }, RowSpec.decodeSpecs("pref"))); //---- selectButton ---- selectButton.setText("Select"); selectButton.setOpaque(false); selectButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { selectButtonActionPerformed(); } }); selectPanel.add(selectButton, cc.xy(3, 1)); //---- doneButton2 ---- doneButton2.setText("Cancel"); doneButton2.setBackground(new Color(231, 188, 251)); doneButton2.setOpaque(false); doneButton2.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { doneButtonActionPerformed(e); } }); selectPanel.add(doneButton2, cc.xy(5, 1)); } contentPane.add(selectPanel, cc.xywh(1, 8, 4, 1, CellConstraints.RIGHT, CellConstraints.DEFAULT)); } dialogPane.add(contentPane, BorderLayout.CENTER); } contentPane2.add(dialogPane, BorderLayout.CENTER); pack(); setLocationRelativeTo(getOwner()); // JFormDesigner - End of component initialization //GEN-END:initComponents }
From source file:org.archiviststoolkit.dialog.QueryEditor.java
License:Open Source License
private void initComponents() { // JFormDesigner - Component initialization - DO NOT MODIFY //GEN-BEGIN:initComponents // Generated using JFormDesigner non-commercial license dialogPane = new JPanel(); HeaderPanel = new JPanel(); mainHeaderPanel = new JPanel(); mainHeaderLabel = new JLabel(); subHeaderPanel = new JPanel(); subHeaderLabel = new JLabel(); tabbedPane1 = new JTabbedPane(); panel1 = new JPanel(); searchEditorLabel = new JLabel(); contentPane = new JPanel(); fieldSelector1 = new JComboBox(); placeHolder1 = new QueryEditorTextPanel(); boolean1 = new JComboBox(); fieldSelector2 = new JComboBox(); placeHolder2 = new QueryEditorTextPanel(); includeComponents = new JCheckBox(); buttonBar2 = new JPanel(); cancelButton2 = new JButton(); queryButton = new JButton(); classSpecificPanel = new JPanel(); altQueryLabel = new JLabel(); panel2 = new JPanel(); label1 = new JLabel(); sortName = new JTextField(); lookupName = new JButton(); clearName = new JButton(); label2 = new JLabel(); function = ATBasicComponentFactory.createUnboundComboBox(LookupListUtils.getLookupListValues( ArchDescriptionNames.class, ArchDescriptionNames.PROPERTYNAME_NAME_LINK_FUNCTION)); label5 = new JLabel(); subject = new JTextField(); lookupSubject = new JButton(); clearSubject = new JButton(); label6 = new JLabel(); location = new JTextField(); lookupLocation = new JButton(); clearLocation = new JButton(); resourceLabel = new JLabel(); resource = new JTextField(); lookupResource = new JButton(); clearResource = new JButton(); fileLabel = new JLabel(); fileURI = new JTextField(); panel3 = new JPanel(); label8 = new JLabel(); deaccessionDateStart = ATBasicComponentFactory.createUnboundDateField(); label3 = new JLabel(); deaccessionDateEnd = ATBasicComponentFactory.createUnboundDateField(); panel4 = new JPanel(); identifierLabel = new JLabel(); bucket1 = new JTextField(); bucket2 = new JTextField(); bucket3 = new JTextField(); bucket4 = new JTextField(); resourceOnlyPanel = new JPanel(); label9 = new JLabel(); noteText = new JTextField(); label7 = new JLabel(); instanceType = ATBasicComponentFactory.createUnboundComboBox(LookupListUtils.getLookupListValues( ArchDescriptionInstances.class, ArchDescriptionInstances.PROPERTYNAME_INSTANCE_TYPE)); includeComponentsRelatedSearch = new JCheckBox(); buttonBar = new JPanel(); cancelButton = new JButton(); queryButton2 = new JButton(); CellConstraints cc = new CellConstraints(); //======== this ======== setModal(true);/* w ww . j a v a 2 s . c o m*/ setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE); addWindowListener(new WindowAdapter() { @Override public void windowClosing(WindowEvent e) { thisWindowClosing(); } }); Container contentPane2 = getContentPane(); contentPane2.setLayout(new BorderLayout()); //======== dialogPane ======== { dialogPane.setBorder(null); dialogPane.setBackground(new Color(200, 205, 232)); dialogPane.setLayout(new BorderLayout()); //======== HeaderPanel ======== { HeaderPanel.setOpaque(false); HeaderPanel.setFont(new Font("Trebuchet MS", Font.PLAIN, 13)); HeaderPanel .setLayout(new FormLayout( new ColumnSpec[] { new ColumnSpec( Sizes.bounded(Sizes.MINIMUM, Sizes.dluX(100), Sizes.dluX(200))), new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, RowSpec.decodeSpecs("default"))); //======== mainHeaderPanel ======== { mainHeaderPanel.setBackground(new Color(80, 69, 57)); mainHeaderPanel.setFont(new Font("Trebuchet MS", Font.PLAIN, 13)); mainHeaderPanel .setLayout( new FormLayout( new ColumnSpec[] { FormFactory.RELATED_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, new RowSpec[] { FormFactory.RELATED_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.RELATED_GAP_ROWSPEC })); //---- mainHeaderLabel ---- mainHeaderLabel.setText("Main Header"); mainHeaderLabel.setFont(new Font("Trebuchet MS", Font.PLAIN, 18)); mainHeaderLabel.setForeground(Color.white); mainHeaderPanel.add(mainHeaderLabel, cc.xy(2, 2)); } HeaderPanel.add(mainHeaderPanel, cc.xy(1, 1)); //======== subHeaderPanel ======== { subHeaderPanel.setBackground(new Color(66, 60, 111)); subHeaderPanel.setFont(new Font("Trebuchet MS", Font.PLAIN, 13)); subHeaderPanel .setLayout( new FormLayout( new ColumnSpec[] { FormFactory.RELATED_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, new RowSpec[] { FormFactory.RELATED_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.RELATED_GAP_ROWSPEC })); //---- subHeaderLabel ---- subHeaderLabel.setText("Search Editor"); subHeaderLabel.setFont(new Font("Trebuchet MS", Font.PLAIN, 18)); subHeaderLabel.setForeground(Color.white); subHeaderPanel.add(subHeaderLabel, cc.xy(2, 2)); } HeaderPanel.add(subHeaderPanel, cc.xy(2, 1)); } dialogPane.add(HeaderPanel, BorderLayout.NORTH); //======== tabbedPane1 ======== { //======== panel1 ======== { panel1.setBorder(Borders.DIALOG_BORDER); panel1.setOpaque(false); panel1.setLayout(new FormLayout(ColumnSpec.decodeSpecs("default:grow"), new RowSpec[] { FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, new RowSpec(RowSpec.CENTER, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) })); //---- searchEditorLabel ---- searchEditorLabel.setText("Search editor"); panel1.add(searchEditorLabel, cc.xy(1, 1)); //======== contentPane ======== { contentPane.setBackground(new Color(231, 188, 251)); contentPane.setOpaque(false); contentPane.setBorder(Borders.DIALOG_BORDER); contentPane .setLayout(new FormLayout( new ColumnSpec[] { FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, new ColumnSpec("400px:grow"), FormFactory.LABEL_COMPONENT_GAP_COLSPEC, new ColumnSpec(ColumnSpec.LEFT, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, new RowSpec[] { FormFactory.DEFAULT_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC })); //---- fieldSelector1 ---- fieldSelector1.setOpaque(false); fieldSelector1.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { fieldSelector1ActionPerformed(e); } }); contentPane.add(fieldSelector1, cc.xy(1, 1)); //---- placeHolder1 ---- placeHolder1.setOpaque(false); contentPane.add(placeHolder1, cc.xy(3, 1)); //---- boolean1 ---- boolean1.setModel(new DefaultComboBoxModel(new String[] { "and", "or" })); boolean1.setOpaque(false); contentPane.add(boolean1, cc.xy(5, 1)); //---- fieldSelector2 ---- fieldSelector2.setOpaque(false); fieldSelector2.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { fieldSelector2ActionPerformed(e); } }); contentPane.add(fieldSelector2, cc.xy(1, 2)); //---- placeHolder2 ---- placeHolder2.setOpaque(false); contentPane.add(placeHolder2, cc.xy(3, 2)); //---- includeComponents ---- includeComponents.setText("Include components in search"); includeComponents.setOpaque(false); includeComponents.setSelected(true); includeComponents.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { includeComponentsActionPerformed(); } }); contentPane.add(includeComponents, cc.xywh(1, 4, 5, 1)); //======== buttonBar2 ======== { buttonBar2.setBorder(Borders.BUTTON_BAR_GAP_BORDER); buttonBar2.setBackground(new Color(231, 188, 251)); buttonBar2.setOpaque(false); buttonBar2.setLayout(new FormLayout( new ColumnSpec[] { FormFactory.GLUE_COLSPEC, FormFactory.BUTTON_COLSPEC, FormFactory.RELATED_GAP_COLSPEC, FormFactory.BUTTON_COLSPEC }, RowSpec.decodeSpecs("pref"))); //---- cancelButton2 ---- cancelButton2.setText("Cancel"); cancelButton2.setOpaque(false); cancelButton2.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { cancelButtonActionPerformed(e); } }); buttonBar2.add(cancelButton2, cc.xy(2, 1)); //---- queryButton ---- queryButton.setText("Search"); queryButton.setOpaque(false); queryButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { queryButtonActionPerformed(e); } }); buttonBar2.add(queryButton, cc.xy(4, 1)); } contentPane.add(buttonBar2, cc.xywh(1, 6, 5, 1)); } panel1.add(contentPane, cc.xy(1, 3)); } tabbedPane1.addTab("Search", panel1); //======== classSpecificPanel ======== { classSpecificPanel.setOpaque(false); classSpecificPanel.setBorder(Borders.DIALOG_BORDER); classSpecificPanel.setLayout(new FormLayout(ColumnSpec.decodeSpecs("default:grow"), new RowSpec[] { FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC })); //---- altQueryLabel ---- altQueryLabel.setText("Search by linked record:"); classSpecificPanel.add(altQueryLabel, cc.xy(1, 1)); //======== panel2 ======== { panel2.setOpaque(false); panel2.setLayout(new FormLayout( new ColumnSpec[] { FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW), FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.DEFAULT_COLSPEC }, new RowSpec[] { FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC })); //---- label1 ---- label1.setText("Find by name"); panel2.add(label1, cc.xy(1, 1)); //---- sortName ---- sortName.setEditable(false); sortName.setOpaque(false); panel2.add(sortName, cc.xy(3, 1)); //---- lookupName ---- lookupName.setText("Lookup"); lookupName.setFont(new Font("Lucida Grande", Font.PLAIN, 10)); lookupName.setOpaque(false); lookupName.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { lookupNameActionPerformed(); } }); panel2.add(lookupName, cc.xy(5, 1)); //---- clearName ---- clearName.setText("Clear"); clearName.setFont(new Font("Lucida Grande", Font.PLAIN, 10)); clearName.setOpaque(false); clearName.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { clearNameActionPerformed(); } }); panel2.add(clearName, cc.xy(7, 1)); //---- label2 ---- label2.setText("Function"); panel2.add(label2, cc.xy(9, 1)); //---- function ---- function.setOpaque(false); panel2.add(function, cc.xywh(11, 1, 1, 1, CellConstraints.LEFT, CellConstraints.DEFAULT)); //---- label5 ---- label5.setText("Find by subject"); panel2.add(label5, cc.xy(1, 3)); //---- subject ---- subject.setEditable(false); subject.setOpaque(false); panel2.add(subject, cc.xy(3, 3)); //---- lookupSubject ---- lookupSubject.setText("Lookup"); lookupSubject.setFont(new Font("Lucida Grande", Font.PLAIN, 10)); lookupSubject.setOpaque(false); lookupSubject.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { lookupSubjectActionPerformed(); } }); panel2.add(lookupSubject, cc.xy(5, 3)); //---- clearSubject ---- clearSubject.setText("Clear"); clearSubject.setFont(new Font("Lucida Grande", Font.PLAIN, 10)); clearSubject.setOpaque(false); clearSubject.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { clearSubjectActionPerformed(); } }); panel2.add(clearSubject, cc.xy(7, 3)); //---- label6 ---- label6.setText("Find by location"); panel2.add(label6, cc.xy(1, 5)); //---- location ---- location.setEditable(false); location.setOpaque(false); panel2.add(location, cc.xy(3, 5)); //---- lookupLocation ---- lookupLocation.setText("Lookup"); lookupLocation.setFont(new Font("Lucida Grande", Font.PLAIN, 10)); lookupLocation.setOpaque(false); lookupLocation.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { lookupLocationActionPerformed(); } }); panel2.add(lookupLocation, cc.xy(5, 5)); //---- clearLocation ---- clearLocation.setText("Clear"); clearLocation.setFont(new Font("Lucida Grande", Font.PLAIN, 10)); clearLocation.setOpaque(false); clearLocation.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { clearLocationActionPerformed(); } }); panel2.add(clearLocation, cc.xy(7, 5)); //---- resourceLabel ---- resourceLabel.setText("Find by resource"); panel2.add(resourceLabel, cc.xy(1, 7)); //---- resource ---- resource.setEditable(false); resource.setOpaque(false); panel2.add(resource, cc.xy(3, 7)); //---- lookupResource ---- lookupResource.setText("Lookup"); lookupResource.setFont(new Font("Lucida Grande", Font.PLAIN, 10)); lookupResource.setOpaque(false); lookupResource.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { lookupResourceActionPerformed(); } }); panel2.add(lookupResource, cc.xy(5, 7)); //---- clearResource ---- clearResource.setText("Clear"); clearResource.setFont(new Font("Lucida Grande", Font.PLAIN, 10)); clearResource.setOpaque(false); clearResource.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { clearResourceActionPerformed(); } }); panel2.add(clearResource, cc.xy(7, 7)); //---- fileLabel ---- fileLabel.setText("Find by file URI"); panel2.add(fileLabel, cc.xy(1, 9)); panel2.add(fileURI, cc.xywh(3, 9, 5, 1)); //======== panel3 ======== { panel3.setOpaque(false); panel3.setLayout(new FormLayout( new ColumnSpec[] { FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.DEFAULT_COLSPEC }, RowSpec.decodeSpecs("default"))); //---- label8 ---- label8.setText("Find by deaccession date"); panel3.add(label8, cc.xy(1, 1)); //---- deaccessionDateStart ---- deaccessionDateStart.setFont(new Font("Trebuchet MS", Font.PLAIN, 13)); deaccessionDateStart.setColumns(12); panel3.add(deaccessionDateStart, cc.xywh(3, 1, 1, 1, CellConstraints.LEFT, CellConstraints.DEFAULT)); //---- label3 ---- label3.setText("-"); panel3.add(label3, cc.xy(5, 1)); //---- deaccessionDateEnd ---- deaccessionDateEnd.setFont(new Font("Trebuchet MS", Font.PLAIN, 13)); deaccessionDateEnd.setColumns(12); deaccessionDateEnd.addFocusListener(new FocusAdapter() { @Override public void focusGained(FocusEvent e) { deaccessionDateEndFocusGained(); } }); panel3.add(deaccessionDateEnd, cc.xywh(7, 1, 1, 1, CellConstraints.LEFT, CellConstraints.DEFAULT)); } panel2.add(panel3, cc.xywh(1, 13, 11, 1)); //======== panel4 ======== { panel4.setOpaque(false); panel4.setLayout(new FormLayout( new ColumnSpec[] { FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW), FormFactory.LABEL_COMPONENT_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW), FormFactory.LABEL_COMPONENT_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW), FormFactory.LABEL_COMPONENT_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, RowSpec.decodeSpecs("default"))); ((FormLayout) panel4.getLayout()).setColumnGroups(new int[][] { { 3, 5, 7, 9 } }); //---- identifierLabel ---- identifierLabel.setText("identifier"); panel4.add(identifierLabel, cc.xy(1, 1)); panel4.add(bucket1, cc.xy(3, 1)); panel4.add(bucket2, cc.xy(5, 1)); panel4.add(bucket3, cc.xy(7, 1)); panel4.add(bucket4, cc.xy(9, 1)); } panel2.add(panel4, cc.xywh(1, 15, 11, 1)); //======== resourceOnlyPanel ======== { resourceOnlyPanel.setOpaque(false); resourceOnlyPanel.setLayout(new FormLayout( new ColumnSpec[] { FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW), FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, FormFactory.DEFAULT_COLSPEC }, new RowSpec[] { FormFactory.DEFAULT_ROWSPEC, FormFactory.DEFAULT_ROWSPEC, FormFactory.LINE_GAP_ROWSPEC, FormFactory.DEFAULT_ROWSPEC })); //---- label9 ---- label9.setText("Find by note text"); resourceOnlyPanel.add(label9, cc.xy(1, 1)); resourceOnlyPanel.add(noteText, cc.xy(3, 1)); //---- label7 ---- label7.setText("Find by instance type"); resourceOnlyPanel.add(label7, cc.xy(1, 2)); //---- instanceType ---- instanceType.setOpaque(false); instanceType.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { instanceTypeActionPerformed(); } }); resourceOnlyPanel.add(instanceType, cc.xywh(3, 2, 1, 1, CellConstraints.LEFT, CellConstraints.DEFAULT)); //---- includeComponentsRelatedSearch ---- includeComponentsRelatedSearch.setText("Include components in search"); includeComponentsRelatedSearch.setOpaque(false); includeComponentsRelatedSearch.setSelected(true); resourceOnlyPanel.add(includeComponentsRelatedSearch, cc.xywh(1, 4, 11, 1)); } panel2.add(resourceOnlyPanel, cc.xywh(1, 17, 11, 1)); } classSpecificPanel.add(panel2, cc.xy(1, 3)); //======== buttonBar ======== { buttonBar.setBorder(Borders.BUTTON_BAR_GAP_BORDER); buttonBar.setBackground(new Color(231, 188, 251)); buttonBar.setOpaque(false); buttonBar.setLayout(new FormLayout( new ColumnSpec[] { FormFactory.GLUE_COLSPEC, FormFactory.BUTTON_COLSPEC, FormFactory.RELATED_GAP_COLSPEC, FormFactory.BUTTON_COLSPEC }, RowSpec.decodeSpecs("pref"))); //---- cancelButton ---- cancelButton.setText("Cancel"); cancelButton.setOpaque(false); cancelButton.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { cancelButtonActionPerformed(e); } }); buttonBar.add(cancelButton, cc.xy(2, 1)); //---- queryButton2 ---- queryButton2.setText("Search"); queryButton2.setOpaque(false); queryButton2.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { queryButton2ActionPerformed(e); } }); buttonBar.add(queryButton2, cc.xy(4, 1)); } classSpecificPanel.add(buttonBar, cc.xy(1, 5)); } tabbedPane1.addTab("Search By Linked Record", classSpecificPanel); } dialogPane.add(tabbedPane1, BorderLayout.SOUTH); } contentPane2.add(dialogPane, BorderLayout.CENTER); pack(); setLocationRelativeTo(getOwner()); // JFormDesigner - End of component initialization //GEN-END:initComponents }
From source file:org.archiviststoolkit.dialog.QueryEditor4BucketPanel.java
License:Open Source License
private void initComponents() { // JFormDesigner - Component initialization - DO NOT MODIFY //GEN-BEGIN:initComponents // Generated using JFormDesigner non-commercial license comparator = new JLabel(); bucket1 = new JTextField(); bucket2 = new JTextField(); bucket3 = new JTextField(); bucket4 = new JTextField(); CellConstraints cc = new CellConstraints(); //======== this ======== setBackground(new Color(231, 188, 251)); setOpaque(false);/* w w w . j ava 2s . c o m*/ setLayout(new FormLayout( new ColumnSpec[] { FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.dluX(10), FormSpec.DEFAULT_GROW), FormFactory.LABEL_COMPONENT_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW), FormFactory.LABEL_COMPONENT_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW), FormFactory.LABEL_COMPONENT_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.dluX(10), FormSpec.DEFAULT_GROW) }, RowSpec.decodeSpecs("default"))); ((FormLayout) getLayout()).setColumnGroups(new int[][] { { 3, 5, 7, 9 } }); //---- comparator ---- comparator.setBackground(new Color(231, 188, 251)); comparator.setText("Equals"); add(comparator, cc.xy(1, 1)); add(bucket1, cc.xy(3, 1)); add(bucket2, cc.xy(5, 1)); add(bucket3, cc.xy(7, 1)); add(bucket4, cc.xy(9, 1)); // JFormDesigner - End of component initialization //GEN-END:initComponents }
From source file:org.archiviststoolkit.dialog.QueryEditorRepositoryPanel.java
License:Open Source License
private void initComponents() { // JFormDesigner - Component initialization - DO NOT MODIFY //GEN-BEGIN:initComponents // Generated using JFormDesigner non-commercial license comparator = new JComboBox(); repositoryList = new JComboBox(); CellConstraints cc = new CellConstraints(); //======== this ======== setBackground(new Color(231, 188, 251)); setOpaque(false);//from w w w.j a va 2s . com setLayout(new FormLayout( new ColumnSpec[] { FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, RowSpec.decodeSpecs("default"))); //---- comparator ---- comparator.setOpaque(false); add(comparator, cc.xy(1, 1)); //---- repositoryList ---- repositoryList.setOpaque(false); add(repositoryList, cc.xy(3, 1)); // JFormDesigner - End of component initialization //GEN-END:initComponents }
From source file:org.archiviststoolkit.dialog.QueryEditorTextPanel.java
License:Open Source License
private void initComponents() { // JFormDesigner - Component initialization - DO NOT MODIFY //GEN-BEGIN:initComponents // Generated using JFormDesigner non-commercial license comparator = new JComboBox(); value = new JTextField(); CellConstraints cc = new CellConstraints(); //======== this ======== setBackground(new Color(231, 188, 251)); setOpaque(false);/*from ww w.j a v a 2s. c o m*/ setLayout(new FormLayout( new ColumnSpec[] { FormFactory.DEFAULT_COLSPEC, FormFactory.LABEL_COMPONENT_GAP_COLSPEC, new ColumnSpec(ColumnSpec.FILL, Sizes.DEFAULT, FormSpec.DEFAULT_GROW) }, RowSpec.decodeSpecs("default"))); //---- comparator ---- comparator.setOpaque(false); comparator.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { comparatorActionPerformed(e); } }); add(comparator, cc.xy(1, 1)); add(value, cc.xy(3, 1)); // JFormDesigner - End of component initialization //GEN-END:initComponents }