POV-Ray : Newsgroups : povray.off-topic : Emacs Server Time
13 Oct 2026 10:15:31 EDT (-0400)
  Emacs (Message 300 to 349 of 349)  
<<< Previous 50 Messages Goto Initial 50 Messages
From: nemesis
Subject: Re: Emacs
Date: 21 Apr 2009 23:53:16
Message: <49ee94ac@news.povray.org>
Darren New wrote:
> Darren New wrote:
>> nemesis wrote:
>>> It is very difficult to write compilers that generate optimized 
>>> native code as good as the ones already provided by mature C 
>>> compilers that have been around for ages.
>>
>> It depends on the language, of course. 
> 
> Here's a good example. Your CPU supports both decimal arithmetic and 
> CISC-style opcodes that check array bounds and multiple-dimension-array 
> calculations.  Like, say, the VAX.  You want to implement Ada, which 
> supports both array bounds checking for multiple-dimension arrays and 
> decimal arithmetic.  Those features probably won't be fast if you 
> generate portable C
/snip/
> Ada also supports natively threads and interrupt handling, neither of 
> which you can generate C to handle. So some languages simply cannot be 
> translated to C in any sort of portable way.

True.  Arrays in Scheme (vectors) are bounds checked.  Probably won't 
run all that nice on VAX but at least will run, something that possibly 
wouldn't happen at all if one was to support optimized native code 
generation for all platforms under the sun out there.  There were crazy 
enough people to do that in the past:  C compiler writers. :)  We just 
reap the benefits...


Post a reply to this message

From: nemesis
Subject: Re: Emacs
Date: 22 Apr 2009 01:08:51
Message: <49eea663$1@news.povray.org>
scott wrote:
>> It's still too little to bother, I guess.  You talk like as if 
>> pressing space and being presented with a graphical menu that works 
>> like any other graphical menu you ever saw is the end of the world.
> 
> It doesn't.  The menu disappears seemingly randomly if you stray too far 
> from it, the menu order is reversed if you open it too near the bottom 
> of the window, the menu gets clipped by the edge of the window rather 
> than being display on top of it, it doesn't respect the user setting for 
> sub-menu open delay, it doesn't reopen at the new point if you press 
> space again. It's all the little features that OS designers spend so 
> much time over to make life easier for everyone, and then some developer 
> comes along and says "nah, we're just going to use our own menu system".

Would you care to complain about that to web developers of javascript 
menus too?

Let's face it:  the future means our platform of choice will be nothing 
but a receiver for foreign programming running on custom cross-platform 
engines, be it web, XUL, XAML, Java, .NET, Windows apps via Wine on 
Linux/Mac etc.

Blender is not at all like any Gnome app on Linux either.  And today's 
Linux noobs just prefer to be underpowered with notepad-on-crack gedit 
than to be superman with vim or emacs.  It sucks seeing great tech 
misused/misunderstood...


Post a reply to this message

From: Jim Henderson
Subject: Re: Emacs
Date: 22 Apr 2009 01:16:57
Message: <49eea849@news.povray.org>
On Wed, 22 Apr 2009 02:19:27 -0300, nemesis wrote:

> And today's
> Linux noobs just prefer to be underpowered with notepad-on-crack gedit
> than to be superman with vim or emacs.

Well, hold on a sec - I actually use both gedit and vim; I use gedit 
sometimes because I just need to do a quick edit and it flies off my 
fingers first, other times I use vim because I prefer its search-and-
replace facilities.

I don't really think it's fair to say that only noobs use gedit or kate 
(or whatever the standard KDE editor is, GNOME user that I am) and 
superhuman beings use vim or emacs.

People use the tools they're most comfortable with, and sometimes more 
than one.

Hell, at times, I use awk for editing.  If I knew sed better, I'd 
probably use that, too.  People doing change-on-the-fly editing using 
pipes might say that it's noobs who use crutches like vim or emacs.

Remember that we all had to start somewhere, and those of us who've been 
in the biz for 15 years or more (which I think is you and me both) tend 
to forget that the landscape has changed in that time.  Our way may be 
better for us, but that doesn't necessarily make it better for everyone.

I also suspect that you - like me - type at a phenomenal rate.  I've 
clocked myself at up to 120 WPM when I'm really in a good groove.  I 
can't move a mouse that fast, so I tend to not even use menus in GNOME (I 
tend to use ALT+F2 and type the program name in because it's faster for 
me).  That doesn't mean that for my stepson - who also types rather 
quickly at 21 - is a lesser computer user because he uses the mouse more 
than I do.  He's just got a different workflow for the things he does.

Jim


Post a reply to this message

From: nemesis
Subject: Re: Emacs
Date: 22 Apr 2009 02:22:28
Message: <49eeb7a4@news.povray.org>
Jim Henderson wrote:
> On Wed, 22 Apr 2009 02:19:27 -0300, nemesis wrote:
>> And today's
>> Linux noobs just prefer to be underpowered with notepad-on-crack gedit
>> than to be superman with vim or emacs.
> 
> I don't really think it's fair to say that only noobs use gedit or kate 
> (or whatever the standard KDE editor is, GNOME user that I am) and 
> superhuman beings use vim or emacs.
> 
> People use the tools they're most comfortable with, and sometimes more 
> than one.

Sure, feeling comfortable with a beautiful, more familiar face is a nice 
thing to get.  Even if underpowered, like by choosing gedit vs vim/emacs. :)

Not all editing tasks would benefit from vim/emacs -- like short, plain 
typing with little editing other than backspace -- but those that do get 
a serious boost from a proper tool.

> Hell, at times, I use awk for editing.  If I knew sed better, I'd 
> probably use that, too.

Like Perl, they're excellent batch text editing tools.

> People doing change-on-the-fly editing using 
> pipes might say that it's noobs who use crutches like vim or emacs.

Batch editing with pipes and sed has no place in today's fast-paced 
interactive programming.  I don't think Bill Joy or Richard Stallman 
would go back to ed or teco after building their tools on them. :)

> Remember that we all had to start somewhere, and those of us who've been 
> in the biz for 15 years or more (which I think is you and me both) tend 
> to forget that the landscape has changed in that time.

I think I've been keeping up with new technological advances just fine. 
  And yet I don't see any text editing tool marvels as those 2, even in 
high end modernese IDEs.

> Our way may be 
> better for us, but that doesn't necessarily make it better for everyone.

I don't think so.  The day I can select and copy one long SQL select 
query with a mouse just as easily as y} or go back after a search to the 
exact point I was 700 lines above with Ctrl+o is the day I'll eat my 
underwear. :)

> I also suspect that you - like me - type at a phenomenal rate.

Not at all.  Thank God for superior editing tools. :)

> can't move a mouse that fast, so I tend to not even use menus in GNOME (I 
> tend to use ALT+F2 and type the program name in because it's faster for 
> me).

I control my Linux box from the always open gnome-terminal.  My regular 
programs are always in bash_history, so it's just a matter of Ctrl-R'ing 
for them. :)

>  That doesn't mean that for my stepson - who also types rather 
> quickly at 21 - is a lesser computer user because he uses the mouse more 
> than I do.  He's just got a different workflow for the things he does.

I think he's losing a lot. ;)


Post a reply to this message

From: Darren New
Subject: Re: Emacs
Date: 22 Apr 2009 11:08:06
Message: <49ef32d6$1@news.povray.org>
nemesis wrote:
> Batch editing with pipes and sed has no place in today's fast-paced 
> interactive programming.

Heh heh heh.

-- 
   Darren New, San Diego CA, USA (PST)
   There's no CD like OCD, there's no CD I knoooow!


Post a reply to this message

From: Nicolas Alvarez
Subject: Re: Emacs
Date: 22 Apr 2009 11:45:08
Message: <49ef3b84@news.povray.org>
Invisible wrote:
> One feature I actually *want* and that no known editor seems to have is
> the ability to do stuff to tabular data easily. Like, if you suddenly
> decide that you need to append the same piece of text to all 10 lines.
> Or you have a grid of numbers, and you want to add another column in the
> middle.

Vim can do that.

POV-Ray for Windows built-in editor can do that.


Post a reply to this message

From: Nicolas Alvarez
Subject: Re: Emacs
Date: 22 Apr 2009 12:02:17
Message: <49ef3f88@news.povray.org>
triple_r wrote:
> Or its vim equivalent for those afraid of the control key ;-)
> 
> 2G     //line 2
> yy     //yank (copy) the line
> 2j     //down two lines
> $      //end of line
> qa     //start macro 'a'
> p      //paste
> j      //next line
> q      //end macro
> 9@a    //run macro 'a' 9 times
> 

Or using the block selection:

2G     //line 2
y$     //yank to end of line
2j     //down two lines
$      //end of line
<C-q>  //enter visual mode blockwise
9j     //down nine lines
A      //visual-block append
<C-r>" //paste from register "
Esc    //quit visual mode (this is when the change will affect all lines)


Post a reply to this message

From: Nicolas Alvarez
Subject: Re: Emacs
Date: 22 Apr 2009 12:10:20
Message: <49ef416b@news.povray.org>
scott wrote:
> Really, I wish MS would ban software that doesn't at least use the
> standard font, menus, toolbars, dialogs etc.

Like Office?


Post a reply to this message

From: Nicolas Alvarez
Subject: Re: Emacs
Date: 22 Apr 2009 12:11:51
Message: <49ef41c7@news.povray.org>
Invisible wrote:
> The really Fun Stuff is things like ported Linux programs that assume
> that your shell is named /bin/sh and so on. (The Emacs FAQ says that if
> you try to open a shell using Emacs on Windows, it bombs for this very
> reason.) Really, Windows is very, *very* different to Unix, and just
> recompiling the source code is insufficient to fix that.

Vim sometimes runs whatever is in $SHELL and expects it to understand Bourne
shell syntax. My interactive shell has quite different syntax... so it
bombs.

Even in the Vim mailing list that was compared to "running $EDITOR and
expecting it to understand Emacs keystrokes".


Post a reply to this message

From: nemesis
Subject: Re: Emacs
Date: 22 Apr 2009 12:14:46
Message: <49ef4276$1@news.povray.org>
Darren New escreveu:
> nemesis wrote:
>> Batch editing with pipes and sed has no place in today's fast-paced 
>> interactive programming.
> 
> Heh heh heh.

Is that a sed programmer laugh? :)

-- 
a game sig: http://tinyurl.com/d3rxz9


Post a reply to this message

From: Nicolas Alvarez
Subject: Re: Emacs
Date: 22 Apr 2009 12:19:01
Message: <49ef4375@news.povray.org>
nemesis wrote:
> Batch editing with pipes and sed has no place in today's fast-paced
> interactive programming.  I don't think Bill Joy or Richard Stallman
> would go back to ed or teco after building their tools on them. :) 

Last year I wanted to add something to a hundred files and I seriously used
a script that sent commands to ed.

Not because I was used to it; I learned ed for that. Although I already knew
vim, and many commands are similar.


Post a reply to this message

From: Nicolas Alvarez
Subject: Re: Emacs
Date: 22 Apr 2009 12:20:27
Message: <49ef43cb@news.povray.org>
Darren New wrote:
> My favorite is how emacs brings up the help screen when you hit backspace.
> I'm pretty sure the defined meaning of backspace predates emacs. :-)

No, Ctrl-H opens help. If your terminal sends Ctrl-H on backspace, that's
not Emacs's fault.

http://www.debian.org/doc/debian-policy/ch-opersys.html#s9.8


Post a reply to this message

From: Nicolas Alvarez
Subject: Re: Emacs
Date: 22 Apr 2009 12:22:34
Message: <49ef444a@news.povray.org>
nemesis wrote:
> scott escreveu:
>> Really, I wish MS would ban software that doesn't at least use the
>> standard font, menus, toolbars, dialogs etc.
> 
> Emacs and vi were around long before Microsoft began selling DOS.  Their
> standards are as valid in their context as Microsoft's in their
> products.  They won't change their way to do their stuff just because
> there's a new kid in town.  More likely they will thin out and die
> before going that route.

gVim for Windows integrates with Windows quite well.

Example: Selection on Vim usually enters 'visual' mode, so eg. if you
press 'y' after selecting something, it will get "yanked" (copied).

On the Windows port, by default, selection enters 'select' mode, so if you
press 'y' after selecting something, it will get deleted and replaced
with 'y'.


Post a reply to this message

From: Darren New
Subject: Re: Emacs
Date: 22 Apr 2009 12:47:40
Message: <49ef4a2c$2@news.povray.org>
nemesis wrote:
> Darren New escreveu:
>> nemesis wrote:
>>> Batch editing with pipes and sed has no place in today's fast-paced 
>>> interactive programming.
>>
>> Heh heh heh.
> 
> Is that a sed programmer laugh? :)

No. That's from someone who just went thru 250+ directories, found all the 
files with the string SDL or sdl in the file name, directory name, or inside 
the files, and duplicated it to another file, directory, or #ifdef section 
within the file, as appropriate.

Do that interactively? I'd still be at it.

-- 
   Darren New, San Diego CA, USA (PST)
   There's no CD like OCD, there's no CD I knoooow!


Post a reply to this message

From: Darren New
Subject: Re: Emacs
Date: 22 Apr 2009 12:49:46
Message: <49ef4aaa$1@news.povray.org>
Nicolas Alvarez wrote:
> No, Ctrl-H opens help. If your terminal sends Ctrl-H on backspace, that's
> not Emacs's fault.

No, it's just the international standard that has been in place since before 
UNIX was even invented, let alone emacs.

What character sequence do you think the backspace key *should* send?

-- 
   Darren New, San Diego CA, USA (PST)
   There's no CD like OCD, there's no CD I knoooow!


Post a reply to this message

From: Nicolas Alvarez
Subject: Re: Emacs
Date: 22 Apr 2009 12:57:11
Message: <49ef4c67@news.povray.org>
Invisible wrote:
> My God... The Windows native port...

http://bash.org/?44287

> ...is a 37 MB download! O_O 
> 
> *dies*
> 
> I thought SciTE was bad for taking almost 2 MB, but 37 MB for a mere
> text editor?

http://qdb.us/29888
http://qdb.us/7109
http://qdb.us/37015
http://qdb.us/47805
http://qdb.us/52563
http://bash.org/?39330

> But of course, a cursory inspection of the online Emacs tutorial quickly
> reveals that Emacs is not, in fact, a text editor. It's a replacement
> operating system. (But one which is none the less only compatible with
> Unix.)

http://qdb.us/37509
http://qdb.us/48521
http://qdb.us/75396

> Not content with merely being a text editor, it also tries to be a
> newsreader, web browser, file manager, calendar, and even a Tetris
> clone. Unfortunately, from the screenshots I've seen, it does none of
> these things very well.

http://qdb.us/24802
http://qdb.us/29834
http://qdb.us/32590
http://qdb.us/60008
http://qdb.us/61838


Post a reply to this message

From: Jim Henderson
Subject: Re: Emacs
Date: 22 Apr 2009 12:58:53
Message: <49ef4ccd$1@news.povray.org>
On Wed, 22 Apr 2009 03:33:04 -0300, nemesis wrote:

>> People use the tools they're most comfortable with, and sometimes more
>> than one.
> 
> Sure, feeling comfortable with a beautiful, more familiar face is a nice
> thing to get.  Even if underpowered, like by choosing gedit vs
> vim/emacs. :)

"Underpowered" though is in the eyes of the beholder - and dependent 
heavily on the task.  I don't know about you, but I wouldn't go and get a 
pneumatic hammer to tap an anchor into the wall to hang a spice rack.

> Not all editing tasks would benefit from vim/emacs -- like short, plain
> typing with little editing other than backspace -- but those that do get
> a serious boost from a proper tool.

Sure.

>> Hell, at times, I use awk for editing.  If I knew sed better, I'd
>> probably use that, too.
> 
> Like Perl, they're excellent batch text editing tools.

I find Perl to be a bit heavy, honestly.  The extensibility is useful 
(and I do use it for some things, though I'm more comfortable in awk) at 
times, but if I want to do just some basic parsing, Perl seems like 
overkill.

>> People doing change-on-the-fly editing using pipes might say that it's
>> noobs who use crutches like vim or emacs.
> 
> Batch editing with pipes and sed has no place in today's fast-paced
> interactive programming.  

Oh, I don't know about that.  I had to process a couple hundred e-mail 
messages, generate PDFs of the contents, and re-send them to myself.  
Easiest way was to export the messages to a text file and run them 
through a few awk scripts - using pipes.  Fed the results into another 
awk script that mailed the stuff back to me.

sed has it's place in there as well, and probably some of what I did 
could've been done more easily with sed.

>> Remember that we all had to start somewhere, and those of us who've
>> been in the biz for 15 years or more (which I think is you and me both)
>> tend to forget that the landscape has changed in that time.
> 
> I think I've been keeping up with new technological advances just fine.
>   And yet I don't see any text editing tool marvels as those 2, even in
> high end modernese IDEs.

Well, that could well be because you're used to the tools you use. :)

>> Our way may be
>> better for us, but that doesn't necessarily make it better for
>> everyone.
> 
> I don't think so.  The day I can select and copy one long SQL select
> query with a mouse just as easily as y} or go back after a search to the
> exact point I was 700 lines above with Ctrl+o is the day I'll eat my
> underwear. :)

There again, you're framing it in terms of your experience.  I'm talking 
about from someone else's POV.  That's much harder to judge for most 
people because they're not used to standing in someone else's shoes and 
saying that the other POV might have a point.

>> can't move a mouse that fast, so I tend to not even use menus in GNOME
>> (I tend to use ALT+F2 and type the program name in because it's faster
>> for me).
> 
> I control my Linux box from the always open gnome-terminal.  My regular
> programs are always in bash_history, so it's just a matter of Ctrl-R'ing
> for them. :)

Heh, same here.  Except I use tcsh and ! - but same concept.

>>  That doesn't mean that for my stepson - who also types rather
>> quickly at 21 - is a lesser computer user because he uses the mouse
>> more than I do.  He's just got a different workflow for the things he
>> does.
> 
> I think he's losing a lot. ;)

Oh, I don't think so - he's quite adept with the tools he uses, both on 
Windows and on Linux.  Just because he doesn't do things the way you and 
I do doesn't mean he's missing out - he might say the same about us 
because we are "stuck in our old ways of doing things". ;-)

Jim


Post a reply to this message

From: Nicolas Alvarez
Subject: Re: Emacs
Date: 22 Apr 2009 13:05:03
Message: <49ef4e3e@news.povray.org>
nemesis wrote:
> Invisible escreveu:
>>>> change absolutely anything [with the not inconsiderable detail that you
>>>> don't have to recompile anything]. But only once you've read and
>>>> memorised the entire source tree. How feasible is that, really?
>>>
>>>     Eh? No! You don't have to dig into source code for Emacs to
>>>     customize
>>> it. It comes with a Lisp interpreter for a reason!
>> 
>> You do if you want to make it do something there isn't a setting for.
> 
> Like a new garbage collector?  Pretty much only the core elisp
> interpreter and basic IO routines are in C, the rest of emacs is elisp.

And that elisp code isn't "source code of emacs"?


Post a reply to this message

From: Nicolas Alvarez
Subject: Re: Emacs
Date: 22 Apr 2009 13:06:37
Message: <49ef4e9d@news.povray.org>
Invisible wrote:
>>> Does anybody know what the hell "C-u 10 C-f" is actually supposed to
>>> mean? What the heck is a "meta key"? Why are cut and past called kill
>>> and yank? The list of questions goes on and on.
>> 
>> which does which? Kill I imagine deletes the text. Yank I guess is
>> similar to a copy then delete operation.
> 
> Actually, it appears that kill = cut and yank = paste. (WTF?)

Yank is paste? In vim, yank is copy. Put is paste.


Post a reply to this message

From: Nicolas Alvarez
Subject: Re: Emacs
Date: 22 Apr 2009 13:10:41
Message: <49ef4f90@news.povray.org>
nemesis wrote:
> Jim Henderson wrote:
>> emacs is a religion.  Notepad isn't.
> 
> Yes, emacs can move mountains. ;)

It has more mass than a mountain, so why not.


Post a reply to this message

From: Nicolas Alvarez
Subject: Re: Emacs
Date: 22 Apr 2009 13:15:16
Message: <49ef50a3@news.povray.org>
Jim Henderson wrote:
> True, but sometimes a bicycle is all you need, you don't need a 747 to
> take you to the corner market. ;-)

A coworker told me he once went to IBM to work for a project, and the other
people there would start Rational Software Architect every time they had to
change a line of a config file *sigh*


Post a reply to this message

From: Nicolas Alvarez
Subject: Re: Emacs
Date: 22 Apr 2009 13:16:39
Message: <49ef50f7@news.povray.org>
Warp wrote:
> Jim Henderson <nos### [at] nospamcom> wrote:
>> I find vi to be completely intuitive.
> 
>   You don't seem to understand the meaning of the word "intuitive".
> 
>   Intuitive means that its basic operations can be used by someone who
> has never used the program before.
> 
>   Intuitive does not mean that you find it easy to use after having years
> of experience.
> 

Vi is more intuitive. p to paste instead of something silly like Ctrl-V.


Post a reply to this message

From: Nicolas Alvarez
Subject: Re: Emacs
Date: 22 Apr 2009 13:17:19
Message: <49ef511e@news.povray.org>
nemesis wrote:
> Darren New wrote:
>> It would seem notepad is as "intuitive" (with arrow keys, mouse clicks
>> to position the cursor, etc) as any other Windows program, while neither
>> emacs nor vi can be driven at all without learning how to run them.
> 
> 20-years vi hacker comes in touch with notepad for the first time:
> iWhat the crap is this thing?
> :wq
> iCrap!  How do I kill this process??!!
> ZZ
> :q!!!

I once found myself pressing Esc a lot on POV-Win.


Post a reply to this message

From: Nicolas Alvarez
Subject: Re: Emacs
Date: 22 Apr 2009 13:18:06
Message: <49ef514d@news.povray.org>
triple_r wrote:
> Like my email messages, "Here's the file, do you think you could printf
> this out
> for me?"  I wish I could say I've only done that once.

I mistype "myself" as "mysqlf" quite often. I notice when I'm about to press
the 'f' :)


Post a reply to this message

From: Warp
Subject: Re: Emacs
Date: 22 Apr 2009 13:23:00
Message: <49ef5273@news.povray.org>
Nicolas Alvarez <nic### [at] gmailcom> wrote:
> Vi is more intuitive. p to paste instead of something silly like Ctrl-V.

  When I press the 'p' key, for some odd reason my intuitive expectation
is for the letter 'p' to appear at the cursor's position, but that might
be just me.

-- 
                                                          - Warp


Post a reply to this message

From: Mike Raiford
Subject: Re: Emacs
Date: 22 Apr 2009 13:28:51
Message: <49ef53d3$1@news.povray.org>
Darren New wrote:

> 
> What character sequence do you think the backspace key *should* send?
> 

Why, the OEM keycode for the backspace key, of course ... Duh!

-- 
~Mike


Post a reply to this message

From: Nicolas Alvarez
Subject: Re: Emacs
Date: 22 Apr 2009 13:37:57
Message: <49ef55f5@news.povray.org>
Darren New wrote:
> What character sequence do you think the backspace key *should* send?

See the link I posted?


Post a reply to this message

From: Nicolas Alvarez
Subject: Re: Emacs
Date: 22 Apr 2009 13:39:01
Message: <49ef5635@news.povray.org>
Warp wrote:
> Nicolas Alvarez <nic### [at] gmailcom> wrote:
>> Vi is more intuitive. p to paste instead of something silly like Ctrl-V.
> 
>   When I press the 'p' key, for some odd reason my intuitive expectation
> is for the letter 'p' to appear at the cursor's position, but that might
> be just me.

And that's what Vim does, when you're in insert mode. In normal mode, it
pastes.

Hey, when you press 'p' on Windows while a menu is open, what does it do?


Post a reply to this message

From: Mike Raiford
Subject: Re: Emacs
Date: 22 Apr 2009 13:48:42
Message: <49ef587a$1@news.povray.org>
Warp wrote:

>   When I press the 'p' key, for some odd reason my intuitive expectation
> is for the letter 'p' to appear at the cursor's position, but that might
> be just me.

No. Too easy.

I've used VI for a semester in a college computer science course.

I learned to hate it.

BTW, where did the combinations Ctrl-Ins(Copy), Shift-Del(Cut) and 
Shift-Ins(Paste) come from? I remember them from the DOS text editors 
for QuickBASIC and such...


-- 
~Mike


Post a reply to this message

From: nemesis
Subject: Re: Emacs
Date: 22 Apr 2009 14:01:24
Message: <49ef5b74@news.povray.org>
Darren New escreveu:
> nemesis wrote:
>> Darren New escreveu:
>>> nemesis wrote:
>>>> Batch editing with pipes and sed has no place in today's fast-paced 
>>>> interactive programming.
>>>
>>> Heh heh heh.
>>
>> Is that a sed programmer laugh? :)
> 
> No. That's from someone who just went thru 250+ directories, found all 
> the files with the string SDL or sdl in the file name, directory name, 
> or inside the files, and duplicated it to another file, directory, or 
> #ifdef section within the file, as appropriate.
> 
> Do that interactively? I'd still be at it.

True, that excellent use for the batch tools.  That's also not typical 
source code editing.

-- 
a game sig: http://tinyurl.com/d3rxz9


Post a reply to this message

From: nemesis
Subject: Re: Emacs
Date: 22 Apr 2009 14:25:17
Message: <49ef610d@news.povray.org>
Jim Henderson escreveu:
>>> People doing change-on-the-fly editing using pipes might say that it's
>>> noobs who use crutches like vim or emacs.
>> Batch editing with pipes and sed has no place in today's fast-paced
>> interactive programming.  
> 
> Oh, I don't know about that.  I had to process a couple hundred e-mail 
> messages, generate PDFs of the contents, and re-send them to myself.  
> Easiest way was to export the messages to a text file and run them 
> through a few awk scripts - using pipes.  Fed the results into another 
> awk script that mailed the stuff back to me.

That's scripting useful tasks, but I probably got the wording ambiguous 
enough so many people replied about the same as you.  Sure scripting is 
useful programming, but by "interactive programming" I meant using 
proper interactive editing tools to *edit program source code*, not awk, 
sed, ed and pipes cause that surely is insane.

>> I don't think so.  The day I can select and copy one long SQL select
>> query with a mouse just as easily as y} or go back after a search to the
>> exact point I was 700 lines above with Ctrl+o is the day I'll eat my
>> underwear. :)
> 
> There again, you're framing it in terms of your experience.  I'm talking 
> about from someone else's POV.  That's much harder to judge for most 
> people because they're not used to standing in someone else's shoes and 
> saying that the other POV might have a point.

It's not from my experience at all, not hard to judge for other people.

I mean, surely being able to select and copy a whole block of text with 
y} is just as easy and straightforward to me as is to Joe Sixpack who've 
never seen vim before but whom I've just showed how to do it so he can 
benefit?

Moving the mouse to start point, then scanning down the text with the 
both eyes and hands for end point and pressing shift as you click it 
then copying involves 3 time-consuming analogic and imprecise steps that 
simply don't appear when you just want to say "copy block", which is 
what y} just means.  Before the guy even gets to the mouse, I'm done 
already with copying that 100-lines block of text.

Joe Sixpack can do that too, if only he learns the basics.  There's no 
way otherwise with mouse-based solutions... plus, after you copy the 
text with the mouse, the cursor is left away from the original position. 
  Not in vim.

> Oh, I don't think so - he's quite adept with the tools he uses, both on 
> Windows and on Linux.  Just because he doesn't do things the way you and 
> I do doesn't mean he's missing out - he might say the same about us 
> because we are "stuck in our old ways of doing things". ;-)

Ok, kid, now just turn away before your uncle gets back. ;)

-- 
a game sig: http://tinyurl.com/d3rxz9


Post a reply to this message

From: nemesis
Subject: Re: Emacs
Date: 22 Apr 2009 14:51:57
Message: <49ef674d$1@news.povray.org>
Nicolas Alvarez escreveu:
> Jim Henderson wrote:
>> True, but sometimes a bicycle is all you need, you don't need a 747 to
>> take you to the corner market. ;-)
> 
> A coworker told me he once went to IBM to work for a project, and the other
> people there would start Rational Software Architect every time they had to
> change a line of a config file *sigh*

that surely is rational. :)

-- 
a game sig: http://tinyurl.com/d3rxz9


Post a reply to this message

From: nemesis
Subject: Re: Emacs
Date: 22 Apr 2009 15:01:04
Message: <49ef6970@news.povray.org>
Mike Raiford escreveu:
> Warp wrote:
> 
>>   When I press the 'p' key, for some odd reason my intuitive expectation
>> is for the letter 'p' to appear at the cursor's position, but that might
>> be just me.

Come on, Warp, I'm sure you know by now vi is a modal editor and its 
primary mode is command-mode rather than edit.  You have the whole 
alphabetic keys binded to commands and that's what makes it so 
effortless to edit text by typing sequences of such commands rather than 
first getting a virtuoso degree in piano playing to handle emacs complex 
key-chords...

> I've used VI for a semester in a college computer science course.
> 
> I learned to hate it.

Yeah, Professor Foo probably goes like:  "Now type vi file and here are 
some basic commands for you.  Have fun!"  Surely wasn't a vi class and 
it just got in the way of the tasks.  You surely had no time to learn it 
while you were fighting against it to get your assignments done...

And I remember you're the guy who backed down from my text-copying 
challenge in this thread. ;)

-- 
a game sig: http://tinyurl.com/d3rxz9


Post a reply to this message

From: Jim Henderson
Subject: Re: Emacs
Date: 22 Apr 2009 15:53:49
Message: <49ef75cd$1@news.povray.org>
On Wed, 22 Apr 2009 15:25:15 -0300, nemesis wrote:

> Jim Henderson escreveu:
>>>> People doing change-on-the-fly editing using pipes might say that
>>>> it's noobs who use crutches like vim or emacs.
>>> Batch editing with pipes and sed has no place in today's fast-paced
>>> interactive programming.
>> 
>> Oh, I don't know about that.  I had to process a couple hundred e-mail
>> messages, generate PDFs of the contents, and re-send them to myself.
>> Easiest way was to export the messages to a text file and run them
>> through a few awk scripts - using pipes.  Fed the results into another
>> awk script that mailed the stuff back to me.
> 
> That's scripting useful tasks, but I probably got the wording ambiguous
> enough so many people replied about the same as you.  Sure scripting is
> useful programming, but by "interactive programming" I meant using
> proper interactive editing tools to *edit program source code*, not awk,
> sed, ed and pipes cause that surely is insane.

Oh, I see - yeah, there are very rare cases I generate awk code using 
pipes, but I have done it for a practical purpose. :-)

>> There again, you're framing it in terms of your experience.  I'm
>> talking about from someone else's POV.  That's much harder to judge for
>> most people because they're not used to standing in someone else's
>> shoes and saying that the other POV might have a point.
> 
> It's not from my experience at all, not hard to judge for other people.
> 
> I mean, surely being able to select and copy a whole block of text with
> y} is just as easy and straightforward to me as is to Joe Sixpack who've
> never seen vim before but whom I've just showed how to do it so he can
> benefit?

Yeah, for the one task, but then learning what to do with it once he's 
selected it?  People resist change, and if Joe Sixpack knows a different 
tool he's going to naturally prefer that tool.

> Moving the mouse to start point, then scanning down the text with the
> both eyes and hands for end point and pressing shift as you click it
> then copying involves 3 time-consuming analogic and imprecise steps that
> simply don't appear when you just want to say "copy block", which is
> what y} just means.  Before the guy even gets to the mouse, I'm done
> already with copying that 100-lines block of text.

I'm not disputing the time involved - but like I said, people are 
generally predisposed to doing things the way they're used to.

Take Blender, for example - how many discussions in here about the 
difficulty of using the interface have there been?  Yet people who use it 
seem to prefer the interface, and the push back is almost always "if you 
take the time to learn it, you'll find it's much more efficient".

> Joe Sixpack can do that too, if only he learns the basics.  There's no
> way otherwise with mouse-based solutions... plus, after you copy the
> text with the mouse, the cursor is left away from the original position.
>   Not in vim.
> 
>> Oh, I don't think so - he's quite adept with the tools he uses, both on
>> Windows and on Linux.  Just because he doesn't do things the way you
>> and I do doesn't mean he's missing out - he might say the same about us
>> because we are "stuck in our old ways of doing things". ;-)
> 
> Ok, kid, now just turn away before your uncle gets back. ;)

LOL

Jim


Post a reply to this message

From: Jim Henderson
Subject: Re: Emacs
Date: 22 Apr 2009 15:54:53
Message: <49ef760d$1@news.povray.org>
On Wed, 22 Apr 2009 14:15:15 -0300, Nicolas Alvarez wrote:

> Jim Henderson wrote:
>> True, but sometimes a bicycle is all you need, you don't need a 747 to
>> take you to the corner market. ;-)
> 
> A coworker told me he once went to IBM to work for a project, and the
> other people there would start Rational Software Architect every time
> they had to change a line of a config file *sigh*

Gotta love it.

Jim


Post a reply to this message

From: Mike Raiford
Subject: Re: Emacs
Date: 22 Apr 2009 16:00:20
Message: <49ef7754$1@news.povray.org>
nemesis wrote:

> Yeah, Professor Foo probably goes like:  "Now type vi file and here are 
> some basic commands for you.  Have fun!"  Surely wasn't a vi class and 
> it just got in the way of the tasks.  You surely had no time to learn it 
> while you were fighting against it to get your assignments done...

That's exactly how it happened :)

> And I remember you're the guy who backed down from my text-copying 
> challenge in this thread. ;)

... I think I missed something here. What challenge was that?

-- 
~Mike


Post a reply to this message

From: Darren New
Subject: Re: Emacs
Date: 22 Apr 2009 16:59:30
Message: <49ef8532$1@news.povray.org>
nemesis wrote:
> True, that excellent use for the batch tools.  That's also not typical 
> source code editing.

Not in your life, maybe. :-)

-- 
   Darren New, San Diego CA, USA (PST)
   There's no CD like OCD, there's no CD I knoooow!


Post a reply to this message

From: Darren New
Subject: Re: Emacs
Date: 22 Apr 2009 17:03:07
Message: <49ef860b$1@news.povray.org>
Nicolas Alvarez wrote:
> Darren New wrote:
>> What character sequence do you think the backspace key *should* send?
> 
> See the link I posted?

Right. So, in other words, because emacs wants to use control-H for help 
instead of backspace, you have to map the backspace key to a non-standard 
escape sequence somewhere in the kernel of the OS, just in case you're 
running emacs. Gee, thanks for that.

The backspace key *should* send ASCII backspace. But since Emacs broke that, 
they decided to make it send something else, rather than fixing emacs.

-- 
   Darren New, San Diego CA, USA (PST)
   There's no CD like OCD, there's no CD I knoooow!


Post a reply to this message

From: nemesis
Subject: Re: Emacs
Date: 22 Apr 2009 17:22:32
Message: <49ef8a98$1@news.povray.org>
Mike Raiford escreveu:
> nemesis wrote:
> 
>> Yeah, Professor Foo probably goes like:  "Now type vi file and here 
>> are some basic commands for you.  Have fun!"  Surely wasn't a vi class 
>> and it just got in the way of the tasks.  You surely had no time to 
>> learn it while you were fighting against it to get your assignments 
>> done...
> 
> That's exactly how it happened :)

And poor vi has nothing to do with it, really. :)

>> And I remember you're the guy who backed down from my text-copying 
>> challenge in this thread. ;)
> 
> ... I think I missed something here. What challenge was that?

Copy a really big block of text with a mouse and then try y} on vim for 
the same task. ;)

Here's another:  open up some big source file, randomly place the cursor 
somewhere inside, then search for the next call of the nearest function 
being called (supposing it's not being called in the next line sure). 
Copy the next block of text following the function call, then go back to 
where you were and paste it.  Pretty routine source code editing.

In vim it can be done in a automated way, barely looking at what's being 
done:  * j 0 y} 2Ctrl+o o Esc p

* over the function name to search for the next occurrence of name
j to go to next line
0 to go to beginning of line
y} to yank/copy the statements block following the call
2Ctrl-o to go back 2 times in the jump stack (search and copy add to it)
o to add a line below the line where you were in the first place
Esc to get out of insert mode
p to place the copy

