Re: [NTG-context] Interlining in a TwoColumns set

2016-08-12 Thread Pablo Rodriguez
On 08/12/2016 03:50 PM, Jean-Pierre Delange wrote:
> Dear List,
> 
> In order to help somebody who wants to improve a kind presentation of
> his own, I have set the sample below.

Dear Jean-Pierre,

we are happy to help, but samples should be minimal.

Otherwise, the sample should be fixed first (to have something to play
with).

Sorrym I tried to compile your sample, but even the simple clipboard
copy and paste adds extra blank lines to the code.

> I am confronting to 2 issues :
> 
> 1. In the second column it would be fine if one could play with the
> interlining. But where to put this command :
> \setupinterlinespace[line=2.8ex]}] which allow to define interlines
> inside the 2nd column ?

Do you want a different interline space in the second column?

> 2. The Logo.svg picture (in /Images/Logo.svg within context repertory)
> doesn't print : 'state: unknown'; is it an issue caused by a layer
> definition ?

You have to set it (see sample below).

> % Select language
> 
> \mainlanguage[fr]
> \language[fr]

\mainlanguage also selects the language for the document. The second
command isn’t required.

> % Normal A4 size paper
> 
> \setuppapersize[A4][A4]

Well, this is the default paper size in ConTeXt. No need to select it.

> \setupcolors[state=start]

I’d say this is not required (at least, I had to stop colors to get rid
of them in one document).

> \definelayer[logo_layer]

[state=start] is to be added here (see
http://wiki.contextgarden.net/Layers#State). Right after your closing
bracket.

And here you have a shorter sample:

\mainlanguage[fr]

\defineparagraphs[TwoColumns][n=2, align={hz,hanging}]
\setupparagraphs[TwoColumns][1][width=200pt]
\setupparagraphs[TwoColumns][2]
[style={\setupinterlinespace[line=5ex]}]

\setupexternalfigure[location=default]

\definelayer[logo_layer][state=start]

\setlayer[logo_layer][preset=lefttop, y=.01\paperheight,
x=.82\paperwidth]{\externalfigure[spider][height=0.2\textwidth]}

\setupbackgrounds[page][background={logo_layer}]

\starttext

\dorecurse{5}{\startTwoColumns

\input knuth

\TwoColumns

\input tufte
\stopTwoColumns}
\stoptext

Interline spacing is set in an unorthodox way (to put it fine), but
there is no "setups" key for \setupparagraphs (or it doesn’t work).

Let us know whether you find more issues.

I hope it helps,


Pablo
-- 
http://www.ousia.tk
___
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
___

Re: [NTG-context] Interlining in a TwoColumns set

2016-08-12 Thread Jean-Pierre Delange

Dear List,

In order to help somebody who wants to improve a kind presentation of 
his own, I have set the sample below.

I am confronting to 2 issues :

1. In the second column it would be fine if one could play with the 
interlining. But where to put this command : 
\setupinterlinespace[line=2.8ex]}] which allow to define interlines 
inside the 2nd column ?


2. The Logo.svg picture (in /Images/Logo.svg within context repertory) 
doesn't print : 'state: unknown'; is it an issue caused by a layer 
definition ?


Thanks for your advices.
JP

% Select language

\mainlanguage[fr]

\language[fr]


% Setup PDF metadata

\setupinteraction

[state=start,

color=colour_link,

click=yes,

contrastcolor=colour_link,

focus=standard, % Clicking an inter-document hyperlink by default 
switches to "fit page" mode. Override.


openaction={FitWidth,ToggleViewer},

title={Anciens et Modernes},

style=normal,

subtitle={Anciens et Modernes},

author=Adeimantos ,

keyword={philosophy, history, political philosophy}]


% Turn off page numbering

\setuppagenumbering[location=]


% Normal A4 size paper

\setuppapersize[A4][A4]


% Setup margins

\setuplayout[

backspace=10mm,

width=190mm,

topspace=5mm,

header=0mm,

footer=5mm,

footerdistance=0mm,

bottomdistance=10mm,

height=280mm]

