Re: [NTG-context] two different outputs.

2019-01-01 Thread Wolfgang Schuster

Jeong Dal schrieb am 01.01.19 um 23:28:

Dear Wolfgang,

Thank you for the solution at the new year’s day.

Your sample works very well. It is what I want.

I copied it into my file and run it, then I got a strange output.
Everything is OK except outer effect text is written twice.
I don’t know what makes it write twice.


I can’t reproduce the effect with your included example.

What I guess is that one of your setuos still contain the line

  \setuphead[title][textcommand=\TitlePage]

and you apply the effect twice because when you take a closer look
at the image you can see even the inner effect appears two times.


I have two more questions.
1. I’d like to put a title only in a page using the following. How to 
put a title as center aligned?


\setuphead[title][align=middle]


%
\page[yes]
\dontleavehmode\blank[5cm]

\title{Why, Math?}
\blank[big]
\midaligned{\fancy Why do we learn mathematics?}
\vfill
\midaligned{\tfb Institution}
\blank[2cm]
\page


2. Is there a way to remove a pagenumber from the title page?


\startstandardmakeup[align=middle]
\blank[5cm]
\title{Why, Math?}
\blank
{\fancy Why do we learn mathematics?}
\vfill
{\tfb Institution}
\blank[2cm]
\stopstandardmakeup

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
___

Re: [NTG-context] two different outputs.

2019-01-01 Thread Jeong Dal
Dear Wolfgang,

Thank you for the solution at the new year’s day.

Your sample works very well. It is what I want.

I copied it into my file and run it, then I got a strange output.
Everything is OK except outer effect text is written twice.
I don’t know what makes it write twice.
I have two more questions.
1. I’d like to put a title only in a page using the following. How to put a 
title as center aligned?
%
\page[yes]
\dontleavehmode\blank[5cm]

\title{Why, Math?}
\blank[big]
\midaligned{\fancy Why do we learn mathematics?}
\vfill
\midaligned{\tfb Institution}
\blank[2cm]
\page


2. Is there a way to remove a pagenumber from the title page?

Thank you again.
Best regards,

Dalyoung


Here is the simplified code:


%\startMPenvironment
%\stopMPenvironment

%\environment defCommon
%\environment defBook
%\usemodule[m-matrix]
%\startluacode
%mtx = moduledata.matrix
%\stopluacode

\setuplanguage[kr][patterns=us]
\mainlanguage[kr]
\setscript[hangul]

%\usetypescriptfile[type-hcrlvt]
%\usetypescript[HcrFont] % As set in your typescript file
%\definefontfamily [Myface] [mm][Neo Euler]

\definefont[fancy][Zapfino at 24pt]
\definefont[GreekA][MinionPro-MediumIt Regular]

\definefontfeature[kr][script=hang,language=kor,mode=node,analyze=yes]
%\setupbodyfont[Myface, rm, 11pt]
\setupbodyfont[pagella]
%\setuppagenumbering[state=stop]
\setupexternalfigures[directory={./figures, ./funmath/WhyMath/whyMathSlide,}]
\setupindenting[medium, yes]

