X-Git-Url: https://mograsim.net/gitweb/?a=blobdiff_plain;f=net.mograsim.logic.ui%2Fsrc%2Fnet%2Fmograsim%2Flogic%2Fui%2FLogicUICanvas.java;h=8e01a1625e9dc42cdffc7d12652099950f5a2cba;hb=ec645d5910fcffae8992ed66abe98ac20b03ac6d;hp=08a40a452e1762edd8ec7829f3321a821f133349;hpb=a0f4b1a2ee3ce0391decb882aa14fa536d5b3a45;p=Mograsim.git diff --git a/net.mograsim.logic.ui/src/net/mograsim/logic/ui/LogicUICanvas.java b/net.mograsim.logic.ui/src/net/mograsim/logic/ui/LogicUICanvas.java index 08a40a45..8e01a162 100644 --- a/net.mograsim.logic.ui/src/net/mograsim/logic/ui/LogicUICanvas.java +++ b/net.mograsim.logic.ui/src/net/mograsim/logic/ui/LogicUICanvas.java @@ -100,7 +100,7 @@ public class LogicUICanvas extends ZoomableCanvas radioBit.setText("Single bit"); Button radioBitVector = new Button(radioGroup, SWT.RADIO); radioBitVector.setText("Bitvector"); - new Label(debugShell, SWT.NONE).setText("Value string representation: "); + new Label(debugShell, SWT.NONE).setText("Value string representation: \n(Bit vectors: MSBit...LSBit)"); Text valueText = new Text(debugShell, SWT.SINGLE | SWT.LEAD | SWT.BORDER); valueText.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, false)); Button send = new Button(debugShell, SWT.PUSH); @@ -121,7 +121,7 @@ public class LogicUICanvas extends ZoomableCanvas if (radioBit.getSelection()) value = Bit.parse(valueString); else if (radioBitVector.getSelection()) - value = BitVector.parse(valueString); + value = BitVector.parse(new StringBuilder(valueString).reverse().toString()); else throw new RuntimeException("No value type selected"); target.setHighLevelState(stateIDText.getText(), value); @@ -138,7 +138,8 @@ public class LogicUICanvas extends ZoomableCanvas { if (componentSelector.getSelectionIndex() >= componentsByItemIndex.size()) throw new RuntimeException("No valid component selected"); - output.setText("Success! Value: \r\n" + componentsByItemIndex.get(componentSelector.getSelectionIndex()).getHighLevelState(stateIDText.getText())); + output.setText("Success! Value: \r\n" + + componentsByItemIndex.get(componentSelector.getSelectionIndex()).getHighLevelState(stateIDText.getText())); } catch (Exception x) {