pvk7 / vim

Automatically exported from code.google.com/p/vim
0 stars 0 forks source link

Character won't map: "–" (U+2013, EN DASH) #169

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Define a key on your keyboard to produce "–", e.g. the Print-Key:
   xmodmap -e "keysym Print = endash"
2. Run "vim -N -u NONE -U NONE -i NONE"
3. :nmap – i
4. Try to enter insert mode by pressing "–" (i.e. the remapped Print-Key from 
above).

What is the expected output? What do you see instead?

You should enter insert mode, instead nothing happens.

What version of the product are you using? On what operating system?

$ vim --version
VIM - Vi IMproved 7.4 (2013 Aug 10, compiled Aug 13 2013 20:48:15)
Compiled by Arch Linux
Huge version with GTK2 GUI.  Features included (+) or not (-):
+arabic          +file_in_path    +mouse_sgr       +tag_binary
+autocmd         +find_in_path    -mouse_sysmouse  +tag_old_static
+balloon_eval    +float           +mouse_urxvt     -tag_any_white
+browse          +folding         +mouse_xterm     -tcl
++builtin_terms  -footer          +multi_byte      +terminfo
+byte_offset     +fork()          +multi_lang      +termresponse
+cindent         +gettext         -mzscheme        +textobjects
+clientserver    -hangul_input    +netbeans_intg   +title
+clipboard       +iconv           +path_extra      +toolbar
+cmdline_compl   +insert_expand   +perl            +user_commands
+cmdline_hist    +jumplist        +persistent_undo +vertsplit
+cmdline_info    +keymap          +postscript      +virtualedit
+comments        +langmap         +printer         +visual
+conceal         +libcall         +profile         +visualextra
+cryptv          +linebreak       +python          +viminfo
+cscope          +lispindent      -python3         +vreplace
+cursorbind      +listcmds        +quickfix        +wildignore
+cursorshape     +localmap        +reltime         +wildmenu
+dialog_con_gui  +lua             +rightleft       +windows
+diff            +menu            +ruby            +writebackup
+digraphs        +mksession       +scrollbind      +X11
+dnd             +modify_fname    +signs           -xfontset
-ebcdic          +mouse           +smartindent     +xim
+emacs_tags      +mouseshape      -sniff           +xsmp_interact
+eval            +mouse_dec       +startuptime     +xterm_clipboard
+ex_extra        +mouse_gpm       +statusline      -xterm_save
+extra_search    -mouse_jsbterm   -sun_workshop    
+farsi           +mouse_netterm   +syntax          
   system vimrc file: "/etc/vimrc"
     user vimrc file: "$HOME/.vimrc"
 2nd user vimrc file: "~/.vim/vimrc"
      user exrc file: "$HOME/.exrc"
  system gvimrc file: "/etc/gvimrc"
    user gvimrc file: "$HOME/.gvimrc"
2nd user gvimrc file: "~/.vim/gvimrc"
    system menu file: "$VIMRUNTIME/menu.vim"
  fall-back for $VIM: "/usr/share/vim"
Compilation: gcc -c -I. -Iproto -DHAVE_CONFIG_H -DFEAT_GUI_GTK  -pthread 
-I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/pango-1.0 
-I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pixman-1 
-I/usr/include/libdrm -I/usr/include/libpng16 -I/usr/include/gdk-pixbuf-2.0 
-I/usr/include/libpng16 -I/usr/include/pango-1.0 -I/usr/include/harfbuzz 
-I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include 
-I/usr/include/freetype2  -D_FORTIFY_SOURCE=2 -I/usr/local/include  
-march=x86-64 -mtune=generic -O2 -pipe -fstack-protector 
--param=ssp-buffer-size=4 -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1      
Linking: gcc   -L. -Wl,-O1,--sort-common,--as-needed,-z,relro -fstack-protector 
-rdynamic -Wl,-export-dynamic -Wl,-E -Wl,-rpath,/usr/lib/perl5/core_perl/CORE  
-Wl,-O1,--sort-common,--as-needed,-z,relro -L/usr/local/lib -Wl,--as-needed -o 
vim   -lgtk-x11-2.0 -lgdk-x11-2.0 -lpangocairo-1.0 -latk-1.0 -lcairo 
-lgdk_pixbuf-2.0 -lgio-2.0 -lpangoft2-1.0 -lpango-1.0 -lgobject-2.0 -lglib-2.0 
-lfreetype -lfontconfig  -lSM -lICE -lXt -lX11 -lXdmcp -lSM -lICE  -lm 
-lncurses -lnsl   -lacl -lattr -lgpm -ldl  -L/usr/lib -llua -Wl,-E 
-Wl,-rpath,/usr/lib/perl5/core_perl/CORE 
-Wl,-O1,--sort-common,--as-needed,-z,relro -fstack-protector -L/usr/local/lib  
-L/usr/lib/perl5/core_perl/CORE -lperl -lnsl -ldl -lm -lcrypt -lutil -lpthread 
-lc -L/usr/lib/python2.7/config -lpython2.7 -lpthread -ldl -lutil -lm -Xlinker 
-export-dynamic   -lruby -lpthread -lrt -ldl -lcrypt -lm  -L/usr/lib   

Please provide any additional information below.

The problematic character is "–" (U+2013, "EN DASH").

It does work, when the lefthandside of the mapping contains something else as 
the first character: "nmap 0– i" makes you enter insert mode when entering 
0–.

Mapping other unicode characters has always worked fine, e.g. "nmap ¿ i" makes 
¿ enter insert mode.

Original issue reported on code.google.com by reof...@gmail.com on 15 Sep 2013 at 5:13

GoogleCodeExporter commented 9 years ago
This may be related to a wide set of problems with mapping[ to] strings 
containing 0x80 byte: EN DASH is 0xE2, *0x80*, 0x93; ¿ is 0xC2, 0xBF.

Original comment by zyx....@gmail.com on 16 Sep 2013 at 3:21

GoogleCodeExporter commented 9 years ago
I have the same issue and would also be interested in a solution or workaround, 
once one is found.

Original comment by janchris...@gmail.com on 14 Nov 2013 at 4:13

GoogleCodeExporter commented 9 years ago
I think this has been already fixed by 7.4.204.

Original comment by ktakata6...@gmail.com on 1 Oct 2014 at 12:15

GoogleCodeExporter commented 9 years ago

Original comment by chrisbr...@googlemail.com on 1 Oct 2014 at 5:01