ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* [NTG-context] learning about the grid
@ 2023-11-19 12:27 Miguel Diaz
  2023-11-19 13:36 ` [NTG-context] " Pablo Rodriguez via ntg-context
  2023-11-19 15:34 ` Henning Hraban Ramm
  0 siblings, 2 replies; 7+ messages in thread
From: Miguel Diaz @ 2023-11-19 12:27 UTC (permalink / raw)
  To: mailing list for ConTeXt users


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

Hi everyone,
being a newbie I just discovered how different setups for the grid may
affect my (very simple) document.
In the Details manual (which of course I don't understand because of my
unexperience) I read that many people don't use the grid, but when I
configure grid=no the whole lines of a section are printed one over the
other.
Playing with the options and setupinterlinespace I got the unhappily
desired 1.3ex that may school requieres for the teaching programs
(grid=line, interlinespace=1.3ex), but I somehow feel that's not the right
way to go.

1. Why are the lines printed one over the other when grid=no? how do profis
then use context without grid?

2. Is there a document where I can read how the grid is conceived to work
for the many options in a simple way?

thanks in advance

[-- Attachment #1.2: Type: text/html, Size: 1414 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] 7+ messages in thread

* [NTG-context] Re: learning about the grid
  2023-11-19 12:27 [NTG-context] learning about the grid Miguel Diaz
@ 2023-11-19 13:36 ` Pablo Rodriguez via ntg-context
  2023-11-19 15:34 ` Henning Hraban Ramm
  1 sibling, 0 replies; 7+ messages in thread
From: Pablo Rodriguez via ntg-context @ 2023-11-19 13:36 UTC (permalink / raw)
  To: ntg-context; +Cc: Pablo Rodriguez

On 11/19/23 13:27, Miguel Diaz wrote:
> [...]

Hi Miguel,

I don’t use the grid. This is also the default in ConTeXt.

I’m not sure whether I’m getting your point here.

See what the difference between not enabling the grid and enabling it:

  \showframe\showgrid
  \setupwhitespace[medium]
  \starttext
    \input knuth
  \setuplayout[grid=yes]\page
    \input knuth
  \stoptext

> 1. Why are the lines printed one over the other when grid=no? how do
> profis then use context without grid?

As said, ConTeXt is \setuplayout[grid=no] by default.

As far as I can recall it, the default value is
\setupinterlinespace[line=2.85ex].

I have just discovered that with values such as line=1.3ex,
\setuplayout[grid=yes] behaves very differently than with values such as
line=2ex (and above).

I mean, lines follow the grid when the text fits. See the difference with:

  \showframe\showgrid
  \setupinterlinespace[line=1.3ex]
  \starttext
    \dorecurse{25}{asa aeo eau}
  \setuplayout[grid=yes]\page
    \dorecurse{25}{asa aeo eau}
  \stoptext

According to https://wiki.contextgarden.net/Grid_typesetting (feel free
to improve the article), a way of solving this would be to wrap your
stuff inside:

  \startlinecorrection
  ...
  \stoplinecorrection

The problem is that your interline space is too small to prevent line
collapsing.

ex is the height of the lowercase 'x'. Are you sure that your school
doesn’t require 1.3em (height of capital 'M') as interline space instead?

You can get yourself the values:

  \starttext
  \the\exheight\\
  %\the \dimexpr1.3\exheight\\
  \the\emwidth
  \stoptext

The first line will give you 1ex is about 5.7pt (with the default font
used by ConTeXt). 1.3ex would be less than 6.75pt.

The value of 1em is the value of the font size. Default for ConTeXt is
12pt, so 1em has to be 12pt.

I think it is clear now that an interline space of 1.3ex calls for line
overlapping.

That being said, I don’t know why the grid avoids collapsing them (if
the person explicitly asks for this).

> 2. Is there a document where I can read how the grid is conceived to
> work for the many options in a simple way?

See the wiki article above. The mailing list is also a way of getting help.

One suggestion, please always provide a minimal working sample (that can
be copied, pasted and compiled automatically), when you ask for help.

