private void jbInit() throws Exception {
   titledBorder1 = new TitledBorder("");
   this.setLayout(borderLayout1);
   this.setBorder(titledBorder1);
   titledBorder1.setTitleColor(Color.blue);
   titledBorder1.setTitle(
       ClientSettings.getInstance().getResources().getResource("documents filter"));
   this.add(sp, BorderLayout.CENTER);
   sp.setBorder(BorderFactory.createEmptyBorder());
   sp.getViewport().add(innerPanel, null);
   sp.setAutoscrolls(true);
   innerPanel.setLayout(gridBagLayout1);
 }
  /**
   * Create plot info panel
   *
   * @return panel
   */
  private JPanel createMapPanel() {
    JPanel panel = new JPanel(new BorderLayout(), true);

    // create an raised, etched, titled border
    Border etchedBorder = BorderFactory.createEtchedBorder(EtchedBorder.LOWERED);
    TitledBorder titledBorder = BorderFactory.createTitledBorder(etchedBorder, "Map");
    titledBorder.setTitleJustification(TitledBorder.LEFT);
    panel.setBorder(titledBorder);

    // load image
    java.net.URL imgURL = getClass().getResource("/resources/map.png");
    map = new ScrollablePicture(new ImageIcon(imgURL), 10);
    // map = new ScrollablePicture(new ImageIcon("resources/map.png"), 10);
    mapScrollPane = new JScrollPane(map);
    mapScrollPane.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_ALWAYS);
    mapScrollPane.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_ALWAYS);

    map.addMouseListener(
        new MouseListener() {
          /**
           * Get the coordinates of a mouse click event
           *
           * @param e MouseEvent
           */
          @Override
          public void mouseClicked(MouseEvent e) {
            if (cemeteryPlotterFrame.cemeteryPlotterPlot.isEditable())
              cemeteryPlotterFrame.cemeteryPlotterPlot.setMapLocationField(e.getPoint());
          }

          @Override
          public void mousePressed(MouseEvent e) {}

          @Override
          public void mouseReleased(MouseEvent e) {}

          @Override
          public void mouseEntered(MouseEvent e) {
            if (cemeteryPlotterFrame.cemeteryPlotterPlot.isEditable())
              mapScrollPane.setCursor(new Cursor(Cursor.CROSSHAIR_CURSOR));
          }

          @Override
          public void mouseExited(MouseEvent e) {}
        });

    // add map scroll pane to main panel
    panel.add(mapScrollPane, BorderLayout.CENTER);

    return panel;
  }
  public BorderedComponent(String text, JComponent comp, boolean collapsible) {
    super(null);

    this.comp = comp;

    // Only add border if text is not null
    if (text != null) {
      TitledBorder border;
      if (collapsible) {
        final JLabel textLabel = new JLabel(text);
        JPanel borderLabel =
            new JPanel(new FlowLayout(FlowLayout.LEFT, 2, 0)) {
              public int getBaseline(int w, int h) {
                Dimension dim = textLabel.getPreferredSize();
                return textLabel.getBaseline(dim.width, dim.height) + textLabel.getY();
              }
            };
        borderLabel.add(textLabel);
        border = new LabeledBorder(borderLabel);
        textLabel.setForeground(border.getTitleColor());

        if (IS_WIN) {
          collapseIcon = new ImageIcon(getImage("collapse-winlf"));
          expandIcon = new ImageIcon(getImage("expand-winlf"));
        } else {
          collapseIcon = new ArrowIcon(SOUTH, textLabel);
          expandIcon = new ArrowIcon(EAST, textLabel);
        }

        moreOrLessButton = new JButton(collapseIcon);
        moreOrLessButton.setContentAreaFilled(false);
        moreOrLessButton.setBorderPainted(false);
        moreOrLessButton.setMargin(new Insets(0, 0, 0, 0));
        moreOrLessButton.addActionListener(this);
        String toolTip = Messages.BORDERED_COMPONENT_MORE_OR_LESS_BUTTON_TOOLTIP;
        moreOrLessButton.setToolTipText(toolTip);
        borderLabel.add(moreOrLessButton);
        borderLabel.setSize(borderLabel.getPreferredSize());
        add(borderLabel);
      } else {
        border = new TitledBorder(text);
      }
      setBorder(new CompoundBorder(new FocusBorder(this), border));
    } else {
      setBorder(new FocusBorder(this));
    }
    if (comp != null) {
      add(comp);
    }
  }
