screen-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[screen-devel] [bug #55138] Bug: UTF-8 characters in hardstatus not work


From: Elof
Subject: [screen-devel] [bug #55138] Bug: UTF-8 characters in hardstatus not working
Date: Fri, 30 Nov 2018 06:59:05 -0500 (EST)
User-agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:63.0) Gecko/20100101 Firefox/63.0

URL:
  <https://savannah.gnu.org/bugs/?55138>

                 Summary: Bug: UTF-8 characters in hardstatus not working
                 Project: GNU Screen
            Submitted by: elof
            Submitted on: Fri 30 Nov 2018 11:59:03 AM UTC
                Category: User Interface
                Severity: 3 - Normal
                Priority: 5 - Normal
                  Status: None
                 Privacy: Public
             Assigned to: None
             Open/Closed: Open
         Discussion Lock: Any
                 Release: 4.6.2
           Fixed Release: None
         Planned Release: None
           Work Required: None

    _______________________________________________________

Details:

I have utf-8 problems in hardstatus even with the latest screen 4.6.2 from
2017.


# screen --version
Screen version 4.06.02 (GNU) 23-Oct-17


How to reproduce:
I press <ctrl-a + A> and change the window title to include a Swedish utf-8
character (like 'å' (an 'a' with a ring above it)).
If I now press <ctrl-a + "> to show the window-list, everything looks good. I
see the Swedish title correct. :-)
In the screen windows themselves (the terminal windows), my UTF-8 characters
work perfectly fine. :-)

Everything is working as intended as long as I don't have a hardstatus line.

If I let the hardstatus string print the window titles:

  hardstatus on
  hardstatus alwayslastline
  hardstatus string '%{=b wK}  %n  %{Kw}  %t  %=@ %H  %{wk}  %D %M %d  %c  '

...then the last line will show a garbage character instead of the Swedish
'å' character.
Also there will be some internal miscalculation of the string length,
resulting in incorrect background coloring on the last lines.

In my terminal I see that the 'å' character is a two-byte-char:

# echo -n a | wc -c
1
# echo -n å | wc -c
2


(My terminal = xterm, running on Debian 9)

/Elof





    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?55138>

_______________________________________________
  Message sent via Savannah
  https://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]