Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

JTabbedPane Problem  RSS feed

 
Maulin Vasavada
Ranch Hand
Posts: 1873
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,
can anybody guide me here.
i am having JTabbedPane having three tabs. each of the pane has a panel with gridbaglayout. when i load the frame having this pane it garbles display initially. but when i click 2-3 times on the tabs and move around it becomes okay.
this doesnt happen if i use CardLayout explicitly using buttons as tabs.
any idea.
i am using VisualCafe SE 4.0.
regards
maulin
 
Manfred Leonhardt
Ranch Hand
Posts: 1492
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Maulin,
This sounds like a classic case of mixing heavy weight objects (AWT) with light weight objects (Swing). Make sure you don't mix because things get messed up! Either use all AWT (with CardLayout) or all Swing (with JTabbedPane) that will avoid any messed up GUIs.
Regards,
Manfred.
 
Maulin Vasavada
Ranch Hand
Posts: 1873
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi manfred,
sorry to thank you so late but i's busy in final exams. yes. you seem right. i am mixing up AWT and SWing components.
i will try to remove that and see if it works properly.
thanks a lot.
maulin.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!