projects
/
Mograsim.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
9c142c9
)
Cleanups in bounding box rendering
author
Daniel Kirschten
<daniel.kirschten@gmx.de>
Mon, 3 Jun 2019 20:11:12 +0000
(22:11 +0200)
committer
Daniel Kirschten
<daniel.kirschten@gmx.de>
Mon, 3 Jun 2019 20:11:12 +0000
(22:11 +0200)
net.mograsim.logic.ui/src/net/mograsim/logic/ui/model/components/Am2901NANDBased.java
patch
|
blob
|
history
net.mograsim.logic.ui/src/net/mograsim/logic/ui/model/components/GUIBitDisplay.java
patch
|
blob
|
history
net.mograsim.logic.ui/src/net/mograsim/logic/ui/model/components/GUIManualSwitch.java
patch
|
blob
|
history
diff --git
a/net.mograsim.logic.ui/src/net/mograsim/logic/ui/model/components/Am2901NANDBased.java
b/net.mograsim.logic.ui/src/net/mograsim/logic/ui/model/components/Am2901NANDBased.java
index
d63b41d
..
4035795
100644
(file)
--- a/
net.mograsim.logic.ui/src/net/mograsim/logic/ui/model/components/Am2901NANDBased.java
+++ b/
net.mograsim.logic.ui/src/net/mograsim/logic/ui/model/components/Am2901NANDBased.java
@@
-35,10
+35,10
@@
public class Am2901NANDBased extends GUIComponent
double posX = getBounds().x;
double posY = getBounds().y;
double posX = getBounds().x;
double posY = getBounds().y;
+ gc.drawRectangle(getBounds());
Font oldFont = gc.getFont();
Font labelFont = new Font(oldFont.getName(), 4, oldFont.getStyle());
gc.setFont(labelFont);
Font oldFont = gc.getFont();
Font labelFont = new Font(oldFont.getName(), 4, oldFont.getStyle());
gc.setFont(labelFont);
- gc.drawRectangle(posX, posY, 50, getBounds().height);
for (int i = 0; i < inputNames.size(); i++)
{
Point textExtent = gc.textExtent(inputNames.get(i));
for (int i = 0; i < inputNames.size(); i++)
{
Point textExtent = gc.textExtent(inputNames.get(i));
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
fd2f736
..
ec397c0
100644
(file)
--- 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
@@
-38,7
+38,7
@@
public class GUIBitDisplay extends GUIComponent
double posY = getBounds().y;
// TODO maybe draw switch state too?
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();
String label = bitDisplay == null ? BitVectorFormatter.formatAsString(null)
: BitVectorFormatter.formatAsString(bitDisplay.getDisplayedValue());
Font oldFont = gc.getFont();
diff --git
a/net.mograsim.logic.ui/src/net/mograsim/logic/ui/model/components/GUIManualSwitch.java
b/net.mograsim.logic.ui/src/net/mograsim/logic/ui/model/components/GUIManualSwitch.java
index
0993024
..
8b9bcd9
100644
(file)
--- a/
net.mograsim.logic.ui/src/net/mograsim/logic/ui/model/components/GUIManualSwitch.java
+++ b/
net.mograsim.logic.ui/src/net/mograsim/logic/ui/model/components/GUIManualSwitch.java
@@
-40,7
+40,7
@@
public class GUIManualSwitch extends GUIComponent
double posY = getBounds().y;
// TODO maybe draw switch state too?
double posY = getBounds().y;
// TODO maybe draw switch state too?
- gc.drawRectangle(
posX, posY, width, height
);
+ gc.drawRectangle(
getBounds()
);
String label = BitVectorFormatter.formatValueAsString(end);
Font oldFont = gc.getFont();
Font labelFont = new Font(oldFont.getName(), fontHeight, oldFont.getStyle());
String label = BitVectorFormatter.formatValueAsString(end);
Font oldFont = gc.getFont();
Font labelFont = new Font(oldFont.getName(), fontHeight, oldFont.getStyle());