代码如下:
----------------------------
public class Test extends JFrame
{
JTabbedPane jTabbedPane1 = new JTabbedPane(JTabbedPane.LEFT);
public Test()
{
try
{
jbInit();
} catch (Exception exception)
{
exception.printStackTrace();
}
} private void jbInit() throws Exception
{
WebBrowser browser = new WebBrowser();
browser.setURL(new java.net.URL("http://www.google.cn/"));
jTabbedPane1.addTab("1111111111111111111111",browser);
this.getContentPane().add(jTabbedPane1);
this.pack();
} public static void main(String args[])
{
Test t = new Test();
t.setSize(500, 500);
t.setVisible(true);
}
}其中的"1111111111111111111111" 写的越长空白就越多. 请问如何去掉空白???
----------------------------
public class Test extends JFrame
{
JTabbedPane jTabbedPane1 = new JTabbedPane(JTabbedPane.LEFT);
public Test()
{
try
{
jbInit();
} catch (Exception exception)
{
exception.printStackTrace();
}
} private void jbInit() throws Exception
{
WebBrowser browser = new WebBrowser();
browser.setURL(new java.net.URL("http://www.google.cn/"));
jTabbedPane1.addTab("1111111111111111111111",browser);
this.getContentPane().add(jTabbedPane1);
this.pack();
} public static void main(String args[])
{
Test t = new Test();
t.setSize(500, 500);
t.setVisible(true);
}
}其中的"1111111111111111111111" 写的越长空白就越多. 请问如何去掉空白???
如果用我刚才的办法会出现滚动条被覆盖的bug
webbrowser有自己的滚动条,但和轻量级组建搭配(JTabbedPane)会出没用的长条,
webbrowser和JTabbedPane组合的问题你现在会解决了吗?我现在急需找到答案。谢谢。
也可以发到邮箱( [email protected])