javaswing 带滚动条文本域边框问题 10

importjava.awt.Color;importjava.awt.Point;importjavax.swing.JFrame;importjavax.swing.... import java.awt.Color;
import java.awt.Point;

import javax.swing.JFrame;
import javax.swing.JLabel;
import javax.swing.JPanel;
import javax.swing.JScrollPane;
import javax.swing.JTextArea;
import javax.swing.UIManager;

//系统皮肤下滚动条外面出现边框
public class sco_area extends JFrame{
private JPanel areapanel ;

static {
try {
UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
} catch (Exception e) {
e.printStackTrace();
}
}

public sco_area(){
setTitle("滚动条例子");
setBounds(200, 200, 330, 300);
setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
setLayout(null);
areaPanelLayout();
add(areapanel);
setBackground(Color.orange);
setVisible(true);

}

public void areaPanelLayout(){
areapanel = new JPanel();
areapanel.setLayout(null);
areapanel.setBounds(0, 0, 330 , 300);
areapanel.setBackground(Color.blue);
JLabel hislabel = new JLabel("历 史");

JPanel hispanel = new JPanel();
hispanel.setBounds(70, 50, 200, 85);
hispanel.setOpaque(false);
hispanel.setLayout(null);
hispanel.setBackground(Color.black);
final JTextArea hisarea = new JTextArea();
hisarea.setLineWrap(true);
JScrollPane areasco = new JScrollPane(hisarea);
hisarea.setBackground(Color.orange);
areasco.getViewport().setViewPosition(new Point(0,0));//到顶
areasco.setBounds(0, 0, 200, 85);
hispanel.add(areasco);
areapanel.add(hispanel);

}
public static void main(String[] args) {
new sco_area();
}
}
要怎么样设置才能去掉文本域旁边的白色边条呢?
展开
 我来答
flyingFish211
2011-08-19 · TA获得超过2.1万个赞
知道大有可为答主
回答量:1.5万
采纳率:50%
帮助的人:1.2亿
展开全部
JDK 1.5 + IBM Ration Application devloper下面也没看到你的边框。。
已赞过 已踩过<
你对这个回答的评价是?
评论 收起
杜忆楣03D
2011-08-19 · TA获得超过458个赞
知道小有建树答主
回答量:364
采纳率:0%
帮助的人:401万
展开全部
很好奇,我在netbeans里面运行没有出现白色的边条,不知道你用什么软件开发的
已赞过 已踩过<
你对这个回答的评价是?
评论 收起
收起 1条折叠回答
推荐律师服务: 若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询

为你推荐:

下载百度知道APP,抢鲜体验
使用百度知道APP,立即抢鲜体验。你的手机镜头里或许有别人想知道的答案。
扫描二维码下载
×

类别

我们会通过消息、邮箱等方式尽快将举报结果通知您。

说明

0/200

提交
取消

辅 助

模 式