Esempio n. 4
0
 private static int getPanelBaseline(JPanel panel, int height) {
   Border border = panel.getBorder();
   if (border instanceof TitledBorder) {
     TitledBorder titledBorder = (TitledBorder) border;
     if (titledBorder.getTitle() != null && !"".equals(titledBorder.getTitle())) {
       Font font = titledBorder.getTitleFont();
       if (font == null) {
         font = panel.getFont();
         if (font == null) {
           font = new Font("Dialog", Font.PLAIN, 12);
         }
       }
       Border border2 = titledBorder.getBorder();
       Insets borderInsets;
       if (border2 != null) {
         borderInsets = border2.getBorderInsets(panel);
       } else {
         borderInsets = EMPTY_INSETS;
       }
       FontMetrics fm = panel.getFontMetrics(font);
       int fontHeight = fm.getHeight();
       int descent = fm.getDescent();
       int ascent = fm.getAscent();
       int y = EDGE_SPACING;
       int h = height - EDGE_SPACING * 2;
       int diff;
       switch (((TitledBorder) border).getTitlePosition()) {
         case TitledBorder.ABOVE_TOP:
           diff = ascent + descent + (Math.max(EDGE_SPACING, TEXT_SPACING * 2) - EDGE_SPACING);
           return y + diff - (descent + TEXT_SPACING);
         case TitledBorder.TOP:
         case TitledBorder.DEFAULT_POSITION:
           diff = Math.max(0, ((ascent / 2) + TEXT_SPACING) - EDGE_SPACING);
           return (y + diff - descent) + (borderInsets.top + ascent + descent) / 2;
         case TitledBorder.BELOW_TOP:
           return y + borderInsets.top + ascent + TEXT_SPACING;
         case TitledBorder.ABOVE_BOTTOM:
           return (y + h) - (borderInsets.bottom + descent + TEXT_SPACING);
         case TitledBorder.BOTTOM:
           h -= fontHeight / 2;
           return ((y + h) - descent) + ((ascent + descent) - borderInsets.bottom) / 2;
         case TitledBorder.BELOW_BOTTOM:
           h -= fontHeight;
           return y + h + ascent + TEXT_SPACING;
       }
     }
   }
   return -1;
 }
Esempio n. 5
0
  /**
   * Add a border of a particular style to a component
   *
   * @param c : JComponent to add border to
   * @param borderType : type of border, BD_x
   * @param label : if not null, string to display at top of border
   * @param labelAlignment : if label defined, this determines its horizontal alignment
   */
  public static void addBorder(JComponent c, int borderType, String label, int labelAlignment) {
    final Border[] b = {
      // #0: empty, spacing of 2
      BorderFactory.createEmptyBorder(2, 2, 2, 2),
      // #1: lowered etched, interior spacing of 2
      BorderFactory.createCompoundBorder(
          BorderFactory.createEtchedBorder(EtchedBorder.LOWERED),
          BorderFactory.createEmptyBorder(2, 2, 2, 2)),
      // BorderFactory.createLineBorder(Color.red,3),
    };

    Tools.ASSERT(!(label != null && borderType < 0));

    if (label != null) {
      TitledBorder t = BorderFactory.createTitledBorder(b[borderType], label);

      int tbAlign = 0;
      switch (labelAlignment) {
        default:
          tbAlign = TitledBorder.LEFT;
          break;
        case SwingConstants.CENTER:
          tbAlign = TitledBorder.CENTER;
          break;
        case SwingConstants.RIGHT:
          tbAlign = TitledBorder.RIGHT;
          break;
      }
      t.setTitleJustification(tbAlign);
      c.setBorder(t);
    } else {
      if (borderType >= 0) {
        c.setBorder(b[borderType]);
      }
    }
  }
