JTextPane Won't Resize
Code:
public static void main(String args[]){ |
I had to dig for this but here you go:
http://216.239.37.104/search?q=cache...hl=en&ie=UTF-8 |
If you leave out mainFrame.pack(), so it doesn't optimize the size of everything and set the mainFrame.setSize(800,600) it should have the effect you want.
|
yeah but my textpane doesnt resize when the window resizes i want it to fill a panel
|
use a scroll pane as it's container
Code:
... |
or give the frame's contentPane a 1x1 GridLayout if you don't want it to scroll...
Code:
mainFrame.getContentPane().setLayout(new GridLayout(1,1)); Code:
B. |
All times are GMT -5. The time now is 02:16 PM. |