It may sound completely alien, but is completely intuitive once you 
learn the basics.  Needless to say, I'd be done with it before the mouse 
guy would still be positioning his cursor beyond the last statement to 
copy and before using page-ups like mad to reach his original location 
-- even if he was smart to bookmark it before... :P

-- 
a game sig: http://tinyurl.com/d3rxz9


Post a reply to this message

From: Mueen Nawaz
Subject: Re: Emacs
Date: 22 Apr 2009 17:22:35
Message: <49ef8a9b$1@news.povray.org>
Mike Raiford wrote:
> I've used VI for a semester in a college computer science course.
> 
> I learned to hate it.

	My hatred for it didn't require any learning.<G>

> BTW, where did the combinations Ctrl-Ins(Copy), Shift-Del(Cut) and
> Shift-Ins(Paste) come from? I remember them from the DOS text editors
> for QuickBASIC and such...

	According to Wikipedia, those bindings were the standard from some IBM
systems. The ^C and ^V ones are actually from Apple.

-- 
"The security of the Enterprise is of Paramount importance.


                    /\  /\               /\  /
                   /  \/  \ u e e n     /  \/  a w a z
                       >>>>>>mue### [at] nawazorg<<<<<<
                                   anl


Post a reply to this message

From: nemesis
Subject: Re: Emacs
Date: 22 Apr 2009 17:34:02
Message: <49ef8d4a$1@news.povray.org>
Darren New escreveu:
> nemesis wrote:
>> True, that excellent use for the batch tools.  That's also not typical 
>> source code editing.
> 
> Not in your life, maybe. :-)

Now, come on, man!  Are you really saying you're one of those legendary 
*nix real programmers writing code with cat, then editing with ed, sed 
and awk pipes?

-- 
a game sig: http://tinyurl.com/d3rxz9


Post a reply to this message

From: nemesis
Subject: Re: Emacs
Date: 22 Apr 2009 17:35:36
Message: <49ef8da8$1@news.povray.org>
Mueen Nawaz escreveu:
> Mike Raiford wrote:
>> I've used VI for a semester in a college computer science course.
>>
>> I learned to hate it.
> 
> 	My hatred for it didn't require any learning.<G>

Then I guess you have no right for it. ;)

-- 
a game sig: http://tinyurl.com/d3rxz9


Post a reply to this message

From: Jim Henderson
Subject: Re: Emacs
Date: 22 Apr 2009 17:37:17
Message: <49ef8e0d@news.povray.org>
On Wed, 22 Apr 2009 16:22:35 -0500, Mueen Nawaz wrote:

> The ^C and ^V ones are actually from Apple.

I seem to remember that they come from Wordstar - ^KC for copy and ^KV 
for paste IIRC.

Jim


Post a reply to this message

From: Mike Raiford
Subject: Re: Emacs
Date: 23 Apr 2009 09:04:00
Message: <49f06740@news.povray.org>
Darren New wrote:

> The backspace key *should* send ASCII backspace. But since Emacs broke 
> that, they decided to make it send something else, rather than fixing 
> emacs.

What about EBCDIC backspace (0x16)?


-- 
~Mike


Post a reply to this message

From: Mike Raiford
Subject: Re: Emacs
Date: 23 Apr 2009 09:17:05
Message: <49f06a51@news.povray.org>
nemesis wrote:
> Mike Raiford escreveu:
>> nemesis wrote:
>>
>>> Yeah, Professor Foo probably goes like:  "Now type vi file and here 
>>> are some basic commands for you.  Have fun!"  Surely wasn't a vi 
>>> class and it just got in the way of the tasks.  You surely had no 
>>> time to learn it while you were fighting against it to get your 
>>> assignments done...
>>
>> That's exactly how it happened :)
> 
> And poor vi has nothing to do with it, really. :)
> 
>>> And I remember you're the guy who backed down from my text-copying 
>>> challenge in this thread. ;)
>>
>> ... I think I missed something here. What challenge was that?
> 
> Copy a really big block of text with a mouse and then try y} on vim for 
> the same task. ;)
> 
> Here's another:  open up some big source file, randomly place the cursor 
> somewhere inside, then search for the next call of the nearest function 
> being called (supposing it's not being called in the next line sure). 
> Copy the next block of text following the function call, then go back to 
> where you were and paste it.  Pretty routine source code editing.
> 
> In vim it can be done in a automated way, barely looking at what's being 
> done:  * j 0 y} 2Ctrl+o o Esc p
> 
> * over the function name to search for the next occurrence of name
> j to go to next line
> 0 to go to beginning of line
> y} to yank/copy the statements block following the call
> 2Ctrl-o to go back 2 times in the jump stack (search and copy add to it)
> o to add a line below the line where you were in the first place
> Esc to get out of insert mode
> p to place the copy
> 
> It may sound completely alien, but is completely intuitive once you 
> learn the basics.  Needless to say, I'd be done with it before the mouse 
> guy would still be positioning his cursor beyond the last statement to 
> copy and before using page-ups like mad to reach his original location 
> -- even if he was smart to bookmark it before... :P
> 

Hmmm Let see .. (This is visual studio, so YMMV)

Ctrl-F3 (Find next occurrence)
Down Arrow
Home
Ctrl-I } <enter>
Ctrl-=
Ctrl-c
3xCtrl--
Down Arrow
Enter
Ctrl-v

A few more keystrokes, but comparable.
-- 
~Mike


Post a reply to this message

From: Mueen Nawaz
Subject: Re: Emacs
Date: 23 Apr 2009 10:14:30
Message: <49f077c6$1@news.povray.org>
Jim Henderson wrote:
> On Wed, 22 Apr 2009 16:22:35 -0500, Mueen Nawaz wrote:
> 
>> The ^C and ^V ones are actually from Apple.
> 
> I seem to remember that they come from Wordstar - ^KC for copy and ^KV 
> for paste IIRC.

	Here's what Wikipedia says (and doesn't say it definitively...):

Apple Computer widely popularized the computer-based cut-and-paste
paradigm through the Lisa (1981) and Macintosh (1984) operating systems
and applications. Apple mapped the functionalities to key-combinations
consisting of a special modifier key held down while typing the letters
X (for cut), C (for copy), and V (for paste), choosing a handful of
keyboard sequences to control basic editing operations. The keys
involved all cluster together at the left end of the bottom row of the
standard QWERTY keyboard, and each key is combined with a control or
special modifier key to perform the desired operation:

    * Z to undo
    * X to cut
    * C to copy
    * V to paste

