xvnkb
revisited .


http://wangji.hoan.googlepages.com/xvnkb-0.2.9-ntdt-wj-0-2.noarch.rpm

http://wangji.hoan.googlepages.com/xvnkb-0.2.9-ntdt-wj.deb

http://wangji.hoan.googlepages.com/xvnkb-0.2.9-ntdt-wj.tgz

  Install one of the above package allows using xvnkb on any distro
including recent livecd (having unionfs or aufs installed ).

Description: Vietnamese input keyboard xvnkb  for ubuntu-hardy heron
 xvnkb built by ntdt in 2005 is good enough for any linux;just learn to
use it correctly ,no need to recompile !
  1 export correct locale   en_US.utf8  which is standard in
locale.archive (type "locale -a" to get them all )
  2 set correct XMODIFIERS="@im=xvnkb" not to be mixed up with
XMODIFIERS="@im=xim or none" at least for ubuntu-8.04
    this avoid disappearing character when typing complex composed vowel
( o^? for ex)
  3  xvnkb cannot ,will never be able to run system wide ,so why setting
up /etc/ld.so.preload to contain xvnkb.so.0.2.9 ?
    Remove this /etc/ld.so.preload ! nobody uses such thing on any
distro now ;use it locally in a wrapper like
    xvnkb_wrapper ! It is far more safer ,and do not create stupid side
effects -troubles on other items in system-
     As hamradio people says K.I.S.S.  !!!  give a kiss !! Keep It
Simple Stupid  !
 we take that into account when creating the icons on Desktop to start
most apps like gedit or oowriter using xvnkb
 

        Điều kiện thử nghiệm  : chạy livecd ubuntu-8.04  clic install
xvnkb-0.2.9-ntdt-wj.deb


                                     I  Thí nghiệm với locale

Trước khi thử ,nhớ tắt hết gedit và xvnkb đã chạy ,thì mới có môi trường
dễ tái diễn ( reproducible environment ) .
 Kiểm tra môi trường với lệnh env  , locale  
 Từ user_terminal  gõ :
                             $ ./xvnkb_wrapper  gedit 
  nhớ quan sát popup_xvnkb_thông_báo : mising locale en_US.utf8  ,tuy
rằng gõ trong gedit tiếng việt vẫn ngon lành !

 Tạo lỗi với locale ,bằng cp xvnkb_wrapper  xvnkb_wrapper_UTF  rồi sửa
trong xvnkb_wrapper_UTF dòng
  export LANG=en_US.utf8   thành    export  LANG=en_US.UTF-8
 Tắt xvnkb ,gedit rồi hãy 
               chạy thử  $ ./xvnkb_wrapper_UTF  gedit   thì thấy báo
lỗi ... và vẫn gõ được chữ việt  !  

Nhưng nếu thay thành export LANG=en_US  thôi  ... thì báo lỗi không gõ
unicode .. 
và lúc gõ ký tự kép thì đều mất chữ cursor chạy giật lùi  ..giống hệt
trường hợp vừa có xvnkb_on và unikey/scim active  !!!!!

                                  II  thí nghiệm với XMODIFIERS

  Cóp  cp xvnkb_wrapper  xvnkb_wrapper_XMOD   rồi trong tệp
xvnkb_wrapper_XMOD  "comment out" chèn dấu # vào đầu dòng có
XMODIFIERS  ,tức là 
        export XMODIFIERS="@im=xvnkb"  biến thành  #export
XMODIFIERS="@im=xvnkb"
 Tắt xvnkb ,gedit rồi 
         chạy  $./xvnkb_wrapper_XMOD gedit  
  khi gõ chữ việt lại xảy ra chuyện mất dấu ,,đi giật lùi  !!!!!! ở đây
lý do là xung đột giữa xim của ubuntu đã mặc định cài trong livecd  và
xvnkb !



 xvnkb_wrapper :
  
#!/bin/sh
export LANG=en_US.utf8
export LD_PRELOAD=/usr/local/lib/xvnkb.so.0.2.9
export XMODIFIERS="@im=xvnkb"
xvnkb &
if [ -e /usr/bin/\$1 ] ; then
/usr/bin/\$1
fi

                                     Đôi lời về ld.so.preload

  Cái đó tự nạp trước -preload - thư viện di động . Bất cứ trình nào
khởi động dù không liên quan chi tới xvnkb nó cũng nạp !  Đó là hành
động system-wide  : hết sức vô lý  . Dĩ nhiên có thể giải quyết tránh
rắc rối như " ld-preload-manager...
nhưng dùng giải pháp thêm để tránh rắc rối  ... thì như dùng lý thuyết
nhóm để chia bánh trưng ngày tết cho gia đình !
  Vứt cái system-wide ld.so.preload ,rồi dùng preload local thôi ,xvnkb
không thiếu thốn chi để hoạt động tốt ( y hệt )
                                     $  xvnkb_wrapper
bất_kỳ_apps_nào_cũng_được   
 kể cả  konqueror  ,kate... firefox  ...và apps không chạy với xvnkb
  đều không vấn đề : môi trường cần cho xvnkb chỉ nằm trong thao tác
đó !

   Lời cuối  xvnkb -ntdt  2005 trên sfnet  biên dịch với glibc2.2  cũng
chạy với glibc2.4   .Tronh khi các biên dịch mới của
xvnkb với glibc2.4  không thể chạy đuợc với các linux cũ kỹ   !!!!
Chỉ cần giữ lại  xvnkb và xvnkb.so.0.2.9  hồi 2005 của ntdt



-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft 
Defy all challenges. Microsoft(R) Visual Studio 2008. 
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
VietLUG-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/vietlug-users

Trả lời cho