ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* Problem with \inouter and text justification
@ 2015-12-08 22:03 josephcanedo
  2015-12-10 10:04 ` josephcanedo
  0 siblings, 1 reply; 6+ messages in thread
From: josephcanedo @ 2015-12-08 22:03 UTC (permalink / raw)
  To: ntg-context


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

Dear all,


I am trying to add margin notes and for some reason I do not understand when having them in the main text, the main text which normally would be fully justified (without notes) is now aligned to left, but right side is erratic. I attach a simple MWE showing this.


If you disable the notes uncommenting the no op versions of \R and \N macros the text is perfectly justified. 


Any hint on what I am doing wrong or some solution to avoid this please?


Another question would be how to make the margin content always aligned to left please (even if the used margin is the left one) ? 


Many thanks


Best regards


Joseph Canedo

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

[-- Attachment #2: margin_mwe.tex --]
[-- Type: application/octet-stream, Size: 1428 bytes --]

\setuppapersize[A5][A5]

% computed from lua in document (large right margin)
\setuplayout[grid=both,edge=0sp,footer=0sp,edgedistance=0sp,margindistance=280166.5sp,footerdistance=0sp,backspace=1837977.5826sp,rightmargin=5951077.8304sp,leftmargin=1277644.5826sp,height=33829095.45sp,header=1015678.5sp,headerdistance=507839.25sp,width=18407373.087sp,topspace=760715.01666667sp]

\setupmargindata[outer][stack=continue, align=inner]

\setupbodyfont[schola, 8pt]

% margin notes, text not justified
\def\R#1{\inouter{#1}}
\def\N#1#2{\high{#1}\R{#1 #2}}

% when uncommented margin notes are gone, text justified
% \def\R#1{}
% \def\N#1#2{}

\starttext

\R{Luc.1.c}Or la nativite de Jesus Christ estoit telle. Car comme Marie mere d'iceluy fut espousee a Joseph : devant 
qu'ilz \N{h*}{ou/ fussent en mesnage}convinssent/ elle fut trouvee \N{i*}{Grec/ ayant au ventre}enceincte du sainct esprit. 
Et Joseph son mary/ estant juste/ & ne
voulant point la diffamer/ la voulut secretement \N{k*}{c'est) repudier}laisser. Mais comme iceluy pensoit ces choses/ voicy \N{l*}{Ange: c'est/ messager}l'ange du
Seigneur s'apparut a luy en son songe/ disant : Joseph filz de David/ ne crains a recevoir Marie ta femme : car
ce qui est \N{m*}{ou/ nay}conceu en elle/ est du sainct Esperit. Or enfantera elle ung filz/ & appelleras son nom \R{Jesus/ pourquoy est il ainsi appelle.}Jesus : car
iceluy sauvera son peuple de leurs pechez.

\stoptext

[-- Attachment #3: Type: text/plain, Size: 485 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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

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

* Re:  Problem with \inouter and text justification
  2015-12-08 22:03 Problem with \inouter and text justification josephcanedo
@ 2015-12-10 10:04 ` josephcanedo
  2015-12-11 12:13   ` Wolfgang Schuster
  0 siblings, 1 reply; 6+ messages in thread
From: josephcanedo @ 2015-12-10 10:04 UTC (permalink / raw)
  To: ntg-context


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

Dear all,


Another problem appears if using both \inouter and \ininner to have notes in both sides. Apparently when doing so the stack=continue does not work any longer. I see margin notes overlapping and not being stacked.


If the “left note” is removed the right side notes are stacked properly again.


Is there any solution to avoid the previous problem and this one please ? 

Thanks


Best regards


Joseph Canedo





From: josephcanedo@gmail.com
Sent: ‎Tuesday‎, ‎December‎ ‎8‎, ‎2015 ‎11‎:‎03‎ ‎PM
To: ntg-context@ntg.nl





Dear all,




I am trying to add margin notes and for some reason I do not understand when having them in the main text, the main text which normally would be fully justified (without notes) is now aligned to left, but right side is erratic. I attach a simple MWE showing this.




If you disable the notes uncommenting the no op versions of \R and \N macros the text is perfectly justified. 




Any hint on what I am doing wrong or some solution to avoid this please?




Another question would be how to make the margin content always aligned to left please (even if the used margin is the left one) ? 




Many thanks




Best regards




Joseph Canedo

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

[-- Attachment #2: margin_mwe.tex --]
[-- Type: application/octet-stream, Size: 2986 bytes --]

\setuppapersize[A5][A5]

% computed from lua in document (large right margin)
\setuplayout[grid=both,edge=0sp,footer=0sp,edgedistance=0sp,margindistance=280166.5sp,footerdistance=0sp,backspace=1837977.5826sp,rightmargin=5951077.8304sp,leftmargin=1277644.5826sp,height=33829095.45sp,header=1015678.5sp,headerdistance=507839.25sp,width=18407373.087sp,topspace=760715.01666667sp]

\setupmargindata[outer][stack=continue, align=inner]
\setupmargindata[inner][stack=continue, align=outer]

\setupbodyfont[schola, 8pt]

% margin notes, text not justified
\def\R#1{\inouter{#1}}
\def\N#1#2{\high{#1}\R{#1 #2}}

% when uncommented margin notes are gone, text justified
% \def\R#1{}
% \def\N#1#2{}

\def\LR#1{\ininner{#1}}

\starttext

Et quand Jesus fut nay en Beth-lehem [cite] de \N{n}{Aucuns exemplaires/ de Jehudah}Judee \N{o}{ou/ jours}au temps du roy Herode : 
voicy les \N{p}{Ceulx cy estoient (comme refere Strabo au livre.16.) gens sages entre les Persiens/ ainsi que estoit Moseh entre les Juifs. Aussi comme anciennement les Druides/ les 
sages de la Gaulle/ desquelz ledict Strabo livre.4. et Diogene au commencement de la vie des Philosophes & Marcellin livre.15. Telz n'estoient pas Roys ne princes: combien qu'il advint
que apres la mort de Cambyses (comme dit Joseph. Antiq.11.ch 3.) ilz gouvernerent le royaume: mais seulement ung an: & ce environ 523 ans avant la venue de Christ.}Sages 
vindrent d'Orient en Jerusalem/
disans : Ou est celuy qui est nay Roy des Juifz ? car nous avons veu son estoille en Orient : & le sommes venuz adorer.

Or le roy Herode/ ayant ouy [ce]/ fut trouble/ & toute la cite \LR{left note}de Jerusalem avec luy. Et ayant assemble tous les
principaulx sacrificateurs/ & les Scribes du peuple/ il senqueroit deulx ou Christ devoit naistre. Et iceulx luy dirent :
En Beth-lehem de Judee. Car il est ainsi par le Prophete : Et toy Beth-lehem terre de Jehudah : tu n'es pas la plus petite 
entre les Princes de Jehudah : car de toy me sortira le Duc qui gouvernera mon peuple Israel.

Adonc Herode appella en secret les sages : & diligemment s'informa de eulx/ du temps de l'estoille/ laquelle [leur]
estoit apparue. Et les envoyant en Beth-lehem [leur] dist : Allez & vous enquestez diligemment de l'enfantelet : & quand
vous l'aurez trouve/ denoncez le moy : affin que aussi je y voyse/ & que je l'adore.

Et quand ilz eurent ouy le roy/ ilz s'en allerent. Et voicy l'estoille qu'ilz avoient veue en Orient/ les precedoit
jusque a tant qu'elle vint/ & s'arresta sus [le lieu] ou estoit l'enfantelet. Et quand ilz veirent l'estoille/ ilz s'esjouyrent de
moult grand joye : & entrans en la maison/ ilz trouverent l'enfantelet avec Marie sa mere/ & se \N{q}{c'est) se baissans/ & se enclinans}prosternans l'adorerent.
Et ayans ouvert leurs thresors/ ilz luy presenterent dons : or/ & encens/ & myrrhe. Et apres qu'ilz eurent eu
divine responce en [leur] somne/ de non retourner a Herode/ ilz s'en retournerent par aultre voye en leur region.

\stoptext

[-- Attachment #3: Type: text/plain, Size: 485 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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

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

* Re: Problem with \inouter and text justification
  2015-12-10 10:04 ` josephcanedo
@ 2015-12-11 12:13   ` Wolfgang Schuster
  2015-12-11 20:03     ` josephcanedo
  0 siblings, 1 reply; 6+ messages in thread
From: Wolfgang Schuster @ 2015-12-11 12:13 UTC (permalink / raw)
  To: mailing list for ConTeXt users


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

> josephcanedo@gmail.com <mailto:josephcanedo@gmail.com>
> 10. Dezember 2015 um 11:04
> Dear all,
>
> Another problem appears if using both \inouter and \ininner to have 
> notes in both sides. Apparently when doing so the stack=continue does 
> not work any longer. I see margin notes overlapping and not being stacked.
>
> If the “left note” is removed the right side notes are stacked 
> properly again.
>
> Is there any solution to avoid the previous problem and this one please ?
Are notes a alternative for you?

\startsetups[marginnotes]
     \startframed[width=max,height=max,align=high,strut=no]
         \placenotes[marginnote][before=,after=,rule=off]
     \stopframed
\stopsetups

\setuptexttexts[margin][][\directsetup{marginnotes}]

\definenote   [marginnote][criterium=page]
\setupnotation[marginnote][number=no]

\starttext

\dorecurse{100}{\input ward\expanded{\marginnote{This is note 
\recurselevel}} }

\stoptext

