Friday finking: IDE 'macro expansions'

Mats Wichmann mats at wichmann.us
Thu Mar 16 19:29:44 EDT 2023


On 3/16/23 16:55, dn via Python-list wrote:
> It is a long, long, time since I've thrown one of these into the 
> maelstrom of our musings.
> (have the nightmares receded?)
> 
> 
> Do you make use of your IDE's expansionist tendencies, and if-so, which 
> ones?
> 
> 
> NB this is where vi/emacs enthusiasts start chuckling (polite term for 
> 'insane cackling'). Hence the question's limitation to IDEs, cf 'editors'!
> Also: I'm talking 'PyCharm' because of the story, but others use Codium, 
> Sublime Text, etc - which presumably offer equivalent features.
> 
> 
> Was helping a friend install PyCharm. Jumped into the Settings. Isn't it 
> incredible how many there are?
> 
> Idly noted that there are two short-cut or macro-expansion types of 
> facilities:
> - Postfix Completion, (nothing to do with email or polish notation) and
> - Live Templates (again, we're not talking about jinja2)
> 
> 
> With both, one types an abbreviated-name and the IDE will expand it into 
> appropriate code. For (LiveTemplate) example, typing compli and pressing 
> Tab induces PyCharm to add the following to the program[me]:
> 
>      [ ! for ! in !drop-down menu! if ! ]
> 
> It offers further typo-saving through the drop-down menu which lists a 
> bunch of likely (iterable) candidates from amongst previously-written 
> code. The action continues after selecting from the menu, by inviting 
> completion of the other ("!") placeholders, in-turn.
> 
> 
> I haven't made use of such a tool, to-date - OK, yes, I have practised a 
> high typing-speed (and accuracy). Puff, puff...
> 
> Also, at the time, I'm thinking in 'code', rather than about what tool 
> might implement said ideas.
> 
> 
> Do you make use of such expansionist-tendencies?
> 
> Do you make use of other powerful features within the IDE, or are its 
> editor functionalities employed at pretty-much the NotePad level?

Not sure the purpose of the "survey" but - no, I don't use these.  IDEs 
are incredible things, but you need to invest yourself completely in 
them, basically live in them, or there's not that much payback. There's 
just too much to remember, and honestly, too much mouse movement needed, 
especially if you have a big screen. In the PyCharm case, the startup 
time is incredibly slow, so, since I don't "live in it", I don't use it 
much any more - there are some things it does superbly, but it's such a 
cost to fire it up just for those I pretty much don't bother any more.



More information about the Python-list mailing list