• JS: console.gotoxy(): The 'y' value now needs to be 1 higher than it s

    From Eric Oulashin@VERT to GitLab issue in main/sbbs on Saturday, April 12, 2025 10:13:14
    open https://gitlab.synchro.net/main/sbbs/-/issues/908

    I was previously using Synchronet binaries and .js from March 6, 2025, and I updated them today (April 12, 2025), so something between then and now must have changed to cause this issue.

    With console.gotoxy() in JS, It looks like the 'y' value now needs to be 1 higher than it should be, at least for the first few calls. There's a JS mod I have where I use console.gotoxy(1, 1), console.gotoxy(1, 2), and console.gotoxy(1, 3) to display text on the first 3 lines of the screen, but now the 'y' value needs to be 2, 3, and 4 for those calls. But later in the script, I can use a 'y' value of 2 to update line 2 and that works as expected.

    DDMsgReader is another JS mod that seems to be affected as well. When I list messages with that, it uses console.gotoxy() to go to the first line and write a header line, but now the 1st line on the screen is left empty (though the rest of the screen displays as expected when listing messages).

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deucе@VERT to GitLab note in main/sbbs on Saturday, April 12, 2025 11:04:22
    https://gitlab.synchro.net/main/sbbs/-/issues/908#note_7025

    Unable to reproduce using this simple test script:

    ```
    console.clear();
    console.gotoxy(1,4);
    console.print("Line 4");
    console.gotoxy(1,3);
    console.print("Line 3");
    console.gotoxy(1,2);
    console.print("Line 2");
    console.gotoxy(1,1);
    console.print("Line 1");
    console.gotoxy(1,5);
    ```

    ---
    ï¿­ Synchronet ï¿­ Vertrauen ï¿­ Home of Synchronet ï¿­ [vert/cvs/bbs].synchro.net
  • From Eric Oulashin@VERT to GitLab note in main/sbbs on Saturday, April 12, 2025 11:41:18
    https://gitlab.synchro.net/main/sbbs/-/issues/908#note_7026

    For an example, place the following two files in the same directory and run the .js as a door:
    [show_tdih.js](/uploads/a3015e8f495df524d1f374a612bf39c3/show_tdih.js) [2025-04-12.json](/uploads/bbd0f96930c7dda387e3e31e4d6c8e6a/2025-04-12.json)

    If on a different day, you can rename 2025-04-12.json so that the date matches whatever day it is and then run show_tdih.js. When you run it, the first line on the screen should have "This day in history" and then the current month & day centered on the line. Line 2 should have "Events Births Deaths", and line 3 should have a horizontal double-line. In show_tdih.js, line 121 is where it starts displaying that. For me, the issue happens with this script; if I change those first 3 lines to 2, 3, and 4 (change lines 123, 135, and 149), then those lines appear in the expected rows on the screen.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Eric Oulashin@VERT to GitLab note in main/sbbs on Saturday, April 12, 2025 13:31:54
    https://gitlab.synchro.net/main/sbbs/-/issues/908#note_7026

    hmm.. It seems it doesn't happen all the time. The following is an example of a mod I'm working on that has the issue. Place the following two files in the same directory and run the .js as a door:
    [show_tdih.js](/uploads/a3015e8f495df524d1f374a612bf39c3/show_tdih.js) [2025-04-12.json](/uploads/bbd0f96930c7dda387e3e31e4d6c8e6a/2025-04-12.json)

    If on a different day, you can rename 2025-04-12.json so that the date matches whatever day it is and then run show_tdih.js. When you run it, the first line on the screen should have "This day in history" and then the current month & day centered on the line. Line 2 should have "Events Births Deaths", and line 3 should have a horizontal double-line. In show_tdih.js, line 121 is where it starts displaying that. For me, the issue happens with this script; if I change those first 3 lines to 2, 3, and 4 (change lines 123, 135, and 149), then those lines appear in the expected rows on the screen.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deucе@VERT to GitLab note in main/sbbs on Saturday, April 12, 2025 15:42:21
    https://gitlab.synchro.net/main/sbbs/-/issues/908#note_7028

    The problem appears to be that the line at the bottom is breaking and scrolling... here's a capture:

    ![image](/uploads/fed9cb34d207cc336c052027984f2d8d/image.png)

    ---
    ï¿­ Synchronet ï¿­ Vertrauen ï¿­ Home of Synchronet ï¿­ [vert/cvs/bbs].synchro.net
  • From Deucе@VERT to GitLab note in main/sbbs on Saturday, April 12, 2025 16:03:30
    https://gitlab.synchro.net/main/sbbs/-/issues/908#note_7030

    This change was by by @rswindell as part of fccf1a5718fdcb9864bcbccf2eb6de7ee50d3dd3

    ---
    ï¿­ Synchronet ï¿­ Vertrauen ï¿­ Home of Synchronet ï¿­ [vert/cvs/bbs].synchro.net
  • From Rob Swindell@VERT to GitLab note in main/sbbs on Saturday, April 12, 2025 16:16:08
    https://gitlab.synchro.net/main/sbbs/-/issues/908#note_7033

    Ah... yes @-codes aren't supposed to split lines.

    KEY_DOWN is a line feed. key_defs.js:
    `var KEY_DOWN = '\x0a'; /* ctrl-j (dn arrow) */`

    So this was a bug fixed in SBBS, so you'll need to update your script to suit.

    I thought this was related to the terminal abstraction changes by Deuce, but it's not.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Rob Swindell@VERT to GitLab issue in main/sbbs on Saturday, April 12, 2025 16:16:08
    close https://gitlab.synchro.net/main/sbbs/-/issues/908

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Eric Oulashin@VERT to GitLab note in main/sbbs on Saturday, April 12, 2025 16:53:08
    https://gitlab.synchro.net/main/sbbs/-/issues/908#note_7034

    Thanks for looking at this @rswindell and @Deuce. I probably wouldn't have realized that was causing the issue.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net