- Fixed: 80col text mode

- Fixed: Video mode indicators
This commit is contained in:
tudnai 2020-08-02 16:37:08 -07:00
parent 6889eafb0b
commit 15a2fd84ac
2 changed files with 15 additions and 3 deletions

View File

@ -759,10 +759,10 @@ class ViewController: NSViewController {
if let fontSize = self.display.font?.pointSize {
if videoMode.col80 == 1 {
self.display.font = NSFont(name: "PRNumber3", size: fontSize)
self.textDisplay.font = NSFont(name: "PRNumber3", size: fontSize)
}
else {
self.display.font = NSFont(name: "PrintChar21", size: fontSize)
self.textDisplay.font = NSFont(name: "PrintChar21", size: fontSize)
}
}
}

View File

@ -247,6 +247,9 @@ enum mmio {
io_VID_CLRALTCHAR = 0xC00E, // ECG W Primary Character Set
io_VID_SETALTCHAR = 0xC00F, // ECG W Alternate Character Set
io_VID_RDTEXT = 0xC01A, // ECG R7 Status of Text/Graphics
io_VID_RDMIXED = 0xC01B, // ECG R7 Status of Full Screen/Mixed Graphics
io_VID_RDPAGE2 = 0xC01C, // ECG R7 Status of Page 1/Page 2
io_VID_RDHIRES = 0xC01D, // ECG R7 Status of LoRes/HiRes
io_VID_ALTCHAR = 0xC01E, // ECG R7 Status of Primary/Alternate Character Set
io_VID_RD80VID = 0xC01F, // ECG R7 Status of 40/80 Columns
io_VID_Text_OFF = 0xC050,
@ -654,6 +657,7 @@ INLINE uint8_t ioRead( uint16_t addr ) {
return videoMode.col80 << 7;
case (uint8_t)io_TAPEIN:
// TODO: this should be only on //c
return MEMcfg.txt_page_2 << 7;
case (uint8_t)io_RDCXROM:
@ -692,6 +696,9 @@ INLINE uint8_t ioRead( uint16_t addr ) {
textPageSelect();
break;
case (uint8_t)io_VID_RDPAGE2:
return MEMcfg.txt_page_2 << 7;
case (uint8_t)io_VID_Text_OFF:
videoMode.text = 0;
break;
@ -708,6 +715,9 @@ INLINE uint8_t ioRead( uint16_t addr ) {
videoMode.mixed = 1;
break;
case (uint8_t)io_VID_RDMIXED:
return videoMode.mixed << 7;
case (uint8_t)io_VID_Hires_OFF:
videoMode.hires = 0;
break;
@ -716,6 +726,8 @@ INLINE uint8_t ioRead( uint16_t addr ) {
videoMode.hires = 1;
break;
case (uint8_t)io_VID_RDHIRES:
return videoMode.hires << 7;
case (uint8_t)io_PDL0:
case (uint8_t)io_PDL1: