Oddiments

Top Page
Attachments:
Message as email
+ (text/plain)
Delete this message
Reply to this message
Author: Trent Shipley
Date:  
To: plug-discuss
Subject: Oddiments
1. Xemacs (frustrated by manual)
1.1 80, 132, and N characters per line
1.2 End-of-Line (CrLf) in Xemacs.

2. Bash, Korn, PERL, and Zsh. (Opinion)

3. Man and especially Info to HTML or *.pdf (confused by manual)
===============

1. Xemacs (frustrated by manual)

I've been looking for "built-in" commands for a couple of things for some
time. Hints in the Xemacs/emacs literature indicate that they should exist
(without needing to roll your own e-Lisp), but I must not have a good keyword
search.

1.1 80, 132, and N characters per line

Can you/how do you set Xemacs to automatically hard break on (or before) the
Nth character of a line (breaking on whitespace, or offering to hyphenate if
in a suitable mode)? Surely the function already exists and can be accessed
through a key-chord or M-x_function_name_.

1.2 End-of-Line (CrLf) in Xemacs.

There are MANY time when I want Xemacs to NOT use the standard *nix Lf EOL.
One common mode is when I want to use Xemacs to prepare a text file for a
certain family of systems that use CrLf as the EOL and that have a commonly
used simple text editor that refuses to display Lf alone as anything other
than an in-line box.

I am even more annoyed when working on SGML or any of its descendents. Did
you know that SGML is implicitly record-oriented? Furthermore, SGML's
default End-of-Record is CrLf. (In addition, woe to the SGML author who
assumes that the CrLf EOR is necessarily the same as the system-SGML EOL.)
More precisely, the SGML standard left me with the impression that Lf
actually corresponds to "start of record" while Cr corresponds to "end of
record", so records are properly delimited with complimentary delimiters.
The exception is the start of a document or file's first line has an
"implicit" record start and the line prior to EOF has an implicit EOR.

Who cares? I do. The default rules for handling whitespace in SGML are so
complex that I have never really figured them out, especially as they pertain
to CrLf.

Worse, XML is a dialect of SGML, and as I recall it inherited the same CrLf
and whitespace rules (plus in XML they are fixed rather than the default
option). Entering or not entering CrLf's has subtle effects on how any
document defined with SGML or XML Document Type Definitions get parsed and
rendered. Unfortunately, the SGML/HTML modes for Xemacs put in Lf-s not
CrLf-s. Thus, to the parser the document looks like one l-o-n-g string.

Also, is there an easy way to make the stupid ^M's go away (and come back)?

How do you enter a ^M? C-M doesn't seem bound to anything?



2. Bash, Korn, PERL, and Zsh. (Opinion)

I started using Bash when I started using Linux back in 1998 or 1999 and have
been using it ever since. Since I under-use my machine as a glorified
typewriter, I hardly ever write a PERL script let alone a script in the
default shell language. Nevertheless, there seem to be a number of jobs that
ask for "familiarity" with Korn. Since Korn and now gratis and open (but not
free), I am toying with the idea of compiling it and using it as my default
shell. Then when asked if I am familiar with Korn, I can--without outright
lying--say that I use it all the time.

_Learning the Korn Shell, 2nd Edition_ praises Zsh but goes into few detail,
especially about scripting. Has anyone had experience with it?

Having read _Learning the Korn_, I am really impressed with Korn as a
scripting language, yet I recognize how much less robust Korn is than PERL
(or Python, I don't like lots of invisible but syntactically necessary tabs
though, bad Make, bad Python). I understand why Korn was so popular as a
glue language, what I do not understand I why PERL hasn't stollen more of
Korn's thunder.


3. Info files to HTML (or better) PDF

On a couple of occasions I've read how-to's on converting man pages to ps/pdf
Those I pretty much could follow. One man page = one nroff file = one *.ps
file, convert *.ps to *.pdf.

However, I get confused by the how-to's for converting Info style
documentation. The problem is that your source is always part of the stupid
_info_ tree. Therefore you need to grab a sub-tree (say Lispref: XEmacs
Lisp Reference Manual.), traverse the sub-tree in JUST the proper order,
generate some sort of appropriate layout language so it has pages and
chapters in the right order with appropriate styling, then generate
PostScript (assuming you did not chose PostScript as your layout language)
and convert the PostScript to Acrobat so you get your XEmacs Lisp Reference
Manual (or whatever) as a nice, convenient (not to mention printable) PDF
book.

Then you could read your XEmacs Lisp Manual, thereby learning to modify the
SGML/XML mode so it defaults to 60 characters per line with Unicode soft line
break characters at the end of each soft break, Lf as a medium break when the
user hits enter once, and CrLf-s for each hard break when the user hits the
enter key twice in succession.



---------------------------------------------------
PLUG-discuss mailing list -
To subscribe, unsubscribe, or to change you mail settings:
http://lists.PLUG.phoenix.az.us/mailman/listinfo/plug-discuss