[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [StrongED] Inserting snippets
On 2017-12-30 11:21, Richard Torrens (lists) wrote:
Fred
Before we learn how to insert them - can you please say what snippets
are
and how they can be used etc.?
A search in StrongHelp reveals no mention - though searching the text
extracted therefrom does reveal several mentions, but no information on
what, how or why!
The concept exists in lots of text editors... under different names.
It's
simply that when editing a set of files there may be a set of small bits
of text that you very often want to insert into that sort of file.
If you were writing lots of letters, you might want to insert your home
address and date, and a Dear Sir. You might have a canned 'Yours in the
hope that we'll meet again, love, Richard" and maybe a few other final
phrases.
If you were writing programs in a particular language you might have a
set of favourite basic procedure or function definitions that - with
slight variations - you copy into many new programs. For example you
might have a 'standard' copyright declaration and a 'standard' way of
formatting an initial description of the program's purpose, call syntax,
parameters, return codes etc. You might have a standard 'empty' proc
or function definition, and a standard skeleton error handler ... or
several of these suited to different sorts of programs.
Without snippets you probably start new files by copying existing ones
and deleting the bits you don't need; you maybe also keep a few other
files open at the same time so you can farly easily c&p stuff from one
to the other. With snippets, you can quickly find common chunks of
text that you frequently use, to use again, without having to keep
other files open to c&p from.
Anyway, snippet support in general allows a set of small texts to be
stored somewhere and loaded into the current file very easily. I do
not know if SE stores separate sets of snippets per mode, or globally
somewhere, or indeed per 'project' (whatever that might mean here).
--
Jeremy Nicoll - my opinions are my own
--
To unsubscribe send a mail to StrongED+unsubscribe@xxxxxxxxxxx
List archives at http://diy.Torrens.org/RO/StrongED/index.html