views:

110

answers:

1

Goodevening

how can have a JTextArea like in netbeans (see the pic)

alt text

my code of the JTextArea:

   JTextArea  infoArea = new JTextArea(10,10);
   infoArea.setLineWrap(true);
   infoArea.setFont(police);
   infoArea.setForeground(Color.YELLOW);
   infoArea.setBackground(Color.BLACK);
   infoArea.setEditable(false);

   JScrollPane scroll = new JScrollPane(infoArea);
   scroll.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_NEVER);
   scroll.setBorder(BorderFactory.createEmptyBorder(5, 0, 10, 0));
   scroll.setPreferredSize(new Dimension(sousFrame.getWidth(),90));
   scroll.setFont( new Font("Arial", Font.BOLD, 13));
   scroll.setBorder(BorderFactory.createTitledBorder("Output"));

thank you

+1  A: 

I'm not sure what NetBeans uses, but we used flexdock at my last company to create dockable windows in a Java Swing application (assuming this is what you meant by "retractable").

Bill the Lizard
yes like in the picture
tuxou
@tuxou: Okay, then a docking framework is what you need. Flexdock is just one of many that you can find online (many of them for free).
Bill the Lizard
the task List in flexdock
tuxou