So is there any way to remove the gray area behind the tab(s):
我尝试过用 CSS 来做到这一点,但没有找到方法。
要设置 tabpane 标题的背景颜色,请在 CSS 文件中写入:
.tab-pane .tab-header-area .tab-header-background {
-fx-background-color: yellow;
}
要删除边框,请写入:
.tab-pane .tab-header-area .tab-header-background {
-fx-effect: null;
}
要完全删除标题,请将不透明度设置为 0:
.tab-pane .tab-header-area .tab-header-background {
-fx-opacity: 0;
}
有关样式类选项卡窗格的更多信息,您可以在这里找到:
http://docs.oracle.com/javafx/2/api/javafx/scene/doc-files/cssref.html#tabpane http://docs.oracle.com/javafx/2/api/javafx/scene/doc-files/cssref.html#tabpane
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)