public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: "Nate DeSimone" <nathaniel.l.desimone@intel.com>
To: "discuss@edk2.groups.io" <discuss@edk2.groups.io>,
	"lersek@redhat.com" <lersek@redhat.com>
Cc: "cadenkline9@gmail.com" <cadenkline9@gmail.com>,
	edk2-devel-groups-io <devel@edk2.groups.io>,
	"Ard Biesheuvel (TianoCore)" <ardb+tianocore@kernel.org>,
	"Leif Lindholm (Nuvia address)" <leif@nuviainc.com>
Subject: Re: [edk2-discuss] Google Summer of Code Interested Student
Date: Tue, 16 Mar 2021 23:25:49 +0000	[thread overview]
Message-ID: <MWHPR1101MB2160480638D0349F19684161CD6B9@MWHPR1101MB2160.namprd11.prod.outlook.com> (raw)
In-Reply-To: <3d466515-7d65-9abe-3609-d0298c1b245b@redhat.com>

Hi Laszlo,

> -----Original Message-----
> From: discuss@edk2.groups.io <discuss@edk2.groups.io> On Behalf Of
> Laszlo Ersek
> Sent: Tuesday, March 16, 2021 8:24 AM
> To: Desimone, Nathaniel L <nathaniel.l.desimone@intel.com>
> Cc: discuss@edk2.groups.io; cadenkline9@gmail.com; edk2-devel-groups-io
> <devel@edk2.groups.io>; Ard Biesheuvel (TianoCore)
> <ardb+tianocore@kernel.org>; Leif Lindholm (Nuvia address)
> <leif@nuviainc.com>
> Subject: Re: [edk2-discuss] Google Summer of Code Interested Student
> 
> Hi Nate,
> 
> (adding Leif and Ard)
> 
> On 03/13/21 03:52, Desimone, Nathaniel L wrote:
> > I've created a new wiki page for this task with all the information I
> > have gathered thus far. I've done some more experimentation and found
> > that there are several newer terminal emulators that don't support DEC
> > Special Graphics so I've reduced the number of modes where DEC Special
> > Graphics should be preferred. Laszlo, if you could take a look at the
> > terminal type matrix I created that would be very helpful.
> >
> > https://github.com/tianocore/tianocore.github.io/wiki/Tasks-Terminal-d
> > river-improvements
> 
> (
> 
> My background:
> 
> I settled on plain (non-UTF-8) xterm around 1998, and have been using it
> ever since. Whenever something was off, I always tried to hammer the
> application into conformance with my particular xterm setup, rather than the
> other way around. I also have some quirky terminal settings -- for me,
> "backspace" generates ^H / keycode 22 (stty sets erase to ^H), "delete"
> generates keycode 119, and there's no "rubout". I still don't use UTF-8 (I use
> latin2).
> 
> )
> 
> * Regarding ArmVirtPkg, I stick with the default TTY_TERMINAL=FALSE
>   setting (which means VT-100). Using that setting, I see the following
>   kind of "ASCII approximation" for box drawing:
> 
>   /------------------------------------------------------------------------------\
>   |                                Boot Manager                                  |
>   \------------------------------------------------------------------------------/
> 
>   I'm really happy with this, as I don't care much for nice-looking
>   boxes; instead I prefer portability.
> 
>   (NB: this seems to disagree with your "Current Behavior (Which is
>   wrong)" line for VT100, as it suggests CP437. That's not what I'm
>   seeing with VT100.)

I went back and looked at this is more detail, and I missed the following critical detail:

if (TerminalDevice->TerminalType != TerminalTypePcAnsi) {
  GraphicChar = AsciiChar;
}

Yes you are totally right! I've adjusted the table to reflect this behavior.

> 
>   TTY_TERMINAL=TRUE would mainly affect backspace / delete I think -- as
>   far as I recall, that's why I asked Roy not to make TTY_TERMINAL=TRUE
>   the default, in 2015:
> 
>   http://mid.mail-archive.com/555458DB.3090602@redhat.com
>   http://mid.mail-
> archive.com/CAFECyb_E+bGZt5xv7QhRqyD0jX=AzoEMw7VW_tjZr+E=sQf8w
> w@mail.gmail.com
> 
>   (I'd like to CC Roy, but I can't tell if he's now working for Linaro,
>   Cavium, HPE, Marvell, or another company.)
> 
> * Regarding OvmfPkg, currently PC_ANSI is hard-coded, and for me it
>   looks like this:
> 
> 
> ÚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ
> ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄż
>   ł                                Boot Manager                                  ł
> 
> ŔÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ
> ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄŮ
> 
>   Obviously I'd much prefer if I got the simple ASCII approximation here
>   as well.
> 
> * Whether VT100 and/or PC_ANSI and/or TTY_TERM are *officially*
> supposed
>   to use DEC Special Graphics, I can't tell.

The UEFI spec doesn't read on this at all, even though it describes VT100 and VT100+ as separate modes... it doesn't say how they differ. I agree with you that it seems reasonable for VT100 to keep character output to strict ASCII only... that way the "+" in VT100+ actually means something. I've updated the wiki accordingly.

I'd advocate for the default to be switched to VT_UTF8. I really don't think you will run into many terminal emulators that don't implement UTF-8 anymore, XTerm included. Those who want pure ASCII output can switch to VT100.

> 
>   I know what my preferences are:
> 
>   - the current BackSpace and Delete mappings (which work fine for me
>     with both VT100 and PC_ANSI, but *not* with TTY_TERM),
> 
>   - and the most primitive ASCII mapping (no special graphics, no UTF-8
>     sequences, etc). I really like a super dumb terminal, where taking
>     simple "ASCII screenshots" (and pasting them into plaintext emails!)
>     is *trivial*.
> 
>   ... Looking at your "Expected Behavior" table, there is only one line
>   left with "poor man's ASCII" -- namely, TTY_TERM. Unfortunately,
>   TTY_TERM breaks my BackSpace / Delete settings :(
> 
> * In summary, I'd prefer if (a) VT100 stayed as-is (using "poor man's
>   ASCII", as seen in ArmVirtPkg), and (b) if OVMF used *that* VT100,
>   rather than PC_ANSI, by default.
> 
> Thanks!
> Laszlo
> 
> 
> 
> 
> 


  reply	other threads:[~2021-03-16 23:25 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <P6oo.1615342201438491325.TWFM@groups.io>
     [not found] ` <848a0cdb-accf-5b7c-df59-65a806ea14a7@redhat.com>
2021-03-12  5:45   ` [edk2-discuss] Google Summer of Code Interested Student Nate DeSimone
2021-03-12 18:51     ` Laszlo Ersek
2021-03-13  2:52       ` Nate DeSimone
     [not found]   ` <166B8219924C8DCE.3757@groups.io>
2021-03-13  2:52     ` Nate DeSimone
2021-03-16 15:23       ` Laszlo Ersek
2021-03-16 23:25         ` Nate DeSimone [this message]
2021-03-17 17:14           ` Laszlo Ersek
2021-03-17 12:02         ` Leif Lindholm
2021-03-17 16:00         ` [edk2-devel] " Andrew Fish
2021-03-22 18:31           ` Nate DeSimone
2021-03-22 23:07             ` Andrew Fish

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-list from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=MWHPR1101MB2160480638D0349F19684161CD6B9@MWHPR1101MB2160.namprd11.prod.outlook.com \
    --to=devel@edk2.groups.io \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox