Re: [GEN] Template Handler

new topic     » goto parent     » topic index » view thread      » older message » newer message

Since my "Template Handler" needs Templates to be useful, and they would
presumably be added semi-regularly, I have to make some nice simple way to
accomplish this "update".

Here's what I have thought of, maybe you all can see flaws or improvements
for it?

TEMPLATE UPDATE FEATURE DETAILS:

1.  An "update" file would have TWO parts:
   a)  new FILES (ie, new CATEGORIES of templates);
   b)  new TEMPLATES to be added to EXISTING categories;

2.  The "update facility" would read in the update file, put all of the NEW
FILES info into ONE VARIABLE (or section of a sequence), all of NEW
TEMPLATES into ANOTHER variable (or second part of main);

3.  Update facility *compares* FILENAMES from update file against a dir of
folder;  puts all filenames *not* in dir into a combo box, asks user to
either select which ones to add, or "add all";  selected new files are
written to new template files;

4.  Update facility then compares NEW template NAMES against names in
existing appropriate categories (each category is a separate file); puts any
"new" templates NOT already in an existing file into a tabbed folder of
combo boxes, with ability to select which to add, and an "add all in this
category" button; also an overall "add *all* new templates" button outside
tabbed folder; selected templates are written to end of existing template
files.

5.  The "Templates Update File" NAME might be something like:  UpdTempl.AA1
(incrementing the extent for each new update, so people could know if they
have updated with it before or not); and after an update, user given choice
to either DELETE the file which just updated the Templates, or to SAVE it as
"BakTempl.AA1"

Does this make sense, or have I missed something that should be done to make
updating templates easy?

Dan Moyer

----- Original Message -----
From: "Dan Moyer"
>
> I've sent Robert a program called "Template Handler", which intends to
make
> it easy to store & retrieve snippets or "templates" of code, for both
> Euphoria and Win32Lib (could be extended to EDS etc, too).  Anyone who's
> interested, please check it out & let me know what you think of it.
>
> It seems to work well, except I don't have many TEMPLATES to include
> with it!
>
> So I'm hoping maybe some of you will contribute code snippets for
> it.  You could either *use* the Template Handler to create template
> contributions (good exercise for it), or just send code snippets here so
> others could comment upon or improve them (could make for better
snippets).
>
> With "comment or improve" in mind, here's a sample template I might
include
> with it later (if you want to use it with the Handler, just save it to a
> file and use an extent ".etp", for "Euphoria TemPlate"); it has two
> templates in it, and the Handler does NOT show all the "!!" comments, just
> the name, description, and code.
>
> Dan Moyer
>
> following could be put into a file, eg "Seq1.etp", to use with the
handler:
>
<snip proto-template>

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu