public AddFriendPanel() {
    this.setLayout(new GridBagLayout());
    GridBagConstraints constraints = new GridBagConstraints();

    text = new JLabel(TEXT);
    constraints.gridx = 0;
    constraints.gridy = 0;
    constraints.gridwidth = 1;
    this.add(text, constraints);

    inputText = new JTextField(10);
    constraints.gridx = 1;
    this.add(inputText, constraints);
  }