%\showframe


% For coloured output

\setupcolors[state=start]


% Font setup


% Font to use

\definefontfamily [main_font] [rm] [titillium] [features={default,quality}]

\definefontfamily [main_font] [mm] [TeX Gyre Pagella]

\setupbodyfont[main_font]


% URL macros and setups


% Usage: \href{http://www.someurl.com}{Text}

\def\href#1#2{\useURL[#2][{#2}][][{#1}]\goto{\url[#2]}[url(#1)]}

\def\ahref#1{\href{#1}{<#1>}}

\def\fullahref#1{\href{#1}{#1}}

\def\mailto#1{\useURL[#1][mailto:#1][][#1]\from[{#1}]}

\def\MailTo#1#2{\useURL[#1][mailto:#1][][#2]\from[{#1}]}


% Style

\setupurl

[color=none,

style=normal]


% Setup two columns

\defineparagraphs[TwoColumns][n=2, align={hz,hanging}]

\setupparagraphs[TwoColumns][1][width=200pt]


% Setup stretching tolerance...

\setuptolerance[verytolerant,stretch]


\setupcolors[state=start]


% The elements of the letterhead are defined as layers. This first layer

% contains the logo; you'll have to supply an image file yourself.

\definelayer[logo_layer]

\setlayer[logo_layer][preset=lefttop,y=.01\paperheight,x=.82\paperwidth]

{\externalfigure[Images/Logo.svg][][height=0.2\textwidth]}


% Activate all layers for this page...

\setupbackgrounds[page][background={logo_layer}]


% Start document body...

\starttext


% Header...

{\switchtobodyfont[40pt] Anciens et Modernes \crlf}

\blackrule[height=0.6mm,width=0.83\textwidth]


% Dateline...

{\bf Présentation}\crlf

\currentdate[dd,{~},m,{~},year]


% Headline...

\blank

\framed[align=middle,width=200mm,height=13mm,frame=off]

{

\bf \switchtobodyfont[15pt]

{\bf Philosophie politique.}

}


\startTwoColumns

\startlines

{\bf Contact Information}

Adeimantos

Le Manoir

F - 18190 Chavannes

adeiman...@free.fr


{\bf Édition}

Livres, articles


{\bf Dévelopement}

Prototype


{\bf Année de création}

2012


{\bf Financements privés}

\$0


\stoplines


\TwoColumns

\input tufte


\stopTwoColumns


\stoptext

___
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
___

Re: [NTG-context] Problems with old style figures and particular font

2016-08-12 Thread Wolfgang Schuster

Martin Oppegaard 
11. August 2016 um 21:42
Hi Wolfgang, thank you for the quick reply.

Moving \definefontfeature before \setupbodyfont doesn't change anything
for me. Here is the output of running context:

You need also "script=latn" when you enable oldstyle numerals.


You can use the mtxrun script to list the available features of a font
where you also see the necessary script:

$ mtxrun --script font --list --info fbbregular

resolvers   | trees | analyzing 'home:texmf'
mtx-fonts   |
mtx-fonts   | mapping   : fbbregular
mtx-fonts   | fontname  : fbbregular
mtx-fonts   | fullname  : fbbregular
mtx-fonts   | filename  : fbb-Regular.otf
mtx-fonts   | family: fbb
mtx-fonts   | weight: normal
mtx-fonts   | style : normal
mtx-fonts   | width : normal
mtx-fonts   | variant   : normal
mtx-fonts   | fweight   : conflict: regular
mtx-fonts   |
...
mtx-fonts   |
mtx-fonts   | gsub features:
mtx-fonts   |
mtx-fonts   | feature  script   languages
mtx-fonts   |
...
mtx-fonts   | onum grek dflt
mtx-fonts   |  latn dflt



 begin example
\starttypescript [serif] [fbb]
  \setups[font:fallback:serif]
  \definefontsynonym [Serif]   [file:fbbregular]
  \definefontsynonym [SerifItalic] [file:fbbitalic]
  \definefontsynonym [SerifBold]   [file:fbbbold]
  \definefontsynonym [SerifBoldItalic] [file:fbbbolditalic]
\stoptypescript

\definefontfeature[default][default][script=latn,onum=yes]

\definetypeface [fbb] [rm] [serif] [fbb][default] [features=default]
\definetypeface [fbb] [mm] [math]  [modern] [default]

\setupbodyfont[fbb]

\starttext
ABC abc 1234
\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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Problems with old style figures and particular font

2016-08-12 Thread Martin Oppegaard
Hi Wolfgang, thank you for the quick reply.

On Thu, Aug 11 2016, Wolfgang Schuster wrote:
> 
> 
> Martin Oppegaard
> 10. August 2016 um 22:27
> 
> Dear list,
> 
> I'm having problems getting old style figures and ligatures with
> the fbb
> font. I'm using Tex live 2014 on OpenBSD 5.9 and context version
> 2014.05.21 22:04. otfinfo -f fbb-Regular.otf reports that it has
> onum
> and liga, and it works fine with lualatex. I have tried with a
> typescript and simplefont (the fbb font is being used in all three
> cases); see attached examples. Do you have any suggestions?
> 
> % type-fbb.mkiv
> \starttypescript [serif] [fbb] [name]
> \definefontsynonym [Serif] [file:fbb-Regular.otf]
> [features=default]
> \definefontsynonym [SerifItalic] [file:fbb-Italic.otf]
> [features=default]
> \stoptypescript
> 
> \starttypescript [fbb]
> \definetypeface [fbb] [rm] [serif] [fbb] [default]
> \stoptypescript
> 
> 
> % contex-test1.tex
> \usetypescriptfile[type-fbb]
> \usetypescript[fbb]
> \setupbodyfont[fbb,11pt]
> \definefontfeature[default][default][liga=yes,onum=yes]
> 
> Move the \definefontfeature setting before \setupbodyfont because
> changes to the feature set after the font is loaded are ignored.
>
> \definefontfeature[default][default][liga=yes,onum=yes]
> \setupbodyfont[fbb,11pt]
>
> Wolfgang
>

Moving \definefontfeature before \setupbodyfont doesn't change anything
for me.  Here is the output of running context:


open source > 1 > 1 > 
/usr/local/share/texmf-dist/tex/context/base/cont-yes.mkiv

ConTeXt  ver: 2014.05.21 22:04 MKIV beta  fmt: 2016.2.22  int: english/english

system  > 'cont-new.mkiv' loaded
open source > 2 > 2 > 
/usr/local/share/texmf-dist/tex/context/base/cont-new.mkiv
close source> 2 > 2 > 
/usr/local/share/texmf-dist/tex/context/base/cont-new.mkiv
system  > files > jobname 'context-test1', input './context-test1', 
result 'context-test1'
fonts   > latin modern fonts are not preloaded
languages   > language 'en' is active
open source > 2 > 3 > /home/martin/documents/fbb-test/context-test1.tex
open source > 3 > 4 > type-fbb.mkiv
close source> 3 > 4 > type-fbb.mkiv
fonts   > preloading modern-designsize (math)
fonts   > typescripts > unknown library 'modern-designsize' or 'modern'
fonts   > 'fallback modern-designsize mm 11pt' is loaded
fonts   > preloading modern-designsize (mono)
fonts   > 'fallback modern-designsize tt 11pt' is loaded
backend > xmp > using file 
'/usr/local/share/texmf-dist/tex/context/base/lpdf-pdx.xml'
pages   > flushing realpage 1, userpage 1
close source> 2 > 4 > /home/martin/documents/fbb-test/context-test1.tex
close source> 1 > 4 > 
/usr/local/share/texmf-dist/tex/context/base/cont-yes.mkiv

system  > structure > start used structure

used structure  > text: context-test1

system  > structure > stop used structure


system  > files > start used files

used file   >1: filename=cont-yes.mkiv filetype=tex 
foundname=/usr/local/share/texmf-dist/tex/context/base/cont-yes.mkiv 
usedmethod=database
used file   >2: filename=cont-new.mkiv filetype=tex 
foundname=/usr/local/share/texmf-dist/tex/context/base/cont-new.mkiv 
usedmethod=database
used file   >3: filename=lang-us.lua filetype=lua 
foundname=/usr/local/share/texmf-dist/tex/context/patterns/lang-us.lua 
usedmethod=database
used file   >4: 
filename=/home/martin/documents/fbb-test/context-test1.tex 
foundname=/home/martin/documents/fbb-test/context-test1.tex usedmethod=direct
used file   >5: filename=type-fbb.mkiv foundname=type-fbb.mkiv 
usedmethod=direct
used file   >6: filename=fbb-Regular.otf filetype=otf format=otf 
foundname=/usr/local/share/texmf-dist/fonts/opentype/public/fbb/fbb-Regular.otf 
usedmethod=database
used file   >7: filename=lpdf-pdx.xml filetype=tex 
foundname=/usr/local/share/texmf-dist/tex/context/base/lpdf-pdx.xml 
usedmethod=database

system  > files > stop used files


system  > options > start commandline options

used option > currentrun="3"
used option > fulljobname="./context-test1.tex"
used option > input="./context-test1.tex"
used option > kindofrun="2"
used option > maxnofruns="8"
used option > no-parse-first-line="true"

system  > options > stop commandline options

system  > options > start commandline files

used file   >1: ./context-test1.tex

system  > options > stop commandline files


mkiv lua stats  > used config file: 
selfautodir:/share/texmf-dist/web2c/texmfcnf.lua
mkiv lua stats  > used cache path: readable: 
'/usr/local/share/texmf-var/luatex-cache/context/0399a8df3aef8d154781d0a9c2b8e28d'
 | readable+writable: 

Re: [NTG-context] Now Bibliography works, but question to the backmatter

2016-08-12 Thread Ursula Hermann
Hello Henri!

Many thanks, this works perfect. 

LG

Uschi

-Ursprüngliche Nachricht-
Von: ntg-context [mailto:ntg-context-boun...@ntg.nl] Im Auftrag von Henri Menke
Gesendet: Donnerstag, 11. August 2016 21:10
An: mailing list for ConTeXt users
Betreff: Re: [NTG-context] Now Bibliography works, but question to the 
backmatter

Hi Uschi,

I guess you have to add a prefix to your dataset.  I'm not so sure about this 
being correct, maybe Alan can help out.  At least the rendering looks decent.

\startbuffer[biblio]
@book{ErikssonBaaz2005,
  author ={Eriksson, Maria}
  title = {The Paternalism of Partnership. A Postcolonial Reader of Identity in 
Development Aid.},
  year = {2005},
}
\stopbuffer

\usebtxdataset[truman][biblio.buffer]
\usebtxdefinitions[apa]
\definebtxrendering[truman][apa][dataset=truman]

\starttext
Das vorangestellte Zitat der Amtsantrittsrede des 33. US-amerikanischen 
Präsidenten Harry S. Truman vom 20. Januar 1949 wird innerhalb der sich als 
kritisch verstehenden Entwicklungsforschung häufig als Beginn des modernen 
Entwicklungsdiskurses diskutiert, in der sich eine neue Diskursordnung im 
Sprechen und Denken über den globalen Süden 
formiert.\footnote{\cite[alternative=entry][truman::ErikssonBaaz2005]}
\startbackmatter
  \startchapter[title={Bibliography}]
\placelistofpublications
\startsection[title=Allgemeine Literatur]
  \placelistofpublications[truman][method=dataset]
\stopsection
  \stopchapter
\stopbackmatter
\stoptext

On 08/11/2016 11:14 AM, Ursula Hermann wrote:
> Hello Henri!
> 
> Now I have tried your example. 
> \startbuffer[biblio]
> @book{ErikssonBaaz2005,
>   author ={Eriksson, Maria}
>   title = {The Paternalism of Partnership. A Postcolonial Reader of Identity 
> in Development Aid.},
>   year = {2005},
> }
> \stopbuffer
> 
> \usebtxdataset[biblio.buffer]
> \usebtxdefinitions[apa]
> \setupbtxrendering[repeat=yes]
> 
> \starttext
> Das vorangestellte Zitat der Amtsantrittsrede des 33. 
> US-amerikanischen Präsidenten Harry S. Truman vom 20. Januar 1949 wird 
> innerhalb der sich als kritisch verstehenden Entwicklungsforschung 
> häufig als Beginn des modernen Entwicklungsdiskurses diskutiert, in 
> der sich eine neue Diskursordnung im Sprechen und Denken über den 
> globalen Süden 
> formiert.\footnote{\cite[alternative=entry][ErikssonBaaz2005]}
> \startbackmatter
>   \startchapter[title={Bibliography}]
> \placelistofpublications
> \startsection[title=Allgemeine Literatur]
>   \placelistofpublications
> \stopsection
>   \stopchapter
> \stopbackmatter
> \stoptext
> 
> But I do not want to repeat. 
> 
> The footnote with "Eriksson" should only be in the section of the backmatter 
> "Allgemeine Literatur". I think this has to do with the 
> command\placelistofpublications or \setupbtxrendering. I have no idea what to 
> write. 
> 
> Uschi
> 
> 
> -Ursprüngliche Nachricht-
> Von: ntg-context [mailto:ntg-context-boun...@ntg.nl] Im Auftrag von 
> Henri Menke
> Gesendet: Dienstag, 9. August 2016 16:22
> An: mailing list for ConTeXt users
> Betreff: Re: [NTG-context] Now Bibliography works, but question to the 
> backmatter
> 
> Hi Uschi,
> 
> you are looking for repeat=yes.  Citing the manual
> 
> »One must specify repeat=yes in order to get multiple renderings of a 
> bibliography list; otherwise, as they appear, entries get marked as 
> placed and will be inhibited from being placed again elsewhere.«
> 
> Cheers, Henri
> 
> ---
> 
> \startbuffer[biblio]
> @book{ErikssonBaaz2005,
>   author ={Eriksson, Maria}
>   title = {The Paternalism of Partnership. A Postcolonial Reader of Identity 
> in Development Aid.},
>   year = {2005},
> }
> \stopbuffer
> 
> \usebtxdataset[biblio.buffer]
> \usebtxdefinitions[apa]
> \setupbtxrendering[repeat=yes]
> 
> \starttext
> Das vorangestellte Zitat der Amtsantrittsrede des 33. 
> US-amerikanischen Präsidenten Harry S. Truman vom 20. Januar 1949 wird 
> innerhalb der sich als kritisch verstehenden Entwicklungsforschung 
> häufig als Beginn des modernen Entwicklungsdiskurses diskutiert, in 
> der sich eine neue Diskursordnung im Sprechen und Denken über den 
> globalen Süden 
> formiert.\footnote{\cite[alternative=entry][ErikssonBaaz2005]}
> \startbackmatter
>   \startchapter[title={Bibliography}]
> \placelistofpublications
> \startsection[title=Allgemeine Literatur]
>   \placelistofpublications
> \stopsection
>   \stopchapter
> \stopbackmatter
> \stoptext
> 
> On 08/09/2016 03:52 PM, Ursula Hermann wrote:
>> Hello Henry!
>> This is the title, wich should be in the section of Bibliography 
>> \startbuffer[biblio] @book{ErikssonBaaz2005,
>>   author ={Eriksson, Maria}
>>   title = {The Paternalism of Partnership. A Postcolonial Reader of Identity 
>> in Development Aid.},
>>   year = {2005},
>> \starttext
>> Das vorangestellte Zitat der Amtsantrittsrede des 33. 
>> US-amerikanischen Präsidenten Harry S. Truman vom 20. Januar 1949 
>> wird innerhalb der sich als kritisch