文件名称:java用画图做IconDemo.rar
文件大小:82KB
文件格式:RAR
更新时间:2023-05-18 01:07:58
java
java用画图做IconDemo,主要代码: @Override public void paintIcon(Component c, Graphics g, int x, int y) { Graphics2D g2d = (Graphics2D) g; g2d.setRenderingHint(RenderingHints.KEY_ANTIALIASING,RenderingHints.VALUE_ANTIALIAS_ON); BasicStroke stroke = new BasicStroke(3); g2d.setStroke(stroke); g2d.drawRoundRect(3, 3, 30 - 6, 30 - 6, 5, 5); stroke = new BasicStroke(1); g2d.setStroke(stroke); g2d.fillOval(8, 9, 2, 2); g2d.fillOval(8, 15, 2, 2); g2d.fillOval(8, 21, 2, 2); stroke = new BasicStroke(2); g2d.drawLine(12, 10, 21, 10); g2d.drawLine(12, 16, 21, 16); g2d.drawLine(12, 22, 21, 22); }
【文件预览】:
Demo_App
----.project(384B)
----bin()
--------CheckBoxEx$1.class(2KB)
--------TextFieldEx$1.class(1KB)
--------BtnEx$3.class(2KB)
--------Btn2dEx$3.class(3KB)
--------JTreeEdit$2.class(1KB)
--------BtnEx.class(2KB)
--------CheckBoxEx$3.class(2KB)
--------JTreeSelect.class(2KB)
--------IconEx$1.class(2KB)
--------MyButtonEditor$1.class(664B)
--------DiyTreePanel$3.class(2KB)
--------BtnEx$5.class(715B)
--------CheckBoxEx$4.class(2KB)
--------Btn2dEx$4.class(1KB)
--------Btn2dEx$1.class(3KB)
--------BtnEx$4.class(1KB)
--------DiyTree.class(2KB)
--------CheckBoxEx$2.class(2KB)
--------DiyTreePanel$5.class(2KB)
--------JTreeCheckBox.class(546B)
--------DiyTreePanel$1.class(1KB)
--------JTreeDemo.class(2KB)
--------TextFieldEx.class(1KB)
--------IconEx$2.class(2KB)
--------Btn2dEx$2.class(3KB)
--------BtnEx$2.class(2KB)
--------IconEx.class(1KB)
--------JTreeEdit.class(3KB)
--------BtnUi.class(2KB)
--------TableBtn$1.class(2KB)
--------JTreeSelect$1.class(2KB)
--------DiyTreeNode.class(3KB)
--------MyButtonEditor.class(2KB)
--------JTreeEdit$1.class(2KB)
--------BtnEx$1.class(2KB)
--------DiyTreePanel$2.class(894B)
--------DiyTreePanel.class(10KB)
--------TableBtn.class(2KB)
--------ImageCheckbox.class(3KB)
--------JTreeCustom.class(3KB)
--------Btn2dEx.class(3KB)
--------MyButtonRender.class(1KB)
--------Btn2dEx$5.class(727B)
--------JTreeEdit$3.class(1KB)
--------TextFieldBorder.class(2KB)
--------DiyTreePanel$4.class(2KB)
--------CheckBoxEx.class(2KB)
--------MainClass.class(397B)
--------Btn2D.class(1023B)
----.settings()
--------org.eclipse.jdt.core.prefs(598B)
----src()
--------DiyTree.java(2KB)
--------TableBtn.java(3KB)
--------MainClass.java(719B)
--------ImageCheckbox.java(4KB)
--------BtnUi.java(1KB)
--------TextFieldBorder.java(1KB)
--------MyButtonEditor.java(3KB)
--------BtnEx.java(4KB)
--------MyButtonRender.java(1KB)
--------Btn2dEx.java(7KB)
--------DiyTreePanel.java(13KB)
--------JTreeSelect.java(2KB)
--------CheckBoxEx.java(5KB)
--------TextFieldEx.java(2KB)
--------JTreeCustom.java(3KB)
--------IconEx.java(3KB)
--------JTreeCheckBox.java(328B)
--------JTreeDemo.java(2KB)
--------DiyTreeNode.java(2KB)
--------Btn2D.java(593B)
--------JTreeEdit.java(5KB)
----images()
--------imagecb()
----.classpath(301B)