[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [StrongED] "wrapwidth" setting

Peter Young <pnyoung@xxxxxxxxxxxx> wrote:

> That would be useful for me, in viewing SyncDisc's logfiles, which open in
> Base Mode...

One of the useful things about SE is the ease with which new modes can be
created.  I used to do this eg for (my own version of) AntiSpam, where by
making a copy of the Basemode files and then changing them I created modes
for both AntiSpam logs and rules files.  

I set up in each mode the special reserved words that meant things in each
type of file, and I set up syntax colouring, so that for example "DELETE" in
a rule showed up in red in the rule file, the delete action showed up in red
in the log file, and in the app itself I broke the rules for WIMP apps (have
a colour screen but make all button legends black) and made the
DELETE-related buttons and text red as well.  I also had some custom toolbar
icons in the logfile mode; eg a red button did a LoF for DELETE-related
lines in the log file.

At first I used the ModeWhen files to make sure that AntiSpam logs & rule
files got opened with the right mode.

But later I replaced that with StrongED$WrapWidth and the corresponding Mode
settings in the comments at the top of rules files, and made the app (when
it cerated new log files) write the same things in teh first couple of log
lines in a new log file.  Some other process frequently archived the logs so
the app would regularly start a new log file.  Using the special values at
the start of the files worked better than ModeWhen because it meant that
backups of logs & rules files (not in the folders where the live files were)
also got coloured etc.  

Jeremy C B Nicoll - my opinions are my own.

To unsubscribe send a mail to StrongED+unsubscribe@xxxxxxxxxxxxxx