Completely changed the structure and switched to Eclipse Plugin.
[Mograsim.git] / net.mograsim.logic.ui / src / net / mograsim / logic / ui / LogicUIRenderer.java
index 4b451fc..7858a70 100644 (file)
@@ -22,6 +22,8 @@ public class LogicUIRenderer
 
        public void render(GeneralGC gc, Rectangle visibleRegion)
        {
+               gc.setAntialias(SWT.ON);
+               gc.setClipping(visibleRegion);
                gc.setLineWidth(.5);
                model.getWires().forEach(w ->
                {
@@ -43,7 +45,7 @@ public class LogicUIRenderer
                        if (DRAW_PINS)
                        {
                                gc.setBackground(gc.getDevice().getSystemColor(SWT.COLOR_DARK_CYAN));
-                               for (Pin p : component.getPins())
+                               for (Pin p : component.getPins().values())
                                {
                                        Point pos = p.getPos();
                                        gc.fillOval(pos.x - 1, pos.y - 1, 2, 2);