[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Japanese input in kon2



Leonardo,

> Greetings. By reading the archive of this list, I've been able to set 
> up Japanese input under X, and I'm very glad with that. But now I want
> to write with jvim-canna in kon2 too.
> 
> To input Japanese under kinput2 I need to press control-Kanji, but my
> keyboard don't have a Kanji key! Fortunately, I can run 
>  xmodmap -e 'keycode 115 = Kanji'
> to change that useless Windows key in a Kanji key. However, I don't know
> how to do this in the console.

 I use kon2, kinput2, and canna. This is how I set up things:

 I have a Japanese keyboard, and the key that I like to reymap has keycode 41.
 The keycode can be found out by running "showkey", from the 'console-tools'
 package. Just press the key, and you will find out the keycode.

 Now, I run the script jp-keyboard. This sets up the keymap for the keyboard.
 
 This is the line I added to jp106.kmap:
 keycode 41 = Control_backslash

 I modified the kmap for _my_ keyboard. These files are found in
 /usr/share/keymaps/. Pick your keyboard from there. Add the above lines to
 make *every* program understand your special sequence. You need not run
 xmodmap after that...

 It helps to keep jp-keyboard, and jp106.kmap in /etc/rc.boot, making
 jp-keyboard executable.
 
 The files are attached.
 :)
 
Vikram
-- 

http://www.mayin.org/~aragorn : オンライン 家, でも
2-3-13-203: 天国

#!/bin/sh
# To set the funny japanese key so that I don't have to do Ctrl \
/bin/loadkeys /etc/rc.boot/jp106.kmap
echo "Loaded the custom Taka keyboard"

# jp106.map : Japanese 106 keyboard keymap
#
# Date: Tue, 20 Aug 1996 16:15:31 +0900
# From: Hideya Hane <wing@aries.bekkoame.or.jp>
#
# Modified by Vikram <totoro@debian.org>
keymaps 0-1,4-5,8-9,12
alt_is_meta
include "qwerty-layout"
include "linux-with-two-alt-keys"
strings as usual
compose as usual for "iso-8859-1"

keycode   1 = Escape
keycode   2 = one              exclam
keycode   3 = two              quotedbl
keycode   4 = three            numbersign
	control	keycode   4 = Escape
keycode   5 = four             dollar
	control	keycode   5 = Control_backslash
keycode   6 = five             percent
	control	keycode   6 = Control_bracketright
keycode   7 = six              ampersand
	control	keycode   7 = Control_underscore
keycode   8 = seven            apostrophe
keycode   9 = eight            parenleft
keycode  10 = nine             parenright
keycode  11 = zero             asciitilde
	control	keycode  11 = nul
keycode  12 = minus            equal
keycode  13 = asciicircum      asciitilde
	control	keycode  13 = Control_asciicircum
keycode  14 = Delete
	control	keycode  14 = BackSpace
keycode  15 = Tab
keycode  26 = at               grave
	control	keycode  26 = nul
keycode  27 = bracketleft      braceleft
keycode  28 = Return
	alt	keycode  28 = Meta_Control_m
keycode  29 = Control
keycode  39 = semicolon        plus
keycode  40 = colon            asterisk
	control keycode  40 = Control_g

#
# This is the line that I added...
keycode  41 = Control_backslash
#
#
keycode  42 = Shift
keycode  43 = bracketright     braceright
	control	keycode  43 = Control_bracketright
keycode  51 = comma            less
keycode  52 = period           greater
	control	keycode  52 = Compose
keycode  53 = slash            question
	control	keycode  53 = Delete
	shift	control	keycode  53 = Delete
keycode  54 = Shift
keycode  56 = Alt
keycode  57 = space
	control	keycode  57 = nul
keycode  58 = Caps_Lock
keycode  86 = less             greater
keycode  89 = backslash        underscore
	control	keycode  89 = Control_backslash
keycode  92 = space
keycode  94 = space
keycode  97 = Control
keycode 124 = backslash        bar
	control	keycode 124 = Control_backslash

Attachment: pgpXY2_7FAGkM.pgp
Description: PGP signature


Reply to: