proj.getSimulator().drawStepPoints(ptContext);
gScaled.dispose();
}
private void drawWithUserState(Graphics base, Graphics g, Project proj) {
Circuit circ = proj.getCurrentCircuit();
Selection sel = proj.getSelection();
Set<Component> hidden;
Tool dragTool = canvas.getDragTool();
if (dragTool == null) {
hidden = NO_COMPONENTS;
} else {
hidden = dragTool.getHiddenComponents(canvas);
if (hidden == null) hidden = NO_COMPONENTS;
}
// draw halo around component whose attributes we are viewing
boolean showHalo = AppPreferences.ATTRIBUTE_HALO.getBoolean();
if (showHalo && haloedComponent != null && haloedCircuit == circ
&& !hidden.contains(haloedComponent)) {
GraphicsUtil.switchToWidth(g, 3);
g.setColor(Canvas.HALO_COLOR);
Bounds bds = haloedComponent.getBounds(g).expand(5);
int w = bds.getWidth();
int h = bds.getHeight();
double a = Canvas.SQRT_2 * w;
double b = Canvas.SQRT_2 * h;
g.drawOval((int) Math.round(bds.getX() + w/2.0 - a/2.0),
(int) Math.round(bds.getY() + h/2.0 - b/2.0),
(int) Math.round(a), (int) Math.round(b));
GraphicsUtil.switchToWidth(g, 1);
g.setColor(Color.BLACK);
}
// draw circuit and selection
CircuitState circState = proj.getCircuitState();
boolean printerView = AppPreferences.PRINTER_VIEW.getBoolean();
ComponentDrawContext context = new ComponentDrawContext(canvas,
circ, circState, base, g, printerView);
context.setHighlightedWires(highlightedWires);
circ.draw(context, hidden);
sel.draw(context, hidden);
// draw tool
Tool tool = dragTool != null ? dragTool : proj.getTool();
if (tool != null && !canvas.isPopupMenuUp()) {