Skip to Content
0

AdT Code-Templates - using them without ${word_selection} ?

Jan 12, 2017 at 12:25 PM

131

avatar image

I'd like an "insert only" template, but have the following problems:

1. If nothing is highlighted, CTRL-+space does nothing.

2. If I do highlight e.g. an empty line, I get the template list, however, templates that don't contain the ${word_selection} don't show up there.

I worked around this by putting ${word_selection} at the start of my template, but I really have the feeling that I might be using the wrong tool for my task...

is that the case? What would be a better Tool?

Thanks

Joachim

10 |10000 characters needed characters left characters exceeded

Sorry, the Initial lines where missing: (and I cant Edit because of "

An Internal error has occurred and we are sorry for the inconvenience.")

I read Thomas' Blog on Code-Templates, and I do get an idea iof how powerfull the are.

However, they seem mainly be made for "surrounding" one's code, right?

0
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Best Answer
Armin Beil
Jan 13, 2017 at 09:09 AM
0

Hi Joachim,

to use code templates that are not surrounding a selection but instead are entering something completely new you can do it this way:

Start typing the name of the template (first 2-3 characters) just as if it was code and press ctrl-space. This should bring up the list of suggestions that also contains templates. Once a template is chosen the previously entered characters (beginning of template name) are replaced with the content of the template.

Best regards,
Armin

Show 1 Share
10 |10000 characters needed characters left characters exceeded

Hey Armin,

ok, that works fine!

Thanks!

Joachim

0