Below is another version of the tlg utilities for cgreek, with minor corrections and a little additional functionality. Thanks to suggestions from a number of list members, I now have a mode-line that at least seems to work with the display of the current reference (eventually, I may actually learn something about emacs-lisp!). I made one very minor aesthetic change in tlg-idt.lex (in the lisp code it emits, the variable 'works' is now 'tlg-works'). There is now a tlg-mode defined, which sets the mode-line. I have changed tlg-getref and some related functions: the citation at point is now stored in tlg-current-ref, which is updated by tlg-update-current-ref. That function is in turn added locally to post-command-hook (seems not to slow things down noticeably). Some of the things formerly being done by tlg-open-single-work are now in tlg-mode (which tlg-open-single-work turns on). Left to do (apart from hosts of other things you will all probably spot): 1. Translate the work titles from beta code into Greek. I could do this by modifying tlgidt2emacs, but it seems better to have just one scanner for translating beta code (tlg2emacs). The only idea I have at this point is to run tlg2emacs (or a slightly hacked version thereof) as an asynchronous process in emacs. Strings to be translated are just sent to the process and retrieved via a filter function. This might be wasteful of memory, and it does sound like a kludge, but coding the translation process into emacs-lisp seems far too complicated. 2. Make the reference citations look nicer. At present, I just present a string of all the six possible reference values, separated by '*'. Since most values are typically not used, this results in a ref string that begins with a string of '*'. tlg-getref should probably be rewritten to ignore nil values. 3. Make some use of the "level" names. The idt file contains in it the names of those levels which are actually used (e.g. "Bekker page", "line number"). These might be useful in several places, e.g. as prompts in tlg-goto-ref, or in tlg-display-current-ref. 4. Lots of little uglinesses: I'm not currently putting very good titles in the buffer names created by tlg-find-idt-file, and that could be fixed (get the author name from the line in *TLG Author List*, for instance). 5. There seem to be problems getting these things to work on Meadow. I don't have access to a copy of Meadow (I'd probably have to run it under Wine). has anyone any idea what's causing the trouble? My ignorance here is essentially total. 6. I've used a single very trivial function from tl-list.el, and I gather not everyone has this library. I should probably just write the same three-line function into tlg-util.el, but I haven't done that yet. As a longer term project, I do have the format descriptions of the TLG index files (there are dozens of these), including the word list and the index of word occurrences. Someone needs to write code to look up word forms in these and retrieve occurrences. I'll get them scanned and circulate them to the list. Another utility that would be useful is a function to search for words while ignoring diacritical marks. I have not done any work on this; has anyone else? The latest version is below (I have begun using obvious version names for the tarball), as well as a patch to update from the previous version. As always, I hope that these utilities are actually useful to some of you. Thanks for your kind words about my programming efforts. Robin Smith Department of Philosophy rasmith@xxxxxxxx Texas A&M University Voice (409) 845-5696 College Station, TX 77843-4237 FAX (409) 845-0458
Attachment:
cgreek-tlg.2000.07.21.tgz
Description: Binary data
Attachment:
cgreek-tlg.2000.07.19-2000.07.21.patch
Description: Binary data