mirror of
https://github.com/bancika/diy-layout-creator
synced 2026-11-11 01:32:08 +10:00
photo diode minor improvement
This commit is contained in:
@@ -33,12 +33,12 @@ import org.diylc.core.annotations.ComponentDescriptor;
|
||||
import org.diylc.core.annotations.KeywordPolicy;
|
||||
|
||||
@ComponentDescriptor(
|
||||
name = "PhotoDiode",
|
||||
name = "Photo Diode",
|
||||
author = "N9XYP",
|
||||
category = "Schematic Symbols",
|
||||
creationMethod = CreationMethod.POINT_BY_POINT,
|
||||
instanceNamePrefix = "D",
|
||||
description = "PhotoDiode schematic symbol",
|
||||
description = "Photo Diode schematic symbol",
|
||||
zOrder = IDIYComponent.COMPONENT,
|
||||
keywordPolicy = KeywordPolicy.SHOW_TAG,
|
||||
keywordTag = "Schematic",
|
||||
@@ -69,7 +69,7 @@ public class PhotoDiodeSymbol extends DiodeSymbol {
|
||||
//upper arrow
|
||||
x2 = (int) (3 * d / 2 + Math.cos(Math.PI / 4) * arrowLength);
|
||||
y2 = (int) (width + Math.sin(Math.PI / 4) * arrowLength);
|
||||
g2d.drawLine(3 * d / 2, (int) width, x2 - 2, y2 - 2);
|
||||
g2d.drawLine(3 * d / 2, (int) width, x2, y2);
|
||||
g2d.fillPolygon(new Polygon(new int[] {3 * d / 2, (int) ((3 * d / 2) + arrowSize), 3 * d / 2}, new int[] {(int) width, (int) width, (int) (width + arrowSize)},3));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user