Esempio n. 6
0
    public PlayerView(String player) {
      playerName = new String(player);

      // Set-Up Top of Score Area
      namePanel = new JPanel();
      nameText = new JLabel(player);
      nameText.setFont(ScoreFont);
      namePanel.setLayout(new BorderLayout());
      namePanel.add(nameText, BorderLayout.CENTER);

      scorePanel = new JPanel();
      scoreText = new JLabel("  0");
      scoreText.setFont(ScoreFont);
      scorePanel.setLayout(new BorderLayout());
      scorePanel.add(scoreText, BorderLayout.CENTER);

      topPanel = new JPanel();
      BoxLayout layout = new BoxLayout(topPanel, BoxLayout.LINE_AXIS);

      topPanel.setLayout(layout);
      topPanel.add(namePanel);
      topPanel.add(Box.createRigidArea(new Dimension(10, 0)));
      topPanel.add(scorePanel);
      topPanel.add(Box.createRigidArea(new Dimension(10, 0)));

      //
      // topPanel.setLayout( new BorderLayout());
      // topPanel.add(namePanel, BorderLayout.WEST);
      // topPanel.add(scorePanel, BorderLayout.EAST);
      //
      // Create bordering for top panel
      Border raisedBevel, loweredBevel, compound;

      raisedBevel = BorderFactory.createRaisedBevelBorder();
      loweredBevel = BorderFactory.createLoweredBevelBorder();
      compound = BorderFactory.createCompoundBorder(raisedBevel, loweredBevel);
      topPanel.setBorder(compound);

      // Set-Up area to display word list
      wordPanel = new JPanel();
      Border etched = BorderFactory.createEtchedBorder();
      TitledBorder etchedTitle = BorderFactory.createTitledBorder(etched, "Word List");
      etchedTitle.setTitleJustification(TitledBorder.RIGHT);
      wordPanel.setBorder(etchedTitle);
      myWordList = new ExpandableList();
      myWordList.addActionListener(
          new ActionListener() {

            @Override
            public void actionPerformed(ActionEvent e) {
              String word = e.getActionCommand();
              java.util.List<BoardCell> list = myFinder.cellsForWord(myBoard, word);
              myBoardPanel.highlightDice(list);
            }
          });
      wordPanel.add(
          new JScrollPane(
              myWordList,
              JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED,
              JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED));

      setLayout(new BorderLayout(30, 30));
      add(topPanel, BorderLayout.NORTH);
      add(wordPanel, BorderLayout.CENTER);
    }
  private void jbInit() throws Exception {
    itemsGrid.setMaxNumberOfRowsOnInsert(50);
    impAllItemsButton.setToolTipText(
        ClientSettings.getInstance().getResources().getResource("import all items"));
    impAllItemsButton.addActionListener(
        new SupplierDetailFrame_impAllItemsButton_actionAdapter(this));

    detailPanel.setLayout(gridBagLayout4);
    itemsGrid.setSelectionMode(ListSelectionModel.MULTIPLE_INTERVAL_SELECTION);
    supplierPanel.setVOClassName("org.jallinone.purchases.suppliers.java.DetailSupplierVO");
    supplierPanel.addLinkedPanel(organizationPanel);
    titledBorder1 = new TitledBorder("");
    titledBorder2 = new TitledBorder("");
    subjectPanel.setLayout(gridBagLayout1);
    supplierPanel.setBorder(titledBorder1);
    supplierPanel.setLayout(gridBagLayout2);
    titledBorder1.setTitle(ClientSettings.getInstance().getResources().getResource("supplier"));
    titledBorder1.setTitleColor(Color.blue);
    labelSupplierCode.setText("supplierCodePUR01");
    labelPay.setText("payment terms");
    labelBank.setText("bank");
    controlSupplierCode.setAttributeName("supplierCodePUR01");
    controlSupplierCode.setCanCopy(false);
    controlSupplierCode.setLinkLabel(labelSupplierCode);
    controlSupplierCode.setMaxCharacters(20);
    //    controlSupplierCode.setRequired(true);
    controlSupplierCode.setTrimText(true);
    controlSupplierCode.setUpperCase(true);
    controlSupplierCode.setEnabledOnEdit(false);
    controlPayment.setAttributeName("paymentCodeReg10PUR01");
    controlPayment.setCanCopy(true);
    controlPayment.setLinkLabel(labelPay);
    controlPayment.setMaxCharacters(20);
    controlPayment.setRequired(true);
    controlPayDescr.setAttributeName("paymentDescriptionSYS10");
    controlPayDescr.setCanCopy(true);
    controlPayDescr.setEnabledOnInsert(false);
    controlPayDescr.setEnabledOnEdit(false);
    controlBank.setAttributeName("bankCodeReg12PUR01");
    controlBank.setCanCopy(true);
    controlBank.setLinkLabel(labelBank);
    controlBank.setMaxCharacters(20);
    controlBankDescr.setAttributeName("descriptionREG12");
    controlBankDescr.setCanCopy(true);
    controlBankDescr.setEnabledOnInsert(false);
    controlBankDescr.setEnabledOnEdit(false);
    refPanel.setLayout(borderLayout1);
    hierarPanel.setLayout(borderLayout4);
    treeGridItemsPanel.setLayout(borderLayout3);
    itemsSplitPane.setOrientation(JSplitPane.HORIZONTAL_SPLIT);
    itemsSplitPane.setDividerSize(5);
    itemsPanel.setLayout(borderLayout5);
    itemButtonsPanel.setLayout(flowLayout2);
    flowLayout2.setAlignment(FlowLayout.LEFT);
    itemsGrid.setAutoLoadData(false);
    itemsGrid.setDeleteButton(deleteButton1);
    itemsGrid.setEditButton(editButton1);
    itemsGrid.setExportButton(exportButton1);
    itemsGrid.setFunctionId("PUR01");
    itemsGrid.setMaxSortedColumns(3);
    itemsGrid.setInsertButton(insertButton1);
    itemsGrid.setNavBar(navigatorBar1);
    itemsGrid.setReloadButton(reloadButton1);
    itemsGrid.setSaveButton(saveButton1);
    itemsGrid.setValueObjectClassName("org.jallinone.purchases.items.java.SupplierItemVO");
    insertButton1.setText("insertButton1");
    editButton1.setText("editButton1");
    saveButton1.setText("saveButton1");
    reloadButton1.setText("reloadButton1");
    deleteButton1.setText("deleteButton1");
    itemHierarsPanel.setLayout(gridBagLayout3);
    labelHierar.setText("item hierarchies");
    colItemCode.setColumnFilterable(true);
    colItemCode.setColumnName("itemCodeItm01PUR02");
    colItemCode.setColumnSortable(true);
    colItemCode.setEditableOnInsert(true);
    colItemCode.setHeaderColumnName("itemCodeITM01");
    colItemCode.setPreferredWidth(90);
    colItemCode.setSortVersus(org.openswing.swing.util.java.Consts.ASC_SORTED);
    colItemCode.setMaxCharacters(20);
    colItemDescr.setColumnFilterable(true);
    colItemDescr.setColumnName("descriptionSYS10");
    colItemDescr.setColumnSortable(true);
    colItemDescr.setHeaderColumnName("itemDescriptionSYS10");
    colItemDescr.setPreferredWidth(200);
    colSupplierItemCode.setMaxCharacters(20);
    colSupplierItemCode.setTrimText(true);
    colSupplierItemCode.setUpperCase(true);
    colSupplierItemCode.setColumnFilterable(true);
    colSupplierItemCode.setColumnName("supplierItemCodePUR02");
    colSupplierItemCode.setColumnSortable(true);
    colSupplierItemCode.setEditableOnEdit(true);
    colSupplierItemCode.setEditableOnInsert(true);
    colSupplierItemCode.setHeaderColumnName("supplierItemCodePUR02");
    colSupplierItemCode.setPreferredWidth(120);
    colUmCode.setColumnDuplicable(true);
    colUmCode.setColumnFilterable(true);
    colUmCode.setColumnName("umCodeReg02PUR02");
    colUmCode.setEditableOnEdit(true);
    colUmCode.setEditableOnInsert(true);
    colUmCode.setHeaderColumnName("umCodeReg02PUR02");
    colUmCode.setMaxCharacters(20);
    colMinQty.setDecimals(2);
    colMinQty.setGrouping(false);
    colMinQty.setColumnDuplicable(true);
    colMinQty.setColumnFilterable(true);
    colMinQty.setColumnSortable(true);
    colMinQty.setEditableOnEdit(true);
    colMinQty.setEditableOnInsert(true);
    colMinQty.setPreferredWidth(80);
    colMinQty.setColumnName("minPurchaseQtyPUR02");
    colMultipleQty.setGrouping(false);
    colMultipleQty.setColumnDuplicable(true);
    colMultipleQty.setColumnFilterable(true);
    colMultipleQty.setColumnSortable(true);
    colMultipleQty.setEditableOnEdit(true);
    colMultipleQty.setEditableOnInsert(true);
    colMultipleQty.setPreferredWidth(80);
    colMultipleQty.setColumnName("multipleQtyPUR02");
    subjectPanel.add(
        organizationPanel,
        new GridBagConstraints(
            0,
            1,
            1,
            1,
            1.0,
            1.0,
            GridBagConstraints.NORTHWEST,
            GridBagConstraints.BOTH,
            new Insets(0, 0, 0, 0),
            0,
            0));
    this.setTitle(ClientSettings.getInstance().getResources().getResource("supplier detail"));
    buttonsPanel.setLayout(flowLayout1);
    flowLayout1.setAlignment(FlowLayout.LEFT);
    insertButton.setText("insertButton1");
    editButton.setText("editButton1");
    saveButton.setEnabled(false);
    saveButton.setText("saveButton1");
    reloadButton.setText("reloadButton1");
    deleteButton.setText("deleteButton1");

    labelCompanyCode.setText("companyCodeSys01REG04");
    controlCompanyCode.setAttributeName("companyCodeSys01REG04");
    controlCompanyCode.setLinkLabel(labelCompanyCode);
    controlCompanyCode.setRequired(true);
    controlCompanyCode.setEnabledOnEdit(false);

    this.getContentPane().add(buttonsPanel, BorderLayout.NORTH);
    buttonsPanel.add(insertButton, null);
    buttonsPanel.add(editButton, null);
    buttonsPanel.add(saveButton, null);
    buttonsPanel.add(reloadButton, null);
    buttonsPanel.add(deleteButton, null);
    buttonsPanel.add(navigatorBar, null);
    //    tabbedPane.add(subjectPanel,   "generic data");
    this.getContentPane().add(tabbedPane, BorderLayout.CENTER);
    supplierPanel.add(
        labelCompanyCode,
        new GridBagConstraints(
            0,
            0,
            1,
            1,
            0.0,
            0.0,
            GridBagConstraints.WEST,
            GridBagConstraints.NONE,
            new Insets(5, 5, 5, 5),
            0,
            0));
    supplierPanel.add(
        controlCompanyCode,
        new GridBagConstraints(
            1,
            0,
            1,
            1,
            0.0,
            0.0,
            GridBagConstraints.WEST,
            GridBagConstraints.HORIZONTAL,
            new Insets(5, 5, 5, 5),
            0,
            0));

    //    tabbedPane.add(supplierPanel,    "supplierPanel");
    supplierPanel.add(
        labelSupplierCode,
        new GridBagConstraints(
            0,
            1,
            1,
            1,
            0.0,
            0.0,
            GridBagConstraints.WEST,
            GridBagConstraints.NONE,
            new Insets(0, 5, 5, 5),
            0,
            0));
    supplierPanel.add(
        controlSupplierCode,
        new GridBagConstraints(
            1,
            1,
            1,
            1,
            0.0,
            0.0,
            GridBagConstraints.WEST,
            GridBagConstraints.HORIZONTAL,
            new Insets(5, 5, 5, 5),
            0,
            0));
    supplierPanel.add(
        labelPay,
        new GridBagConstraints(
            0,
            2,
            1,
            1,
            0.0,
            0.0,
            GridBagConstraints.WEST,
            GridBagConstraints.NONE,
            new Insets(5, 5, 5, 5),
            0,
            0));
    supplierPanel.add(
        controlPayment,
        new GridBagConstraints(
            1,
            2,
            1,
            1,
            0.0,
            0.0,
            GridBagConstraints.WEST,
            GridBagConstraints.HORIZONTAL,
            new Insets(5, 5, 5, 5),
            40,
            0));
    supplierPanel.add(
        controlPayDescr,
        new GridBagConstraints(
            2,
            2,
            2,
            1,
            1.0,
            0.0,
            GridBagConstraints.WEST,
            GridBagConstraints.HORIZONTAL,
            new Insets(5, 5, 5, 5),
            0,
            0));
    supplierPanel.add(
        labelPricelist,
        new GridBagConstraints(
            0,
            3,
            1,
            1,
            0.0,
            0.0,
            GridBagConstraints.WEST,
            GridBagConstraints.NONE,
            new Insets(5, 5, 5, 5),
            0,
            0));
    supplierPanel.add(
        labelBank,
        new GridBagConstraints(
            0,
            4,
            1,
            1,
            0.0,
            0.0,
            GridBagConstraints.WEST,
            GridBagConstraints.NONE,
            new Insets(5, 5, 0, 5),
            0,
            0));
    supplierPanel.add(
        controlBank,
        new GridBagConstraints(
            1,
            4,
            1,
            1,
            0.0,
            0.0,
            GridBagConstraints.WEST,
            GridBagConstraints.HORIZONTAL,
            new Insets(5, 5, 5, 5),
            40,
            0));
    supplierPanel.add(
        controlBankDescr,
        new GridBagConstraints(
            2,
            4,
            2,
            3,
            1.0,
            1.0,
            GridBagConstraints.NORTHWEST,
            GridBagConstraints.HORIZONTAL,
            new Insets(5, 5, 0, 5),
            0,
            0));

    supplierPanel.add(
        labelDebit,
        new GridBagConstraints(
            0,
            5,
            1,
            1,
            0.0,
            0.0,
            GridBagConstraints.WEST,
            GridBagConstraints.HORIZONTAL,
            new Insets(5, 5, 5, 5),
            0,
            0));
    supplierPanel.add(
        labelPurchase,
        new GridBagConstraints(
            0,
            6,
            1,
            1,
            0.0,
            1.0,
            GridBagConstraints.WEST,
            GridBagConstraints.HORIZONTAL,
            new Insets(5, 5, 15, 5),
            0,
            0));
    supplierPanel.add(
        controlDebitsCode,
        new GridBagConstraints(
            1,
            5,
            1,
            1,
            0.0,
            0.0,
            GridBagConstraints.WEST,
            GridBagConstraints.HORIZONTAL,
            new Insets(5, 5, 5, 5),
            40,
            0));
    supplierPanel.add(
        controlDebitsDescr,
        new GridBagConstraints(
            2,
            5,
            2,
            1,
            0.0,
            0.0,
            GridBagConstraints.WEST,
            GridBagConstraints.HORIZONTAL,
            new Insets(5, 5, 0, 5),
            0,
            0));
    supplierPanel.add(
        controlCostsCode,
        new GridBagConstraints(
            1,
            6,
            1,
            1,
            0.0,
            0.0,
            GridBagConstraints.WEST,
            GridBagConstraints.NONE,
            new Insets(5, 5, 5, 5),
            40,
            0));
    supplierPanel.add(
        controlCostsDescr,
        new GridBagConstraints(
            2,
            6,
            2,
            3,
            1.0,
            1.0,
            GridBagConstraints.NORTHWEST,
            GridBagConstraints.HORIZONTAL,
            new Insets(5, 5, 0, 5),
            0,
            0));

    labelDebit.setText("debits account");
    labelPurchase.setText("purchase costs account");
    controlDebitsCode.setAttributeName("debitAccountCodeAcc02PUR01");
    controlDebitsDescr.setAttributeName("debitAccountDescrPUR01");
    controlCostsCode.setAttributeName("costsAccountCodeAcc02PUR01");
    controlCostsDescr.setAttributeName("costsAccountDescrPUR01");

    detailPanel.add(
        subjectPanel,
        new GridBagConstraints(
            0,
            0,
            1,
            1,
            1.0,
            1.0,
            GridBagConstraints.WEST,
            GridBagConstraints.BOTH,
            new Insets(5, 5, 5, 5),
            0,
            0));
    detailPanel.add(
        supplierPanel,
        new GridBagConstraints(
            0,
            1,
            1,
            1,
            1.0,
            0.0,
            GridBagConstraints.WEST,
            GridBagConstraints.HORIZONTAL,
            new Insets(5, 5, 5, 5),
            0,
            0));
    tabbedPane.add(detailPanel, "supplier data");

    tabbedPane.add(refPanel, "references");
    refPanel.add(referencesPanel, BorderLayout.CENTER);
    tabbedPane.add(hierarPanel, "hierarchies");
    hierarPanel.add(hierarchiesPanel, BorderLayout.CENTER);
    tabbedPane.add(treeGridItemsPanel, "supplierItems");
    treeGridItemsPanel.add(itemsSplitPane, BorderLayout.CENTER);
    itemsSplitPane.add(treePanel, JSplitPane.LEFT);
    itemsSplitPane.add(itemsPanel, JSplitPane.RIGHT);
    itemsPanel.add(itemButtonsPanel, BorderLayout.NORTH);
    itemsPanel.add(itemsGrid, BorderLayout.CENTER);
    itemsGrid.getColumnContainer().add(colItemCode, null);
    itemButtonsPanel.add(insertButton1, null);
    itemButtonsPanel.add(editButton1, null);
    itemButtonsPanel.add(saveButton1, null);
    itemButtonsPanel.add(reloadButton1, null);
    itemButtonsPanel.add(deleteButton1, null);
    itemButtonsPanel.add(exportButton1, null);
    itemButtonsPanel.add(navigatorBar1, null);
    itemButtonsPanel.add(impAllItemsButton, null);

    controlDebitsCode.setLinkLabel(labelDebit);
    controlDebitsCode.setMaxCharacters(20);
    controlDebitsCode.setRequired(true);
    controlDebitsDescr.setEnabledOnInsert(false);
    controlDebitsDescr.setEnabledOnEdit(false);
    controlCostsCode.setLinkLabel(labelPurchase);
    controlCostsCode.setMaxCharacters(20);
    controlCostsCode.setRequired(true);
    controlCostsDescr.setEnabledOnInsert(false);
    controlCostsDescr.setEnabledOnEdit(false);

    treeGridItemsPanel.add(itemHierarsPanel, BorderLayout.NORTH);
    itemHierarsPanel.add(
        labelHierar,
        new GridBagConstraints(
            0,
            0,
            1,
            1,
            0.0,
            0.0,
            GridBagConstraints.WEST,
            GridBagConstraints.NONE,
            new Insets(5, 5, 5, 0),
            0,
            0));
    itemHierarsPanel.add(
        controlHierarchy,
        new GridBagConstraints(
            1,
            0,
            1,
            1,
            1.0,
            0.0,
            GridBagConstraints.WEST,
            GridBagConstraints.NONE,
            new Insets(5, 5, 5, 5),
            100,
            0));
    tabbedPane.add(supplierPricelistPanel, "supplierPricelistPanel");
    itemsGrid.getColumnContainer().add(colItemDescr, null);
    itemsGrid.getColumnContainer().add(colSupplierItemCode, null);
    itemsGrid.getColumnContainer().add(colUmCode, null);
    itemsGrid.getColumnContainer().add(colMinQty, null);
    itemsGrid.getColumnContainer().add(colMultipleQty, null);

    tabbedPane.setTitleAt(
        0, ClientSettings.getInstance().getResources().getResource("supplier data"));
    tabbedPane.setTitleAt(1, ClientSettings.getInstance().getResources().getResource("references"));
    tabbedPane.setTitleAt(
        2, ClientSettings.getInstance().getResources().getResource("hierarchies"));
    tabbedPane.setTitleAt(
        3, ClientSettings.getInstance().getResources().getResource("supplierItems"));
    tabbedPane.setTitleAt(
        4, ClientSettings.getInstance().getResources().getResource("supplierPricelists"));
    itemsSplitPane.setDividerLocation(200);
  }