When I do this in my terminal:

echo -e "\xF0\x9f\x8d\xba"

I get a cool beer mug in my terminal: 🍺

However, when I start screen, and try the same, I'm getting a �. How do I get the nice beer mug?

This is my .screenrc:

nethack on
startup_message off
defscrollback 3000
hardstatus on
hardstatus alwayslastline
hardstatus string "%{.bW}%-w%{.rW}%n %t%{-}%+w %=%{..G} %H %{..Y} %m/%d %c"
termcapinfo xterm 'bc@:bs@'
ignorecase on
maptimeout 0
vbell off
defutf8 on
defencoding utf8

Also running screen with the -U option doesn't help.

share|improve this question

migrated from serverfault.com Jul 5 '13 at 18:48

This question came from our site for system and network administrators.

    
� is U+FFFD, the Unicode replacement character. This means your computer does not recognize the character that the bytes are trying to represent. Are you switching from your physical terminal to a terminal emulator during these tests by any chance? – Andrew B Jul 4 '13 at 16:03
    
When I do it in my terminal without starting screen it works, when I start screen and do the same it doesn't work. It's on the same machine and in the same terminal. I use a terminal emulator all the time. – rednaw Jul 4 '13 at 16:11
    
what terminal emulator are you using? – dawud Jul 4 '13 at 16:39
up vote 12 down vote accepted

It's a apparently a known bug: No characters beyond the BMP are displayed, as screen apparently only has a two byte buffer for characters.

(It works in tmux).

share|improve this answer
    
That's a bummer.. Tried tmux in the past but it crashed a lot. Maybe I could give it another try at some point... – rednaw Jul 5 '13 at 7:36
    
Btw update: I've been on tmux for a long time now and loving it. Almost never crashes and has great configurability and plugins. Took some time to configure it so that it became nice to work in though, but it's certainly worth the effort :). – rednaw Apr 21 '16 at 20:44
2  
Update: the bug is fixed as of v4.2.0! sudo apt install screen=4.2.1-2~ubuntu14.04.1 worked for me. – Adam Monsen Dec 3 '16 at 6:09

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.