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

DDMsgReader: New configurable colors in the theme file for the indexed newscan...

DDMsgReader: New configurable colors in the theme file for the indexed newscan menu header text: indexMenuHeader, indexMenuNewIndicator, and indexMenuNewIndicatorHighlight
parent fc9d6410
No related branches found
No related tags found
1 merge request!376DDMsgReader: New configurable colors in the theme file for the indexed newscan menu header text: indexMenuHeader, indexMenuNewIndicator, and indexMenuNewIndicatorHighlight
...@@ -101,6 +101,10 @@ ...@@ -101,6 +101,10 @@
* New configurable colors in the theme file for the indexed mode newscan menu: * New configurable colors in the theme file for the indexed mode newscan menu:
* indexMenuSeparatorLine (sub-board separator line) and indexMenuSeparatorText * indexMenuSeparatorLine (sub-board separator line) and indexMenuSeparatorText
* (sub-board separator text) * (sub-board separator text)
* 2023-12-15 Eric Oulashin Version 1.90b
* New configurable colors in the theme file for the indexed newscan menu
* header text (indexMenuHeader), "NEW" indicator text (indexMenuNewIndicator),
* and highlighted "NEW" indicator text (indexMenuNewIndicatorHighlight)
*/ */
   
"use strict"; "use strict";
...@@ -205,8 +209,8 @@ var ansiterm = require("ansiterm_lib.js", 'expand_ctrl_a'); ...@@ -205,8 +209,8 @@ var ansiterm = require("ansiterm_lib.js", 'expand_ctrl_a');
   
   
// Reader version information // Reader version information
var READER_VERSION = "1.90a"; var READER_VERSION = "1.90b";
var READER_DATE = "2023-12-12"; var READER_DATE = "2023-12-15";
   
// Keyboard key codes for displaying on the screen // Keyboard key codes for displaying on the screen
var UP_ARROW = ascii(24); var UP_ARROW = ascii(24);
...@@ -15231,8 +15235,9 @@ function DigDistMsgReader_IndexedModeChooseSubBoard(pClearScreen, pDrawMenu, pDi ...@@ -15231,8 +15235,9 @@ function DigDistMsgReader_IndexedModeChooseSubBoard(pClearScreen, pDrawMenu, pDi
var currentTotalColWidth = descWidthForHdr + numMsgsWidth + numNewMsgsWidth + lastPostDateWidth; var currentTotalColWidth = descWidthForHdr + numMsgsWidth + numNewMsgsWidth + lastPostDateWidth;
if (currentTotalColWidth < maxScreenWidth) if (currentTotalColWidth < maxScreenWidth)
descWidthForHdr += (maxScreenWidth - currentTotalColWidth - 1); descWidthForHdr += (maxScreenWidth - currentTotalColWidth - 1);
var formatStrStrs = "%-" + descWidthForHdr + "s %" + numMsgsWidth + "s %" + numNewMsgsWidth + "s %" + lastPostDateWidth + "s"; var indexMenuHdrFormatStr = "\x01n" + this.colors.indexMenuHeader;
printf(formatStrStrs, "Description", "Total", "New", "Last Post"); indexMenuHdrFormatStr += "%-" + descWidthForHdr + "s %" + numMsgsWidth + "s %" + numNewMsgsWidth + "s %" + lastPostDateWidth + "s";
printf(indexMenuHdrFormatStr, "Description", "Total", "New", "Last Post");
console.attributes = "N"; console.attributes = "N";
if (!usingANSI) if (!usingANSI)
console.crlf(); console.crlf();
...@@ -15623,7 +15628,9 @@ function DigDistMsgReader_CreateLightbarIndexedModeMenu(pNumMsgsWidth, pNumNewMs ...@@ -15623,7 +15628,9 @@ function DigDistMsgReader_CreateLightbarIndexedModeMenu(pNumMsgsWidth, pNumNewMs
{ {
// Start & end indexes for the selectable items // Start & end indexes for the selectable items
var indexMenuIdxes = { var indexMenuIdxes = {
descStart: 0, newStatusStart: 0,
newStatusEnd: 4,
descStart: 4,
descEnd: pDescWidth+1, descEnd: pDescWidth+1,
totalStart: pDescWidth+1, totalStart: pDescWidth+1,
totalEnd: pDescWidth+pNumMsgsWidth+2, totalEnd: pDescWidth+pNumMsgsWidth+2,
...@@ -15643,16 +15650,19 @@ function DigDistMsgReader_CreateLightbarIndexedModeMenu(pNumMsgsWidth, pNumNewMs ...@@ -15643,16 +15650,19 @@ function DigDistMsgReader_CreateLightbarIndexedModeMenu(pNumMsgsWidth, pNumNewMs
indexedModeMenu.scrollbarEnabled = true; indexedModeMenu.scrollbarEnabled = true;
indexedModeMenu.borderEnabled = false; indexedModeMenu.borderEnabled = false;
// Colors: // Colors:
var newStatusHigh = "\x01n" + this.colors.indexMenuHighlightBkg + this.colors.indexMenuNewIndicatorHighlight;
var descHigh = "\x01n" + this.colors.indexMenuHighlightBkg + this.colors.indexMenuDescHighlight; var descHigh = "\x01n" + this.colors.indexMenuHighlightBkg + this.colors.indexMenuDescHighlight;
var totalMsgsHi = "\x01n" + this.colors.indexMenuHighlightBkg + this.colors.indexMenuTotalMsgsHighlight; var totalMsgsHi = "\x01n" + this.colors.indexMenuHighlightBkg + this.colors.indexMenuTotalMsgsHighlight;
var numNewMsgsHi = "\x01n" + this.colors.indexMenuHighlightBkg + this.colors.indexMenuNumNewMsgsHighlight; var numNewMsgsHi = "\x01n" + this.colors.indexMenuHighlightBkg + this.colors.indexMenuNumNewMsgsHighlight;
var lastPostDateHi = "\x01n" + this.colors.indexMenuHighlightBkg + this.colors.indexMenuLastPostDateHighlight; var lastPostDateHi = "\x01n" + this.colors.indexMenuHighlightBkg + this.colors.indexMenuLastPostDateHighlight;
indexedModeMenu.SetColors({ indexedModeMenu.SetColors({
itemColor: [{start: indexMenuIdxes.descStart, end: indexMenuIdxes.descEnd, attrs: "\x01n" + this.colors.indexMenuDesc}, itemColor: [{start: indexMenuIdxes.newStatusStart, end: indexMenuIdxes.newStatusEnd, attrs: "\x01n" + this.colors.indexMenuNewIndicator},
{start: indexMenuIdxes.descStart, end: indexMenuIdxes.descEnd, attrs: "\x01n" + this.colors.indexMenuDesc},
{start: indexMenuIdxes.totalStart, end: indexMenuIdxes.totalEnd, attrs: "\x01n" + this.colors.indexMenuTotalMsgs}, {start: indexMenuIdxes.totalStart, end: indexMenuIdxes.totalEnd, attrs: "\x01n" + this.colors.indexMenuTotalMsgs},
{start: indexMenuIdxes.newMsgsStart, end: indexMenuIdxes.newMsgsEnd, attrs: "\x01n" + this.colors.indexMenuNumNewMsgs}, {start: indexMenuIdxes.newMsgsStart, end: indexMenuIdxes.newMsgsEnd, attrs: "\x01n" + this.colors.indexMenuNumNewMsgs},
{start: indexMenuIdxes.lastPostDateStart, end: indexMenuIdxes.lastPostDateEnd, attrs: "\x01n" + this.colors.indexMenuLastPostDate}], {start: indexMenuIdxes.lastPostDateStart, end: indexMenuIdxes.lastPostDateEnd, attrs: "\x01n" + this.colors.indexMenuLastPostDate}],
selectedItemColor: [{start: indexMenuIdxes.descStart, end: indexMenuIdxes.descEnd, attrs: descHigh}, selectedItemColor: [{start: indexMenuIdxes.newStatusStart, end: indexMenuIdxes.newStatusEnd, attrs: newStatusHigh},
{start: indexMenuIdxes.descStart, end: indexMenuIdxes.descEnd, attrs: descHigh},
{start: indexMenuIdxes.totalStart, end: indexMenuIdxes.totalEnd, attrs: totalMsgsHi}, {start: indexMenuIdxes.totalStart, end: indexMenuIdxes.totalEnd, attrs: totalMsgsHi},
{start: indexMenuIdxes.newMsgsStart, end: indexMenuIdxes.newMsgsEnd, attrs: numNewMsgsHi}, {start: indexMenuIdxes.newMsgsStart, end: indexMenuIdxes.newMsgsEnd, attrs: numNewMsgsHi},
{start: indexMenuIdxes.lastPostDateStart, end: indexMenuIdxes.lastPostDateEnd, attrs: lastPostDateHi}], {start: indexMenuIdxes.lastPostDateStart, end: indexMenuIdxes.lastPostDateEnd, attrs: lastPostDateHi}],
...@@ -17505,12 +17515,15 @@ function getDefaultColors() ...@@ -17505,12 +17515,15 @@ function getDefaultColors()
unreadMsgMarkColor: "\x01n\x01w\x01h\x01i", unreadMsgMarkColor: "\x01n\x01w\x01h\x01i",
   
// Colors for the indexed mode sub-board menu: // Colors for the indexed mode sub-board menu:
indexMenuHeader: "\x01n\x01w",
indexMenuNewIndicator: "\x01n\x01w",
indexMenuDesc: "\x01n\x01w", indexMenuDesc: "\x01n\x01w",
indexMenuTotalMsgs: "\x01n\x01w", indexMenuTotalMsgs: "\x01n\x01w",
indexMenuNumNewMsgs: "\x01n\x01w", indexMenuNumNewMsgs: "\x01n\x01w",
indexMenuLastPostDate: "\x01b\x01h", indexMenuLastPostDate: "\x01b\x01h",
// Highlighted/selected: // Highlighted/selected:
indexMenuHighlightBkg: "\x014", indexMenuHighlightBkg: "\x014",
indexMenuNewIndicatorHighlight: "\x01w\x01h",
indexMenuDescHighlight: "\x01w\x01h", indexMenuDescHighlight: "\x01w\x01h",
indexMenuTotalMsgsHighlight: "\x01w\x01h", indexMenuTotalMsgsHighlight: "\x01w\x01h",
indexMenuNumNewMsgsHighlight: "\x01w\x01h", indexMenuNumNewMsgsHighlight: "\x01w\x01h",
......
Digital Distortion Message Reader Digital Distortion Message Reader
Version 1.90a Version 1.90b
Release date: 2023-12-12 Release date: 2023-12-15
   
by by
   
...@@ -898,6 +898,12 @@ msgListTimeHighlightColor Message list highlighted time color (for ...@@ -898,6 +898,12 @@ msgListTimeHighlightColor Message list highlighted time color (for
lightbar mode) lightbar mode)
   
Colors for the indexed mode sub-board menu: Colors for the indexed mode sub-board menu:
indexMenuHeader Header text above the indexed mode menu
indexMenuNewIndicator "NEW" indicator text at the start of the
indexed mode menu sub-boards that have new
messages
indexMenuDesc Indexed mode menu item description indexMenuDesc Indexed mode menu item description
   
indexMenuTotalMsgs Indexed mode menu total number of messages indexMenuTotalMsgs Indexed mode menu total number of messages
...@@ -909,6 +915,10 @@ indexMenuLastPostDate Indexed mode menu last post date ...@@ -909,6 +915,10 @@ indexMenuLastPostDate Indexed mode menu last post date
indexMenuHighlightBkg Indexed mode menu highlighted item indexMenuHighlightBkg Indexed mode menu highlighted item
background background
   
indexMenuNewIndicatorHighlight Indexed mode highlighted "NEW" indicator
text at the start of the sub-boards that
have new messages
indexMenuDescHighlight Indexed mode menu highlighted description indexMenuDescHighlight Indexed mode menu highlighted description
   
indexMenuTotalMsgsHighlight Indexed mode menu highlighted total number indexMenuTotalMsgsHighlight Indexed mode menu highlighted total number
......
...@@ -5,6 +5,10 @@ Revision History (change log) ...@@ -5,6 +5,10 @@ Revision History (change log)
============================= =============================
Version Date Description Version Date Description
------- ---- ----------- ------- ---- -----------
1.90b 2023-12-15 New configurable colors in the theme file for the indexed
newscan menu header text (indexMenuHeader), "NEW"
indicator text (indexMenuNewIndicator), and highlighted
"NEW" indicator text (indexMenuNewIndicatorHighlight)
1.90a 2023-12-12 New configurable colors in the theme file for the indexed 1.90a 2023-12-12 New configurable colors in the theme file for the indexed
mode newscan menu: indexMenuSeparatorLine (sub-board mode newscan menu: indexMenuSeparatorLine (sub-board
separator line) and indexMenuSeparatorText (sub-board separator line) and indexMenuSeparatorText (sub-board
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment