Debian console graphic error - terminal

when I try to install something over Putty, it looks like this:
so really buggy :).
Has anyone a suggestion for this?

It's probably something to do with UTF-8 handling on different terminal types.
You could try this solution I found on linux.debian.user:
What release of PuTTY are you using? I'm using PuTTY 0.63, which is
the latest release. In this version, the default value for the terminal
type string is xterm. At least it is for me. I have to explicitly change
it to putty, even after setting the remote character set to UTF-8. Make
sure the terminal type string is all lower case. Terminal type strings
are case sensitive. They have to match the terminal type definition in
ncurses. The putty terminal type definition in ncurses can be found in
/usr/share/terminfo/p. You can also try a terminal type string of
xterm-utf8. This terminal type definition in ncurses is found in
/usr/share/terminfo/x. The latest version of PuTTY can be downloaded
here:
http://www.chiark.greenend.org.uk/~sgtatham/putty
https://groups.google.com/forum/#!topic/linux.debian.user/Yy-kQu1RC44

It's indirectly related to UTF-8: the PuTTY developers chose to ignore VT100 line-drawing control sequences when UTF-8 encoding is used. Doing that requires any application that uses line-drawing to do some workaround.
You can work around this by one of these methods:
setting the NCURSES_NO_UTF8_ACS environment variable, as noted in the manual page, or
using a correct terminal description such as putty, which happens to have a special capability U8 defined, telling ncurses the same thing as the environment variable.

Related

Can’t display diacritic characters within Cygwin terminal

Both in Cygwin (minnty) and Git Bash I have set font to pl_PL/ISO-8859-2. It results (in both cases) in:
$ locale
LANG=pl_PL.ISO-8859-2
LC_CTYPE="pl_PL.ISO-8859-2"
LC_NUMERIC="pl_PL.ISO-8859-2"
LC_TIME="pl_PL.ISO-8859-2"
LC_COLLATE="pl_PL.ISO-8859-2"
LC_MONETARY="pl_PL.ISO-8859-2"
LC_MESSAGES="pl_PL.ISO-8859-2"
LC_ALL=
But in Cygwin, when I display Git commits’ comments - diacritical characters are not displayed properly (regardless of the font I use - e.g., Consolas, Lucida Console). The same commits’ comments are properly displayed in Git Bash. The comments have been UTF-8 encoded while saving.
I didn’t have this issue before, but once I reinstalled the OS now it occurs. Unfortunately I can’t tell what I have done differently.
Is it possible to fix that? I use Windows 7 32-bit.
In general, you're better off using UTF-8 and setting your locale to pl_PL.UTF-8. UTF-8 is capable of supporting all languages, including Polish. If that doesn't work, then there's a different issue which should be addressed independently. Git by default uses UTF-8 in most cases, and so does pretty much everything else on a Unix or Cygwin system.
If you really, absolutely insist upon using ISO-8859-2, then you'll need to set the i18n.logOutputEncoding to ISO-8859-2 so that it will render things in the proper character set. Note that if you have this set in one Git configuration (the Git Bash one) and not in the other (the Cygwin one), that will explain why you're seeing different behavior.
You may also want to set your system code page to UTF-8 by using chcp 65001 in a CMD window.

Working with UTF-8 encoded TCL files on windows

We try to convert the source files of a TCL/TK application to UTF-8, because this is the default charset of the plattforms we use for development (Linux and OSX).
Our problem is now that windows uses "cp1252" as system encoding, and because of this displays labels and buttons with (for example) german umlauts wrong.
The only solution we found yet would be to add "-encoding UTF-8" to all "wish" calls and "source" commands.
(There is also "encoding system UTF-8", but the documentation says that you shouldn't use it because of problems with system calls)
Is there a way to tell TCL that it should use UTF-8 as default encoding for all source files, or maybe another solution for this problem?
The solution suggested in the TCL chat:
Create and use your own versions of "open" und "source" (like "my_open" and "my_source") which then call the original commands with "-encoding utf-8"

Console isn't showing pretty characters in Shell

I want to write some pretty, special characters taken from Web in my Shell Console with echo command. I want to write, for example, ▲ character, but it shows me ��� character. How can I solve the problem? Thanks!
I am using Ubuntu 64 bit also. You should check your terminal type and what kind of character-set does it supports. Take a look at this
and this
You need to make sure you character sets match and that you are using the correct terminal emulation. This can be set on both the Linux side or using your terminal client software.
e.g. ANSI, VT100, Linux
Character sets like UTF-8 does include symbols.

Is there any way to prevent ncurses based programs from running?

Hey there, I'm building a remote shell server that interfaces between a text-only client and a virtual shell.
It works perfectly when using regular shell commands, but the first thing that people try after that is vim, which promptly drives my server crazy and can't even be closed remotely.
Is there any way to detect ncurses based programs and prevent them from running in my special shell?
(the server is ruby, but any system command will do)
You can declare the capabilities your shell has, by setting the TERM environment variable to the correct value. For instance, if your shell has the same capabilities as the vt100 terminal, export TERM to the correct value, and programs like vim will respect that.
To run vim in vt100-mode, try:
TERM=vt100 vim
You could also try:
export TERM=dumb
The trick is to find a terminal that corresponds to the capabilities of what you are creating. There is a lot to choose from. On my system (Arch Linux) this gives me a long list of choices:
find /usr/share/terminfo
You might be able to find a terminal specification that corresponds to what your program can handle.
Alternatively, you may want to consider implementing terminal emulation for ansi or vt100:
http://en.wikipedia.org/wiki/ANSI_escape_code
http://www.termsys.demon.co.uk/vtansi.htm
Best of luck!

Numeric keys not working in Bash Terminal (MacBook Pro)

I'm trying to push a rails app to my remote Heroku repository from a MacBook Pro using the Bash Terminal.
The remote repository address contains numeric characters which are stripped out as soon as I copy/paste "git#heroku.com:app-name-[numbers].git". If I try to type the numbers in manually, the comp just beeps.
Really stuck on this one!
You've got a terminal setup problem. First thing to try is simply to close down the terminal and restart; that'll be a fresh session.
If that doesn't work, carefully type the following
stty sane^J
or
^Jreset^J
to set it to something normal.
It sounds as if you're getting characters echoed at least, so that may be easy. The ^J characters are LINEFEED, which is the actual ASCII character used for newline in UNIX-based systems.

Resources