ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* Problem with grid alignment and paragraph
@ 2018-12-14 21:14 Luca Donetti
  2018-12-14 22:22 ` Rik
  2019-01-06 13:53 ` Wolfgang Schuster
  0 siblings, 2 replies; 6+ messages in thread
From: Luca Donetti @ 2018-12-14 21:14 UTC (permalink / raw)
  To: ntg-context


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

Dear list,

I am facing a problem with grid alignment when using paragraphs. I think it
could be a bug because the MWE below produces lines which are correctly
aligned to the grid with the context version included in texlive 2017, but
it does not seem to work with the context in texlive 2018 and the current
beta (ConTeXt  ver: 2018.12.07 19:37 MKIV beta  fmt: 2018.12.14).
This is the MWE:

\setuplayout[grid=yes]
\defineparagraphs[twocols][n=2]
\showgrid

\starttext
\starttwocols
  \input knuth
\nexttwocols
  \input knuth
\stoptwocols
\stoptext

Am I doing anything wrong? If not, I'll appreciate any suggestion or
workaround.

Thank you in advance for your help.

LD

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

[-- Attachment #2: Type: text/plain, Size: 492 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] 6+ messages in thread

* Re: Problem with grid alignment and paragraph
  2018-12-14 21:14 Problem with grid alignment and paragraph Luca Donetti
@ 2018-12-14 22:22 ` Rik
  2019-01-06 13:53 ` Wolfgang Schuster
  1 sibling, 0 replies; 6+ messages in thread
From: Rik @ 2018-12-14 22:22 UTC (permalink / raw)
  To: ntg-context


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

On 12/14/2018 16:14, Luca Donetti wrote:
> Dear list,
>
> I am facing a problem with grid alignment when using paragraphs. I 
> think it could be a bug because the MWE below produces lines which are 
> correctly aligned to the grid with the context version included in 
> texlive 2017, but it does not seem to work with the context in texlive 
> 2018 and the current beta (ConTeXt ver: 2018.12.07 19:37 MKIV beta  
> fmt: 2018.12.14).
> This is the MWE:
>
> \setuplayout[grid=yes]
> \defineparagraphs[twocols][n=2]
> \showgrid
>
> \starttext
> \starttwocols
>   \input knuth
> \nexttwocols
>   \input knuth
> \stoptwocols
> \stoptext
>
> Am I doing anything wrong? If not, I'll appreciate any suggestion or 
> workaround.
>
> Thank you in advance for your help.
>
> LD
>
> ___________________________________________________________________________________
> 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
> ___________________________________________________________________________________

The result is properly aligned here on W10x64 both with the (same) 
current beta and with TL18.

-- 
Rik


[-- Attachment #1.2.1: Type: text/html, Size: 3514 bytes --]

[-- Attachment #1.2.2: fhaodhkkeabpmlce.png --]
[-- Type: image/png, Size: 32358 bytes --]

[-- Attachment #2: Type: text/plain, Size: 492 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] 6+ messages in thread

* Re: Problem with grid alignment and paragraph
  2018-12-14 21:14 Problem with grid alignment and paragraph Luca Donetti
  2018-12-14 22:22 ` Rik
@ 2019-01-06 13:53 ` Wolfgang Schuster
  2019-01-07 20:21   ` Luca Donetti
  1 sibling, 1 reply; 6+ messages in thread
From: Wolfgang Schuster @ 2019-01-06 13:53 UTC (permalink / raw)
  To: mailing list for ConTeXt users, Luca Donetti

Luca Donetti schrieb am 14.12.18 um 22:14:
> Dear list,
>
> I am facing a problem with grid alignment when using paragraphs. I 
> think it could be a bug because the MWE below produces lines which are 
> correctly aligned to the grid with the context version included in 
> texlive 2017, but it does not seem to work with the context in texlive 
> 2018 and the current beta (ConTeXt  ver: 2018.12.07 19:37 MKIV beta  
> fmt: 2018.12.14).
> This is the MWE:
>
> \setuplayout[grid=yes]
> \defineparagraphs[twocols][n=2]
> \showgrid
>
> \starttext
> \starttwocols
> \input knuth
> \nexttwocols
>   \input knuth
> \stoptwocols
> \stoptext
>
> Am I doing anything wrong? If not, I'll appreciate any suggestion or 
> workaround.

https://tex.stackexchange.com/questions/468711/context-defineparagraphs-aligned-to-grid/

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] 6+ messages in thread

* Re: Problem with grid alignment and paragraph
  2019-01-06 13:53 ` Wolfgang Schuster
@ 2019-01-07 20:21   ` Luca Donetti
  2019-01-07 20:35     ` Wolfgang Schuster
  0 siblings, 1 reply; 6+ messages in thread
From: Luca Donetti @ 2019-01-07 20:21 UTC (permalink / raw)
  To: mailing list for ConTeXt users


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

On Sun, Jan 6, 2019 at 2:53 PM Wolfgang Schuster <
wolfgang.schuster.lists@gmail.com> wrote:

> Luca Donetti schrieb am 14.12.18 um 22:14:
> > Dear list,
> >
> > I am facing a problem with grid alignment when using paragraphs. I
> > think it could be a bug because the MWE below produces lines which are
> > correctly aligned to the grid with the context version included in
> > texlive 2017, but it does not seem to work with the context in texlive
> > 2018 and the current beta (ConTeXt  ver: 2018.12.07 19:37 MKIV beta
> > fmt: 2018.12.14).
> > This is the MWE:
> >
> > \setuplayout[grid=yes]
> > \defineparagraphs[twocols][n=2]
> > \showgrid
> >
> > \starttext
> > \starttwocols
> > \input knuth
> > \nexttwocols
> >   \input knuth
> > \stoptwocols
> > \stoptext
> >
> > Am I doing anything wrong? If not, I'll appreciate any suggestion or
> > workaround.
>
>
> https://tex.stackexchange.com/questions/468711/context-defineparagraphs-aligned-to-grid/
>
> Wolfgang
>

Dear Wolfgang,

thank you for your help. Unfortunately, if I follow the suggestion in your
link (using [location=depth]), the alignment improves but it is still not
good: some lines are on grid while some others are not. If I understand
correctly your answer, inside the \framed there is a table and, in this
case, it seems to me that the spacing between lines is not always equal to
the grid spacing.

Is there a way to force the interline spacing inside the \framed block? I'm
sorry if this is a simple question, but I'm quite new to context.

This is the new example:

\setuplayout[grid=yes]
\defineparagraphs[twocols][n=2]
\setupparagraphs[twocols][location=depth]
\showgrid

\starttext
\starttwocols
  \input knuth
\nexttwocols
  \input knuth
\stoptwocols
\stoptext

Thank you,
Luca

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

[-- Attachment #2: Type: text/plain, Size: 492 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] 6+ messages in thread

* Re: Problem with grid alignment and paragraph
  2019-01-07 20:21   ` Luca Donetti
@ 2019-01-07 20:35     ` Wolfgang Schuster
  2019-01-19 18:35       ` Luca Donetti
  0 siblings, 1 reply; 6+ messages in thread
From: Wolfgang Schuster @ 2019-01-07 20:35 UTC (permalink / raw)
  To: mailing list for ConTeXt users, Luca Donetti

Luca Donetti schrieb am 07.01.19 um 21:21:
> On Sun, Jan 6, 2019 at 2:53 PM Wolfgang Schuster 
> <wolfgang.schuster.lists@gmail.com 
> <mailto:wolfgang.schuster.lists@gmail.com>> wrote:
>
>     Luca Donetti schrieb am 14.12.18 um 22:14:
>     > Dear list,
>     >
>     > I am facing a problem with grid alignment when using paragraphs. I
>     > think it could be a bug because the MWE below produces lines
>     which are
>     > correctly aligned to the grid with the context version included in
>     > texlive 2017, but it does not seem to work with the context in
>     texlive
>     > 2018 and the current beta (ConTeXt  ver: 2018.12.07 19:37 MKIV beta
>     > fmt: 2018.12.14).
>     > This is the MWE:
>     >
>     > \setuplayout[grid=yes]
>     > \defineparagraphs[twocols][n=2]
>     > \showgrid
>     >
>     > \starttext
>     > \starttwocols
>     > \input knuth
>     > \nexttwocols
>     >   \input knuth
>     > \stoptwocols
>     > \stoptext
>     >
>     > Am I doing anything wrong? If not, I'll appreciate any
>     suggestion or
>     > workaround.
>
>     https://tex.stackexchange.com/questions/468711/context-defineparagraphs-aligned-to-grid/
>
>     Wolfgang
>
> Dear Wolfgang,
>
> thank you for your help. Unfortunately, if I follow the suggestion in 
> your link (using [location=depth]), the alignment improves but it is 
> still not good: some lines are on grid while some others are not. If I 
> understand correctly your answer, inside the \framed there is a table 
> and, in this case, it seems to me that the spacing between lines is 
> not always equal to the grid spacing.
>
> Is there a way to force the interline spacing inside the \framed 
> block? I'm sorry if this is a simple question, but I'm quite new to 
> context.

The interlinespace is correct but the paragraphs environment is too high,
location=bottom puts the text on the baseline but it adds an extra blank
line at the begin of the environment.

A simple fix to get rid of the extra line is to set the width of the frame
border to 0pt which doesn’t matter when the rules are disabled.

\setuplayout[grid=yes]

\defineparagraphs [twocols] [n=2]

\setupparagraphs
   [twocols]
   [location=bottom,
    rulethickness=0pt]

\showgrid

\starttext

\starttwocols
   \input knuth
   \nexttwocols
   \input knuth
\stoptwocols

\stoptext

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] 6+ messages in thread

* Re: Problem with grid alignment and paragraph
  2019-01-07 20:35     ` Wolfgang Schuster
@ 2019-01-19 18:35       ` Luca Donetti
  0 siblings, 0 replies; 6+ messages in thread
From: Luca Donetti @ 2019-01-19 18:35 UTC (permalink / raw)
  To: mailing list for ConTeXt users


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

On Mon, Jan 7, 2019 at 9:35 PM Wolfgang Schuster <
wolfgang.schuster.lists@gmail.com> wrote:

> Luca Donetti schrieb am 07.01.19 um 21:21:
> > On Sun, Jan 6, 2019 at 2:53 PM Wolfgang Schuster
> > <wolfgang.schuster.lists@gmail.com
> > <mailto:wolfgang.schuster.lists@gmail.com>> wrote:
> >
> >     Luca Donetti schrieb am 14.12.18 um 22:14:
> >     > Dear list,
> >     >
> >     > I am facing a problem with grid alignment when using paragraphs. I
> >     > think it could be a bug because the MWE below produces lines
> >     which are
> >     > correctly aligned to the grid with the context version included in
> >     > texlive 2017, but it does not seem to work with the context in
> >     texlive
> >     > 2018 and the current beta (ConTeXt  ver: 2018.12.07 19:37 MKIV beta
> >     > fmt: 2018.12.14).
> >     > This is the MWE:
> >     >
> >     > \setuplayout[grid=yes]
> >     > \defineparagraphs[twocols][n=2]
> >     > \showgrid
> >     >
> >     > \starttext
> >     > \starttwocols
> >     > \input knuth
> >     > \nexttwocols
> >     >   \input knuth
> >     > \stoptwocols
> >     > \stoptext
> >     >
> >     > Am I doing anything wrong? If not, I'll appreciate any
> >     suggestion or
> >     > workaround.
> >
> >
> https://tex.stackexchange.com/questions/468711/context-defineparagraphs-aligned-to-grid/
> >
> >     Wolfgang
> >
> > Dear Wolfgang,
> >
> > thank you for your help. Unfortunately, if I follow the suggestion in
> > your link (using [location=depth]), the alignment improves but it is
> > still not good: some lines are on grid while some others are not. If I
> > understand correctly your answer, inside the \framed there is a table
> > and, in this case, it seems to me that the spacing between lines is
> > not always equal to the grid spacing.
> >
> > Is there a way to force the interline spacing inside the \framed
> > block? I'm sorry if this is a simple question, but I'm quite new to
> > context.
>
> The interlinespace is correct but the paragraphs environment is too high,
> location=bottom puts the text on the baseline but it adds an extra blank
> line at the begin of the environment.
>
> A simple fix to get rid of the extra line is to set the width of the frame
> border to 0pt which doesn’t matter when the rules are disabled.
>
> \setuplayout[grid=yes]
>
> \defineparagraphs [twocols] [n=2]
>
> \setupparagraphs
>    [twocols]
>    [location=bottom,
>     rulethickness=0pt]
>
> \showgrid
>
> \starttext
>
> \starttwocols
>    \input knuth
>    \nexttwocols
>    \input knuth
> \stoptwocols
>
> \stoptext
>
> Wolfgang
>

 Dear Wolfgang,

thank you very much for your reply (and sorry for my late reply). Your
suggestion do solve my minimal example but, unfortunately, not my real
world example. I will try to find another minimal example which still shows
the problem. In the meantime I'll try to play with different options of
location=.

LD

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

[-- Attachment #2: Type: text/plain, Size: 492 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] 6+ messages in thread

end of thread, other threads:[~2019-01-19 18:35 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-12-14 21:14 Problem with grid alignment and paragraph Luca Donetti
2018-12-14 22:22 ` Rik
2019-01-06 13:53 ` Wolfgang Schuster
2019-01-07 20:21   ` Luca Donetti
2019-01-07 20:35     ` Wolfgang Schuster
2019-01-19 18:35       ` Luca Donetti

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