Merge in DESIGN/design from ~ZONGYU.WANG/design:newui to newui * commit '8013627bcc22ae4658c3c96faa845a99a4ea5708': REPORT-127437 fix:setui 调整 REPORT-127437 fix:setui 调整 REPORT-127437 fix:文件夹翻新,边框调整,部分图标替换,提示弹框布局样式等 REPORT-127437 fix: table UI 调整newui
@ -0,0 +1,23 @@ |
|||||||
|
package com.fr.design.gui.icontainer; |
||||||
|
|
||||||
|
import com.fr.design.gui.iscrollbar.UIVerticalScrollBar; |
||||||
|
|
||||||
|
import javax.swing.JScrollBar; |
||||||
|
import javax.swing.JTable; |
||||||
|
import java.awt.Component; |
||||||
|
|
||||||
|
/** |
||||||
|
* FineUITable 定义垂直滚动条 {@link UIVerticalScrollBar} |
||||||
|
* @author lemon |
||||||
|
* @since |
||||||
|
* Created on |
||||||
|
*/ |
||||||
|
public class UITableScrollPane extends UIScrollPane { |
||||||
|
|
||||||
|
public UITableScrollPane(Component c) { |
||||||
|
super(c); |
||||||
|
if (c instanceof JTable) { |
||||||
|
setVerticalScrollBar(new UIVerticalScrollBar((JTable) c, JScrollBar.VERTICAL)); |
||||||
|
} |
||||||
|
} |
||||||
|
} |
@ -0,0 +1,31 @@ |
|||||||
|
package com.fr.design.gui.iscrollbar; |
||||||
|
|
||||||
|
import javax.swing.JTable; |
||||||
|
|
||||||
|
/** |
||||||
|
* jtable 垂直滚动条 |
||||||
|
* |
||||||
|
* @author lemon |
||||||
|
* @since |
||||||
|
* Created on |
||||||
|
*/ |
||||||
|
public class UIVerticalScrollBar extends UIScrollBar { |
||||||
|
private static final String UI_CLASS_ID = "TableVerticalBarUI"; |
||||||
|
private static final long serialVersionUID = 1L; |
||||||
|
|
||||||
|
public JTable table; |
||||||
|
|
||||||
|
public UIVerticalScrollBar(JTable table, int orientation) { |
||||||
|
super(orientation); |
||||||
|
this.table = table; |
||||||
|
} |
||||||
|
|
||||||
|
public String getUIClassID() { |
||||||
|
return UI_CLASS_ID; |
||||||
|
} |
||||||
|
|
||||||
|
public JTable getTable() { |
||||||
|
return this.table; |
||||||
|
} |
||||||
|
|
||||||
|
} |
@ -0,0 +1,38 @@ |
|||||||
|
package com.fr.design.gui.itable; |
||||||
|
|
||||||
|
import javax.swing.JTable; |
||||||
|
import javax.swing.table.AbstractTableModel; |
||||||
|
import javax.swing.table.JTableHeader; |
||||||
|
import javax.swing.table.TableColumnModel; |
||||||
|
|
||||||
|
/** |
||||||
|
* 应用 TableHeaderUI 样式的 table |
||||||
|
* @author lemon |
||||||
|
* @since |
||||||
|
* Created on |
||||||
|
*/ |
||||||
|
public class FineUITable extends JTable { |
||||||
|
|
||||||
|
|
||||||
|
public FineUITable(AbstractTableModel tableModel){ |
||||||
|
super(tableModel); |
||||||
|
setTableHeader(new FineUITableHeader(tableHeader.getColumnModel())); |
||||||
|
} |
||||||
|
|
||||||
|
/** |
||||||
|
* tableHeader |
||||||
|
*/ |
||||||
|
public static class FineUITableHeader extends JTableHeader { |
||||||
|
private static final String UI_CLASS_ID = "TableHeaderUI"; |
||||||
|
|
||||||
|
|
||||||
|
public FineUITableHeader(TableColumnModel columnModel){ |
||||||
|
super(columnModel); |
||||||
|
} |
||||||
|
|
||||||
|
@Override |
||||||
|
public String getUIClassID() { |
||||||
|
return UI_CLASS_ID; |
||||||
|
} |
||||||
|
} |
||||||
|
} |
@ -1,14 +1,16 @@ |
|||||||
package com.fr.design.gui.itable; |
package com.fr.design.gui.itable; |
||||||
|
|
||||||
import com.fine.theme.light.ui.FineTableHeaderUI; |
/** |
||||||
|
* SortableJTable |
||||||
|
* @author lemon |
||||||
|
* @since |
||||||
|
* Created on |
||||||
|
*/ |
||||||
|
public class SortableJTable extends FineUITable { |
||||||
|
|
||||||
import javax.swing.JTable; |
|
||||||
|
|
||||||
public class SortableJTable extends JTable{ |
|
||||||
public SortableJTable(TableSorter tableModel){ |
public SortableJTable(TableSorter tableModel){ |
||||||
super(tableModel); |
super(tableModel); |
||||||
tableModel.setTableHeader(getTableHeader()); |
tableModel.setTableHeader(getTableHeader()); |
||||||
setShowGrid(true); |
setShowGrid(true); |
||||||
getTableHeader().setUI(new FineTableHeaderUI()); |
|
||||||
} |
} |
||||||
} |
} |
After Width: | Height: | Size: 379 B |
After Width: | Height: | Size: 553 B |
After Width: | Height: | Size: 567 B |
After Width: | Height: | Size: 726 B |
After Width: | Height: | Size: 441 B |
After Width: | Height: | Size: 618 B |
After Width: | Height: | Size: 541 B |
After Width: | Height: | Size: 380 B |
After Width: | Height: | Size: 1.0 KiB |
After Width: | Height: | Size: 958 B |
After Width: | Height: | Size: 552 B |
After Width: | Height: | Size: 541 B |
After Width: | Height: | Size: 715 B |
After Width: | Height: | Size: 888 B |
After Width: | Height: | Size: 729 B |
After Width: | Height: | Size: 461 B |
After Width: | Height: | Size: 851 B |
After Width: | Height: | Size: 920 B |
After Width: | Height: | Size: 858 B |
After Width: | Height: | Size: 654 B |
After Width: | Height: | Size: 605 B |
After Width: | Height: | Size: 826 B |
After Width: | Height: | Size: 1.0 KiB |
After Width: | Height: | Size: 1.0 KiB |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 1.2 KiB |