From: Rik Kabel via ntg-context <ntg-context@ntg.nl>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Cc: Rik Kabel <ConTeXt@rik.users.panix.com>
Subject: \autoinsertedspace fails
Date: Thu, 29 Dec 2022 19:12:08 -0500 [thread overview]
Message-ID: <86830236-f8d8-cbdd-ff24-d14f9a35f90e@rik.users.panix.com> (raw)
[-- Attachment #1.1: Type: text/plain, Size: 1777 bytes --]
Happy New Year all!
Following up on the problem with \autoinsertnextspace
(https://mailman.ntg.nl/pipermail/ntg-context/2022/107111.html) and the
new \autoinsertedspace that came from that report, I see that there is
still a problem, or perhaps a problem again after it was previously
repaired.
The following code, run under the latest (and recent previous) version,
produces an incorrect result, with no space inserted where expected in
many cases. As the first examples after \starttext show, the problem
appears to be with \autoinsertedspace, but perhaps I am using it
incorrectly in the macro as well.
\starttexdefinition unexpanded BD
\dodoublegroupempty
\doBD
\stoptexdefinition
\starttexdefinition doBD #1#2
\removeunwantedspaces\ % insert a space
(
\ifsecondargument
#1|–|#2
\else\iffirstargument
#1–
\else
{\red I NEED A DATE OR DATES!}
\fi\fi
)
\autoinsertedspace
\stoptexdefinition
\tt
\starttext
This\autoinsertedspace fails unexpectedly with autoinsertedspace.\par
This\autoinsertedspace \emph{fails unexpectedly} with
autoinsertedspace.\par
This\autoinsertnextspace works with autoinsertnextspace.\par
This\autoinsertnextspace \emph{fails} as expected with
autoinsertnextspace.\par
Saussure\BD{1857}{1913} works.\par
Saussure \BD{1857}{1913} \emph{works}.\par
Saussure \BD{1857}{1913}. Works.\par
Chomsky\BD{1928} fails with LMTX, works with MkIV.\par
Chomsky \BD{1928} \emph{fails with LMTX, works with MkIV}.\par
Chomsky \BD{1928}. Works.\par
\BD blah\par
\contextversion\ \texenginename
\stoptext
--
Rik
[-- Attachment #1.2: Type: text/html, Size: 2911 bytes --]
[-- Attachment #2: Type: text/plain, Size: 496 bytes --]
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage : https://www.pragma-ade.nl / http://context.aanhet.net
archive : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___________________________________________________________________________________
next reply other threads:[~2022-12-30 0:12 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-12-30 0:12 Rik Kabel via ntg-context [this message]
2023-01-04 22:10 ` Rik Kabel via ntg-context
2023-01-04 23:45 ` Hans Hagen via ntg-context
2023-01-05 3:21 ` Rik Kabel via ntg-context
2023-01-05 7:38 ` Hans Hagen via ntg-context
2023-01-05 9:35 ` Hans Hagen via ntg-context
2023-01-06 2:05 ` Rik Kabel via ntg-context
2023-01-06 7:53 ` Hans Hagen via ntg-context
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=86830236-f8d8-cbdd-ff24-d14f9a35f90e@rik.users.panix.com \
--to=ntg-context@ntg.nl \
--cc=ConTeXt@rik.users.panix.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).