|
From: | dzach |
Subject: | [Therion] automatic template insertion |
Date: | Fri, 16 Sep 2005 15:11:35 +0300 |
User-agent: | Mozilla Thunderbird 1.0.2 (Windows/20050317) |
Continuing on possible improvements of Xtherion, a quote from the therion:faq-How
to enter centreline? in the wiki offers a hint: "It’s handy to start with an empty template file as shown bellow, where the dots will be replaced with appropriate text." For a newbie, it would be better if the template text could be inserted automatically in a new text file (following an option "Use template" in the relevant panel). To do that, create a text file named text.tpl, paste the following template text in it and save. encoding ISO8859-1 survey ... -title "..." centreline team "..." team "..." date ... units clino compass grad data normal from to compass clino length ... ... ... ... ... endcentreline endsurveyNext, add the following tcl code at the very end of proc xth_te_create_file, just before the closing bracket: if {[glob -nocomplain text.tpl] ne {}} { xth_te_insert_text $cfr.txt [read [open "text.tpl" r]] } From now on, when you open a new text editor file, you will have the
template text inserted automatically at the begining. |
_______________________________________________ Therion mailing list address@hidden http://www.speleo.cz/mailman/listinfo/therion
[Prev in Thread] | Current Thread | [Next in Thread] |