CUA (for OS/2) also uses combinations of the Insert, Del, Shift and
Control keys. Early versions of Windows used the IBM standard. Microsoft
later adopted similar key-combinations with the introduction of Windows.


-- 
"The security of the Enterprise is of Paramount importance.


                    /\  /\               /\  /
                   /  \/  \ u e e n     /  \/  a w a z
                       >>>>>>mue### [at] nawazorg<<<<<<
                                   anl


Post a reply to this message

From: nemesis
Subject: Re: Emacs
Date: 23 Apr 2009 12:59:02
Message: <49f09e56@news.povray.org>
Mike Raiford escreveu:
> nemesis wrote:
>> Here's another:  open up some big source file, randomly place the 
>> cursor somewhere inside, then search for the next call of the nearest 
>> function being called (supposing it's not being called in the next 
>> line sure). Copy the next block of text following the function call, 
>> then go back to where you were and paste it.  Pretty routine source 
>> code editing.
>>
>> In vim it can be done in a automated way, barely looking at what's 
>> being done:  * j 0 y} 2Ctrl+o o Esc p
>>
>> * over the function name to search for the next occurrence of name
>> j to go to next line
>> 0 to go to beginning of line
>> y} to yank/copy the statements block following the call
>> 2Ctrl-o to go back 2 times in the jump stack (search and copy add to it)
>> o to add a line below the line where you were in the first place
>> Esc to get out of insert mode
>> p to place the copy
>>
>> It may sound completely alien, but is completely intuitive once you 
>> learn the basics.  Needless to say, I'd be done with it before the 
>> mouse guy would still be positioning his cursor beyond the last 
>> statement to copy and before using page-ups like mad to reach his 
>> original location -- even if he was smart to bookmark it before... :P
>>
> 
> Hmmm Let see .. (This is visual studio, so YMMV)
> 
> Ctrl-F3 (Find next occurrence)
> Down Arrow
> Home
> Ctrl-I } <enter>
> Ctrl-=
> Ctrl-c
> 3xCtrl--
> Down Arrow
> Enter
> Ctrl-v
> 
> A few more keystrokes, but comparable.

I see you chose to ditch the mouse, which the original challenge was 
about.  Good for you anyway! :)

BTW, 2Ctrl+o is just that:  press 2, press Ctrl+o. ;)  No need to press 
it 2 or 3 times... May not sound much for short repetitions where indeed 
repressing the same key may be faster, but for numerous repetitious it 
can be very worth it, like yy10p to copy the current line and paste it 
10 times bellow.

As far as I know, VS has emacs keyboard shortcuts emulation, so it 
surely must have similar editings capabilities.  I know I had set up it 
once to do the wonderful copy buffer cycling.  I also know Netbeans has 
keyboard shortcuts resembling vi.  Not really surprising coming from 
Bill Joy's Sun Microsystems.

Anyway, someone suggested mouse would make emacs (and vim by extension) 
obsolete, but this is clearly dull as the mouse is an imprecise analogic 
tool which simply can't compare to the ease of discrete and concise 
commands typed as keyboard shortcuts...

I rest my case. :)

-- 
a game sig: http://tinyurl.com/d3rxz9


Post a reply to this message

From: Mike Raiford
Subject: Re: Emacs
Date: 23 Apr 2009 13:24:29
Message: <49f0a44d$1@news.povray.org>
nemesis wrote:

> 
> Anyway, someone suggested mouse would make emacs (and vim by extension) 
> obsolete, but this is clearly dull as the mouse is an imprecise analogic 
> tool which simply can't compare to the ease of discrete and concise 
> commands typed as keyboard shortcuts...

Yeah... no. I still use a lot of keyboard shortcuts. When using 
Photoshop, for example, I usually have the tablet's stylus in my right 
hand, and my left hand over the keyboard. I rarely do any "mousing" with 
the stylus. Everything that needs to be done usually has a keyboard 
shortcut. :)

> I rest my case. :)
> 

Yep. But it was the quickest way I could think of. Granted I do scroll 
through a lot with the mouse, or use the drop-down lists to navigate to 
a specific function within a class. I'm also the type that tends to use 
regular expressions to change things en masse.

But here it is with the mouse involved...:

^F3
In the left column, mouse down, drag until you see the first } Mouse Up
^C
^- x2
^V


-- 
~Mike


Post a reply to this message

From: Jim Henderson
Subject: Re: Emacs
Date: 23 Apr 2009 13:58:32
Message: <49f0ac48$1@news.povray.org>
On Thu, 23 Apr 2009 09:14:30 -0500, Mueen Nawaz wrote:

> and doesn't say it definitively..

That's the part I'm having trouble with.  ISTR that WordStar predated 
Apple, and I'm pretty sure that those control codes (the ^K prefixed 
ones) were correct in WordStar.

Jim


Post a reply to this message

From: Jim Henderson
Subject: Re: Emacs
Date: 23 Apr 2009 14:10:37
Message: <49f0af1d@news.povray.org>
On Thu, 23 Apr 2009 13:58:32 -0400, Jim Henderson wrote:

> On Thu, 23 Apr 2009 09:14:30 -0500, Mueen Nawaz wrote:
> 
>> and doesn't say it definitively..
> 
> That's the part I'm having trouble with.  ISTR that WordStar predated
> Apple, and I'm pretty sure that those control codes (the ^K prefixed
> ones) were correct in WordStar.

Found a reference that confirms my memory - ^KV was "move" not "paste", 
but otherwise I recall pretty much correctly.

http://www.glinx.com/~grifwood/WSCOMSUM.PDF

WordStar was first developed for CP/M in 1978; Apple was founded in 1976 
(incorporated in 1977), so they may have beaten Wordstar to the punch 
there, though the bit you cited said it was popularlized in 1981 with the 
Lisa, so it's possible that they were following a modified version of 
WordStar's choices or they came up with them independently.

Jim


Post a reply to this message

<<< Previous 50 Messages Goto Initial 50 Messages

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.