Skip to content
Snippets Groups Projects
Commit 2b2fdfa4 authored by Eric Oulashin's avatar Eric Oulashin Committed by Rob Swindell
Browse files

DDMsgReader: Fix in reader mode for refreshing the message area after closing another window

parent 1d60aa39
No related branches found
No related tags found
1 merge request!455Update branch with changes from master
......@@ -44,6 +44,10 @@
* 2023-10-25 Eric Oulashin Version 1.83
* Personal emails to the sysop received as "sysop" (or starting with "sysop")
* are now correctly identified and marked as read when read
* 2023-10-26 Eric Oulashin Version 1.84
* Fix in reader mode for refreshing the message area after
* closing another window (necessary with recent changes to
* substrWithAttrCodes())
*/
 
"use strict";
......@@ -148,8 +152,8 @@ var ansiterm = require("ansiterm_lib.js", 'expand_ctrl_a');
 
 
// Reader version information
var READER_VERSION = "1.83";
var READER_DATE = "2023-10-25";
var READER_VERSION = "1.84";
var READER_DATE = "2023-10-26";
 
// Keyboard key codes for displaying on the screen
var UP_ARROW = ascii(24);
......@@ -16401,15 +16405,20 @@ function DigDistMsgReader_RefreshMsgAreaRectangle(pTxtLines, pTopLineIdx, pTopLe
// text line. Otherwise, output an empty string.
if (txtLineIdx < pTxtLines.length)
{
// Get the text attributes up to the current point and output them
//console.print(getAllEditLineAttrsUntilLineIdx(pTxtLines, txtLineIdx, true, txtLineStartIdx));
// Get the section of line (and make sure it can fill the needed width), and print it
// Note: substrWithAttrCodes() is defined in dd_lightbar_menu.js
var lineText = substrWithAttrCodes(pTxtLines[txtLineIdx].replace(/[\r\n]+/g, ""), txtLineStartIdx, pWidth);
var printableTxtLen = console.strlen(lineText);
if (printableTxtLen < pWidth)
lineText += format("\x01n%*s", pWidth - printableTxtLen, "");
console.print(lineText);
if (txtLineStartIdx < console.strlen(pTxtLines[txtLineIdx]))
{
// Get the text attributes up to the current point and output them
//console.print(getAllEditLineAttrsUntilLineIdx(pTxtLines, txtLineIdx, true, txtLineStartIdx));
// Get the section of line (and make sure it can fill the needed width), and print it
// Note: substrWithAttrCodes() is defined in dd_lightbar_menu.js
var lineText = substrWithAttrCodes(pTxtLines[txtLineIdx].replace(/[\r\n]+/g, ""), txtLineStartIdx, pWidth);
var printableTxtLen = console.strlen(lineText);
if (printableTxtLen < pWidth)
lineText += format("\x01n%*s", pWidth - printableTxtLen, "");
console.print(lineText);
}
else // The start index is beyond the length of the string, so print an empty string
printf(emptyFormatStr, "");
}
else // We've printed all the remaining text lines, so now print an empty string.
printf(emptyFormatStr, "");
......
Digital Distortion Message Reader
Version 1.83
Release date: 2023-10-25
Version 1.84
Release date: 2023-10-26
by
......
......@@ -5,6 +5,9 @@ Revision History (change log)
=============================
Version Date Description
------- ---- -----------
1.84 2023-10-26 Fix in reader mode for refreshing the message area after
closing another window (necessary with recent changes to
substrWithAttrCodes())
1.83 2023-10-25 Personal emails to the sysop received as "sysop" (or
starting with "sysop") are now correctly identified and
marked as read when read
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment