Re: Convert2HTML Again
Does that mean that you are waiting for Bram to give his blessing? Na, just that it's not my decision to make. I'll just do the code. Best Regards Edd
Re: [macvim] modifiers should be applied to special keys too (patch)
On Sunday, September 24 at 08:46 PM, quoth Nicolas Weber: here's a patch to current svn that applies modifier keys (shift, ctrl, cmd etc) to special keys as well. With this patch, Shift-Left/ Right work and some of the mapping problems some people complained about on [EMAIL PROTECTED] should be fixed too. HUZZAH! This is fantastic! (I use ctrl-/ as a mapping for :nohlsearch, and I've been sorely missing it in MacVim.) Please test this patch and tell me about any regressions you find. Well, I get these errors: gui_mac.c:2018: warning: return type defaults to 'int' gui_mac.c: In function 'gui_mac_doKeyEventCarbon': gui_mac.c:2097: warning: suggest parentheses around within || gui_mac.c: In function 'gui_mch_init': gui_mac.c:3081: warning: passing argument 1 of 'NewEventHandlerUPP' from incompatible pointer type I haven't noticed any regressions, but I'll keep my eyes open. ~Kyle -- A tyrant must put on the appearance of uncommon devotion to religion. Subjects are less apprehensive of illegal treatment from a ruler whom they consider God-fearing and pious. On the other hand, they do less easily move against him, believing that he has the gods on his side. -- Aristotle pgpql866h2Vw2.pgp Description: PGP signature
Re: Convert2HTML Again
On Sun, 2006-09-24 at 16:41 +0200, A.J.Mechelynck wrote: Steve Hall wrote: On Sun, 2006-09-24 at 00:31 +0200, Michael Schaap wrote: I beg you, please don't hardcode Courier New! [snip] It's not just the proper way, it's the first thing discussed in the specification: http://www.w3.org/TR/REC-CSS2/fonts.html#font-specification It is said nowhere in that document that a generic-family should be the only element in a font-face specification. [snip] In fact that W3C document mentions selecting a font by a single string only to dismiss it as inappropriate because of lack of standardization. My point was that the generic families were designed for an obvious reason...to fall back to something that works everywhere. Why wouldn't we want Vim to work just this way? Designers, not converters, should select font faces. If the converter is going to attempt to select one, than it had better do a good job of understanding what platform I am writing for, what fonts are available for that platform, and selecting one that follows my intentions within all the details of that specification. -- Steve Hall [ digitect dancingpaper com ]
Re: Convert2HTML Again
[Resending because Thunderbird sent the original email in HTML, which vim.org promptly bounced. Grrr.] Steve Hall wrote: On Sun, 2006-09-24 at 16:41 +0200, A.J.Mechelynck wrote: Steve Hall wrote: On Sun, 2006-09-24 at 00:31 +0200, Michael Schaap wrote: I beg you, please don't hardcode Courier New! [snip] It's not just the proper way, it's the first thing discussed in the specification: http://www.w3.org/TR/REC-CSS2/fonts.html#font-specification It is said nowhere in that document that a generic-family should be the only element in a font-face specification. [snip] In fact that W3C document mentions selecting a font by a single string only to dismiss it as inappropriate because of lack of standardization. My point was that the generic families were designed for an obvious reason...to fall back to something that works everywhere. Why wouldn't we want Vim to work just this way? Designers, not converters, should select font faces. If the converter is going to attempt to select one, than it had better do a good job of understanding what platform I am writing for, what fonts are available for that platform, and selecting one that follows my intentions within all the details of that specification. Whatever is chosen should be compatible with CSS, allowing the designer to specify a font for pre or #vim-pre (or whatever the class is). -- /George V. Reilly [EMAIL PROTECTED] http://www.georgevreilly.com/blog The biggest mistake is not learning from all your other mistakes.
Re: Plain TeX support ?
From: Benji Fisher [EMAIL PROTECTED] Subject: Re: Plain TeX support ? Date: Sat, 23 Sep 2006 15:16:00 -0400 On Sat, Sep 23, 2006 at 06:54:29AM +0200, Meino Christian Cramer wrote: Hi, Looking into :help \TeX\ does not that much information about the support of generating nice and find documents via plain TeX. Where can I get informations about what I can do/download/install/read to get a TeX-support a la AucTeX for Emacs ? Keep hacking! mcc That is an odd looking use of :help . Perhaps you meant to try :helpgrep \TeX\ instead? Note that the tex file type is for LaTeX and plaintex is used for plain TeX. See :help ft-tex-plugin if your plain TeX files are given file type tex. (I am assuming you are using vim 7. Correct me if I am wrong!) The default ftplugin/plaintex.vim does a few things: it sets options so that \input files will be recognized for include-file searches (:help include-search) and comments are recognized as such. What are the three features you miss most from AucTeX? HTH --Benji Fisher Hi Benji ! Thanks a lot for your reply and pointing me to the right help. I will see, what the plugin does for me and will post again in case of missing a certain thing (AucTeX-related or not :) Have a nice Sunday! mcc
To be a keycode or not to be a keycode - that is the question!
Hi, VimTip 979 suggests to do the following mapping: nmap Space / nmap C-Space ? . I wanted to try that and wrote the sequence into my .vimrc. The first mapping works nice, but the second doesn nothing. I tried to figure out what happens (or what do not happen...) and used the Ctrl-k trick I learnd here. But it shows that the problem is some levels down. I used xkeycaps and it shows, that Ctrl-Space isn't recognized at all and Shift-Space does the same as Space. Before I shoot into my own feet and render my computer useless by screwing up the keyboard interface: 1.) Is it possible and sane to map S-Space and C-Space to something (and what ?) with xkeycaps ? 2.) Or is it a more general problem, that those combination of keys aren't recognized correctly ? Thank you very much in advance for any help in advance ! mcc
Re: latin1 words in an utf-8 file
Hi Yakov, * Yakov Lerner on Saturday, September 23, 2006 at 21:01:30 +0300: If you can do the following two steps, then you'll achieve what you want to obtain: 1) write your own decoder/encoder from/to your mixed utf-8+latin format (in perl, C or in whatever language) that just reads stdin and writes to stdout 2) setup autocmds analogously to of :help hex-editing Then it will work. But. The real prolem is how the decoder would know which bytes are latin1 vs which bytes are utf-8. The same problem the encoder will have. You can solve it if you define 2 special quoting chars as markup chars that delimit latin1 parts. For simple stuff \caps{latin1} would suffice. But in the real virtual world it's easier to read from differently encoded files by LaTeX' \input{latin1-file}. Looking for special quoting chars, encoder and decoder can do their work. Without quoting chars markup, it is impossible. Ok ? Ok ;) See also my reply to Tony. Yakov set ignorecase Lerner Thanks. dirty note c -- _B A U S T E L L E N_ lesen! --- http://www.blacktrash.org/baustellen.html
Re: latin1 words in an utf-8 file
Hi Tony, * A.J.Mechelynck on Saturday, September 23, 2006 at 17:35:25 +0200: Christian Ebert wrote: * A.J.Mechelynck on Saturday, September 23, 2006 at 09:57:40 +0200: #1. cat file1.utf8.txt file2.latin1.txt file3.utf8.txt file99.utf8.txt will produce invalid output unless the Latin1 input file is actually 7-bit US-ASCII. This is not a limitation of the cat program (which inherently never translates anything) but a false manoeuver on the part of the user. Hm, I want illegal stuff, hehe. Then don't use UTF-8 files. Yup. Basically I can't edit files with mixed encodings. What fooled me was that if I do in an utf-8 environment: $ echo 'Vögel' file-utf8.txt and then illegally: $ echo 'Vögel' | iconv -f utf-8 -t iso-8859-1 file-utf8.txt $ vim file-utf8.txt Vim then decides to convert to latin1 automatically for representation: #v+ Vögel Vögel #v- Makes sense as Vim considers 'ö' as legal latin1 chars. And apparently there is no way to force Vim in a less sensible way ;) like to represent the illegal chars with a placeholder. Blinded by my (dirty workaround) purpose I hoped for a way to force Vim /not/ to convert. #2. gvim :if tenc == | let tenc = enc | endif :set enc=utf-8 fencs=utf-bom,utf-8,latin1 ucs-bom :e ++enc=utf-8 file1.utf8.txt :$r ++enc=latin1 file2.latin1.txt :$r ++enc=utf-8 file3.utf-8.txt :saveas file99.utf8.txt Then file99.utf8.txt is the same as the one produced with the cat command. Which is actually what I want. No. It is what the one produced with the cat command should have been, with the Latin1 accented characters properly converted to UTF-8. You are right, of course. To summarize: I tried to work around a shortcoming in a LaTeX package (it can't parse utf input). For my purposes the easiest workaround would have been the dirtiest: [LaTeX pseudo-code] #v+ \usepackage[utf8]{inputenc} \usepackage{soul}% - the package in question Loads of legal utf-8 text ... \begingroup\inputencoding{latin1} \caps{short text in illegal iso-8859-1} \endgroup Loads of legal utf-8 text ... #v- This does not work in one file if I want to continue to edit the loads of legal utf-8 text in Vim. In the above simple case I could do: $ voeg=`echo 'Vögel' | iconv -f utf-8 -t iso-8859-1`; \ sed -i~ -e s/\\caps{.*}/\\caps{$voeg}/ file-utf8.tex to get the result (LaTeX output) I wanted. Or I could write the group around \caps in a latin1 file and \input it, or decide to switch to a latin1 environment ... ... or rewrite the LaTeX-package to accept utf-8 encoding -- which would be the cleanest solution, but unfortunately over my head ATM. So, what I had in mind was too dirty (for Vim). Thanks for taking your time, Tony. c -- _B A U S T E L L E N_ lesen! --- http://www.blacktrash.org/baustellen.html
Re: To be a keycode or not to be a keycode - that is the question!
On 9/24/06, Meino Christian Cramer [EMAIL PROTECTED] wrot Hi, VimTip 979 suggests to do the following mapping: nmap Space / nmap C-Space ? . I wanted to try that and wrote the sequence into my .vimrc. The first mapping works nice, but the second doesn nothing. I tried to figure out what happens (or what do not happen...) and used the Ctrl-k trick I learnd here. But it shows that the problem is some levels down. I used xkeycaps and it shows, that Ctrl-Space isn't recognized at all and Shift-Space does the same as Space. Before I shoot into my own feet and render my computer useless by screwing up the keyboard interface: 1.) Is it possible and sane to map S-Space and C-Space to something (and what ?) with xkeycaps ? Try 'man xmodmap'. The following actions can/will lead to the solution: 1) Choose new unique escap-sequence, unused by other control keys; for example Esc)1 (I don't really know if this is unique...) 2) Tell xmodmap to send this key sequence for Ctrl-Space 3) In vim, map Esc)1 to the rhs of your choice. Repeat for Shift-space. Note that in this scenario, vim doesn't really know that Esc)1 is Ctrl-Space, but nevertheless the whose conspiracy works. Hope it helps Yakov ignorecase Lerner
Re: To be a keycode or not to be a keycode - that is the question!
From: Yakov Lerner [EMAIL PROTECTED] Subject: Re: To be a keycode or not to be a keycode - that is the question! Date: Sun, 24 Sep 2006 15:20:44 +0300 On 9/24/06, Meino Christian Cramer [EMAIL PROTECTED] wrot Hi, VimTip 979 suggests to do the following mapping: nmap Space / nmap C-Space ? . I wanted to try that and wrote the sequence into my .vimrc. The first mapping works nice, but the second doesn nothing. I tried to figure out what happens (or what do not happen...) and used the Ctrl-k trick I learnd here. But it shows that the problem is some levels down. I used xkeycaps and it shows, that Ctrl-Space isn't recognized at all and Shift-Space does the same as Space. Before I shoot into my own feet and render my computer useless by screwing up the keyboard interface: 1.) Is it possible and sane to map S-Space and C-Space to something (and what ?) with xkeycaps ? Try 'man xmodmap'. The following actions can/will lead to the solution: 1) Choose new unique escap-sequence, unused by other control keys; for example Esc)1 (I don't really know if this is unique...) 2) Tell xmodmap to send this key sequence for Ctrl-Space 3) In vim, map Esc)1 to the rhs of your choice. Repeat for Shift-space. Note that in this scenario, vim doesn't really know that Esc)1 is Ctrl-Space, but nevertheless the whose conspiracy works. Hope it helps Yakov ignorecase Lerner Hi Yakov, Thank you for your reply! :) There is only one thing remaining mysterious: Why do I have to hack my keyboard settings, when others (at least the author of the vimtip 979) can simply use that? Is this a difference between Unix/Windows/MacOSX or is it just my flavour of keyboard settings? Keep hacking! mcc Meino I have CTRL-Space now! Cramer :)
Re: latin1 words in an utf-8 file
Christian Ebert wrote: [...] My terminal font has the necessary glyphs as well. That's not the problem. I can read your homepage fine with w3m console text browser. My terminal displays utf just fine. The following: #v+ Vögel - utf-8 Vögel - latin1 #v- *only* happens when I insert latin1 (the last line) in an otherwise utf file. Then Vim (not my terminal) decides to represent latin1 correctly but not utf. I want it the other way round. [...] Vim displays it as Latin1 because your file is not a valid UTF-8 file. You can try to circumvent it as follows: 1. Make sure that 'encoding' is set to UTF-8 :verbose set encoding? 2. Load the file, forcing Vim to read it in UTF-8. :e ++enc=utf-8 filename.tex 3. Set a BOM at the head of the file so it will be read as UTF-8 next time :setlocal bomb 4. Check that 'fileencodings' starts with ucs-bom :verbose set fileencodings? Vögel (Latin1) should then display as VF6gel But I repeat: you're breaking the rules. Best regards, Tony.
Re: Plain TeX support ?
From: Benji Fisher [EMAIL PROTECTED] Subject: Re: Plain TeX support ? Date: Sat, 23 Sep 2006 15:16:00 -0400 On Sat, Sep 23, 2006 at 06:54:29AM +0200, Meino Christian Cramer wrote: Hi, Looking into :help \TeX\ does not that much information about the support of generating nice and find documents via plain TeX. Where can I get informations about what I can do/download/install/read to get a TeX-support a la AucTeX for Emacs ? Keep hacking! mcc That is an odd looking use of :help . Perhaps you meant to try :helpgrep \TeX\ instead? Note that the tex file type is for LaTeX and plaintex is used for plain TeX. See :help ft-tex-plugin if your plain TeX files are given file type tex. (I am assuming you are using vim 7. Correct me if I am wrong!) The default ftplugin/plaintex.vim does a few things: it sets options so that \input files will be recognized for include-file searches (:help include-search) and comments are recognized as such. What are the three features you miss most from AucTeX? HTH --Benji Fisher After I wrote my first TeX-text without Emacs/AucTeX spontaneous I would say the following things are missing: A Keystrokes to insert {\bf X }, {\it X \/} and such where X marks the cursor position after doing the keystroke. B Interface to run TeX and a viewer (configurable) on the file one is editing which ensures, that the file on the HD is uptodate. C Defintions to automatically map word to ``word'' and to remap - in my case - german umlauts to the TeX-commandsequences. This should be done for any non-ASCII-character. Most of the bugs I had to remove while trying to tex my file were of such kind. I have not proofen that this is not already implemented, I only read the few lines of the help text for ft-tex-plugin. And didn't fiddle with quickfix and such. May be quickfix can be misused for texing ? Dont know. Keep hacking and TeXing! mcc
Re: To be a keycode or not to be a keycode - that is the question!
Yakov Lerner wrote: On 9/24/06, Meino Christian Cramer [EMAIL PROTECTED] wrot Hi, VimTip 979 suggests to do the following mapping: nmap Space / nmap C-Space ? . I wanted to try that and wrote the sequence into my .vimrc. The first mapping works nice, but the second doesn nothing. I tried to figure out what happens (or what do not happen...) and used the Ctrl-k trick I learnd here. But it shows that the problem is some levels down. I used xkeycaps and it shows, that Ctrl-Space isn't recognized at all and Shift-Space does the same as Space. Before I shoot into my own feet and render my computer useless by screwing up the keyboard interface: 1.) Is it possible and sane to map S-Space and C-Space to something (and what ?) with xkeycaps ? Try 'man xmodmap'. The following actions can/will lead to the solution: 1) Choose new unique escap-sequence, unused by other control keys; for example Esc)1 (I don't really know if this is unique...) 2) Tell xmodmap to send this key sequence for Ctrl-Space 3) In vim, map Esc)1 to the rhs of your choice. Repeat for Shift-space. Note that in this scenario, vim doesn't really know that Esc)1 is Ctrl-Space, but nevertheless the whose conspiracy works. Hope it helps Yakov ignorecase Lerner Note that since xmodmap doesn't know about Vim modes, if you hack the Shift-Space combo -- e.g. telling xmodmap to send Esc)2 -- you'll need to add :map! Esc)2 Space in order to be able to use the space bar to insert spaces within a string of capitals in Insert/Replace/Command-line mode without lifting your finger off the Shift key. Best regards, Tony.
vim and java source code browsing
Hello, I wanted to know how can I efficiently browse java source code in VIM? That is to say that I should be able to jump to class and methods definition etc. I tried using ctags, but could not use it to produce tags for java source. The code is distributed across multiple source directories in a hierarchy. I have heard about jtags, but I was not able to install that on my home directory. any hints? -Khubaib
Re: vim and java source code browsing
Khubaib wrote: Hello, I wanted to know how can I efficiently browse java source code in VIM? That is to say that I should be able to jump to class and methods definition etc. I tried using ctags, but could not use it to produce tags for java source. The code is distributed across multiple source directories in a hierarchy. I have heard about jtags, but I was not able to install that on my home directory. any hints? -Khubaib Exuberant ctags knows about Java (I have version 5.5.4 installed). Java tags kinds: c classes f fields i interfaces l local variables [off] m methods p packages Best regards, Tony.
New User - Opening Files From Server ?
*if this came through twice I apologize, got an error message the first time.* Hi, I am a new user of VIM -- have it installed now on my Mac, PC, and Linux box (Ubuntu). On the linux system am having some trouble and wondered if you might be able to help: If I want to open a file with VIM, I typically right-click on the document (say: index.html), and select GVIM Editor -- this opens the document. However, if I am browsing my documents on a remote server (through an SFTP connection or plain FTP), this no longer works. If I right-click, select open with GVIM, I get a blank document. If I select gedit from the right-click menu the document opens without a problem (so it is not my connection). Only GVIM won't open it. Of course: I can select the document, copy it to my desktop, then open it that way, but I would really like to save that step -- since I am often editing things from my other linux server where my files are stored. Thanks in advance; looking forward to learning more. Damon -- In Search of #6, a travelogue memoir by Damon Timm available for free online as an audiobook / podcast or to read at: http://www.damonjustisntfunny.com -- In Search of #6, a travelogue memoir by Damon Timm available for free online as an audiobook / podcast or to read at: http://www.damonjustisntfunny.com
Re: vim and java source code browsing
Khubaib wrote: hello tony, thanks for the reply. I tried using it, but I think I may be doing something wrong. do you know how to produce tags when java source files are distributed across directories? -khubaib see man ctags To recurse into directories, use the -R command-line parameter. e.g. to create tags for files of all known filetypes in the current directory and below, and sort them ignoring case: ctags -R --sort=foldcase To create tags for java files only, in the current directory and below, and sort them not ignoring case ctags -R --languages=java To create tags for only classes, interfaces and methods, java files only, in the current directory and below, sort not ignoring case ctags -R --languages=java --java-kinds=cim etc. - Original Message From: A.J.Mechelynck [EMAIL PROTECTED] To: Khubaib [EMAIL PROTECTED] Cc: vim@vim.org Sent: Sunday, September 24, 2006 4:30:36 PM Subject: Re: vim and java source code browsing Khubaib wrote: Hello, I wanted to know how can I efficiently browse java source code in VIM? That is to say that I should be able to jump to class and methods definition etc. I tried using ctags, but could not use it to produce tags for java source. The code is distributed across multiple source directories in a hierarchy. I have heard about jtags, but I was not able to install that on my home directory. any hints? -Khubaib Exuberant ctags knows about Java (I have version 5.5.4 installed). Java tags kinds: c classes f fields i interfaces l local variables [off] m methods p packages Best regards, Tony.
Re: Plain TeX support ?
On 9/24/06, Meino Christian Cramer [EMAIL PROTECTED] wrote: After I wrote my first TeX-text without Emacs/AucTeX spontaneous I would say the following things are missing: A Keystrokes to insert {\bf X }, {\it X \/} and such where X marks the cursor position after doing the keystroke. It is easily done with mappings, e.g. (define CTRL-I in insert mode): :imap C-I {\it \/}leftleftleftleft You can add such lines to your ftplugin\plaintex.vim. B Interface to run TeX and a viewer (configurable) on the file one is editing which ensures, that the file on the HD is uptodate. Vim is not an IDE. However, I have put these lines in C:\localtexmf\miktex\config\miktex.ini: [TeX] Editor=C:\Program Files\Vim\vim70\gvim.exe --servername tex --remote-silent +%l %f And have done similar with Yap. So when an error occurs, I just type `e' to edit in the place where things went wrong; and double-click on a line in the DVI viewer to go to the source. Be sure to start editing with `gvim --servername tex xyz.tex' to ensure only one GVIM is started to edit the TeX file, if you intent to open the file before launching Tex or the DVI viewer. C Defintions to automatically map word to ``word'' and to remap - in my case - german umlauts to the TeX-commandsequences. This should be done for any non-ASCII-character. Most of the bugs I had to remove while trying to tex my file were of such kind. I am not sure about this one. So leave it to others. I have not proofen that this is not already implemented, I only read the few lines of the help text for ft-tex-plugin. And didn't fiddle with quickfix and such. May be quickfix can be misused for texing ? Dont know. Keep hacking and TeXing! mcc Best regards, Yongwei -- Wu Yongwei URL: http://wyw.dcweb.cn/
Re: Plain TeX support ?
From: Yongwei Wu [EMAIL PROTECTED] Subject: Re: Plain TeX support ? Date: Mon, 25 Sep 2006 09:42:21 +0800 On 9/24/06, Meino Christian Cramer [EMAIL PROTECTED] wrote: After I wrote my first TeX-text without Emacs/AucTeX spontaneous I would say the following things are missing: A Keystrokes to insert {\bf X }, {\it X \/} and such where X marks the cursor position after doing the keystroke. It is easily done with mappings, e.g. (define CTRL-I in insert mode): :imap C-I {\it \/}leftleftleftleft You can add such lines to your ftplugin\plaintex.vim. B Interface to run TeX and a viewer (configurable) on the file one is editing which ensures, that the file on the HD is uptodate. Vim is not an IDE. However, I have put these lines in C:\localtexmf\miktex\config\miktex.ini: [TeX] Editor=C:\Program Files\Vim\vim70\gvim.exe --servername tex --remote-silent +%l %f And have done similar with Yap. So when an error occurs, I just type `e' to edit in the place where things went wrong; and double-click on a line in the DVI viewer to go to the source. Be sure to start editing with `gvim --servername tex xyz.tex' to ensure only one GVIM is started to edit the TeX file, if you intent to open the file before launching Tex or the DVI viewer. C Defintions to automatically map word to ``word'' and to remap - in my case - german umlauts to the TeX-commandsequences. This should be done for any non-ASCII-character. Most of the bugs I had to remove while trying to tex my file were of such kind. I am not sure about this one. So leave it to others. I have not proofen that this is not already implemented, I only read the few lines of the help text for ft-tex-plugin. And didn't fiddle with quickfix and such. May be quickfix can be misused for texing ? Dont know. Keep hacking and TeXing! mcc Best regards, Yongwei -- Wu Yongwei URL: http://wyw.dcweb.cn/ Hi Yongwei, thank you for your reply and suggestions. One thing I forget to mention is, that I only use vim (console) and Linux. Keep hacking ! mcc
Many GVIM locale problems fixed; one remains
Hi Bram (and Edward), Some time ago I complained about UTF-8 related problems in Windows GVIM URL:http://tech.groups.yahoo.com/group/vim/message/72622. Today I installed Steve Hall's build of GVIM 7.0.106, and gladly find that some of the problems are fixed. No hacking to menu_zh_cn.utf-8.vim is necessary now, and trick of runtime! delmenu.vim is not needed any more. With the thee-line _vimrc the look is generally OK: set encoding=utf-8 source $VIMRUNTIME/vimrc_example.vim lang messages zh_CN.UTF-8 However, the context menu for tabs is still not correct. Removing the third line above can make the menu right, with the price that Chinese in start-up screen, status messages, and titles are not correct. I would be very glad to see it fixed too. Best regards, Yongwei -- Wu Yongwei URL: http://wyw.dcweb.cn/
Anyway to do spell check only for selected charset?
Hello everyone. The spell-check in Vim7 seems wonderful, several weeks ago I've been challenged to do spellcheck for files which contain both English and Chinese text. I failed to do that. The problem is that if the spell-check turned on, ALL chinese text are marked as spell error and it might be difficult to see where the real spell error is. Chinese text do not need spell check at all since all chinese characters are valid words, we do want to check English text only. Note that the target file may also be a C program and we may want to spell check the comment. One solution may be add all chinese characters into spell dictionary but that seems to be crazy and the dictionary would be huge. Is it possible to do spell-check only for ascii character and just ignore the double-width character? Thanks -- Sincerely, Pan, Shi Zhu. ext: 2606
Re: Single-File Vim?
On Sat, 23 Sep 2006 at 3:38am, A.J.Mechelynck wrote: Hari Krishna Dara wrote: On Sat, 23 Sep 2006 at 1:46am, A.J.Mechelynck wrote: Hari Krishna Dara wrote: On Fri, 22 Sep 2006 at 4:05pm, Dmitriy Yamkovoy wrote: Hi all, Is there a binary compiled for Windows which allows me to run Vim without any of the runtime files? Long story short, I want something I can keep online or on a USB key and just copy to the desktop of any computer I sit at. Thanks, -Dmitriy I think Vim, when behaving as plain Vi, doesn't require any of the runtime files. E.g., try starting vim with -u NONE option, and run :scripts command, you will see that nothing is loaded. The runtime directory is not essential for using Vim. indeed, but then you will get - no help (doc/) - no Vim tutor (tutor/) - no syntax highlighting and no colorschemes (syntax/, colors/) - no filetype detection, no filetype plugins and no filetype indenting (filetype.vim, ftplugin/, indent/) - no keymaps (keymap/) - no non-English messages (lang/) - no menus (not even English menus) (menu.vim) - no spell checking (spell/) - no matchit matching (macros/matchit.vim) - no directory browsing (plugin/netrwPlugin.vim etc.) - no editing of remote files (plugin/netrwPlugin.vim etc.) - no editing of zipfiles, tarballs, etc. (plugin/gzip.vim, plugin/tarPlugin.vim, plugin/zipPlugin.vim) - no conversion to HTML (syntax/2html.vim) - no :options command (optwin.vim) - no vimrc_example.vim (vimrc_example.vim) etc., in other words, you would lose most of the things which, IMHO, make Vim great. First of all, I presumed that that is what OP wanted. Secondly, it is still several magnitudes better than plain Vi :) For the sake of argument, glancing through your list again I find none of them to be essential. The only feature out of the list that I use most is the matchit, the rest, I don't either (regularly) use or need. Not even the help? Then you've got a better (and more encyclopaedic) memory than mine. Sorry, that was a mistake. Help is essential for all the newer features and finding options etc. -- Thanks, Hari In fact most of these features didn't even exist in older Vim versions (which was still a lot better than Vi). I don't remember Vim versions older than 6.1 but I would expect them to have had a help system. PS: I don't need lang, but I would imagine it to be essential for someone needing a non-English language. When typing Russian or Arabic I would also need keymaps, except that I'm using my own keymaps, in $VIM/vimfiles/keymap or ~/vimfiles/keymap. I also use syntax colouring whenever available. Best regards, Tony. __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com
Re: copy paste file names from windows explorer
On Sat, 23 Sep 2006 at 4:02am, A.J.Mechelynck wrote: Hari Krishna Dara wrote: On Sat, 23 Sep 2006 at 12:49am, Yakov Lerner wrote: On 9/23/06, Hari Krishna Dara [EMAIL PROTECTED] wrote: I am wondering if it is possible to copy a file in the windows explorer (MS windows) and then access the filename(s) from vim/gvim. I know there are workarounds like dnd and sendto powertoy to send the filename to clipboard, but they are not that convenience, as they either require using the mouse or you need to use several key strokes. It is easy to add SendTo items to file explorer. I think I had a trick that added a SendTo item and when you selected it, it puts filename to the clipboard. But I forgot how exactly I did it, and (2) it does require mouse, although yuo can do it with keyborad shortcuts like Shift-F10 ... I'm not using windows anymore, forgot it. I was also using the Rename trick: choose rename file in explorer, press Ctrl-C, and you have filename in the clipboard. Yakov The SendTo works, I currently have it, but it will just open a new instance. If you use the Vim installer, it creates Open With context menu entries which are better, as you can open with existing windows. However, this is not what I want, and I realize I am not clear about one thing here. I don't want to open the file, I just want to get the filename at the command-line (or insert the filename into the current buffer, say as a string constant). The reason I mentioned dnd is if you start the command mode, and then dnd a file, Vim nicely inserts its filename instead of actually loading the file. I want the same functionality without having to do dnd or open the file first. The best I can think of is if Vim can understand this format, and extract filename(s) it will be very useful (at least for me). I use the rename trick often, but this will not get the entire path into the clipboard, just the name. You can get the full path-and-filename (at least in XP) from RightClick - Properties - General - Location. Select that path by dragging the mouse pointer over it, then Ctrl-C copies it to the clipboard. Then paste it into Vim with +p or similar. Best regards, Tony. It is much easier to use the SendTo Clipboard PowerToy than this. However, nothing will compare to just pressing ^C and retrieving the name in Vim (i.e, if it is possible). It will also make it possible to copy multiple files and retrieve their names in Vim. -- Thanks, Hari __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com