mirror of
https://github.com/hneemann/Digital.git
synced 2025-09-19 09:54:49 -04:00
smaller font size for splitter pin descriptions
This commit is contained in:
parent
4e50918f09
commit
0817ad347e
@ -89,6 +89,10 @@ public class Style {
|
||||
* Used to draw the pin description text
|
||||
*/
|
||||
public static final Style SHAPE_PIN = new Style(LINETHIN, false, Color.GRAY, 18, null);
|
||||
/**
|
||||
* Used to draw the pin description text for splitters
|
||||
*/
|
||||
public static final Style SHAPE_SPLITTER = new Style(LINETHIN, false, Color.GRAY, 12, null);
|
||||
/**
|
||||
* Used to draw the pin description text
|
||||
*/
|
||||
|
@ -58,12 +58,12 @@ public class SplitterShape implements Shape {
|
||||
public void drawTo(Graphic graphic, Style heighLight) {
|
||||
for (int i = 0; i < inputs.size(); i++) {
|
||||
Vector pos = new Vector(-2, i * SIZE - 3);
|
||||
graphic.drawText(pos, pos.add(2, 0), inputs.get(i).getName(), Orientation.RIGHTBOTTOM, Style.SHAPE_PIN);
|
||||
graphic.drawText(pos, pos.add(2, 0), inputs.get(i).getName(), Orientation.RIGHTBOTTOM, Style.SHAPE_SPLITTER);
|
||||
graphic.drawLine(new Vector(0, i * SIZE), new Vector(SIZE2, i * SIZE), Style.NORMAL);
|
||||
}
|
||||
for (int i = 0; i < outputs.size(); i++) {
|
||||
Vector pos = new Vector(SIZE + 2, i * SIZE - 3);
|
||||
graphic.drawText(pos, pos.add(2, 0), outputs.get(i).getName(), Orientation.LEFTBOTTOM, Style.SHAPE_PIN);
|
||||
graphic.drawText(pos, pos.add(2, 0), outputs.get(i).getName(), Orientation.LEFTBOTTOM, Style.SHAPE_SPLITTER);
|
||||
graphic.drawLine(new Vector(SIZE, i * SIZE), new Vector(SIZE2, i * SIZE), Style.NORMAL);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user