JTextPane focus problem
Hi.. I'm really confused why I can't make my JTextPane focused :(
I have a jframe with JTabbedPane inside it, inside the JTabbedPane is a JPanel, inside the JPanel is JTextPane included with JScrollpane.
I want to make the JTextPane focused when the window opened, now it focused on the JTabbedPane.
I've tried these
I even tried to turn off the focusable of JTabbedPane to false.
Still I can't make the JTextPane focused.
I also already tried to move the code above before the JFrame.setvisibile(true)
Anyone can help? :(
ok I found the solution, I must pack the the jframe to make the request focus working..