本文整理了Java中javax.swing.JTable.getShowHorizontalLines()
方法的一些代码示例,展示了JTable.getShowHorizontalLines()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。JTable.getShowHorizontalLines()
方法的具体详情如下:
包路径:javax.swing.JTable
类名称:JTable
方法名:getShowHorizontalLines
暂无
代码示例来源:origin: com.github.insubstantial/substance
private Rectangle getCellRectangleForRepaint(int row, int column) {
Rectangle rect = this.table.getCellRect(row, column, true);
if (!table.getShowHorizontalLines() && !table.getShowVerticalLines()) {
float extra = SubstanceSizeUtils
.getBorderStrokeWidth(SubstanceSizeUtils
.getComponentFontSize(table.getTableHeader()));
rect.x -= (int) extra;
rect.width += 2 * (int) extra;
rect.y -= (int) extra;
rect.height += 2 * (int) extra;
}
return rect;
}
代码示例来源:origin: org.java.net.substance/substance
private Rectangle getCellRectangleForRepaint(int row, int column) {
Rectangle rect = this.table.getCellRect(row, column, true);
if (!table.getShowHorizontalLines() && !table.getShowVerticalLines()) {
float extra = SubstanceSizeUtils
.getBorderStrokeWidth(SubstanceSizeUtils
.getComponentFontSize(table.getTableHeader()));
rect.x -= (int) extra;
rect.width += 2 * (int) extra;
rect.y -= (int) extra;
rect.height += 2 * (int) extra;
}
return rect;
}
代码示例来源:origin: uk.org.mygrid.taverna.scufl/scufl-ui
/**
* Paints the horizontal grid lines between rMin and rMax if
* {@link JTable#getShowHorizontalLines() getShowHorizontalLines}returns
* <code>true</code>.
*
* @param g
* the graphics context to draw onto
* @param rMin
* the first row to draw the grid around
* @param rMax
* the last row to draw the grid around
*/
private void paintGrid(Graphics g, int rMin, int rMax)
{
if (table.getShowHorizontalLines())
{
g.setColor(table.getGridColor());
int rowHeight = table.getRowHeight();
int tableWidth = g.getClipBounds().width;
int x = g.getClipBounds().x;
int y = rowHeight * rMin;
for (int row = rMin; row <= rMax; row++)
{
y += rowHeight;
g.drawLine(x, y - 1, tableWidth - 1, y - 1);
}
}
}
代码示例来源:origin: com.github.insubstantial/substance
/**
* Checks whether the table has animations.
*
* @return <code>true</code> if the table has animations, <code>false</code>
* otherwise.
*/
protected boolean _hasAnimations() {
// fix for defects 164 and 209 - selection
// and deletion are very slow on large tables.
int rowCount = this.table.getRowCount();
int colCount = this.table.getColumnCount();
if (rowCount * colCount >= 500)
return false;
if (this.table.getColumnSelectionAllowed()
&& !this.table.getRowSelectionAllowed()) {
if (!this.table.getShowHorizontalLines()
&& !this.table.getShowVerticalLines())
return rowCount <= 10;
return rowCount <= 25;
}
if (!this.table.getColumnSelectionAllowed()
&& this.table.getRowSelectionAllowed()) {
if (!this.table.getShowHorizontalLines()
&& !this.table.getShowVerticalLines())
return colCount <= 10;
return colCount <= 25;
}
return true;
}
代码示例来源:origin: org.java.net.substance/substance
/**
* Checks whether the table has animations.
*
* @return <code>true</code> if the table has animations, <code>false</code>
* otherwise.
*/
protected boolean _hasAnimations() {
// fix for defects 164 and 209 - selection
// and deletion are very slow on large tables.
int rowCount = this.table.getRowCount();
int colCount = this.table.getColumnCount();
if (rowCount * colCount >= 500)
return false;
if (this.table.getColumnSelectionAllowed()
&& !this.table.getRowSelectionAllowed()) {
if (!this.table.getShowHorizontalLines()
&& !this.table.getShowVerticalLines())
return rowCount <= 10;
return rowCount <= 25;
}
if (!this.table.getColumnSelectionAllowed()
&& this.table.getRowSelectionAllowed()) {
if (!this.table.getShowHorizontalLines()
&& !this.table.getShowVerticalLines())
return colCount <= 10;
return colCount <= 25;
}
return true;
}
代码示例来源:origin: GoldenGnu/jeveassets
Rectangle damagedArea = minCell.union(maxCell);
if (table.getShowHorizontalLines()) {
int tableWidth = damagedArea.x + damagedArea.width;
int y = damagedArea.y;
代码示例来源:origin: net.sf.squirrel-sql.thirdparty-non-maven/toniclf
Rectangle damagedArea=minCell.union(maxCell);
if(table.getShowHorizontalLines())
代码示例来源:origin: GoldenGnu/jeveassets
if (table.getShowHorizontalLines()) {
g.setColor(table.getGridColor());
Rectangle rcr = table.getCellRect(row, draggedColumnIndex, true);
代码示例来源:origin: org.tentackle/tentackle-swing
if (table.getShowHorizontalLines()) {
g.setColor(table.getGridColor());
Rectangle rcr = table.getCellRect(row, draggedColumnIndex, true);
代码示例来源:origin: org.java.net.substance/substance
if (this.table.getShowHorizontalLines()) {
g.setColor(this.table.getGridColor());
Rectangle rcr = this.table.getCellRect(row, draggedColumnIndex,
代码示例来源:origin: com.github.insubstantial/substance
if (this.table.getShowHorizontalLines()) {
g.setColor(this.table.getGridColor());
Rectangle rcr = this.table.getCellRect(row, draggedColumnIndex,
代码示例来源:origin: net.sf.squirrel-sql.thirdparty-non-maven/toniclf
if(table.getShowHorizontalLines())
代码示例来源:origin: uk.org.mygrid.taverna.scufl/scufl-ui
if (table.getShowHorizontalLines())
代码示例来源:origin: org.java.net.substance/substance
RenderingHints.VALUE_ANTIALIAS_ON);
if (this.table.getShowHorizontalLines()) {
int tableWidth = damagedArea.x + damagedArea.width;
int y = damagedArea.y;
代码示例来源:origin: com.github.insubstantial/substance
true));
if (!table.getShowHorizontalLines()
&& !table.getShowVerticalLines()) {
float extra = SubstanceSizeUtils
代码示例来源:origin: org.java.net.substance/substance
i, true));
if (!table.getShowHorizontalLines()
&& !table.getShowVerticalLines()) {
float extra = SubstanceSizeUtils
代码示例来源:origin: com.github.insubstantial/substance
i, true));
if (!table.getShowHorizontalLines()
&& !table.getShowVerticalLines()) {
float extra = SubstanceSizeUtils
代码示例来源:origin: org.java.net.substance/substance
true));
if (!table.getShowHorizontalLines()
&& !table.getShowVerticalLines()) {
float extra = SubstanceSizeUtils
代码示例来源:origin: khuxtable/seaglass
SynthGraphicsUtils synthG = context.getStyle().getGraphicsUtils(context);
if (table.getShowHorizontalLines()) {
int tableWidth = damagedArea.x + damagedArea.width;
int y = damagedArea.y;
代码示例来源:origin: khuxtable/seaglass
if (table.getShowHorizontalLines()) {
g.setColor(table.getGridColor());
Rectangle rcr = table.getCellRect(row, draggedColumnIndex, true);
内容来源于网络,如有侵权,请联系作者删除!