Re: Emacs and vim modelines

2013-01-07 Thread Nicholas Nethercote
On Fri, Jan 4, 2013 at 4:21 PM, Benjamin Smedberg wrote: >> >> So it sounds like the recommended mode lines should look like this: >> >>/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; >> c-basic-offset: 2 -*- */ >>/* vim: set ts=8 sts=2 et sw=2 tw=80: */ > > Please make this change.

Re: Emacs and vim modelines

2013-01-04 Thread Robert O'Callahan
I agree with what David said. Also does anyone know if there's any research on how line lengths affect code reading speed? For reading regular text there's definitely an optimal line length: when text lines are too long, then when your eye moves from the end of one line to the start of the next li

Re: Emacs and vim modelines

2013-01-04 Thread L. David Baron
On Friday 2013-01-04 22:01 +0100, Mike Hommey wrote: > That being said, in 2013, I'm not convinced limiting to 80 characters on > one line still has much meaning... I think it absolutely does, because if we pick a number other than 80, we'll end up having to listen to complaints from the people wh

Re: Emacs and vim modelines

2013-01-04 Thread Benjamin Smedberg
On 1/4/13 3:49 PM, Nicholas Nethercote wrote: On Fri, Jan 4, 2013 at 12:23 PM, Nicholas Nethercote wrote: But putting sts in would be reasonable for those that don't have |smarttab| set. So it sounds like the recommended mode lines should look like this: /* -*- Mode: C++; tab-width: 8; ind

Re: Emacs and vim modelines

2013-01-04 Thread Nicholas Nethercote
On Sat, Jan 5, 2013 at 8:34 AM, Jeff Hammel wrote: > > I find editor-specific modelines extraneous, > since you can always modify emacs/vim to do what you want anyway. I mentioned above that I find it extremely useful because we have an awkward mix of 2-space indent and 4-space indent files (and

Re: Emacs and vim modelines

2013-01-04 Thread Ralph Giles
On 13-01-04 1:01 PM, Mike Hommey wrote: > That being said, in 2013, I'm not convinced limiting to 80 characters on > one line still has much meaning... FWIW I still edit in 80 column windows. Helps get more columns on the screen. Now, maybe if you were suggesting switching to proportional fonts.

Re: Emacs and vim modelines

2013-01-04 Thread Jeff Hammel
On 01/04/2013 01:01 PM, Mike Hommey wrote: On Sat, Jan 05, 2013 at 07:49:22AM +1100, Nicholas Nethercote wrote: On Fri, Jan 4, 2013 at 12:23 PM, Nicholas Nethercote wrote: But putting sts in would be reasonable for those that don't have |smarttab| set. So it sounds like the recommended mode l

Re: Emacs and vim modelines

2013-01-04 Thread Mike Hommey
On Sat, Jan 05, 2013 at 07:49:22AM +1100, Nicholas Nethercote wrote: > On Fri, Jan 4, 2013 at 12:23 PM, Nicholas Nethercote > wrote: > > > > But putting sts in would be > > reasonable for those that don't have |smarttab| set. > > So it sounds like the recommended mode lines should look like this:

Re: Emacs and vim modelines

2013-01-04 Thread Nicholas Nethercote
On Fri, Jan 4, 2013 at 12:23 PM, Nicholas Nethercote wrote: > > But putting sts in would be > reasonable for those that don't have |smarttab| set. So it sounds like the recommended mode lines should look like this: /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */

Re: Emacs and vim modelines

2013-01-03 Thread Nicholas Nethercote
On Thu, Jan 3, 2013 at 5:13 PM, Justin Lebar wrote: >> Are there any common installations of vi/vim that actually honor >> modelines anymore? The ones on the Linux distros that I used >> stopped doing so as a security measure. Mine (vanilla Ubuntu 12.10) does. I had to |set modelines=2| for it

Re: Emacs and vim modelines

2013-01-03 Thread Justin Lebar
> Are there any common installations of vi/vim that actually honor > modelines anymore? The ones on the Linux distros that I used > stopped doing so as a security measure. :help modeline says > No other commands than "set" are supported, for security reasons (somebody > might create a Trojan hor

Re: Emacs and vim modelines

2013-01-03 Thread L. David Baron
On Thursday 2013-01-03 16:44 -0800, Nicholas Nethercote wrote: > https://developer.mozilla.org/en-US/docs/Developer_Guide/Coding_Style > says that mozilla code files should have the following Emacs and Vim > mode lines: > > /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; > c-basic-offset:

Re: Emacs and vim modelines

2013-01-03 Thread L. David Baron
On Thursday 2013-01-03 20:02 -0500, Benjamin Smedberg wrote: > On 1/3/13 7:44 PM, Nicholas Nethercote wrote: > >Hi > > > >https://developer.mozilla.org/en-US/docs/Developer_Guide/Coding_Style > >says that mozilla code files should have the following Emacs and Vim > >mode lines: > > > > /* -*- Mod

Re: Emacs and vim modelines

2013-01-03 Thread Benjamin Smedberg
On 1/3/13 7:44 PM, Nicholas Nethercote wrote: Hi https://developer.mozilla.org/en-US/docs/Developer_Guide/Coding_Style says that mozilla code files should have the following Emacs and Vim mode lines: /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ /* vim: s

Emacs and vim modelines

2013-01-03 Thread Nicholas Nethercote
Hi https://developer.mozilla.org/en-US/docs/Developer_Guide/Coding_Style says that mozilla code files should have the following Emacs and Vim mode lines: /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ /* vim: set ts=2 et sw=2 tw=80: */ AIUI, |tab-width| in Em