Skip to Main Content

Java SE (Java Platform, Standard Edition)

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

tableView css cell border

CelerJul 3 2012 — edited Jul 3 2012
I have a tableView when running it on windows I don't see a cell border, but on mac I do

I have the following css
.table-view {
	-fx-text-fill: #fffafa;
    -fx-border-color: #414042;
    -fx-border-weight: 2px;
}

.table-view:filled:selected:focused {
	-fx-background-color: yellow;
    -fx-border-color: #f8c27f;
    -fx-border-weight: 0px;
}

.table-view:empty {
    -fx-background-color: white;
}

.table-row-cell {
	-fx-text-fill: white;
    -fx-background-color: white;
}

.table-row-cell:odd {
    -fx-background-color: #F1F1F1;
}

.table-row-cell .table-cell {
    -fx-background-color: transparent;
    -fx-border-width: 1px;
    -fx-border-color: black;
    -fx-padding: 1 1 1 1;
}

/* .table-row-cell:even { */
/* } */

.table-view .column-header .label {
	-fx-text-fill: #f1f3f2;
/* 	-fx-font: 8pt "Century Gothic"; */
}

/** this is for the the last cell in the column-header so should essentially be the same styling as column-header* */
.table-view .column-header-background {
	-fx-background-color: linear (0px,0px) to (0px,8px) stops (100%, rgb(127,127,127)) (10%, rgb(89,89,89));
/* 	-fx-font: 8pt "Century Gothic"; */
/* 	-fx-text-fill: #f1f3f2; */
/* 	-fx-font-weight: bold; */
	-fx-border-color: #F1F1F1;
	-fx-border-weight: 1px; 
}

.table-view .indexed-cell .cell: selected {
	-fx-text-fill: #F2F2F2;
	-fx-background-color: #90A8BF;
}

.table-row-cell:empty {
    -fx-background-color: transparent;
}
 
.table-row-cell:empty .table-cell {
    -fx-background-color: transparent;
}

.table-view .cell-selection {
/* 	 -fx-border-color: red; */
    -fx-border-weight: 0px;
}

.table-view:focused { 
    -fx-border-color: #414042;
    -fx-border-weight: 2px;
}
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jul 31 2012
Added on Jul 3 2012
1 comment
2,815 views