OpenComputers II

OpenComputers II

27.1k Downloads

Terminal troubles

Bs0Dd opened this issue ยท 5 comments

commented

I built several programs on C and ncurses and discovered a couple of unpleasant problems.

  1. Environment variable TERMINFO is empty.
    Missing terminfo
    For this reason, the program with ncurses cannot find a folder with terminfo files and gives an error.
    Terminfo error
    Although terminfo is present in the system in the folder /usr/share/terminfo.
    Therefore, I think you should configure the system to assign the path to the variable.

  2. Terminal type is incorrect.
    In the TERM environment variable, the VT100 terminal is set. This also causes problems for programs on ncurses.
    If you run the program, it will be B/W and the arrows buttons, Home, Insert and others will not work.
    vt100
    Alas, none of the terminal files in terminfo are fully compatible with the terminal in OC2. I did not work with terminfo before, but I tried to write a file for this terminal. I do not know that all attributes are correct, but I tested it with a pair of programs and games on ncurses and did not find problems with I/O.
    oc2-term
    I think the file should be included in the system and change the type of terminal in TERM.

  3. The terminal does not support the pseudographic, withdrawing the letter instead of special characters, which looks not very beautiful. At first I thought that the problem is in Sedna, but in the other terminals everything is displayed adequately.
    pseudographic

commented

TERMINFO env var is now set, and the terminal emulator has gotten a lot of fixes.

ESC ( 0 (special graphics) is something I may look into at a later time.

commented

Probably won't add support for special graphics on the terminal, since for fancy graphics there's the projector now, so closing this.

commented

Aight, then I agree; TERMINFO should recieve a definition, and optionally, Prompt Strings should be customised with ANSI colour codes.

commented

Ncurses support is currently not installed

commented

In fact, programs on ncurses require only the presence of terminfo, and it is already present in the system, but for some reason the path to it is not set. If you specify the path and correct terminal through 'export', there will be no problems in the work of the programs on ncurses