fixed point visibility on curved trace

added option to hide color bands on the resistor
This commit is contained in:
bancika
2011-01-28 17:48:46 +00:00
parent 11b7756a59
commit 7de327b9bd
7 changed files with 38 additions and 12 deletions
@@ -38,11 +38,6 @@ public class CurvedTrace extends AbstractCurvedComponent<Void> {
g2d.draw(curve);
}
@Override
public VisibilityPolicy getControlPointVisibilityPolicy(int index) {
return VisibilityPolicy.NEVER;
}
@EditableProperty(name = "Width")
public Size getSize() {
return size;
@@ -91,6 +91,9 @@ public class Resistor extends AbstractLeadedComponent<Resistance> {
@Override
protected void decorateComponentBody(Graphics2D g2d) {
// int width = getWidth().convertToPixels();
if (colorCode == ResistorColorCode.NONE) {
return;
}
int height = getClosestOdd(getHeight().convertToPixels());
Color[] bands = value.getColorCode(colorCode);
int x = 4;