\definefont [BigFontOne] [\classfont{notosanscjkkr}{Bold} sa 4]
\definecolor [BigColorOne] [r=.86,g=.850,b=.54]
\define[1]\TitlePage
 {\rlap{\offset[x=2pt,y=2pt]{\color[blue]{\effect[outer]{#1%
  \effect[inner]{#1}}
\setuphead
 [title]
 [deeptextcommand=\TitlePage,
  color=BigColorOne,
  style=BigFontOne,
  incrementnumber=list]

\startproduct Danggok

\definestructureconversionset[frontpart:pagenumber][][romannumerals]
\definestructureconversionset[bodypart:pagenumber][][numbers]
\definestructureconversionset[backpart:pagenumber][][numbers]

\startsectionblockenvironment[frontpart]
\setupuserpagenumber[numberconversion=romannumerals]
\setuppagenumber[alternative=singlesided,number=]
\stopsectionblockenvironment

\startsectionblockenvironment[bodypart]
\setuppagenumber[number=2]
\setuppagenumbering[alternative=singlesided]
\stopsectionblockenvironment

%\startsectionblockenvironment[backpart]
%\setupuserpagenumber[numberconversion=romannumerals]
%\setuppagenumbering[alternative=doublesided]
%\setuppagenumber[number=1]
%\stopsectionblockenvironment

\setupcombinedlist[content][list={title,chapter}]%,section,subsection}]
\setuplist[chapter, title][width=5mm, style=,textstyle={\ss\bf 
}]%,after={\blank[preference]}]
\setuplist[section][width=10mm, style=,textstyle=\ss,after={\blank[preference]}]
\setuplist[subsection][style=,textstyle={\ss}]
%
\startfrontmatter
\title{Contents}
\placelist[chapter,title]
\stopfrontmatter

\startbodymatter
\title{First}
\page
\title{Second}
\page
%   \component ./funmath/whyMath/whyMathH
%   \component ./Mathematics/TopicsInMath/Crypto/CryptoH
%   \component ./funmath/algorithm/algorithmH
%   \component ./funmath/Problems/squareH
%   \component ./funmath/Tiling/tilingH
\stopbodymatter

%\startbackmatter
%\stopbackmatter

\stopproduct
 

> 2019. 1. 2. 오전 5:13, Wolfgang Schuster  작성:
> 
> Jeong Dal schrieb am 01.01.19 um 01:33:
>> Dear all,
>> First, Happy new year!
>> I tried to make a style of title as following. The first code creates the 
>> title as I wanted, but the second which uses “\title” creates the title 
>> strange. they are almost same code.
>> To include it in the list of contents, I use “\title”.
> 
> \setuphead [title] [incrementnumber=list]
> 
>> Is there a way to make output as the first one and include it in the list of 
>> contents?
> 
> You have to apply your command to the deeptextcommand key.
> 
>  begin example
> 
> % \definefontfamily [mainface] [ss] [Noto Sans CJK KR]
> %
> % \setupbodyfont [mainface]
> %
> % \definefont [BigFontOne]   [SansBold sa 4]
> 
> \definefontfamily [notosanscjkkr] [ss] [Noto Sans CJK KR]
> 
> %\definefont [BigFontOne] [file:notosanscjkkrbold*default sa 4]
> \definefont [BigFontOne] [\classfont{notosanscjkkr}{Bold} sa 4]
> 
> \setupbodyfont [pagella]
> 
> \definecolor [BigColorOne] [r=.86,g=.850,b=.54]
> 
> \define[1]\TitlePage
>  {\rlap{\offset[x=2pt,y=2pt]{\color[blue]{\effect[outer]{#1%
>   \effect[inner]{#1}}
> 
> \setuphead
>  [title]
>  [deeptextcommand=\TitlePage,
>   color=BigColorOne,
>   style=BigFontOne,
>   incrementnumber=list]
> 
> \starttext
> 
> \title{Contents}
> 
> \placelist[chapter,title]
> 
> \title{Title}
> 
> \title{타이틀}
> 
> \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 / 

Re: [NTG-context] two different outputs.

2019-01-01 Thread Wolfgang Schuster

Jeong Dal schrieb am 01.01.19 um 01:33:

Dear all,

First, Happy new year!

I tried to make a style of title as following. The first code creates the title 
as I wanted, but the second which uses “\title” creates the title strange. they 
are almost same code.
To include it in the list of contents, I use “\title”.


\setuphead [title] [incrementnumber=list]


Is there a way to make output as the first one and include it in the list of 
contents?


You have to apply your command to the deeptextcommand key.

 begin example

% \definefontfamily [mainface] [ss] [Noto Sans CJK KR]
%
% \setupbodyfont [mainface]
%
% \definefont [BigFontOne]   [SansBold sa 4]

\definefontfamily [notosanscjkkr] [ss] [Noto Sans CJK KR]

%\definefont [BigFontOne] [file:notosanscjkkrbold*default sa 4]
\definefont [BigFontOne] [\classfont{notosanscjkkr}{Bold} sa 4]

\setupbodyfont [pagella]

\definecolor [BigColorOne] [r=.86,g=.850,b=.54]

\define[1]\TitlePage
  {\rlap{\offset[x=2pt,y=2pt]{\color[blue]{\effect[outer]{#1%
   \effect[inner]{#1}}

\setuphead
  [title]
  [deeptextcommand=\TitlePage,
   color=BigColorOne,
   style=BigFontOne,
   incrementnumber=list]

\starttext

\title{Contents}

\placelist[chapter,title]

\title{Title}

\title{타이틀}

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

[NTG-context] two different outputs.

2018-12-31 Thread Jeong Dal
Dear all,

First, Happy new year!

I tried to make a style of title as following. The first code creates the title 
as I wanted, but the second which uses “\title” creates the title strange. they 
are almost same code.
To include it in the list of contents, I use “\title”.
Is there a way to make output as the first one and include it in the list of 
contents?
Thank you for reading.
Best regards,

Dalyoung


\definefont[BigFontOne][NotoSansCJKkr-Bold sa 4]
\definefont[BigFontTwo][NotoSansCJKkr-Bold sa 3]
\definefont[BigFontThree][NotoSansCJKkr-Bold sa 1.5]%[YoonGothicB sa 1.5]
\definecolor[BigColorOne][r=.86,g=.850,b=.54]
\definecolor[BigColorTwo][r=.43,g=.425,b=.27]

\define[1]\TitlePage
{\begingroup
\defineoverlay[back][{\BigFontOne \blue  \starteffect[outer]#1\stopeffect}]%
\framed[frame=off,background=back,align={hilo}]
{\kern-3pt{\BigFontOne\BigColorOne  \starteffect[inner]#1\stopeffect}}
\endgroup}

\setuphead[title]
[textcommand=\TitlePage,
%color=BigColorTwo,
%style=\BigFontTwo,
%after={\blank[2cm]}]
] %number=yes]

 \starttext
\defineoverlay[back][{\BigFontOne \blue  
\starteffect[outer]Title\stopeffect}]%
\framed[frame=off,background=back,align={hilo}]
{\kern-3pt{\BigFontOne\BigColorOne  
\starteffect[inner]Title\stopeffect}}


\title{Title}

\defineoverlay[back][{\BigFontOne \blue  \starteffect[outer]타이틀\stopeffect}]%
\framed[frame=off,background=back,align={hilo}]
{\kern-3pt{\BigFontOne\BigColorOne  \starteffect[inner]타이틀\stopeffect}}

\title{타이틀}
\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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___