How minimal? Well, they cannot lack essential parts to be compiled.
Other than that, they should only contain required content to reproduce
your issue.

This minimal working sample helps the one who reads to understand what
you are dealing with.

Otherwise, it is really hard to understand which kind of issue you might
be facing (consider that no one else may read your mind or be in front
of your computer).

I hope it might help,

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

* [NTG-context] Re: learning about the grid
  2023-11-19 12:27 [NTG-context] learning about the grid Miguel Diaz
  2023-11-19 13:36 ` [NTG-context] " Pablo Rodriguez via ntg-context
@ 2023-11-19 15:34 ` Henning Hraban Ramm
  2023-11-19 22:17   ` madiazm.eoicc
  1 sibling, 1 reply; 7+ messages in thread
From: Henning Hraban Ramm @ 2023-11-19 15:34 UTC (permalink / raw)
  To: ntg-context

Am 19.11.23 um 13:27 schrieb Miguel Diaz:
> 1. Why are the lines printed one over the other when grid=no? how do 
> profis then use context without grid?

That usually only happens in one of the column modes that requires the 
grid. It doesn’t happen in usual one-column typesetting. There must be 
something wrong in your setup.

Please make a minimal example (MWE).

> 2. Is there a document where I can read how the grid is conceived to 
> work for the many options in a simple way?

AFAIK, the details manual is the only documentation for it.

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

* [NTG-context] Re: learning about the grid
  2023-11-19 15:34 ` Henning Hraban Ramm
@ 2023-11-19 22:17   ` madiazm.eoicc
  2023-11-19 22:42     ` Henning Hraban Ramm
                       ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: madiazm.eoicc @ 2023-11-19 22:17 UTC (permalink / raw)
  To: ntg-context

Thanks, Pablo and Henning

I suppose I am making a mistake with my setupinterlinearspace. My school asks for Times New Roman (I use termes) 12pt and onehalfspacing. In latex I used linespread{1.3} and so I supposed setting ConTeXt with setupinterlinearspace[1.3ex] was the right way (I read somewhere that vertical spaces should be measured in ex and horizontal spaces in em; maybe it's not widely accepted).
I tried setting my interlinearspace to 3ex and it looked much better, but I must compare it with a onehalfspacing of wordprocessors to be sure it is not such different.

Sorry for not providing an example (again my lack of experience), I will do it from now on.
thanks, I will try to learn a little more to get an idea of how ConTeXt ist built
___________________________________________________________________________________
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] 7+ messages in thread

* [NTG-context] Re: learning about the grid
  2023-11-19 22:17   ` madiazm.eoicc
@ 2023-11-19 22:42     ` Henning Hraban Ramm
  2023-11-20 17:29     ` Pablo Rodriguez via ntg-context
  2023-11-20 17:41     ` Wolfgang Schuster
  2 siblings, 0 replies; 7+ messages in thread
From: Henning Hraban Ramm @ 2023-11-19 22:42 UTC (permalink / raw)
  To: ntg-context

