[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Extra space after punctuation marks
From: |
Blake McBride |
Subject: |
Extra space after punctuation marks |
Date: |
Mon, 15 Jan 1996 21:40:17 -0600 |
Greetings fellow Lout enthusiasts,
There is an issue regarding how Lout handles (or really doesn't) handle extra
space at
the end of sentences which has bothered me for some time and I thought I'd
bring it
up for public discussion.
First of all being that I only know english, I can only speak for that language.
As you know, it is customary and proper to put extra space after punctuation
marks which
end sentences. Lout does not do this automatically. Further more, the method
Lout
currently provides to achieve this necessary effect is, in my opinion, clumsy,
error
prone and a general pain. Let me elaborate.
Fact 1: Lout retains interword spaces
Fact 2: Lout strips spaces at the end of source lines
Fact 3: Lout retains source text spacing (putting extra spaces between words
causes Lout
to output additional space between said words)
Fact 4: Lout does not automatically add extra space after end of sentence
marks.
Fact 5: In order to achieve the desired inter-sentence gap one must separate
each sentence
by two explicit space characters.
Fact 6: Lout treats a new line as a single space when justifying the text
Problem: If one has a source paragraph such as follows:
One one one one one one one one one one one
one one one. Two two two two two two two two.
Three three three three three three three.
given the above facts it is easy to achieve the desired inter-sentence gap
between
sentences One and Two by using two spaces. However, due again to the above
facts,
Lout will only separate sentence Two with Three by one space! The problem
arises
whenever any sentence within a paragraph happens to end at the end of a source
line.
This is a situation which often occurs.
Granted, Lout provides several solutions to this problem. I'll discuss each and
why they are inadequate.
Solution 1: Don't ever end a sentence within a paragraph at the end of a
source line.
This way you always have the opportunity to put the two spaces.
This solution is inadequate for two reasons:
1A. This detracts from a writer's ability to write because of instead of
spending their
time on the document at hand they are spending a great deal of their mental
effort making
sure a sentence never ends at the end of a line.
1B. Most decent text editors (emacs) perform both automatic word wrapping and
have the ability
to re-wrap the lines should some word be inserted or deleted. This leads to
the problem where
one doesn't even have convenient control over where sentences end within a
source paragraph.
Attempting to avoid the re-wrap feature of an editor quickly renders a source
document
a mess after several edits (you know, lines with two words on them or other
lines with 60).
Solution 2: End sentences like sentence Two above with " ".
This also solves the problem and also suffers from the same problems as
Solution 1.
Proposed solution: Lout should guesstimate where the end of sentences are and
insert
an extra space regardless of where in the line the sentence ends. Source text
will
just always use one space (or new line) between words or spaces. This feature
can be
controlled by setting some sort of option. Some syntax should be added in
order to
tell Lout, explicitly, when Lout might guess incorrectly about a punctuation
mark.
Objections and replies.
Objection 1: Some languages don't use extra spaces between sentences (I
assume).
Reply 1: Turn off the option when using that language.
Objection 2: It is a pain to have to explicitly tell Lout when not to insert
the extra space
(when it might guess wrong like "Allen B. Smith").
Reply 2: True enough, but, this occurs _much_ less frequently then the stated
problem.
I don't mind checking and handling one or two special cases in a document,
rather then
having to check every sentence.
Well thats my thought. What do you think?
--blake
--
Blake McBride Algorithms Corporation
615-791-1636 voice 3020 Liberty Hills Drive
615-791-7736 fax Franklin, TN 37067
address@hidden USA
See our WEB page at: http://www.edge.net/algorithms
- Extra space after punctuation marks,
Blake McBride <=