Re: Updated floating point patch

2008-06-09 Fir de Conversatie Bram Moolenaar
Bill McCarthy wrote: (2) does this LC_NUMERIC actually work on Windows - I recall having problems with LC_ALL using the unix sort of GNU coreutils - is this an environment variable we need to set? I haven't tried it. So please set your environment so that a comma is used for a

Re: Updated floating point patch

2008-06-09 Fir de Conversatie Bill McCarthy
On Mon 9-Jun-08 2:01am -0600, Tony Mechelynck wrote: On 09/06/08 03:43, Bill McCarthy wrote: On Sun 8-Jun-08 4:25pm -0600, Bram Moolenaar wrote: Bill McCarthy wrote: (2) does this LC_NUMERIC actually work on Windows - I recall having problems with LC_ALL using the unix sort of GNU

Re: Updated floating point patch

2008-06-09 Fir de Conversatie Bill McCarthy
On Mon 9-Jun-08 3:41am -0600, Bram Moolenaar wrote: Bill McCarthy wrote: Also, commas don't work as expected. Here's what I get from: :echo 1,2 1 E15: Invalid expression: ,2 E15: Invalid expression: ,2 Eh, I think you mean that this doesn't work, and that this is

RE: Updated floating point patch

2008-06-09 Fir de Conversatie John Beckett
Bram Moolenaar wrote: Attached you will find the latest floating point patch. Thanks Bram. I have patched and compiled without incident. A few tests, and a superficial look at the code changes, make me believe that the new float patch is good. As discussed, using strtod() is much more robust.

Re: Updated floating point patch

2008-06-09 Fir de Conversatie Dominique Pelle
On Mon, Jun 9, 2008 at 12:06 PM, Tony Mechelynck wrote: On 09/06/08 11:52, Bill McCarthy wrote: [...] Thanks for the explanation. If you know of a way of setting a locale that accepts commas as decimal points, see if it causes Vim to accept 1,2 as 1.2 - that's what I think Bram was asking

Patch 7.1.312

2008-06-09 Fir de Conversatie Bram Moolenaar
Patch 7.1.312 Problem:The .po files have mistakes in error numbers. Solution: Search for these mistakes in the check script. (Dominique Pelle) Files: src/po/check.vim *** ../vim-7.1.311/src/po/check.vim Wed Nov 23 22:10:37 2005 --- src/po/check.vimSun May 25 13:47:59 2008

Patch 7.1.314

2008-06-09 Fir de Conversatie Bram Moolenaar
Patch 7.1.314 Problem:The value of 'pastetoggle' is written to the session file without any escaping. (Randall Hansen) Solution: Use put_escstr(). (Ben Schmidt) Files: src/option.c *** ../vim-7.1.313/src/option.c Wed Mar 12 17:37:53 2008 --- src/option.cWed Jun

BUG: Partially reversed strings with long entered ex command

2008-06-09 Fir de Conversatie Ingo Karkat
Hello VIM developers, I'd like to report a bug that occurs when a very long ex command is entered, so that the GUI / console screen space isn't sufficient to display the complete command. I have an external VBScript that uses the VIM OLE SendKeys() function (or WshShell.SendKeys() as a

Re: Improve vim's keyboard input subsystem

2008-06-09 Fir de Conversatie Paul LeoNerd Evans
On Mon, 09 Jun 2008 17:41:00 +0200 Bram Moolenaar [EMAIL PROTECTED] wrote: In that case, I'd like to hear your suggestion on how I may use combinations of Shift/Ctrl/Alt with keypresses in a normal vim. Nothing special, most of them can be recognized already. Especially if you are using

Re: Updated floating point patch

2008-06-09 Fir de Conversatie Charles E Campbell Jr
Mikolaj Machowski wrote: Things works, thanks :) Few things I'd like to see explained (fixed, implemented?): 1. Once a float, always a float. Don't see way to make float other type of data - string, integer. At least one can convert floats to strings: :let x=1.3 :echo

Re: BUG: Partially reversed strings with long entered ex command

2008-06-09 Fir de Conversatie Bram Moolenaar
Ingo Karkat wrote: I'd like to report a bug that occurs when a very long ex command is entered, so that the GUI / console screen space isn't sufficient to display the complete command. I have an external VBScript that uses the VIM OLE SendKeys() function (or WshShell.SendKeys() as a

Re: Updated floating point patch

2008-06-09 Fir de Conversatie Bram Moolenaar
Mikolaj Machowski wrote: Things works, thanks :) Few things I'd like to see explained (fixed, implemented?): 1. Once a float, always a float. Don't see way to make float other type of data - string, integer. String - Float with str2float() Float - String with printf() When would

Re: Improve vim's keyboard input subsystem

2008-06-09 Fir de Conversatie Paul LeoNerd Evans
On Mon, 09 Jun 2008 21:04:51 +0200 Bram Moolenaar [EMAIL PROTECTED] wrote: No, because only a few terminals send these codes. Instead, add the entries in the termcap/terminfo. That might break other programs though. You can also use a Vim script to set them. Or a shell wrapper around Vim.

RE: Updated floating point patch

2008-06-09 Fir de Conversatie John Beckett
Mikolaj Machowski wrote: echo printf(%.0f, 0.4) E807: expected Float argument for printf() You mean (argument not a string): :echo printf(%.0f, 0.4) echo printf(%d, 4-2) Same glitch. It's 4-2 not 4-2. user friendly (eg. store and display 0.5 instead of 0.50) Here is a workaround:

Re: Updated floating point patch

2008-06-09 Fir de Conversatie Ben Schmidt
Ben Schmidt wrote: When would you need Float - Int? You can actually use printf(.0f, float), and rely on automatic String to Int conversion, but it's clumsy. Float - Int can be very handy, using floats as intermediate calculations in scripts and then converting to ints for some kind of

Re: Updated floating point patch

2008-06-09 Fir de Conversatie Ben Schmidt
Gary Johnson wrote: On 2008-06-10, Ben Schmidt [EMAIL PROTECTED] wrote: Out of curiosity, why the preference for a few functions with parameters, e.g., To be honest, I probably prefer the 'many functions' approach. I was just thinking in terms of not cluttering the Vim function namespace

Re: Updated floating point patch

2008-06-09 Fir de Conversatie Gautam Iyer
On Tue, Jun 10, 2008 at 01:55:04PM +1000, John Beckett wrote: It would be a pointless waste of development time to do much more with floats in Vim, IMHO. I *strongly* agree! Apart from the basic operations, the rest can be left to vim-perl/python/ruby/etc. Please don't bloat Vim. GI --

Re: Updated floating point patch

2008-06-09 Fir de Conversatie Ben Schmidt
John Beckett wrote: Ben Schmidt wrote: math('sqrt',argument) math('exp',exponent[,base=e]) math('log',argument[,base=e]) math('sin',argument[,degrees (bool)=0]) math('cos',argument[,degrees (bool)=0]) math('tan',argument[,degrees (bool)=0]) math('atan',argument[,degrees (bool)=0])