LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 10-14-2011, 05:31 AM   #1
simonbcn
LQ Newbie
 
Registered: Jan 2011
Location: Barcelona, Spain
Distribution: Ubuntu
Posts: 4

Rep: Reputation: Disabled
Question Write special unicode chars in hardstatus of GNU Screen


Hi,
I want write the next specials chars to hardstatus of GNU Screen: "↑" (up arrow) and "↓" (down arrow), but it shows strange chars. How can I do this?
This worked to me before but I have to reinstall my SO (Ubuntu 11.04) and now it doesn't work.
Thanks in advance.
Regards.

ADD:
Config files
Code:
  $ cat ~/.screenrc
deflogin off
shell bash

termcapinfo xterm* ti@:te@
backtick 25 1 1 $HOME/bin/scripts_screen/velocidad_eth1
backtick 26 300 300 $HOME/bin/scripts_screen/espacio_libre_servidor
backtick 27 300 300 $HOME/bin/scripts_screen/espacio_libre_menor_que
hardstatus alwayslastline "  %{= Wb}%LD %d %LM, %c %{=b Wk}| %?%{=b rg}%27`%:%{= Wm}%?Espacio libre: %26` %{=b Wk}| %{= Wk}%25`"
Code:
  $ cat $HOME/bin/scripts_screen/velocidad_eth1
#!/bin/sh
bajada=`ifstat -qwni eth1 0.1 1 | tail -n 1 | awk '{print $1}'`
subida=`ifstat -qwni eth1 0.1 1 | tail -n 1 | awk '{print $2}'`
echo "↓ $bajada / ↑ $subida"
I think this problem is related to enconding but my locales are correct:
Code:
LANG=es_ES.UTF-8
LANGUAGE=es_ES:en
LC_CTYPE="es_ES.UTF-8"
LC_NUMERIC="es_ES.UTF-8"
LC_TIME="es_ES.UTF-8"
LC_COLLATE=C
LC_MONETARY="es_ES.UTF-8"
LC_MESSAGES=POSIX
LC_PAPER="es_ES.UTF-8"
LC_NAME="es_ES.UTF-8"
LC_ADDRESS="es_ES.UTF-8"
LC_TELEPHONE="es_ES.UTF-8"
LC_MEASUREMENT="es_ES.UTF-8"
LC_IDENTIFICATION="es_ES.UTF-8"
LC_ALL=
This is a capture of a screen session:
http://i.stack.imgur.com/8icXQ.png

You can see that the unicode characters in terminal are correct but not the unicode chars of hardstatus/caption screen.

Last edited by simonbcn; 10-15-2011 at 05:34 AM. Reason: added config/script files
 
  


Reply

Tags
gnu screen, screen, unicode


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] acpi result in hardstatus line in screen xeon123 Linux - Newbie 5 04-18-2011 05:22 AM
python: how to handle unicode chars in ascii strings? BrianK Programming 5 01-27-2009 04:20 PM
python: how to handle unicode chars in ascii strings? BrianK Programming 1 01-26-2009 09:46 PM
cyrillic chars - unicode or koi8_ru ojav Linux - Newbie 1 05-29-2005 02:51 PM


All times are GMT -5. The time now is 09:33 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration