ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* vertical offset with "i" in position-command
@ 2021-02-12 12:31 Peter Münster
  2021-02-12 12:47 ` Wolfgang Schuster
  0 siblings, 1 reply; 3+ messages in thread
From: Peter Münster @ 2021-02-12 12:31 UTC (permalink / raw)
  To: ConTeXt users

Hi,

When I want to type an "i" in the position-command, there is some
vertical offset:

\starttext
\startpositioning
\position(1, 1){i} \position(2, 1){x}
\position(1, 2){x} \position(2, 2){i}
\position(1, 3){a} \position(2, 3){x}
\position(1, 4){x} \position(2, 4){a}
\stoppositioning
\stoptext

Why is it so, and how could I avoid that please?

TIA for any hints,
-- 
           Peter
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : http://contextgarden.net
___________________________________________________________________________________

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

* Re: vertical offset with "i" in position-command
  2021-02-12 12:31 vertical offset with "i" in position-command Peter Münster
@ 2021-02-12 12:47 ` Wolfgang Schuster
  2021-02-12 13:22   ` Peter Münster
  0 siblings, 1 reply; 3+ messages in thread
From: Wolfgang Schuster @ 2021-02-12 12:47 UTC (permalink / raw)
  To: ConTeXt users

Peter Münster schrieb am 12.02.2021 um 13:31:
> Hi,
> 
> When I want to type an "i" in the position-command, there is some
> vertical offset:
> 
> \starttext
> \startpositioning
> \position(1, 1){i} \position(2, 1){x}
> \position(1, 2){x} \position(2, 2){i}
> \position(1, 3){a} \position(2, 3){x}
> \position(1, 4){x} \position(2, 4){a}
> \stoppositioning
> \stoptext
> 
> Why is it so, and how could I avoid that please?

1. Because the letters have different heights.

\startTEXpage[offset=1ex]
\processisolatedchars{aix}\ruledhbox
\stopTEXpage

2. Add \strut, e.g. \position(1, 1){\strut i}

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

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : http://contextgarden.net
___________________________________________________________________________________

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

* Re: vertical offset with "i" in position-command
  2021-02-12 12:47 ` Wolfgang Schuster
@ 2021-02-12 13:22   ` Peter Münster
  0 siblings, 0 replies; 3+ messages in thread
From: Peter Münster @ 2021-02-12 13:22 UTC (permalink / raw)
  To: ConTeXt users

On Fri, Feb 12 2021, Wolfgang Schuster wrote:

> 2. Add \strut, e.g. \position(1, 1){\strut i}

Ah, thanks. So the anchor is not the baseline, but the top-left corner of
the content.

Since "\setuppositioning[before=\strut]" does not work, I use this
workaround now:
\def\myPosition(#1, #2)#3{\position(#1, #2){\strut#3}}

Would it make sense to add the "before" key to \setuppositioning?

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

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : http://contextgarden.net
___________________________________________________________________________________

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

end of thread, other threads:[~2021-02-12 13:22 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-12 12:31 vertical offset with "i" in position-command Peter Münster
2021-02-12 12:47 ` Wolfgang Schuster
2021-02-12 13:22   ` Peter Münster

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).