ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* [NTG-context] How to force end-of-sentence space?
       [not found] <406102413.135736.1745680965447.ref@mail.yahoo.com>
@ 2025-04-26 15:22 ` Joel via ntg-context
  2025-04-26 21:14   ` [NTG-context] " Hans Hagen via ntg-context
  2025-04-27  8:44   ` Hans Hagen via ntg-context
  0 siblings, 2 replies; 3+ messages in thread
From: Joel via ntg-context @ 2025-04-26 15:22 UTC (permalink / raw)
  To: Mailing List for ConTeXt Users; +Cc: Joel


[-- Attachment #1.1: Type: text/plain, Size: 572 bytes --]

When I have a word like "U.S." in a sentence, I'm using code like this:

     After the U.S.\ Army left Vietnam, they focused on...
...that seems to make sure the space between U.S. Army isn't so big.
My copy editor noticed that when I use footnote, there isn't the right space after, like.
     Here is a sentence.\footnote{This is footnote text.} This is another sentence.
They are saying that after that, the space isn't the right size. Is there something similar to the first option that makes sure a full end-of-sentence space width appears?
--Joel


[-- Attachment #1.2: Type: text/html, Size: 1921 bytes --]

[-- Attachment #2: Type: text/plain, Size: 511 bytes --]

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki     : https://wiki.contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [NTG-context] Re: How to force end-of-sentence space?
  2025-04-26 15:22 ` [NTG-context] How to force end-of-sentence space? Joel via ntg-context
@ 2025-04-26 21:14   ` Hans Hagen via ntg-context
  2025-04-27  8:44   ` Hans Hagen via ntg-context
  1 sibling, 0 replies; 3+ messages in thread
From: Hans Hagen via ntg-context @ 2025-04-26 21:14 UTC (permalink / raw)
  To: Joel via ntg-context; +Cc: Hans Hagen

On 4/26/2025 5:22 PM, Joel via ntg-context wrote:
> When I have a word like "U.S." in a sentence, I'm using code like this:
> 
>       After the U.S.\ Army left Vietnam, they focused on...
> 
> ...that seems to make sure the space between U.S. Army isn't so big.
> 
> My copy editor noticed that when I use footnote, there isn't the right 
> space after, like.
> 
>       Here is a sentence.\footnote{This is footnote text.} This is 
> another sentence.
> 
> They are saying that after that, the space isn't the right size. Is 
> there something similar to the first option that makes sure a full end- 
> of-sentence space width appears?

Interesting that no one brought this up till now. It is something that 
has to be solved at either the engine level (kind of cool) or in all 
macros that qualify fof this treatment (doable but less cool).

Here is a hack:

\def\FakeSomething#1%
   {\begingroup
    #1\space
    \scratchskip\lastskip
    \unskip
    \removepunctuation
    \hskip\scratchskip
    \endgroup}

\protected\def\FakePeriod{\FakeSomething.}
\protected\def\FakeComma {\FakeSomething,}

\starttext

Here is a sentence.\footnote{This is footnote text.} This is another 
sentence.

Here is a\footnote{This is footnote text.} sentence. This is another 
sentence.

Here is a sentence.\footnote{This is footnote text.}\FakePeriod This is 
another sentence.

\stoptext

So you can make the editor happy and not have to defend some shortcoming.

Hans

-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
        tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki     : https://wiki.contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [NTG-context] Re: How to force end-of-sentence space?
  2025-04-26 15:22 ` [NTG-context] How to force end-of-sentence space? Joel via ntg-context
  2025-04-26 21:14   ` [NTG-context] " Hans Hagen via ntg-context
@ 2025-04-27  8:44   ` Hans Hagen via ntg-context
  1 sibling, 0 replies; 3+ messages in thread
From: Hans Hagen via ntg-context @ 2025-04-27  8:44 UTC (permalink / raw)
  To: Joel via ntg-context; +Cc: Hans Hagen

On 4/26/2025 5:22 PM, Joel via ntg-context wrote:
> When I have a word like "U.S." in a sentence, I'm using code like this:
> 
>       After the U.S.\ Army left Vietnam, they focused on...
> 
> ...that seems to make sure the space between U.S. Army isn't so big.
> 
> My copy editor noticed that when I use footnote, there isn't the right 
> space after, like.
> 
>       Here is a sentence.\footnote{This is footnote text.} This is 
> another sentence.
> 
> They are saying that after that, the space isn't the right size. Is 
> there something similar to the first option that makes sure a full end- 
> of-sentence space width appears?

In the next upload this is 'fixed'. The footnote adds stuff that makes 
the space factor reset and we can catch that - optionally - in the engine.

Hans

-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
        tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki     : https://wiki.contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2025-04-27  8:48 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <406102413.135736.1745680965447.ref@mail.yahoo.com>
2025-04-26 15:22 ` [NTG-context] How to force end-of-sentence space? Joel via ntg-context
2025-04-26 21:14   ` [NTG-context] " Hans Hagen via ntg-context
2025-04-27  8:44   ` Hans Hagen via ntg-context

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).