Am 19.11.23 um 23:17 schrieb madiazm.eoicc@gmail.com:
> Thanks, Pablo and Henning
> 
> I suppose I am making a mistake with my setupinterlinearspace. My school asks for Times New Roman (I use termes) 12pt and onehalfspacing. In latex I used linespread{1.3} and so I supposed setting ConTeXt with setupinterlinearspace[1.3ex] was the right way (I read somewhere that vertical spaces should be measured in ex and horizontal spaces in em; maybe it's not widely accepted).
> I tried setting my interlinearspace to 3ex and it looked much better, but I must compare it with a onehalfspacing of wordprocessors to be sure it is not such different.
> 
> Sorry for not providing an example (again my lack of experience), I will do it from now on.
> thanks, I will try to learn a little more to get an idea of how ConTeXt ist built

It’s \setupinterlinespace, and the default is 2.8ex, so 1.3ex is too small.

Try to understand https://wiki.contextgarden.net/Command/setupinterlinespace

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

* [NTG-context] Re: learning about the grid
  2023-11-19 22:17   ` madiazm.eoicc
  2023-11-19 22:42     ` Henning Hraban Ramm
@ 2023-11-20 17:29     ` Pablo Rodriguez via ntg-context
  2023-11-20 17:41     ` Wolfgang Schuster
  2 siblings, 0 replies; 7+ messages in thread
From: Pablo Rodriguez via ntg-context @ 2023-11-20 17:29 UTC (permalink / raw)
  To: ntg-context; +Cc: Pablo Rodriguez

On 11/19/23 23:17, madiazm.eoicc@gmail.com wrote:
> Thanks, Pablo and Henning
>
> I suppose I am making a mistake with my setupinterlinearspace. My
> school asks for Times New Roman (I use termes) 12pt and
> onehalfspacing. In latex I used linespread{1.3} and so I supposed
> setting ConTeXt with setupinterlinearspace[1.3ex] was the right way.

Hi Miguel,

sorry, but I don’t have any idea what \linespread might mean for LaTeX
in plain English.

Some ConTeXt users may also use LaTeX too, but don’t rely on that.

> (I read somewhere that vertical spaces should be measured in ex and
> horizontal spaces in em; maybe it's not widely accepted).

As far as I know, em is defined by the width of the capital 'M' and ex
is defined by the height of the lowercase 'x'.

With your requirements, I think it is easier to set line spacing to one
and a half line with 1.5em, such as in:

  \setupbodyfont[termes]
  \starttext
  \the\exheight\\
  \the\dimexpr3\exheight\\
  \the\emwidth
  \the\dimexpr1.5\emwidth\\
  \stoptext

Just in case it might help,

Pablo

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

* [NTG-context] Re: learning about the grid
  2023-11-19 22:17   ` madiazm.eoicc
  2023-11-19 22:42     ` Henning Hraban Ramm
  2023-11-20 17:29     ` Pablo Rodriguez via ntg-context
@ 2023-11-20 17:41     ` Wolfgang Schuster
  2 siblings, 0 replies; 7+ messages in thread
From: Wolfgang Schuster @ 2023-11-20 17:41 UTC (permalink / raw)
  To: mailing list for ConTeXt users, madiazm.eoicc

madiazm.eoicc@gmail.com schrieb am 19.11.2023 um 23:17:
> Thanks, Pablo and Henning
>
> I suppose I am making a mistake with my setupinterlinearspace. My school asks for Times New Roman (I use termes) 12pt and onehalfspacing. In latex I used linespread{1.3} and so I supposed setting ConTeXt with setupinterlinearspace[1.3ex] was the right way (I read somewhere that vertical spaces should be measured in ex and horizontal spaces in em; maybe it's not widely accepted).
> I tried setting my interlinearspace to 3ex and it looked much better, but I must compare it with a onehalfspacing of wordprocessors to be sure it is not such different.

The unit ex uses the x-height value of the font as dimension, the 
x-height is the height of the lowercase x (actually it's a value in the 
font which is most cases equal to the height of the lowercase x) as can 
be seen in the output of the following example.

\starttext

\heightofstring{x}

\the\exheight

\stoptext

To get one and a half line of interlinespace with ConTeXt you can set a 
fixed value with the \setupinterlinespace command.

\setupinterlinespace[line=18pt]

\showgrid

\starttext
\samplefile{lorem}
\stoptext

Wolfgang

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

end of thread, other threads:[~2023-11-20 17:41 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-11-19 12:27 [NTG-context] learning about the grid Miguel Diaz
2023-11-19 13:36 ` [NTG-context] " Pablo Rodriguez via ntg-context
2023-11-19 15:34 ` Henning Hraban Ramm
2023-11-19 22:17   ` madiazm.eoicc
2023-11-19 22:42     ` Henning Hraban Ramm
2023-11-20 17:29     ` Pablo Rodriguez via ntg-context
2023-11-20 17:41     ` Wolfgang Schuster

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