X-Git-Url: https://mograsim.net/gitweb/?a=blobdiff_plain;f=net.mograsim.logic.ui%2Fsrc%2Fnet%2Fmograsim%2Flogic%2Fui%2Fmodel%2Fcomponents%2FGUIBitDisplay.java;h=82399c130b9a0742c21d2632c40569831150ce71;hb=7aa6eab72deba89dbc22ae9c90ffb5df53f9d496;hp=fd2f736c50cb175651810fc0ec0702c84dc37b15;hpb=9c142c9ad59d2af070ebb6495b1ca48242da62d8;p=Mograsim.git diff --git a/net.mograsim.logic.ui/src/net/mograsim/logic/ui/model/components/GUIBitDisplay.java b/net.mograsim.logic.ui/src/net/mograsim/logic/ui/model/components/GUIBitDisplay.java index fd2f736c..82399c13 100644 --- a/net.mograsim.logic.ui/src/net/mograsim/logic/ui/model/components/GUIBitDisplay.java +++ b/net.mograsim.logic.ui/src/net/mograsim/logic/ui/model/components/GUIBitDisplay.java @@ -28,7 +28,7 @@ public class GUIBitDisplay extends GUIComponent logicObs = (i) -> requestRedraw(); setSize(width, height); - addPin(this.inputPin = new Pin(this, 1, 0, height / 2)); + addPin(this.inputPin = new Pin(this, "", 1, 0, height / 2)); } @Override @@ -38,7 +38,7 @@ public class GUIBitDisplay extends GUIComponent double posY = getBounds().y; // TODO maybe draw switch state too? - gc.drawRectangle(posX, posY, width, height); + gc.drawRectangle(getBounds()); String label = bitDisplay == null ? BitVectorFormatter.formatAsString(null) : BitVectorFormatter.formatAsString(bitDisplay.getDisplayedValue()); Font oldFont = gc.getFont();