diff --git a/exec/SlyEdit.js b/exec/SlyEdit.js index 9be6b6450979e482a7dd56eee8845b64501209d0..fe5d2d69510e4632acd874784bddcbee2d88d07e 100644 --- a/exec/SlyEdit.js +++ b/exec/SlyEdit.js @@ -158,8 +158,8 @@ if (console.screen_columns < 80) } // Constants -const EDITOR_VERSION = "1.66"; -const EDITOR_VER_DATE = "2019-05-29"; +const EDITOR_VERSION = "1.66.1"; +const EDITOR_VER_DATE = "2019-06-05"; // Program variables diff --git a/exec/SlyEdit_DCTStuff.js b/exec/SlyEdit_DCTStuff.js index 451033a1f25c21024f8cec8757c29af0b7c43e81..e1126956990c031a0051e0e92ebbc66d07755ea8 100644 --- a/exec/SlyEdit_DCTStuff.js +++ b/exec/SlyEdit_DCTStuff.js @@ -313,51 +313,54 @@ function DisplayTextAreaBottomBorder_DCTStyle(pLineNum, pUseQuotes, pEditLeft, p // pUsingQuotes: Boolean - Whether or not message quoting is enabled. function DisplayBottomHelpLine_DCTStyle(pLineNum, pUsingQuotes) { - // For efficiency, define the help line variable only once. - if (typeof(DisplayBottomHelpLine_DCTStyle.helpText) == "undefined") - { - DisplayBottomHelpLine_DCTStyle.helpText = gConfigSettings.DCTColors.BottomHelpBrackets + - "[" + gConfigSettings.DCTColors.BottomHelpKeys + "CTRL" + - gConfigSettings.DCTColors.BottomHelpFill + DOT_CHAR + - gConfigSettings.DCTColors.BottomHelpKeys + "Z" + - gConfigSettings.DCTColors.BottomHelpBrackets + "]n " + - gConfigSettings.DCTColors.BottomHelpKeyDesc + "Saven " + - gConfigSettings.DCTColors.BottomHelpBrackets + "[" + - gConfigSettings.DCTColors.BottomHelpKeys + "CTRL" + - gConfigSettings.DCTColors.BottomHelpFill + DOT_CHAR + - gConfigSettings.DCTColors.BottomHelpKeys + "A" + - gConfigSettings.DCTColors.BottomHelpBrackets + "]n " + - gConfigSettings.DCTColors.BottomHelpKeyDesc + "Abort"; - // If we can allow message quoting, then add a text to show Ctrl-Q for - // quoting. - if (pUsingQuotes) - DisplayBottomHelpLine_DCTStyle.helpText += "n " + - gConfigSettings.DCTColors.BottomHelpBrackets + "[" + - gConfigSettings.DCTColors.BottomHelpKeys + "CTRL" + - gConfigSettings.DCTColors.BottomHelpFill + DOT_CHAR + - gConfigSettings.DCTColors.BottomHelpKeys + "Q" + - gConfigSettings.DCTColors.BottomHelpBrackets + "]n " + - gConfigSettings.DCTColors.BottomHelpKeyDesc + "Quote"; - DisplayBottomHelpLine_DCTStyle.helpText += "n " + - gConfigSettings.DCTColors.BottomHelpBrackets + "[" + - gConfigSettings.DCTColors.BottomHelpKeys + "ESC" + - gConfigSettings.DCTColors.BottomHelpBrackets + "]n " + - gConfigSettings.DCTColors.BottomHelpKeyDesc + "Menu"; - // Center the text by padding it in the front with spaces. This is done instead - // of using console.center() because console.center() will output a newline, - // which would not be good on the last line of the screen. - var numSpaces = (console.screen_columns/2).toFixed(0) - - (strip_ctrl(DisplayBottomHelpLine_DCTStyle.helpText).length/2).toFixed(0); - for (var i = 0; i < numSpaces; ++i) - DisplayBottomHelpLine_DCTStyle.helpText = " " + DisplayBottomHelpLine_DCTStyle.helpText; - } + // For efficiency, define the help line variable only once. + if (typeof(DisplayBottomHelpLine_DCTStyle.helpText) == "undefined") + { + DisplayBottomHelpLine_DCTStyle.helpText = gConfigSettings.DCTColors.BottomHelpBrackets + + "[" + gConfigSettings.DCTColors.BottomHelpKeys + "CTRL" + + gConfigSettings.DCTColors.BottomHelpFill + DOT_CHAR + + gConfigSettings.DCTColors.BottomHelpKeys + "Z" + + gConfigSettings.DCTColors.BottomHelpBrackets + "]\1n " + + gConfigSettings.DCTColors.BottomHelpKeyDesc + "Save\1n " + + gConfigSettings.DCTColors.BottomHelpBrackets + "[" + + gConfigSettings.DCTColors.BottomHelpKeys + "CTRL" + + gConfigSettings.DCTColors.BottomHelpFill + DOT_CHAR + + gConfigSettings.DCTColors.BottomHelpKeys + "A" + + gConfigSettings.DCTColors.BottomHelpBrackets + "]\1n " + + gConfigSettings.DCTColors.BottomHelpKeyDesc + "Abort"; + // If we can allow message quoting, then add a text to show Ctrl-Q for + // quoting. + if (pUsingQuotes) + { + DisplayBottomHelpLine_DCTStyle.helpText += "\1n " + + gConfigSettings.DCTColors.BottomHelpBrackets + "[" + + gConfigSettings.DCTColors.BottomHelpKeys + "CTRL" + + gConfigSettings.DCTColors.BottomHelpFill + DOT_CHAR + + gConfigSettings.DCTColors.BottomHelpKeys + "Q" + + gConfigSettings.DCTColors.BottomHelpBrackets + "]\1n " + + gConfigSettings.DCTColors.BottomHelpKeyDesc + "Quote"; + } + DisplayBottomHelpLine_DCTStyle.helpText += "\1n " + + gConfigSettings.DCTColors.BottomHelpBrackets + "[" + + gConfigSettings.DCTColors.BottomHelpKeys + "ESC" + + gConfigSettings.DCTColors.BottomHelpBrackets + "]\1n " + + gConfigSettings.DCTColors.BottomHelpKeyDesc + "Menu"; + // Center the text by padding it in the front with spaces. This is done instead + // of using console.center() because console.center() will output a newline, + // which would not be good on the last line of the screen. + var numSpaces = (console.screen_columns/2).toFixed(0) - (strip_ctrl(DisplayBottomHelpLine_DCTStyle.helpText).length/2).toFixed(0); + for (var i = 0; i < numSpaces; ++i) + DisplayBottomHelpLine_DCTStyle.helpText = " " + DisplayBottomHelpLine_DCTStyle.helpText; + } - // Display the help line on the screen - var lineNum = console.screen_rows; + // Display the help line on the screen + var lineNum = console.screen_rows; if ((typeof(pLineNum) != "undefined") && (pLineNum != null)) lineNum = pLineNum; - console.gotoxy(1, lineNum); + console.gotoxy(1, lineNum); console.print(DisplayBottomHelpLine_DCTStyle.helpText); + console.print("\1n"); + console.cleartoeol(); } // Updates the insert mode displayd on the screen, for DCT Edit style. diff --git a/exec/SlyEdit_IceStuff.js b/exec/SlyEdit_IceStuff.js index a4bea2ad334fe03af61a3678cef003d0194d2bd1..00bca020a49d773f742ad9254ef87285264c6c40 100644 --- a/exec/SlyEdit_IceStuff.js +++ b/exec/SlyEdit_IceStuff.js @@ -364,6 +364,8 @@ function DisplayBottomHelpLine_IceStyle(pLineNum, pUsingQuotes) // Display the help text on the screen console.gotoxy(1, lineNum); console.print(DisplayBottomHelpLine_IceStyle.helpText); + console.print("\1n"); + console.cleartoeol(); } // Updates the insert mode displayd on the screen, for Ice Edit style.