Share your knowledge at the LQ Wiki.
Go Back > Forums > Linux Forums > Linux - Desktop
User Name
Linux - Desktop This forum is for the discussion of all Linux Software used in a desktop context.


  Search this Thread
Old 12-08-2010, 07:44 AM   #1
LQ Newbie
Registered: Oct 2004
Location: Sofia,Bulgaria
Distribution: Slackware,FreeBSD
Posts: 11

Rep: Reputation: 0
Add new encoding to terminal

I am looking for a method to add new encoding to Gnome Terminal.
The encoding i want to add is MIK (Bulgarian DOS cyrillic encoding) and it is not found in Terminal -> Set character encoding -> Add or remove list.
Is there a way to add this encoding to the list ? Or is there some other terminal or telnet / ssh client which allows me to add encodings ?
Old 12-08-2010, 02:18 PM   #2
Registered: Dec 2010
Distribution: Arch
Posts: 115

Rep: Reputation: 21
In Konsole (KDE) I once "hacked" an encoding. Not really. Maybe I did it the wrong way, but it worked for me

The situation, somewhat over simplified

The server sends forms with mixed language (what would count as first level and third level on a modern system), but uses plain upper case and lower case text to encode it (so for example A=A and a=). And it also expects text to be typed the same way, but not exactly. Originally the system used some Windows 95 machines with custom built telnet client specially for this encoding, that took care of everything. Then I set up some more boxes running Linux to the network

What I did

Part 1 : Make copy of a layout file from /usr/share/X11/xkb/symbols/. Rename it indise and outside to a new locale name (for example "forms") or add a variant to an existing locale (anyway backup the file as you're going to screw it multiple times when experimenting). The file is a table matching characters to keyboard keys. Edit it and set what character you want each key to type in your application. Save and add this new layout to your keyboard layouts, so you can switch to it

Part 2 : Make copy of a font. Rename it inside and outside to a new name, change the "font family name" too. Open it with Fontforge, copy the characters you want to the new places (for example, copy to a), save and install. Configure Konsole to use this font

Part 3 : Instruct the user to switch to "the forms language" when using this application. Any key he types is changed to the correct code by the xkb file, and that's how it's submitted to the server. Any key appearing on the screen appeaars in the font you created, and the shape of the character is what you want the user to see


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
How to add custom encoding to KDE konsole? kofucii Linux - Newbie 1 09-18-2009 02:01 PM
gnome-terminal and character encoding problem guillaume31 Linux - Software 0 03-13-2006 09:09 AM
gnome-terminal wrong character encoding guillaume31 Linux - General 2 02-01-2006 09:04 AM
vi encoding/terminal problem ricky_ds Linux - Software 0 03-30-2005 08:20 AM
how to add mp3 encoding support on sarge? zero79 Debian 2 08-12-2004 06:02 PM > Forums > Linux Forums > Linux - Desktop

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

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