jeromejj / vim

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

same normal cmds on linux and windows #150

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1.Open the file fileinlinux (attached) in vim :
2.Execute the vim command 

    :%no<S-Tab>!Y6r gw}Vp<CR>

3.after the command the result file fileoutlinux is attached

What is the expected output? What do you see instead?
The command works well on linux but not on windows.
I will update the issue with windows version of in and out files.

What version of the product are you using? On what operating system?
7.4a.024 on linux , 7.4a.023 on windows

Please provide any additional information below.

VIM - Vi IMproved 7.4a BETA (2013 Jul 6, compiled Jul 16 2013 01:39:07)
Included patches: 1-24
Compiled by root@g_VBox_xubuntu
Huge version without 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      -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
+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: "$VIM/vimrc"
     user vimrc file: "$HOME/.vimrc"
 2nd user vimrc file: "~/.vim/vimrc"
      user exrc file: "$HOME/.exrc"
  fall-back for $VIM: "/usr/local/share/vim"
Compilation: gcc -c -I. -Iproto -DHAVE_CONFIG_H   -I/usr/local/include  -g -O2 
-U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1
Linking: gcc   -L/usr/local/lib -Wl,--as-needed -o vim        -lm -ltinfo -lnsl 
 -ldl

Original issue reported on code.google.com by Zulolox4...@gmail.com on 16 Jul 2013 at 12:26

Attachments:

GoogleCodeExporter commented 9 years ago
In windows the input file : fileinwin32 and output, after command: 
fileoutwin32, attached.

The  vim win32 version tested on:

VIM - Vi IMproved 7.4a BETA (2013 Jul 6, compiled Jul 14 2013 14:36:09)
MS-Windows 32-bit console version
Included patches: 1-23
Compiled by g_user@os-PC-WIN7-64
Huge version without GUI.  Features included (+) or not (-):
+arabic          +cmdline_info    -ebcdic          -gettext         +localmap   
     +path_extra      -ruby            -tag_any_white   +visualextra
+autocmd         +comments        +emacs_tags      -hangul_input    -lua        
     -perl            +scrollbind      -tcl             +viminfo
-balloon_eval    +conceal         +eval            +iconv/dyn       +menu       
     +persistent_undo +signs           -tgetent         +vreplace
-browse          +cryptv          +ex_extra        +insert_expand   +mksession  
     -postscript      +smartindent     -termresponse    +wildignore
++builtin_terms  +cscope          +extra_search    +jumplist        
+modify_fname    +printer         -sniff           +textobjects     +wildmenu
+byte_offset     +cursorbind      +farsi           +keymap          +mouse      
     +profile         +startuptime     +title           +windows
+cindent         +cursorshape     +file_in_path    +langmap         -mouseshape 
     -python          +statusline      -toolbar         +writebackup
+clientserver    +dialog_con      +find_in_path    +libcall         +multi_byte 
     -python3         -sun_workshop    +user_commands   -xfontset
+clipboard       +diff            +float           +linebreak       +multi_lang 
     +quickfix        +syntax          +vertsplit       -xim
+cmdline_compl   +digraphs        +folding         +lispindent      -mzscheme   
     +reltime         +tag_binary      +virtualedit     -xterm_save
+cmdline_hist    -dnd             -footer          +listcmds        
-netbeans_intg   +rightleft       +tag_old_static  +visual          -xpm_w32
   system vimrc file: "$VIM\vimrc"
     user vimrc file: "$HOME\_vimrc"
 2nd user vimrc file: "$HOME\vimfiles\vimrc"
 3rd user vimrc file: "$VIM\_vimrc"
      user exrc file: "$HOME\_exrc"
  2nd user exrc file: "$VIM\_exrc"
Compilation: cl -c /W3 /nologo  -I. -Iproto -DHAVE_PATHDEF -DWIN32   
-DFEAT_CSCOPE       -DWINVER=0x0400 -D_WIN32_WINNT=0x0400  /Fo.\ObjCi386/ /Ox 
/GL -DNDEBUG
 /Zl /MT -DFEAT_MBYTE -DDYNAMIC_ICONV -DFEAT_HUGE /Fd.\ObjCi386/ /Zi
Linking: link /RELEASE /nologo /subsystem:console /LTCG:STATUS oldnames.lib 
kernel32.lib advapi32.lib shell32.lib gdi32.lib  comdlg32.lib ole32.lib 
uuid.lib /ma
chine:i386 /nodefaultlib  libcmt.lib   user32.lib             /PDB:vim.pdb 
-debug

Original comment by Zulolox4...@gmail.com on 16 Jul 2013 at 12:36

Attachments:

GoogleCodeExporter commented 9 years ago
I can't reproduce the problem. On Windows 7.3.822 using your command, I get the 
same text you got in Linux.

Actually, you missed a step. You need to set autoindent before running your 
command.

Also, your result depends on either the value of 'textwidth', or the window 
size if 'textwidth' is zero. Are you sure your 'textwidth' setting is the same 
in each instance? How about the window size? What does ":set columns?" say in 
each of your Vims?

That's a clever way to add a hanging indent, by the way. I'll need to remember 
that.

But note, maybe you just want to set up 'formatlistpat' instead, and set fo+=n.

Original comment by fritzoph...@gmail.com on 16 Jul 2013 at 4:25

GoogleCodeExporter commented 9 years ago
I tested with vim 7.3.822 on win7 this config:
:ver
VIM - Vi IMproved 7.3 (2010 Aug 15, compiled Jul 17 2013 03:39:13)
MS-Windows 32-bit console version
Included patches: 1-822
Compiled by g_user7@win7-PC
Huge version without GUI.  Features included (+) or not (-):
+arabic +autocmd -balloon_eval -browse ++builtin_terms +byte_offset +cindent 
+clientserver +clipboard +cmdline_compl +cmdline_hist +cmdline_info +comments
+conceal +cryptv +cscope +cursorbind +cursorshape +dialog_con +diff +digraphs 
-dnd -ebcdic +emacs_tags +eval +ex_extra +extra_search +farsi +file_in_path
+find_in_path +float +folding -footer -gettext -hangul_input +iconv/dyn 
+insert_expand +jumplist +keymap +langmap +libcall +linebreak +lispindent 
+listcmds
+localmap -lua +menu +mksession +modify_fname +mouse -mouseshape +multi_byte 
+multi_lang -mzscheme -netbeans_intg +path_extra -perl +persistent_undo
-postscript +printer +profile -python -python3 +quickfix +reltime +rightleft 
-ruby +scrollbind +signs +smartindent -sniff +startuptime +statusline
-sun_workshop +syntax +tag_binary +tag_old_static -tag_any_white -tcl -tgetent 
-termresponse +textobjects +title -toolbar +user_commands +vertsplit
+virtualedit +visual +visualextra +viminfo +vreplace +wildignore +wildmenu 
+windows +writebackup -xfontset -xim -xterm_save -xpm_w32
   system vimrc file: "$VIM\vimrc"
     user vimrc file: "$HOME\_vimrc"
 2nd user vimrc file: "$VIM\_vimrc"
      user exrc file: "$HOME\_exrc"
  2nd user exrc file: "$VIM\_exrc"
Compilation: cl -c /W3 /nologo  -I. -Iproto -DHAVE_PATHDEF -DWIN32   
-DFEAT_CSCOPE       -DWINVER=0x0400 -D_WIN32_WINNT=0x0400  /Fo.\ObjCi386/ /Ox 
/GL -DNDEBUG
 /Zl /MT -DFEAT_MBYTE -DDYNAMIC_ICONV -DFEAT_HUGE /Fd.\ObjCi386/ /Zi
Linking: link /RELEASE /nologo /subsystem:console /LTCG:STATUS oldnames.lib 
kernel32.lib advapi32.lib shell32.lib gdi32.lib  comdlg32.lib ole32.lib 
uuid.lib /ma
chine:i386 /nodefaultlib  libcmt.lib   user32.lib             /PDB:vim.pdb 
-debug

vimrc file used:

" http://vimdoc.sourceforge.net/htmldoc/starting.html#vimrc

set nocompatible        " use vim defaults
set scrolloff=3         " keep 3 lines when scrolling
set ai                  " set auto-indenting on for programming

set showcmd             " display incomplete commands
set nobackup            " do not keep a backup file
set number              " show line numbers
set ruler               " show the current row and column

set hlsearch            " highlight searches
set incsearch           " do incremental searching
set showmatch           " jump to matches when entering regexp
set ignorecase          " ignore case when searching
set smartcase           " no ignorecase if Uppercase char present

set visualbell t_vb=    " turn off error beep/flash
set novisualbell        " turn off visual bell

set backspace=indent,eol,start  " make that backspace key work the way it should

syntax on               " turn syntax highlighting on by default
filetype on             " detect type of file
filetype indent on      " load indent file for specific file type

set t_RV=               " http://bugs.debian.org/608242, 
http://groups.google.com/group/vim_dev/browse_thread/thread/9770ea844cec3282

After executed the vim normal command on fileinwin32 input file:

 :%no<S-Tab>!Y6r gw}Vp<CR>

  with the config above, in last paragraph of buffer, the word "BL" is repeated on the next line  and "connotation" is pushed on next line.

Also, I used this line windows command to start vim:
      vim -u NONE -U NONE fileinwin32
In this case the paragraphs are not indented, but word "BL," is added, after 
execution of vim normal command, and the word "BL," appears two times. 

Original comment by Zulolox4...@gmail.com on 17 Jul 2013 at 2:29

GoogleCodeExporter commented 9 years ago
I can't see a difference, starting from vim -u NONE -N --cmd ':set autoindent' 
and 1 80 column wide window in Windows and 1 80 column wide window in Linux. 
Therefore closing as invalid.

Original comment by chrisbr...@googlemail.com on 11 Oct 2014 at 8:44