Re: [hatari-devel] correct ?

[ Thread Index | Date Index | More lists.tuxfamily.org/hatari-devel Archives ]


On Sunday 02 April 2017 11:08:19 Thomas Huth wrote:
> I can also reproduce it when using an empty floppy disk like this:

I can reproduce it with tos 1.04, but not with 2.06. Seems to be related to 
the order of line-a initialization there. Attach patch should fix this.


--- a/src/vdi.c
+++ b/src/vdi.c
@@ -867,11 +867,14 @@ void VDI_LineA(Uint32 linea, Uint32 font
                        }
                        /* make this new default font */
                        STMemory_WriteLong(linea-0x1cc, fontadr);
+                       /* make this new current font */
+                       STMemory_WriteLong(linea-0x38a, fontadr);
                        /* set DEFAULT flag for chosen font */
                        STMemory_WriteWord(fontadr + 66, 
STMemory_ReadWord(fontadr + 66) | 0x01);
                }
                cel_wd = STMemory_ReadWord(fontadr + 52);
                cel_ht = STMemory_ReadWord(fontadr + 82);
+               Log_Printf(LOG_INFO, "Using %dx%d system font\n", cel_wd, 
cel_ht);
                if (cel_wd <= 0)
                {
                        Log_Printf(LOG_WARN, "VDI Line-A init failed due to 
bad cell width!\n");


diff --git a/src/vdi.c b/src/vdi.c
--- a/src/vdi.c
+++ b/src/vdi.c
@@ -867,11 +867,14 @@ void VDI_LineA(Uint32 linea, Uint32 font
 			}
 			/* make this new default font */
 			STMemory_WriteLong(linea-0x1cc, fontadr);
+			/* make this new current font */
+			STMemory_WriteLong(linea-0x38a, fontadr);
 			/* set DEFAULT flag for chosen font */
 			STMemory_WriteWord(fontadr + 66, STMemory_ReadWord(fontadr + 66) | 0x01);
 		}
 		cel_wd = STMemory_ReadWord(fontadr + 52);
 		cel_ht = STMemory_ReadWord(fontadr + 82);
+		Log_Printf(LOG_INFO, "Using %dx%d system font\n", cel_wd, cel_ht);
 		if (cel_wd <= 0)
 		{
 			Log_Printf(LOG_WARN, "VDI Line-A init failed due to bad cell width!\n");


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/