[kwlug-disc] Vim with unicode ...

William Park opengeometry at yahoo.ca
Sat Nov 30 23:52:27 EST 2024


No problem here also.

$ locale
LANG=en_US.UTF-8
LC_CTYPE="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_COLLATE=C
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_PAPER="en_US.UTF-8"
LC_NAME="en_US.UTF-8"
LC_ADDRESS="en_US.UTF-8"
LC_TELEPHONE="en_US.UTF-8"
LC_MEASUREMENT="en_US.UTF-8"
LC_IDENTIFICATION="en_US.UTF-8"
LC_ALL=

$ echo $TERM
xterm-256color

My terminal is Konsole: View -> Set Encoding -> Unicode -> UTF-8
-- 

On 2024-11-30 19:47, Doug Moen wrote:
> I type funny characters like ° into vim all the time, even over ssh.
> 
> This environment variable might be relevant:
> LANG=en_CA.UTF-8
> 
> Vim needs to know that the character encoding is UTF-8.
> 
> On Sun, Dec 1, 2024, at 12:33 AM, Khalid Baheyeldin wrote:
>> I am having a problem with special characters in Vim.
>>
>> The background: InfluxDB has "measurements" instead
>> of tables in relational databases. A measurement is
>> usually named after the unit, e.g. degrees, %, ...etc
>>
>> Degrees here is for celsius, and it is an actual degree
>> unicode (hex c0b2).
>>
>> When I try to edit a script that has the this in it, vim
>> loses its position and display in any characters after
>> the special character.
>>
>> To illustrate this, copy this line from Pastebin, into
>> a file:
>> https://pastebin.com/8aaXZirA <https://pastebin.com/8aaXZirA>
>> Then search for the number 3, and substitute it
>> with a string, e.g abc.
>>
>> Then press Ctrl L, and you will see that vim is no
>> at the correct character visually.
>>
>> If I edit the same file in Mousepad, everything is
>> as it should be. But that is a GUI application not
>> a CLI one on a remote terminal.
>>
>> Anyone else facing this issue?
>> What is your $TERM variable set to?
>> Any special configuration for vim or the terminal?
>>
>> --
>> Khalid M. Baheyeldin
>> _______________________________________________
>> kwlug-disc mailing list
>> To unsubscribe, send an email to kwlug-disc-leave at kwlug.org 
>> <mailto:kwlug-disc-leave at kwlug.org>
>> with the subject "unsubscribe", or email
>> kwlug-disc-owner at kwlug.org <mailto:kwlug-disc-owner at kwlug.org> to 
>> contact a human being.
>>
> 
> 
> _______________________________________________
> kwlug-disc mailing list
> To unsubscribe, send an email to kwlug-disc-leave at kwlug.org
> with the subject "unsubscribe", or email
> kwlug-disc-owner at kwlug.org to contact a human being.




More information about the kwlug-disc mailing list