Wolfgang

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

[-- Attachment #2: Type: text/plain, Size: 485 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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

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

* Re:  Problem with \inouter and text justification
  2015-12-11 12:13   ` Wolfgang Schuster
@ 2015-12-11 20:03     ` josephcanedo
  2015-12-15 20:58       ` josephcanedo
  0 siblings, 1 reply; 6+ messages in thread
From: josephcanedo @ 2015-12-11 20:03 UTC (permalink / raw)
  To: ntg-context


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

Thanks Wolfgang for alternative proposal.

I had a try with your sample and it seems the margin notes stay stacked but not nearby the line I insert them in the text, which is what I

am looking for. Is there a way to achieve this using notes ?


Otherwise I assume that there is a bug with \ininner \inouter then ? 


Also I noticed there is a \ininnermargin, but I was curious to know what’s the difference with \ininner.


Thanks a lot


Joseph





From: Wolfgang Schuster
Sent: ‎Friday‎, ‎December‎ ‎11‎, ‎2015 ‎1‎:‎13‎ ‎PM
To: ntg-context@ntg.nl








josephcanedo@gmail.com

10. Dezember 2015 um 11:04


Dear all,




Another problem appears if using both \inouter and \ininner to have notes in both sides. Apparently when doing so the stack=continue does not work any longer. I see margin notes overlapping and not being stacked.




If the “left note” is removed the right side notes are stacked properly again.




Is there any solution to avoid the previous problem and this one please ? 
Are notes a alternative for you?

\startsetups[marginnotes]
    \startframed[width=max,height=max,align=high,strut=no]
        \placenotes[marginnote][before=,after=,rule=off]
    \stopframed
\stopsetups

\setuptexttexts[margin][][\directsetup{marginnotes}]

\definenote   [marginnote][criterium=page]
\setupnotation[marginnote][number=no]

\starttext

\dorecurse{100}{\input ward\expanded{\marginnote{This is note \recurselevel}} }

\stoptext

Wolfgang

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

[-- Attachment #2: Type: text/plain, Size: 485 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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

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

* Re:  Problem with \inouter and text justification
  2015-12-11 20:03     ` josephcanedo
@ 2015-12-15 20:58       ` josephcanedo
  2016-01-22  8:45         ` josephcanedo
  0 siblings, 1 reply; 6+ messages in thread
From: josephcanedo @ 2015-12-15 20:58 UTC (permalink / raw)
  To: ntg-context


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


Is this problem a hard limitation from (lua)TeX ? or simply some bug in ConTeXt ?

The problem with main text justification is not present with “stable” version of ConTeXt, so my guess is that’s a regression in beta.


I initially used stack=yes but despite the name in some cases the notes fail to stack and overlapped. 




Thanks a lot,




Joseph





From: josephcanedo@gmail.com
Sent: ‎Friday‎, ‎December‎ ‎11‎, ‎2015 ‎9‎:‎03‎ ‎PM
To: ntg-context@ntg.nl





Thanks Wolfgang for alternative proposal.

I had a try with your sample and it seems the margin notes stay stacked but not nearby the line I insert them in the text, which is what I

am looking for. Is there a way to achieve this using notes ?




Otherwise I assume that there is a bug with \ininner \inouter then ? 




Also I noticed there is a \ininnermargin, but I was curious to know what’s the difference with \ininner.




Thanks a lot




Joseph





From: Wolfgang Schuster
Sent: ‎Friday‎, ‎December‎ ‎11‎, ‎2015 ‎1‎:‎13‎ ‎PM
To: ntg-context@ntg.nl








josephcanedo@gmail.com

10. Dezember 2015 um 11:04


Dear all,




Another problem appears if using both \inouter and \ininner to have notes in both sides. Apparently when doing so the stack=continue does not work any longer. I see margin notes overlapping and not being stacked.




If the “left note” is removed the right side notes are stacked properly again.




Is there any solution to avoid the previous problem and this one please ? 
Are notes a alternative for you?

\startsetups[marginnotes]
    \startframed[width=max,height=max,align=high,strut=no]
        \placenotes[marginnote][before=,after=,rule=off]
    \stopframed
\stopsetups

\setuptexttexts[margin][][\directsetup{marginnotes}]

\definenote   [marginnote][criterium=page]
\setupnotation[marginnote][number=no]

\starttext

\dorecurse{100}{\input ward\expanded{\marginnote{This is note \recurselevel}} }

\stoptext

Wolfgang

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

[-- Attachment #2: Type: text/plain, Size: 485 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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

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

* Re:  Problem with \inouter and text justification
  2015-12-15 20:58       ` josephcanedo
@ 2016-01-22  8:45         ` josephcanedo
  0 siblings, 0 replies; 6+ messages in thread
From: josephcanedo @ 2016-01-22  8:45 UTC (permalink / raw)
  To: ntg-context


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

Dear list,


The problem with margin notes and main text justification being wrong in some lines when using stack=continue is still present with latest beta mtx-context     | current version: 2016.01.18 22:21 


This can be verified with the test stacking-002.tex in test suite or with MWE I posted earlier.


Just wanted to know if fixing this problem was planned for next “stable” version or if that feature is somewhat deprecated ? This problem does not occur with current “stable” ConTeXt version.


Many thanks for any hint,


Joseph





From: josephcanedo@gmail.com
Sent: ‎Tuesday‎, ‎December‎ ‎15‎, ‎2015 ‎9‎:‎58‎ ‎PM
To: ntg-context@ntg.nl






Is this problem a hard limitation from (lua)TeX ? or simply some bug in ConTeXt ?

The problem with main text justification is not present with “stable” version of ConTeXt, so my guess is that’s a regression in beta.




I initially used stack=yes but despite the name in some cases the notes fail to stack and overlapped. 




Thanks a lot,




Joseph





From: josephcanedo@gmail.com
Sent: ‎Friday‎, ‎December‎ ‎11‎, ‎2015 ‎9‎:‎03‎ ‎PM
To: ntg-context@ntg.nl





Thanks Wolfgang for alternative proposal.

I had a try with your sample and it seems the margin notes stay stacked but not nearby the line I insert them in the text, which is what I

am looking for. Is there a way to achieve this using notes ?




Otherwise I assume that there is a bug with \ininner \inouter then ? 




Also I noticed there is a \ininnermargin, but I was curious to know what’s the difference with \ininner.




Thanks a lot




Joseph





From: Wolfgang Schuster
Sent: ‎Friday‎, ‎December‎ ‎11‎, ‎2015 ‎1‎:‎13‎ ‎PM
To: ntg-context@ntg.nl








josephcanedo@gmail.com

10. Dezember 2015 um 11:04


Dear all,




Another problem appears if using both \inouter and \ininner to have notes in both sides. Apparently when doing so the stack=continue does not work any longer. I see margin notes overlapping and not being stacked.




If the “left note” is removed the right side notes are stacked properly again.




Is there any solution to avoid the previous problem and this one please ? 
Are notes a alternative for you?

\startsetups[marginnotes]
    \startframed[width=max,height=max,align=high,strut=no]
        \placenotes[marginnote][before=,after=,rule=off]
    \stopframed
\stopsetups

\setuptexttexts[margin][][\directsetup{marginnotes}]

\definenote   [marginnote][criterium=page]
\setupnotation[marginnote][number=no]

\starttext

\dorecurse{100}{\input ward\expanded{\marginnote{This is note \recurselevel}} }

\stoptext

Wolfgang

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

[-- Attachment #2: Type: text/plain, Size: 485 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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

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

end of thread, other threads:[~2016-01-22  8:45 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-12-08 22:03 Problem with \inouter and text justification josephcanedo
2015-12-10 10:04 ` josephcanedo
2015-12-11 12:13   ` Wolfgang Schuster
2015-12-11 20:03     ` josephcanedo
2015-12-15 20:58       ` josephcanedo
2016-01-22  8:45         ` josephcanedo

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