Quantcast
Channel: Embarcadero Community - Embarcadero Community
Viewing all articles
Browse latest Browse all 1888

Define editor macros - increasing productivity

$
0
0

Hello,

I heavily comment my sources, mostly by placing a "// ..." comment at the end of the line. While this has saved me many times trying to understand what I meant in my code a decade ago, it does take time. I don't mind typing the comments, but a relatively huge part of my life is spent on the following dumb and repetitive task:

  • bring the cursor just in front of the last "//" in the line
  • press the spacebar as many times as necessary to bring the end of the comment into a predefined position.

The first of the two phases is particularly painful: since Ctrl-Left/Right IGNORES "//"s, it usually involves a horrendously long series of Ctrl-Left/Rights followed by plain Left/Rights to get the cursor just in front of the last "//" in the line. When you talk about several millions of lines needing that, you realize the staggering waste of time.

I would like to do the above two bullets in a single stroke, say "Ctrl-Shift-/" - is there a way to define an editor macro to that purpose in 10.1 Berlin?

Many thanks for your help!

 

P.S. To give you the perspective: spending just 5 seconds on the two bullets on ten million lines (and I've already written far more than that) yields nearly two years of my life spent just chasing and pushing the "//"s!  :-O :-O   I don't even dare to imagine how much actual code I could have written in those two years...


Viewing all articles
Browse latest Browse all 1888

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>