Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.arch.embedded > #13272

Re: Editor recommendation

From Stefan Reuther <stefan.news@arcor.de>
Newsgroups comp.arch.embedded
Subject Re: Editor recommendation
Date 2013-08-31 11:36 +0200
Message-ID <kvskgp.ao.1@stefan.msgid.phost.de> (permalink)
References (6 earlier) <kvoe7l$1bk$1@speranza.aioe.org> <10620464-8d66-4b18-b344-b466079bbc27@googlegroups.com> <kvoqup$uo4$1@speranza.aioe.org> <b8bdjcFel7tU1@mid.dfncis.de> <kvr4ld$4nl$1@speranza.aioe.org>

Show all headers | View raw


Don Y wrote:
> On 8/30/2013 4:22 AM, Hans-Bernhard Bröker wrote:
>> E.g., and just because this
>> particular editor hasn't been mentioned yet: in plain old vi, that
>> would be
>>
>> :1,$s/<Figure \([^:]*\): continued on Page \([^)]\)>/<Illustration \1:
>> <italic>(see page \2)<\italic>>/g
>>
>> (all in one line, not really tested)
> 
> And *that* is the problem ^^^^^^^^^^^^!  Unless you want to invest
> lots of time learning to be an RE guru (and then complaining when
> some tool doesn't support them!), you're never quite sure you've
> got it right when you hit ENTER.

If you got it wrong, every editor worth its money allows you to undo and
try again. No problem.

> Write a piece of code to perform the same sort of thing and you
> can easily (i.e., with a high degree of success) change a stub
> that emits "found <foo> at file offset <x>; replacing with <bar>"
> (i.e., used to let you preview the actions that the code will
> ultimately take) with one that writes <bar> directly to the desired
> output file (without fear of overwriting the original input!).

If you asked me to write that piece of code, it would most likely be a
Perl one-liner looking almost like Hans-Bernhard's vi snippet. Normally
I do such things using Emacs' query-replace-regexp, though, because that
saves me one level of escaping.

> And, there are problems that just don't lend themselves to an RE
> sort of solution (e.g., transposing a matrix is easy to do with
> keystroke macros or "a piece of code" -- considerably harder
> "out of the gate" with a set of RE's!)

And this is where an editor with a pipe-block-through-a-program function
comes in handy. That single feature alone is enough reason for me to use
Emacs; all of the "modern" IDEs lack it.

>> And you really shouldn't be.  Any programmer's editor really worth
>> having has some sort of "rectangle fill" feature.  E.g. in Notepad++,
>> you would just <Alt>-mark the column (i.e. drag the mouse while holding
>> <Alt>, or move the cursor from one end to the other while holding
>> Alt+Shift), then type a single $.  Done.  For more complicated cases, it
>> can even fill in a sequence of numbers
> 
> Do you *only* deal with "programmer's editors"?

Most of the time.

> E.g., when I type
> code fragments into a FrameMaker document (to formally document
> something that I've created), *where* the cursor ends up if I type
> <down_arrow> depends on my position in the current line and
> the "font" used on that line and the line that follows.  The
> idea of a "rectangular fill/copy/delete" simply doesn't apply
> (note that this isn't just the proportional/fixed width font
> issue but also the *sizes* of the typefaces comes into play!)
> 
> What's the keystroke sequence to cut/paste/fill a rectangular region
> while composing in Thunderbird?  (or, do you never share code
> fragments with colleagues electronically)
> 
> Should I keep Emacs open in a second window, type whatever "code"
> I want in that window (using the tools emacs makes available to
> me) and then *paste* it into whatever application I happen to
> be *actively* working in at the time?

Actually, that's what I often do. I draft a piece of code in Emacs, and
when I got it ready, paste it into Word, or Thunderbird, or whatever is
needed at the time (or from the C file into the LaTeX file in Emacs).

> Over the years, I've found that the more "features" you rely on,
> the more you *need* those features in your normal workflow.

So what? I spend my whole workday in front of an editor, so of course I
try to make that as efficient as possible. Of course I *can* write C
with Notepad, but that is very efficient for programs exceeding the
complexity of a "hello world" (... "blink LED", "jump to reset vector").

Your argument sounds like telling your carpenter he should use fewer
tools so he doesn't rely on them in his normal workflow. After all, he
can probably build a house with nothing more than a sharp screwdriver.


  Stefan

Back to comp.arch.embedded | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Editor recommendation Roberto Waltman <usenet@rwaltman.com> - 2013-08-28 16:18 -0400
  Re: Editor recommendation David Brown <david.brown@removethis.hesbynett.no> - 2013-08-28 22:46 +0200
    Re: Editor recommendation chris <meru@devnull.com> - 2013-08-28 22:10 +0000
      Re: Editor recommendation dp <dp@tgi-sci.com> - 2013-08-29 09:23 -0700
        Re: Editor recommendation Simon Clubley <clubley@remove_me.eisner.decus.org-Earth.UFP> - 2013-08-29 17:15 +0000
          Re: Editor recommendation dp <dp@tgi-sci.com> - 2013-08-29 10:38 -0700
            Re: Editor recommendation Simon Clubley <clubley@remove_me.eisner.decus.org-Earth.UFP> - 2013-08-29 17:49 +0000
              Re: Editor recommendation dp <dp@tgi-sci.com> - 2013-08-29 12:19 -0700
          Re: Editor recommendation Paul Rubin <no.email@nospam.invalid> - 2013-08-29 12:16 -0700
        Re: Editor recommendation Don Y <this@isnotme.com> - 2013-08-29 11:32 -0700
          Re: Editor recommendation Paul Rubin <no.email@nospam.invalid> - 2013-08-29 12:15 -0700
          Re: Editor recommendation dp <dp@tgi-sci.com> - 2013-08-29 14:04 -0700
            Re: Editor recommendation Don Y <this@isnotme.com> - 2013-08-29 14:25 -0700
              Re: Editor recommendation Robert Wessel <robertwessel2@yahoo.com> - 2013-08-29 17:05 -0500
                Re: Editor recommendation Don Y <this@isnotme.com> - 2013-08-29 16:32 -0700
              Re: Editor recommendation dp <dp@tgi-sci.com> - 2013-08-29 15:44 -0700
                Re: Editor recommendation Don Y <this@isnotme.com> - 2013-08-29 18:02 -0700
                Re: Editor recommendation Hans-Bernhard Bröker <HBBroeker@t-online.de> - 2013-08-30 13:22 +0200
                Re: Editor recommendation Don Y <this@isnotme.com> - 2013-08-30 15:00 -0700
                Re: Editor recommendation Hans-Bernhard Bröker <HBBroeker@t-online.de> - 2013-08-31 02:17 +0200
                Re: Editor recommendation Stefan Reuther <stefan.news@arcor.de> - 2013-08-31 11:36 +0200
          Re: Editor recommendation Randy Yates <yates@digitalsignallabs.com> - 2013-08-30 20:30 -0400
            Re: Editor recommendation Don Y <this@isnotme.com> - 2013-08-31 00:50 -0700
              Re: Editor recommendation Stefan Reuther <stefan.news@arcor.de> - 2013-08-31 11:54 +0200
                Re: Editor recommendation Randy Yates <yates@digitalsignallabs.com> - 2013-08-31 10:17 -0400
                Re: Editor recommendation Randy Yates <yates@digitalsignallabs.com> - 2013-08-31 10:20 -0400
        Re: Editor recommendation chris <meru@devnull.com> - 2013-08-30 13:29 +0000
          Re: Editor recommendation dp <dp@tgi-sci.com> - 2013-08-30 15:04 -0700
    Re: Editor recommendation George Neuner <gneuner2@comcast.net> - 2013-08-30 13:05 -0400
      Re: Editor recommendation chris <meru@devnull.com> - 2013-08-30 22:55 +0000
  Re: Editor recommendation Les Cargill <lcargill99@comcast.com> - 2013-08-28 21:22 -0500
    Re: Editor recommendation Don Y <this@isnotme.com> - 2013-08-28 19:54 -0700
      Re: Editor recommendation Les Cargill <lcargill99@comcast.com> - 2013-08-28 22:28 -0500
        Re: Editor recommendation Don Y <this@isnotme.com> - 2013-08-28 22:38 -0700
    Re: Editor recommendation George Neuner <gneuner2@comcast.net> - 2013-08-30 12:42 -0400
      Re: Editor recommendation Paul Urbanus <urb@urbonix.com> - 2013-09-02 21:20 -0500
        Re: Editor recommendation Paul Urbanus <urb@urbonix.com> - 2013-09-04 01:20 -0500
        Re: Editor recommendation Randy Yates <yates@digitalsignallabs.com> - 2013-09-04 07:22 -0400
  Re: Editor recommendation Don Y <this@isnotme.com> - 2013-08-28 19:52 -0700
  Re: Editor recommendation bbhack <bbhack@gmail.com> - 2013-08-28 22:41 -0500
    Re: Editor recommendation chris <meru@devnull.com> - 2013-08-29 12:19 +0000
      Re: Editor recommendation bbhack <bbhack@gmail.com> - 2013-08-31 11:54 -0500
        Re: Editor recommendation chris <meru@devnull.com> - 2013-09-03 15:32 +0000
  Re: Editor recommendation Tauno Voipio <tauno.voipio@notused.fi.invalid> - 2013-08-29 09:19 +0300
  Re: Editor recommendation Roberto Waltman <usenet@rwaltman.com> - 2013-08-29 10:01 -0400
    Re: Editor recommendation Tauno Voipio <tauno.voipio@notused.fi.invalid> - 2013-08-29 18:45 +0300
    Re: Editor recommendation Don Y <this@isnotme.com> - 2013-08-29 12:04 -0700
      Re: Editor recommendation Robert Wessel <robertwessel2@yahoo.com> - 2013-08-29 16:31 -0500
        Re: Editor recommendation Don Y <this@isnotme.com> - 2013-08-29 15:00 -0700
        Re: Editor recommendation Randy Yates <yates@digitalsignallabs.com> - 2013-08-30 20:50 -0400
      Re: Editor recommendation Randy Yates <yates@digitalsignallabs.com> - 2013-08-30 20:37 -0400
        Re: Editor recommendation Don Y <this@isnotme.com> - 2013-08-30 21:15 -0700
          Re: Editor recommendation Stefan Reuther <stefan.news@arcor.de> - 2013-08-31 12:05 +0200
            Re: Editor recommendation Don Y <this@isnotme.com> - 2013-08-31 11:26 -0700
              Re: Editor recommendation Stefan Reuther <stefan.news@arcor.de> - 2013-09-01 20:21 +0200
                Re: Editor recommendation Don Y <this@isnotme.com> - 2013-09-01 17:02 -0700
                Re: Editor recommendation Stefan Reuther <stefan.news@arcor.de> - 2013-09-02 19:55 +0200
                Re: Editor recommendation Don Y <this@isnotme.com> - 2013-09-02 16:22 -0700
                Re: Editor recommendation Randy Yates <yates@digitalsignallabs.com> - 2013-09-02 19:39 -0400
                Re: Editor recommendation Don Y <this@isnotme.com> - 2013-09-02 17:51 -0700
                Re: Editor recommendation Don Y <this@isnotme.com> - 2013-09-02 18:49 -0700
          Re: Editor recommendation Randy Yates <yates@digitalsignallabs.com> - 2013-08-31 15:13 -0400
            Re: Editor recommendation Don Y <this@isnotme.com> - 2013-08-31 13:45 -0700
  Re: Editor recommendation Habib Bouaziz-Viallet <h.bouazizviallet@free.fr> - 2013-08-29 16:31 +0200
    Re: Editor recommendation bbhack <bbhack@gmail.com> - 2013-08-31 12:03 -0500
      Re: Editor recommendation Randy Yates <yates@digitalsignallabs.com> - 2013-08-31 13:27 -0400
        Re: Editor recommendation bbhack <bbhack@gmail.com> - 2013-08-31 13:17 -0500
      Re: Editor recommendation Habib Bouaziz-Viallet <h.bouazizviallet@free.fr> - 2013-09-01 19:16 +0200
        Re: Editor recommendation Randy Yates <yates@digitalsignallabs.com> - 2013-09-01 19:52 -0400
          Re: Editor recommendation chris <meru@devnull.com> - 2013-09-03 14:41 +0000
  Re: Editor recommendation jhallen@TheWorld.com (Joseph H Allen) - 2013-08-29 20:09 +0000
  Re: Editor recommendation stephenXXX@mpeforth.com (Stephen Pelc) - 2013-09-04 12:10 +0000

csiph-web