From 88a778dd8ef78072d80e8374f860c3a978258020 Mon Sep 17 00:00:00 2001
From: Leon Dieter <Leon Dieter@DESKTOP-L4JC8N4>
Date: Tue, 16 Mar 2021 16:22:25 +0100
Subject: [PATCH] minor changes

---
 src/tec/letsgoing/ardublock/simulator/view/GUI.java | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/src/tec/letsgoing/ardublock/simulator/view/GUI.java b/src/tec/letsgoing/ardublock/simulator/view/GUI.java
index c235bbd..7be8124 100644
--- a/src/tec/letsgoing/ardublock/simulator/view/GUI.java
+++ b/src/tec/letsgoing/ardublock/simulator/view/GUI.java
@@ -202,9 +202,10 @@ public class GUI extends JFrame implements Runnable, ActionListener {
 		
 		//updateSerialLog(getHeight()-topPanel.getHeight());
 
-		System.out.println(xscale + "  :  " + yscale);
-		System.out.println(getWidth() + "  :  " + getHeight());
+		updateSerialLog(getHeight()-topPanel.getHeight());
 		
+		System.out.println(topPanel.getHeight());
+		System.out.println(modulPanel.getHeight());
 	}
 	
 	
@@ -299,7 +300,6 @@ public class GUI extends JFrame implements Runnable, ActionListener {
 
 		panel.add(scrollPane, BorderLayout.PAGE_END);
 		
-		updateSerialLog(getHeight()-topPanel.getHeight());
 		
 		return panel;
 	}
@@ -312,9 +312,9 @@ public class GUI extends JFrame implements Runnable, ActionListener {
 	 */
 	public void updateSerialLog(int size) {
 		
-		int numRows =  Math.min(Math.max(((int)size/30), 2), 16);
+		int numRows =  Math.min(Math.max(((int)size/20-3), 3), 20);
 		serialLog.setRows(numRows);	
-		
+		System.out.println(numRows);
 	}
 
 	/**
-- 
GitLab