ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* ConTeXt's equivalent of raisebox
@ 2021-10-10 22:16 noib3 via ntg-context
  2021-10-10 22:25 ` Wolfgang Schuster via ntg-context
  2021-10-11  8:46 ` Hans Hagen via ntg-context
  0 siblings, 2 replies; 3+ messages in thread
From: noib3 via ntg-context @ 2021-10-10 22:16 UTC (permalink / raw)
  To: ntg-context; +Cc: noib3


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

How can I make vertical microadjustments to individual characters in
ConTeXt?

In LaTeX I would do it with

```
\documentclass{article}
\begin{document}
\raisebox{-1pt}{f}oo
\end{document}
```

however the following doesn't work

```
\starttext
\raisebox{-1pt}{f}oo
\stoptext
```

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

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

___________________________________________________________________________________
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: ConTeXt's equivalent of raisebox
  2021-10-10 22:16 ConTeXt's equivalent of raisebox noib3 via ntg-context
@ 2021-10-10 22:25 ` Wolfgang Schuster via ntg-context
  2021-10-11  8:46 ` Hans Hagen via ntg-context
  1 sibling, 0 replies; 3+ messages in thread
From: Wolfgang Schuster via ntg-context @ 2021-10-10 22:25 UTC (permalink / raw)
  To: mailing list for ConTeXt users, noib3 via ntg-context; +Cc: Wolfgang Schuster

noib3 via ntg-context schrieb am 11.10.2021 um 00:16:
> How can I make vertical microadjustments to individual characters in 
> ConTeXt?
>
> In LaTeX I would do it with
>
> ```
> \documentclass{article}
> \begin{document}
> \raisebox{-1pt}{f}oo
> \end{document}
> ```
>
> however the following doesn't work
>
> ```
> \starttext
> \raisebox{-1pt}{f}oo
> \stoptext
> ```

The \raisebox command expects a box for the second argument. A better 
solution is to use the \offset command but in both cases you need 
\dontleavehmode at the start of a paragraph.

%%%% begin example
\starttext

\dontleavehmode\raisebox{1pt}\hbox{f}oo

\dontleavehmode\offset[y=-1pt]{f}oo

\stoptext
%%%% end example

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: ConTeXt's equivalent of raisebox
  2021-10-10 22:16 ConTeXt's equivalent of raisebox noib3 via ntg-context
  2021-10-10 22:25 ` Wolfgang Schuster via ntg-context
@ 2021-10-11  8:46 ` Hans Hagen via ntg-context
  1 sibling, 0 replies; 3+ messages in thread
From: Hans Hagen via ntg-context @ 2021-10-11  8:46 UTC (permalink / raw)
  To: mailing list for ConTeXt users; +Cc: Hans Hagen

On 10/11/2021 12:16 AM, noib3 via ntg-context wrote:
> How can I make vertical microadjustments to individual characters in 
> ConTeXt?
> 
> In LaTeX I would do it with
> 
> ```
> \documentclass{article}
> \begin{document}
> \raisebox{-1pt}{f}oo
> \end{document}
> ```
> 
> however the following doesn't work
> 
> ```
> \starttext
> \raisebox{-1pt}{f}oo
> \stoptext
depends on if you want to keep kerning and ligature building etc

\starttext

xx\glyph yoffset 1pt `f\relax oo

xx\glyph yoffset 1pt `f\relax \glyph yoffset -1pt `o\relax \glyph 
yoffset 2pt `o\relax

xx\glyph yoffset 1pt `f\relax fi

\dontleavehmode\offset[y=-1pt]{f}oo

\stoptext


-----------------------------------------------------------------
                                           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 / 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-10-11  8:46 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-10 22:16 ConTeXt's equivalent of raisebox noib3 via ntg-context
2021-10-10 22:25 ` Wolfgang Schuster via ntg-context
2021-10-11  8:46 ` 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).