[NTG-context] Two questions related with bibliography

2012-07-29 Thread Wei-Wei Guo
Dear all,

I have a self-made bst file in the same folder with the main tex file. I
cannot figure out how to enable it. I tried 

\setuppublications[alternative=mybst]

and 

\bibstyle[mybst]

Both do not work. How should I do?


Another question is how to set the citations in main text to be
subscript? 


BTW, will ConTeXt drop BibTeX one day?


Best regards,
Wei-Wei

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


[NTG-context] Does or will bib module use ris format?

2009-05-15 Thread Wei-Wei Guo

Hi Taco,

I searched in mailing list and found that you had been considering using risx
as the internal bib format? Did you do it in t-bib?

And as I understand, you are writing a new bib module with Lua. What will the
internal format of the new bib module be?

I'm using RefDB, whose internal bib format is ris, and am thinking about
combining RefDB with ConTeXt.


Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] beta

2009-05-11 Thread Wei-Wei Guo

Hans Hagen 写道:



i uploaded a beta with some fixes



The following bug is still there.


! Argument of \dotripletestemptyx has an extra }.
inserted text
\par
to be read again
   }
\doif #1#2-\edef \!!stringa {#1}
 \edef \!!stringb {#2}\ifx \!!stringa \!!str...
\dostructurecountercomponent ...\c!title }\v!none
  {\setfalse \hasstructureco...
\docompletefloat ...c!title ={#4},\c!bookmark =][]
  \globallet \currentfloatnu...
argument ...\footnote {Test footnote.}}\nextbox
  \else \docompletefloat {ta...
...
l.12 {\placelocalfootnotes}


Example:


\starttext

\startlocalfootnotes
\placetable{Test table\footnote{Test footnote.}}
\placelegend{
\starttable[|l|l|]
  \HL
  \NC East \NC North \NC \FR
  \NC West \NC South \NC  \LR
  \HL
\stoptable}
{\placelocalfootnotes}
\stoplocalfootnotes

\stoptext


Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] texts in \component files are not present

2009-05-11 Thread Wei-Wei Guo

Henning Hraban Ramm 写道:

Am 2009-05-11 um 02:32 schrieb Wei-Wei Guo:

1. Don't use project files as top level file for your document, use 
product and
  components (which can be nested) files only, projects are meta file 
when you

  have many document with the same topic (e.g. a magazine etc.)


A magazine is really one of my purposes. :)


Then the magazine is your project, one issue is a product, one article 
is a component.


For something similar I use a directory for the magazine and 
subdirectories per product; i.e. project and environment file reside in 
the main directory, product and component files in subdirs.


ConTeXt looks for files always in parent directories, so the environment 
is always found, but the same component file names can occurr in several 
product dirs.




Thanks. That's what I'm trying to do, but texts in \component files is not 
included.
Should I run the product file instead of project file?


Best wishes,
Wei-Wei

___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] texts in \component files are not present

2009-05-10 Thread Wei-Wei Guo

Dear all,

Text in component files are not included in the attached example. I also put 
the log
file in it. The log shows that the component files were found and complied but 
their
texts were not present in the generated pdf file.

I'm not sure whether I did anything wrong in the example or not. I checked many 
time
and didn't find anything.


Best wishes,
Wei-Wei


test.tgz
Description: Binary data
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] texts in \component files are not present

2009-05-10 Thread Wei-Wei Guo

Hans Hagen 写道:

Text in component files are not included in the attached example. I 
also put the log
file in it. The log shows that the component files were found and 
complied but their

texts were not present in the generated pdf file.

I'm not sure whether I did anything wrong in the example or not. I 
checked many time

and didn't find anything.


runs ok here; 


It runs ok here too, but the texts, like Text of leasure., are not present.
Actually the whole contents of \component files are missing. Do your generated
pdf has lines like Text of leasure. or Text of kaka.?


 i see cache filling in the log; does that happen each run?

Do you mean the info in the log? The log info seems the same in each run.


Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] texts in \component files are not present

2009-05-10 Thread Wei-Wei Guo

Wolfgang Schuster 写道:

Text in component files are not included in the attached example. I 
also put the log
file in it. The log shows that the component files were found and 
complied but their

texts were not present in the generated pdf file.

I'm not sure whether I did anything wrong in the example or not. I 
checked many time

and didn't find anything.


Works OK for me but I found a few you could/should change.

1. Don't use project files as top level file for your document, use 
product and
   components (which can be nested) files only, projects are meta file 
when you

   have many document with the same topic (e.g. a magazine etc.)



A magazine is really one of my purposes. :)


2. You can write \usepath[kaka,leasure] in your environment files and write
   in test.tex

 \component leasure
 \component kaka

   ConTeXt looks now in both directories for the files leasure.tex and 
kaka.tex

   but take care to use unique filenames.



After adding \usepath[kaka,leasure], the texts in \component present, but, as 
the
caution you mentioned, since I have two files with the same name, i.e. 
mytime.tex,
only the file in kaka/ is added and is added twice. Although \usepath can partly
solve my problem, it limits flexibility.


Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] beta

2009-04-29 Thread Wei-Wei Guo

Yanrui Li 写道:

Hi,


The numbering of footnotes are abnormal. Simple example:

\starttext
\chapter{T}
This is a test\footnote{t}.

\chapter{E}
This is a test\footnote{e}.

\chapter{S}
This is a test\footnote{s}.

\chapter{T}
This is a test\footnote{t}.
\stoptext

The numbering of four footnotes is 1.1, 2.2, 3.3, 4.4 respectively.



I got the problem too.

$ context --version
MTXrun | current version: 2009.04.29 20:23


Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] beta

2009-04-28 Thread Wei-Wei Guo

Hans Hagen 写道:


I uploaded a beta just before leaving for bachotek. Quite some structure 
(lua) code has been overhauled and i need to finish some bits.




Have fun!



As I'm redoing the backend as well as cross referencing some interaction 
features might be broken but normally they are easy to fix (once i know 
what fails). So, best collect all bugs while i'm away so that i can deal 
with then at once.




I got an error here.

! Argument of \dotripletestemptyx has an extra }.
inserted text
\par
to be read again
   }
\doif #1#2-\edef \!!stringa {#1}
 \edef \!!stringb {#2}\ifx \!!stringa 
\!!str...
\dostructurecountercomponent ...\c!title }\v!none
  {\setfalse 
\hasstructureco...
\docompletefloat ...c!title ={#4},\c!bookmark =][]
  \globallet 
\currentfloatnu...
argument ...\footnote {Test footnote.}}\nextbox
  \else \docompletefloat 
{ta...
...
l.13 {\placelocalfootnotes}

Minimal example:

\starttext

\startlocalfootnotes
\placetable{Test table\footnote{Test footnote.}}
\placelegend{
\starttable[|l|l|]
  \HL
  \NC East \NC North \NC \FR
  \NC West \NC South \NC  \LR
  \HL
\stoptable}
{\placelocalfootnotes}
\stoplocalfootnotes

\stoptext


2. And another thing I have mentioned before. I just want to arise your 
attention.

The underlines set by textbackground are not stable. Their vertical positions 
are
not predictable.

Minimal example:

\startuseMPgraphic{mpos:par:columnset:textuline}
  \iftracepositions show_multi_pars \else draw_multi_pars \fi ;
  path p ; p := boundingbox currentpicture ;
  currentpicture := currentpicture shifted (0,0.1*StrutDepth) ;
  setbounds currentpicture to p ;
\stopuseMPgraphic

\definetextbackground
  [underline]
  [location=text,
   alternative=1,
   mp=mpos:par:columnset:textuline,
   background=,
   frame=off]

\starttext

\underline{blurblur}

\underline{blurblur}

\underline{blurblur}

\underline{blurblur}

\stoptext


Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] Mplib problem of latest beta on luatex 0.40

2009-04-26 Thread Wei-Wei Guo

Dear developers,

Here is the example and warnings.

Example:

\startuseMPgraphic{mpos:par:columnset:textuline}
  \iftracepositions show_multi_pars \else draw_multi_pars \fi ;
  path p ; p := boundingbox currentpicture ;
  currentpicture := currentpicture shifted (0,-0.3*StrutDepth) ;
  setbounds currentpicture to p ;
\stopuseMPgraphic

\definetextbackground
  [underline]
  [location=text,
   alternative=1,
   mp=mpos:par:columnset:textuline,
   background=,
   frame=off]

\starttext

\underline{blurblur}

\stoptext

The compiled result has no underline and ConTeXt complains during compilation:

mplib   : making 'metafun.mp' into 
'/var/cache/texmf/luatex-cache/context/b51cb04348b3b14d1dfc7333fc9b63f2/formats/cont-en-metafun.mem'
mplib   : problems with 'metafun.mp' from 
'/var/cache/texmf/luatex-cache/context/b51cb04348b3b14d1dfc7333fc9b63f2/formats/cont-en-metafun.mem'




Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Mplib problem of latest beta on luatex 0.40

2009-04-26 Thread Wei-Wei Guo

Longmin Wang 写道:

Hi Longmin,


It works fine here with the latest beta and luatex 0.40. You may try
to delete luatex-cache and regenerate it. 



It solves the problem, thanks.

I find another problem with the example in my previous email. I changed the
example a little bit.

Example:

\startuseMPgraphic{mpos:par:columnset:textuline}
  \iftracepositions show_multi_pars \else draw_multi_pars \fi ;
  path p ; p := boundingbox currentpicture ;
  currentpicture := currentpicture shifted (0,0.3*StrutDepth) ;
  setbounds currentpicture to p ;
\stopuseMPgraphic

\definetextbackground
  [underline]
  [location=text,
   alternative=1,
   mp=mpos:par:columnset:textuline,
   background=,
   frame=off]

\starttext

\underline{blurblur}

\underline{blurblur}

\underline{blurblur}

\underline{blurblur}

\stoptext

The vertical positions of underlines are not stable. See the attached PDF file.


Best wishes,
Wei-Wei


test.pdf
Description: Adobe PDF document
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Font table

2009-04-20 Thread Wei-Wei Guo

Hans Hagen 写道:

Hi,

Here are my results with those two commands:



luatools --show-path tex



!!/etc/texmf/tex/context//:
!!/etc/texmf/tex/plain//:
!!/etc/texmf/tex/generic//:
!!/etc/texmf/tex///:
!!/var/lib/texmf/tex/context//:
!!/var/lib/texmf/tex/plain//:
!!/var/lib/texmf/tex/generic//:
!!/var/lib/texmf/tex///:
!!/usr/share/texmf/tex/context//:
!!/usr/share/texmf/tex/plain//:
!!/usr/share/texmf/tex/generic//:
!!/usr/share/texmf/tex///:
!!/usr/local/share/texmf/tex/context//:
!!/usr/local/share/texmf/tex/plain//:
!!/usr/local/share/texmf/tex/generic//:
!!/usr/local/share/texmf/tex///:
!!/usr/share/texmf-site/tex/context//:
!!/usr/share/texmf-site/tex/plain//:
!!/usr/share/texmf-site/tex/generic//:
!!/usr/share/texmf-site/tex///:
!!/usr/share/texmf-dist/tex/context//:
!!/usr/share/texmf-dist/tex/plain//:
!!/usr/share/texmf-dist/tex/generic//:
!!/usr/share/texmf-dist/tex///


luatools --show-path lua



/usr/lib/ocaml/ocamldoc:
!!/etc/texmf/scripts/luatex//:
!!/etc/texmf/scripts/context//:
!!/etc/texmf/scripts///:
!!/var/lib/texmf/scripts/luatex//:
!!/var/lib/texmf/scripts/context//:
!!/var/lib/texmf/scripts///:
!!/usr/share/texmf/scripts/luatex//:
!!/usr/share/texmf/scripts/context//:
!!/usr/share/texmf/scripts///:
!!/usr/local/share/texmf/scripts/luatex//:
!!/usr/local/share/texmf/scripts/context//:
!!/usr/local/share/texmf/scripts///:
!!/usr/share/texmf-site/scripts/luatex//:
!!/usr/share/texmf-site/scripts/context//:
!!/usr/share/texmf-site/scripts///:
!!/usr/share/texmf-dist/scripts/luatex//:
!!/usr/share/texmf-dist/scripts/context//:
!!/usr/share/texmf-dist/scripts///


Almost all the paths have exclamations before. Is is the reason?


Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Font table

2009-04-20 Thread Wei-Wei Guo

Hans Hagen 写道:

luatools --show-path tex



!!/etc/texmf/tex/context//:
!!/etc/texmf/tex/plain//:
!!/etc/texmf/tex/generic//:
!!/etc/texmf/tex///:
!!/var/lib/texmf/tex/context//:
!!/var/lib/texmf/tex/plain//:
!!/var/lib/texmf/tex/generic//:
!!/var/lib/texmf/tex///:
!!/usr/share/texmf/tex/context//:
!!/usr/share/texmf/tex/plain//:
!!/usr/share/texmf/tex/generic//:
!!/usr/share/texmf/tex///:
!!/usr/local/share/texmf/tex/context//:
!!/usr/local/share/texmf/tex/plain//:
!!/usr/local/share/texmf/tex/generic//:
!!/usr/local/share/texmf/tex///:
!!/usr/share/texmf-site/tex/context//:
!!/usr/share/texmf-site/tex/plain//:
!!/usr/share/texmf-site/tex/generic//:
!!/usr/share/texmf-site/tex///:
!!/usr/share/texmf-dist/tex/context//:
!!/usr/share/texmf-dist/tex/plain//:
!!/usr/share/texmf-dist/tex/generic//:
!!/usr/share/texmf-dist/tex///


luatools --show-path lua



/usr/lib/ocaml/ocamldoc:
!!/etc/texmf/scripts/luatex//:
!!/etc/texmf/scripts/context//:
!!/etc/texmf/scripts///:
!!/var/lib/texmf/scripts/luatex//:
!!/var/lib/texmf/scripts/context//:
!!/var/lib/texmf/scripts///:
!!/usr/share/texmf/scripts/luatex//:
!!/usr/share/texmf/scripts/context//:
!!/usr/share/texmf/scripts///:
!!/usr/local/share/texmf/scripts/luatex//:
!!/usr/local/share/texmf/scripts/context//:
!!/usr/local/share/texmf/scripts///:
!!/usr/share/texmf-site/scripts/luatex//:
!!/usr/share/texmf-site/scripts/context//:
!!/usr/share/texmf-site/scripts///:
!!/usr/share/texmf-dist/scripts/luatex//:
!!/usr/share/texmf-dist/scripts/context//:
!!/usr/share/texmf-dist/scripts///


Almost all the paths have exclamations before. Is is the reason?


(1) what happens if you replace : by ;
(2) also make the /// into //



These : and /// are auto generated, I don't which file I need to change. I look
into texmf.cnf and find there is no /// and :. Paths are seperated by ; in 
texmf.cnf.


Wei-Wei

___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Font table

2009-04-19 Thread Wei-Wei Guo

Eythan Weg 写道:

Hans Hagen pra...@wxs.nl
Sat, 18 Apr 2009 21:21:37 +0200

   Eythan Weg wrote:
   
Hi,
   
I tried this 
   

  mtxrun --verbose --reload --script fonts
   
but it fails with:
   
  MTXrun | using script: 
/usr/local/share/texmf/scripts/context/lua/mtx-fonts.lua
   
  cannot open : No such file or directory
   
I think that this line in mtx-fonts.lua is the culprit:
 dofile(resolvers.find_file(font-syn.lua))
   
although this file:
font-syn.lua
   
exists.
   
Any hints
   
   it should just work ok
   
   did you run luatools --generate to make a file database?


Yes.  And I find no errors in doing so.  I have
no problems using context with the standard fonts
defined otf-type.tex.  

Note that 

   luatools font-syn.lua  


shows nothing.

Eythan 



The same with Eythan here.

Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] How to set \definemakeup without affect other pages?

2009-04-18 Thread Wei-Wei Guo

Wolfgang Schuster 写道:

I use \setupbackgrounds to draw a line under header. It works fine.
When I setup a cover makeup and use it, the lines under headers are gone.

The headerstate=none causes the problem. But I don't want the lines 
under headers

appear in cover. What should I do?


headerstate=high

Wolfgang


Thanks a lot. What does high mean? Do I need to set footerstate to high too?

Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] new beta

2009-04-18 Thread Wei-Wei Guo

Hans Hagen 写道:

Wei-Wei Guo wrote:


   1 Should have a caption title here   Should have dots here  13

   Example:
\starttext

\completelistoftables

\placetable[here][example-table]{\LaTeX}
\starttable[|l|l|]
  \NC longtable  \NC LONG TABLE \NC \AR
  \NC booktabs   \NC BOOKTABS \NC \AR
\stoptable

\stoptext


title now shows up


Works fine here now.



  2. \writebetweenlist has no effect.


   Example:
\starttext

\completecontent
\writebetweenlist[section]{Text}

\section{Section 1}
\input knuth

\stoptext


fixed


Still not work here. The Text isn't shown in contents.



Best wishes,
Wei-Wei

___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] new beta

2009-04-18 Thread Wei-Wei Guo

Hans Hagen 写道:


there was a bug in the flusher (footnotes can have 3 states: insert, 
postpone and save)


however, your example also needs a fix: watch the start-stop local place
as otherwise the note in the caption ends of nowhere

here you have insert's (outer ones), a local one (in the table) and a 
postponed one (in the graphic); the postponed one might end up at the 
wrong place; future mkiv might handle that better but first we need to 
reach a reasonable state of compatibility and then we can start hacking 
around in the page code (inserts are somewhat special in tex)


\starttext

\chapter{First}

Way to \ConTeXt\footnote{It's also the title of Yanrui Li's tutorial.} 
is painful.


\section{First}

Way to \ConTeXt\footnote{It's also the title of Yanrui Li's tutorial.} 
is painful.


\section{Second}

But \ConTeXt is amazing.\footnote{Yanrui Li's tutorial too.}

\placetable
  {Complex Table\footnote{An test table.}}
  {\startlocalfootnotes
   \placelegend
 {\starttable[|l|n3.1 |n3.1 |n3.1 |n3.1 |]
  \HL
  \NC\NC \Use{2}[c]{First Half} \NC \Use{2}[c]{Second 
Half} \NC \FR

  \DC\DL[4] \DR
  \NC\NC 1st Qtr  \NC 2nd Qtr   \NC 3rd Qtr \NC 4th Qtr 
\NC \LR

  \HL
  \NC East \NC   20.4   \NC7.4\footnote{inside.}\NC 90 
 \NC20.4 \NC \FR

  \NC West \NC   30.6   \NC  338.6\NC   34.6  \NC31.6 \NC  \LR
  \HL
  \stoptable}
 {\placelocalfootnotes}
   \stoplocalfootnotes}

flush'm


\stoptext

maybe clean up this example a bit (smaller table) and wikify it



I wikified it, but there is a problem with the generate picture by context:

- The footnote inside the table are not shown right under the table.

And I have a further question. Is it possible to put the footnote of table head
under the table instead of at the bottom of the page? I think it would be more
reasonable of putting the footnote under the table.


Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] How to set \definemakeup without affect other pages?

2009-04-18 Thread Wei-Wei Guo

Wolfgang Schuster 写道:
The headerstate=none causes the problem. But I don't want the lines 
under headers

appear in cover. What should I do?


headerstate=high



I just noticed that headerstate=high had a side effect. The cover should be 
followed
by a blank page. With high, the blank page has header now.


Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] new beta

2009-04-18 Thread Wei-Wei Guo

Hans Hagen 写道:

Wei-Wei Guo wrote:
And I have a further question. Is it possible to put the footnote of 
table head
under the table instead of at the bottom of the page? I think it would 
be more

reasonable of putting the footnote under the table.


in principle yes, but then i need to add something to the float 
mechanism so it's not a quick hack (and it will not happen before i have 
completely spit the code in mkii/mkiv)




Thanks!

BTW, when will you finish the splitting?


Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] How to set \definemakeup without affect other pages?

2009-04-18 Thread Wei-Wei Guo

Hi Wolfgang,

Wolfgang Schuster 写道:


Am 18.04.2009 um 06:21 schrieb Wei-Wei Guo:


Dear all,

I use \setupbackgrounds to draw a line under header. It works fine.
When I setup a cover makeup and use it, the lines under headers are gone.

The headerstate=none causes the problem. But I don't want the lines 
under headers

appear in cover. What should I do?


headerstate=high



Sorry for posting one by one. I just found that \definemakeup could make the 
whole
header disappear.

%===
\setupheadertexts[]
\setupheadertexts[pagenumber][MyHeader][][]

\definemakeup[cover]
  [headerstate=high,
   footerstate=high,
   pagestate=stop,]

\starttext


\startcovermakeup

\midaligned{My Title}

\stopcovermakeup

\input knuth

\inleft{\ConTeXt }Other text\footnote{\LaTeX }.

\stoptext
%=


Am I setting something wrong?


Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] new beta

2009-04-17 Thread Wei-Wei Guo

Hi,

The \completepublications error is gone with newly published t-bib.

I find a new bug. The figure list and table list do not show caption titles and 
dots.
Only label number and page number appear there, such as:

   1.2.1 Should have a caption title here   Should have dots here 13

Dots appears in contents list.


Best wishes,
Wei-Wei



Wei-Wei Guo 写道:

Hi Hans,

Something are not working here with the latest beta on luatex 0.39.

1. The following two settings has no effect.

   % lines under headers.
   \setupbackgrounds
  [header][text]
  [frame=off,bottomframe=on,rulethickness=1.5pt]

   % Text inserted in Contents
   \writebetweenlist[section]{Text}

2. Footnote number has a weird triangle mark beside, like 1▲.

3. \completepublications causes error though text citations are fine. 
Here is the error:


   ! Undefined control sequence.
   \preparebibrefprefix ...lltoclevels \alltoclevels
 \let 
\savedcurrentlevel \c...

   \typesetpubslist ... {}\else \preparebibrefprefix
 \fi \ifsortbycite 
\fillloc...

   \dodoplacepublications ...sttrue \typesetpubslist
 \inpublistfalse 
\endgroup

   to be read again
  \stopappendices
   l.80 \stopappendices


Best wishes,
Wei-Wei


___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] new beta

2009-04-17 Thread Wei-Wei Guo

Hi Hans,

Here is the minimal examples.

1. The figure list and table list do not show caption titles and dots.
   Only label number and page number appear there, such as:

   1 Should have a caption title here   Should have dots here  13

   Example:
\starttext

\completelistoftables

\placetable[here][example-table]{\LaTeX}
\starttable[|l|l|]
  \NC longtable  \NC LONG TABLE \NC \AR
  \NC booktabs   \NC BOOKTABS \NC \AR
\stoptable

\stoptext

2. \writebetweenlist has no effect.

   Example:
\starttext

\completecontent
\writebetweenlist[section]{Text}

\section{Section 1}
\input knuth

\stoptext


3. Footnote number has a weird triangle mark beside, like 1▲.

   Example:
   I cannot reproduce the problem with default settings. Maybe it's
   a problem related with Chinese. What Chinese fonts do you have?
   Can I use Yanrui Li's zhfonts.tex in my examples?


Best Wishes,
Wei-Wei


Hans Hagen 写道:

minimal example needed


___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] new beta

2009-04-17 Thread Wei-Wei Guo

Hi Hans,

Another bug, probably.

4. interlinespace of \setupbodyfontenvironment is not working.

   Example:
\setupbodyfontenvironment[12pt]
   [interlinespace=2.3ex]

\setupbodyfont[rm,12pt]

\starttext
\input knuth
\stoptext


Best wishes,
Wei-Wei


Hans Hagen 写道:

minimal example needed

___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] new beta

2009-04-17 Thread Wei-Wei Guo

Hi,

The reproduction of the footnote problem is tricky. And it seems it's not a 
Chinese
related problem. Here is the example:

%===
\starttext

\chapter{First}

Way to \ConTeXt\footnote{It's also the title of Yanrui Li's tutorial.} is 
painful.

\input knuth

\section{Second}

But \ConTeXt is amazing.\footnote{Yanrui Li's tutorial too.}

\input knuth

\startlocalfootnotes
\placetable{Complex Table\footnote{An test table.}}
\placelegend{
\starttable[|l|n3.1 |n3.1 |n3.1 |n3.1 |]
  \HL
  \NC\NC \Use{2}[c]{First Half} \NC \Use{2}[c]{Second Half} \NC \FR
  \DC\DL[4] \DR
  \NC\NC 1st Qtr  \NC 2nd Qtr   \NC 3rd Qtr \NC 4th Qtr \NC \LR
  \HL
  \NC East \NC   20.4   \NC7.4\NC 90  \NC20.4 \NC \FR
  \NC West \NC   30.6   \NC  338.6\NC   34.6  \NC31.6 \NC  \LR
  \HL
\stoptable}
{\placelocalfootnotes}
\stoplocalfootnotes
%=


The problem:
   The second footnote are generated twice. The duplicated footnote appears
   only when \section, \startlocalfootnotes, and other \footnote are there.

I cannot reproduce the 1▲ problem I have said before. It more tricky.


Best wishes,
Wei-Wei


Yanrui Li 写道:

3. Footnote number has a weird triangle mark beside, like 1▲.

  Example:
  I cannot reproduce the problem with default settings. Maybe it's
  a problem related with Chinese. What Chinese fonts do you have?
  Can I use Yanrui Li's zhfonts.tex in my examples?




Hi, Wei-Wei,
the third one can also work.
You can post your example with zhfonts.tex which use
Adobe Song and Kai fonts. I think that Hans have these fonts.


___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] How to set \definemakeup without affect other pages?

2009-04-17 Thread Wei-Wei Guo

Dear all,

I use \setupbackgrounds to draw a line under header. It works fine.
When I setup a cover makeup and use it, the lines under headers are gone.

The headerstate=none causes the problem. But I don't want the lines under 
headers
appear in cover. What should I do?

Here is an example.

%==
\setupbackgrounds
   [header][text]
   [frame=off,bottomframe=on,rulethickness=1.5pt]

\definemakeup[cover]
  [headerstate=none,
   footerstate=none,
   pagestate=stop,
   doublesided=yes]

\starttext

\startcovermakeup
\input knuth
\stopcovermakeup

\input knuth

\stoptext
%==


Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] How to set a layout shown in the attachment png file?

2009-04-16 Thread Wei-Wei Guo

Hi Ales,

Alex Lubberts 写道:

I attached a PNG file to show the layout that I want. I want the text part
narrowed and
right aligned. I tried the following settings:

\setuplayout
   [backspace=20mm,
topspace=20mm,
height=257mm,
width=170mm,
%textwidth=115mm,
header=10mm,
footer=0mm,
rightmargin=0mm,
leftmargin=25mm,
leftmargindistance=-25mm,]

The problem is that text is too wide. I commented the 'textwidth' for it
will make the
narrowed text centering. What else do I need to set?


From the picture the exact measures are not clear, but perhaps you should


The picture only shows relative position of header, text, and margin.



try:
  ...
  width=115mm,
  ...
  leftmargindistance=25mm]
'width' is used to set the textwidth. And 'leftmargindistance'is used to
indicate the distance between the lefmargin column and the body text, so I
think it should be a positive amount. This setting will result in an empty
backspace of 20mm + margin of 25mm + 25mm whitespace + 115mm bodytext +
cutspace of 25mm cutspace (assuming you're using A4 papersize).


I tried. It doesn't work. As my understanding, margin and margindistance do not
affect layout. They only decide where margins are.


Best wishes,
Wei-Wei

___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] new beta

2009-04-16 Thread Wei-Wei Guo

Hi Hans,

Something are not working here with the latest beta on luatex 0.39.

1. The following two settings has no effect.

   % lines under headers.
   \setupbackgrounds
  [header][text]
  [frame=off,bottomframe=on,rulethickness=1.5pt]

   % Text inserted in Contents
   \writebetweenlist[section]{Text}

2. Footnote number has a weird triangle mark beside, like 1▲.

3. \completepublications causes error though text citations are fine. Here is 
the error:

   ! Undefined control sequence.
   \preparebibrefprefix ...lltoclevels \alltoclevels
 \let \savedcurrentlevel 
\c...
   \typesetpubslist ... {}\else \preparebibrefprefix
 \fi \ifsortbycite 
\fillloc...
   \dodoplacepublications ...sttrue \typesetpubslist
 \inpublistfalse \endgroup
   to be read again
  \stopappendices
   l.80 \stopappendices


Best wishes,
Wei-Wei


Hans Hagen 写道:

Hi,

I uploaded a beta matching luatex 0.39 (+ some fixes)

Hans


___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] How to set a layout shown in the attachment png file?

2009-04-15 Thread Wei-Wei Guo

Dear all,

I attached a PNG file to show the layout that I want. I want the text part 
narrowed and
right aligned. I tried the following settings:

\setuplayout
  [backspace=20mm,
   topspace=20mm,
   height=257mm,
   width=170mm,
   %textwidth=115mm,
   header=10mm,
   footer=0mm,
   rightmargin=0mm,
   leftmargin=25mm,
   leftmargindistance=-25mm,]

The problem is that text is too wide. I commented the 'textwidth' for it will 
make the
narrowed text centering. What else do I need to set?


Best wishes,
Wei-Wei
inline: mylayout.png___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] TeXLive 2008 + ConTeXt problems (on Gentoo Linux)

2009-04-14 Thread Wei-Wei Guo

Hi Matija,

You need to set TEXMFCNF, TEXMFCACHE, and OSFONTDIR in your system environment,
for example in /etc/env.d/98texlive.


Best wishes,
Wei-Wei


Matija Šuklje 写道:

Hullo,

it's been a while since I used ConTeXt (I simply didn't have to write any 
documents), but now that I upgraded to TeXLive 2008 I noticed that ConTeXt is 
giving me gripes.


'context test.tex' produces:
MtxRun | error unable to identify cnf file
MtxRun | error unable to identify cnf file
MtxRun | no cnf files found (TEXMFCNF may not be set/known)
MtxRun | unknown script: context

'texexec test.tex' actually produces a PDF.

'luatex test.tex' starts asking questions:
This is LuaTeX, Version snapshot-0.30.3-2009041418 (Web2C 7.5.7)
(test.tex
! Undefined control sequence.
l.1 \starttext

?

...and later on produces a completely messed up PDF


'luatools --generate' produces:
LuaTools | error unable to identify cnf file
LuaTools | error unable to identify cnf file
LuaTools | no cnf files found (TEXMFCNF may not be set/known)
LuaTools |
LuaTools | runtime: 0.046 seconds


I'm sure there's a step I missed in the upgrade, but I have no idea what. I've 
already tried a few things from the Wiki, which I think resulted in 'texexec' 
actually working, but the rest is still foo.


Does anyone have any idea what I'm doing wrong?


Cheers,
Matija Šuklje




___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] TeXLive 2008 + ConTeXt problems (on Gentoo Linux)

2009-04-14 Thread Wei-Wei Guo

Hi,

- TEXMFCNF value should be /etc/texmf/web2c.
- TEXMFCACHE value is the directory chosen by yourself.
- OSFONTDIR value should be the paths of your system fonts.

Best wishes,
Wei-Wei

Matija Šuklje 写道:

Dne sreda 15. aprila 2009 je Wei-Wei Guo napisal(a):

You need to set TEXMFCNF, TEXMFCACHE, and OSFONTDIR in your system
environment, for example in /etc/env.d/98texlive.


Thanks. :)

E.g. what are appropriate values for these variables? I'll try to change them 
to my system's right paths, but I'd be grateful for some pointers where to 
start searching.



Cheers,
Matija

___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] new structure code

2009-04-13 Thread Wei-Wei Guo

Hi Wolfgang,

I just notice that you said adding my error with new beta in this thread, so I
post it here again.

Problem with footertexts.

  ! Undefined control sequence.
  argument \@@plaatspaginanummer

  \firstoftwoarguments #1#2-#1

  \doattributes ...sname #1...@ea \endcsname \fi {#4
}\dostopattributes
  \dosingletexts ...atetexts {#1#2#5}{#6{}{}{}}}
\egroup
  argument ...?tk \v!footer \v!text \c!righttext }
\@@nmpos {\getvalue 
{\??tk...
  \dododoplacelayouttextline ...#2 #3}\hbox to #1{#4
}\stoplayoutcomponent 
\get...
  ...
  l.71 \stopbodymatter


The minimal example:

  \setupfootertexts[][pagenumber][pagenumber][]

  \starttext
  \input knuth
  \stoptext


Best wishes,
Wei-Wei



Wolfgang Schuster 写道:


Am 11.04.2009 um 01:29 schrieb Hans Hagen:


Wolfgang Schuster wrote:


I add it to my list, mkii and mkiv behave in the reverse way.


thanks for collecting the issues, i prefer looking at them at once 
(next week) so if you make a summary / test file ...


I can send you the files at the end of next week, I wait till more users 
can test the beta.


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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] new beta

2009-04-11 Thread Wei-Wei Guo

Hi Wolfgang,

Here is the minimal example,

   \setupfootertexts[][pagenumber][pagenumber][]

   \starttext
   \input knuth
   \stoptext

Just as you said, it's a problem with footertexts.

Wei-Wei


Wolfgang Schuster 写道:

I get an error:

 ! Undefined control sequence.
 argument \@@plaatspaginanummer

 \firstoftwoarguments #1#2-#1

 \doattributes ...sname #1...@ea \endcsname \fi {#4
   }\dostopattributes
 \dosingletexts ...atetexts {#1#2#5}{#6{}{}{}}}
   \egroup
 argument ...?tk \v!footer \v!text \c!righttext }
   \@@nmpos {\getvalue 
{\??tk...

 \dododoplacelayouttextline ...#2 #3}\hbox to #1{#4
   
}\stoplayoutcomponent \get...

 ...
 l.71 \stopbodymatter


Can you track it down and make a minimal example which can be added to 
my other thread,

it looks like a problem with footertexts.

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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] new beta

2009-04-10 Thread Wei-Wei Guo

Hi Hans,

I get an error:

  ! Undefined control sequence.
  argument \@@plaatspaginanummer

  \firstoftwoarguments #1#2-#1

  \doattributes ...sname #1...@ea \endcsname \fi {#4
}\dostopattributes
  \dosingletexts ...atetexts {#1#2#5}{#6{}{}{}}}
\egroup
  argument ...?tk \v!footer \v!text \c!righttext }
\@@nmpos {\getvalue 
{\??tk...
  \dododoplacelayouttextline ...#2 #3}\hbox to #1{#4
}\stoplayoutcomponent 
\get...
  ...
  l.71 \stopbodymatter


And indentation doesn't work here.


Best wishes,
Wei-Wei



Hans Hagen 写道:

Hi,

I uploaded a new beta, one that needs luatex beta 0.38, which has just 
been released. The most important things:


- some fixes in the new structure code
- bookmarks are now supported in the new structure
- otf math kerning is supported (neat)
- some cleanup of lua code
- the usual bug fixes

as said ... you need luatex 0.38

there will be a current when luatex 0.40 is available

___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] How to use MPgraphic with options?

2009-04-09 Thread Wei-Wei Guo

Thanks!

Best wishes,
Wei-Wei

Mikael Persson 写道:

I think this is one way:

\startuseMPgraphic{ARule}
 draw origin -- (\MPvar{mylength},0) ;
\stopuseMPgraphic

\def\ARule#1{%
\setupMPvariables[ARule][mylength=#1]
\useMPgraphic{ARule}
}

\starttext
Foo \ARule{5mm} bar \ARule{10mm}
\stoptext

Best regards, Mikael



___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] How to get the number of lines of a paragraph?

2009-04-08 Thread Wei-Wei Guo

Hi Wolfgang,

I tried many ways, but could not make the following effect:

  Title Head: Here is text, blur blur blur blur blur blur
  ---
  blur blur blur blur
  ---

I tried \starttabulate, \starttable, \setupTABLE, and \definedescription
with \underline{} and \startunderline.

- Tabulate will get error.
- Table do not show underline.
- Natural table displays the underline with only half length as the text
  line's. And the vertical positions are also not right.
- Description seems more promising, but the head will be about one line
  height higher than the text with underline (I use location=left).

Could you help me with it?


Wei-Wei


Wolfgang Schuster 写道:


Am 06.04.2009 um 17:17 schrieb Wei-Wei Guo:


Dear all,

I need to draw underlines under a paragraph. The number of underlines is
determined by the number of lines of the paragraph. For example:


\definetextbackground
  [underline]
  [location=text,
   alternative=1,
   background=,
   frame=off]

\starttext

\startunderline
\input knuth
\stopunderline

\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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] How to get the number of lines of a paragraph?

2009-04-08 Thread Wei-Wei Guo

Thanks! The p solves my problem.

Wei-Wei


Wolfgang Schuster 写道:

You can need a p column in table/tabulate.

The wrong position of the line is a bug, make a bug report and use Li 
Yanruis

fix for the moment.

\definetextbackground
  [underline]
  [location=paragraph,
   alternative=1,
   background=,
   frame=off]

\starttext

\starttabulate
\NC Title Head \EQ \underline{Here is text, \dorecurse{20}{blur }} \NC\NR
\stoptabulate

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


[NTG-context] How to use MPgraphic with options?

2009-04-08 Thread Wei-Wei Guo

Dear all,

I need to use many rules with different lengths. Is there any way to implement
function like below:

  \startuniqueMPgraphic{ARule}{length}
  draw origin -- (\MPvar{length},0) ;
  \stopuniqueMPgraphic

  \uniqueMPgraphic[length=5mm]{ARule}

The example cannot be run. I only use it to explain what I want.

Any suggestion is appreciated.

Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] How to get the number of lines of a paragraph?

2009-04-06 Thread Wei-Wei Guo

Dear all,

I need to draw underlines under a paragraph. The number of underlines is
determined by the number of lines of the paragraph. For example:

If the paragraph have one line:

  text of paragraph, blur blur.
  --

If the paragraph have two lines:

  text of paragraph, blur blur blur blur blur blur blur blur
  --
  blur blur blur blur blur blur blur blur.
  --


Another question: How can I set the header of the pages of contents?

Thanks!

Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] How to get the number of lines of a paragraph?

2009-04-06 Thread Wei-Wei Guo

Wolfgang Schuster 写道:


Am 06.04.2009 um 17:17 schrieb Wei-Wei Guo:


Dear all,

I need to draw underlines under a paragraph. The number of underlines is
determined by the number of lines of the paragraph. For example:


\definetextbackground
  [underline]
  [location=text,
   alternative=1,
   background=,
   frame=off]

\starttext

\startunderline
\input knuth
\stopunderline

\stoptext



It is not what I want. First, the underline is too close to the text. I need
to be able to manipulate the distance between the underline and the text.
Second, the underline of the last line has the same length with the last
line of the text. The underlines should be all the same length.



Another question: How can I set the header of the pages of contents?


\setupheadtext[language][content=...]

or

\title{...}
\placecontent



I don't mean the head of contents. I mean the header of the page, which is
the opposite concept to footer. It seems the head of the contents is not
treated as chapter. I tried \getmarking, but it doesn't work.


Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] How to get the number of lines of a paragraph?

2009-04-06 Thread Wei-Wei Guo

It works, thanks!

Can \startunderline be put into a table or a tabulate? I want to implement
thing like this:

  \startbuffer[chinesetitle]
\startunderline
基于成本的钉耙强度与应用——东方视角分析
\stopunderline
  \stopbuffer

  \startbuffer[englishtitle]
\startunderline
Cost Based Rake Strength and Application: An Oriental View
\stopunderline
  \stopbuffer

  \starttabulate[|l|l|]
  \NC 中文论文题目: \NC \getbuffer[chinesetitle] \NC \NR
  \NC 英文论文题目: \NC \getbuffer[englishtitle] \NC \NR
  \stoptabulate

Of cause, the codes do not work. Is there any alternative way?


Best wishes,
Wei-Wei




Yanrui Li 写道:

2009/4/7 Yanrui Li liyanrui...@gmail.com:

Hi,

May be this can help you.


\startuseMPgraphic{mpos:par:columnset} % Shift underlining down a touch
  \iftracepositions show_multi_pars \else draw_multi_pars \fi ;
  path p ; p := boundingbox currentpicture ;
  currentpicture := currentpicture shifted (0,-1.2*StrutDepth) ;
  setbounds currentpicture to p ;
\stopuseMPgraphic

\definetextbackground[underline]
 [location=paragraph,alternative=1,background=,frame=off]

\definestartstop
 [underline]
 [before={\starttextbackground[underline]},
  after=\stoptextbackground]

\starttext

\startunderline
\input knuth
\stopunderline

\stoptext




You can control the distances by setting up the params of
currentpicture shifted and linespace.


___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Affiliation change

2009-04-02 Thread Wei-Wei Guo

Although the fool's day passed, I still had been gotten by you. It's so
good that those horrible things are not true.

Good job!
Wei-Wei


Taco Hoekwater 写道:

Hi,

As Arthur emailed me already: you people are just too gullible ! :)

Taco Hoekwater wrote:

Hello everybody,

This message is to inform you all that as of today, I am no longer an
employee of Elvenkind BV, the company where I have worked for during
the past years.


This part is true, I am in fact an independant contractor now. Life is
just more fun that way, there is no other reason.


Working for Elvenkind has been a pleasure, but it has always been
hard for Elvenkind to find enough commercial projects to employ me in.


false


Even the recent (much appreciated!) funded TeX-development projects
simply do not generate enough revenue for Elvenkind to make it viable
to keep me as an employee in the current economic climate.


false (Elvenkind is doing better than ever, if anything)



This is not the best time to be out of a job, but nevertheless I have
decided to try to make the most of it an attempt to make an old dream
happen: being my own boss.


true


Since quite some time already I have had a private company called
Bittext that I use for various bits and pieces that simply did not fit
in with Elvenkind's company strategy (its original intent was to place 
my font development work in that company, but it has also been used as

the company behind organizing the ConTeXt Epen meeting in 2007, for
example).


true


For the development of luatex and metapost, I do not expect that much
to change compared to the current situation: Hans and I will continue
to write funding proposals and we hope that enough of those will be
granted so that I can keep that development work going much like it is.
(about a 50% commitment working on these two programs in an average
working week).


true


However, for ConTeXT and other TeX-related things, the situation is a
bit more problematic. 


false


   Pragma ADE does not have money to fund any
projects, even if I managed to find something to excite Hans that
he couldn't do faster himself ;). 


true


  To find the missing source of
income, I intend to start giving commercial ConTeXt courses and


false

I plan to start selling manuals via lulu. 


false


  Perhaps there is a bit of
consultancy that can be found as well, 


false


  and I will try to regain some
of my old mathematical typesetting clients.


false


But I fear that even all of that together will generate enough income
for me to continue developing modules and offering help for free. 


false


Therefore, the planned bib module replacement will be released as
commercial software, 


false


  and support for other ConTeXT stuff (like the
current bib module) will become a paid service. 


false


Probably via a
subscription website, that will (for example) also host my release
notes. 


false


   I am brooding on other ConTeXt module ideas that people
may be willing to pay for, 


false


   and I will finish the font projects
that are still on my disk for sale via my website.


maybe


This April (until around BachoTeX) I will still be busy preparing the
luatex and metapost binaries for the TeXlive 2009 deadline, but after


true

that I will likely drop offline for a while, 


false

  creating the Bittext 
website ( http://www.bittext.com ) 


true-ish, that really does need to be done.


   and figuring out things like how to
be on the receiving end of Lulu and PayPal.


false

Well, that is about all I wanted to say right now. I am quite 
apprehensive about how this news will fall in the ConTeXT community, but
I see no other way. 


false


And I must admit that at the same time I am quite
excited about being in control of my own destiny, as they say!


true

Best wishes,
Taco

___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


___
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  : https://foundry.supelec.fr/projects/contextrev/

Re: [NTG-context] Is there anything like developer's manual for ConTeXt?

2009-03-17 Thread Wei-Wei Guo


Yes, there are may fruitful pages in ConTeXt wiki. But all wiki resources have
the same problem: If you know what you are looking for, it's helpful. If not,
it would be a time hole. And I was told that MkIV progresses so fast that many
things in the current manuals are out of date. I don't know which manual I
should stick with. To make thing worse, there are so many places containing
ConTeXt tutorials and manuals(see the following list).

- wiki.contextgarden.net
- http://foundry.supelec.fr/projects/contextman/
- http://context.aanhet.net/svn/contextman/
- http://www.pragma-ade.com/dir?path=

Those materials are scattered, overlapped and not complete. It makes new
users, like me, don't know what to read. If all those materials are put in
only one place and companying with two and only two complete manuals, one for
developer and one for user, it would be time saving for both users and
developers. Then the next time when I meet command like '\??pb', I could look
for it in manuals first, then wiki probably, then mail list. If I don't find
answer in those three places, I would know the command is not documented then
I could ask in the mail list without hesitating and worrying about wasting
other people's time.


To Taco: My emails don't mean any offense to you. You give me lots of help.
 I really appreciate it.

To Alan: Thanks, your proverbs are very inspiriting.

To Xan and Corin: Thanks for your understanding.


Best wishes,
Wei-Wei



Corin Royal Drummond 写道:
In terms of process, I think someone to comb the list archives for 
common problems and solutions, and wikify them would get the most bang 
for the buck initially.  These wiki entries could later be ConTeXtified 
into printed (and screen) docs, like Hans' awesome old manuals.
Honestly, we've got smart people wasting time answering the same 
questions in different ways on the list, when they could be plugging in 
some of that time into writing docs for everyone.  And as useful as the 
list is, it's no substitute for manuals.

___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] Problem of transfering bib to bbl in Chinese.

2009-03-16 Thread Wei-Wei Guo

Hi everyone,

I asked the question days ago. I find something new, so I submit it here and 
hope
it can provide some useful information and, hopefully, can solve the problem.

t-bib can transfer the following bib entry correct.

   @ARTICLE{c-article-full,
  author = {??},
  title = {},
  journal = {??},
  year = 1986,
  volume = 41,
  number = 7,
  pages = 73--82,
  month = jul,
  language = chinese
   }

but the following bib entry will be rubbish.

   @ARTICLE{c-article-full,
  author = {?? and ??},
  title = {},
  journal = {??},
  year = 1986,
  volume = 41,
  number = 7,
  pages = 73--82,
  month = jul,
  language = chinese
   }

The difference is that there are multiple authors separated by 'and' in the 
second
bib entry. Is it solvable?


Best wishes,
Wei-Wei



___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Problem of transfering bib to bbl in Chinese.

2009-03-16 Thread Wei-Wei Guo

Thanks for answering.

Taco Hoekwater :


Wei-Wei Guo wrote:

but the following bib entry will be rubbish.

   @ARTICLE{c-article-full,
  author = {?? and ??},


You can try

author = {{??} and {??}},

but internationalization support in bibtex is almost
nonexisting, so don't be too surprised if it fails.



It doesn't work. I checked the .bbl file generated by LaTeX from the
same .bib file. There is no rubbish. Why can LaTeX do the thing right
with the same bibtex? (I use TeXLive 2008 companying with rsynced
ConTeXt of current branch, in which the t-bib is replaced by the
newest version.)


Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Problem of transfering bib to bbl in Chinese.

2009-03-16 Thread Wei-Wei Guo

Taco Hoekwater 写道:


You can't turn the bib module's 's' handling off in a nice way, sorry.
You have to either hack the cont-XX.bst files by deleting the line
that says

clabel write$



It's great to have the problem solved. Thank you very much!

I meet another two problems.

1. I'm using the solution that you give me in 'runme.tex'. I find when I need
   to write a citation such as (Hoekwater et al 2009; 小郭 等 2009), I will be
   in an awkward situation. With the solution, I cannot have both English
   citation and Chinese citation in one \cite. Although it not a serious
   problem, it would be better if it could be done.

2. The pubsep can be set in \setupcite, but it doesn't affect the separation
   between compressed citations. For example, I set 'pubsep={;}' and I still
   get (Hoekwater 2008, 2009). How to change the comma between 2008 and 2009?


Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] Is there anything like developer's manual for ConTeXt?

2009-03-16 Thread Wei-Wei Guo

Hi everyone,

After fighting with ConTeXt one month, I find it's too difficult. I have two 
years
experience of LaTeX. I never thought ConTeXt could be so difficult. Using 
ConTeXt
is like climbing a steep mountain, every step need extensive searching, reading,
and asking.

Sorry for the useless complain. I'm stuck by so many problems. I might be lack 
of
the basic knowledge of ConTeXt. Could someone tell me where I can find manuals 
or
papers that describe the logic of ConTeXt design and basics of ConTeXt 
programming.

Thanks in advance.

Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] What does \c! means?

2009-03-15 Thread Wei-Wei Guo

Hi Taco,

I just finished reading the 'System_Macros'. I still don't get the meaning
of '\??pb @lang@' in the following codes:

  \def\lang#1%
   {\def\biblanguage{#1}%
\ifcsname \??pb @l...@#1\endcsname
\expanded{\mainlanguage[\getvalue{\??pb @l...@#1}]}%
\expanded{\language[\getvalue{\??pb @l...@#1}]}%
 \fi \ignorespaces}

In \lang[zh], for example, '\??pb @lang@' will be expanded to \@@pblangen,
will it? Is \??pb a command? Is '\??pb @lang@' a command? Why can there be
a whitespace in '\??pb @lang@'?

Sorry for some many questions. I'm so confused and don't know what to
search in wiki, manuals, etc..


Best wishes,
Wei-Wei

Taco Hoekwater 写道:

Also generally helpful for a low-level understanding of context are
these wiki pages:

  http://wiki.contextgarden.net/System_Macros

___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] What does \c! means?

2009-03-15 Thread Wei-Wei Guo

Thanks, Wolfgang and Hans.


Best wishes,
Wei-Wei


Hans Hagen 写道:


this is not stuff most users want to know or see; add a few 
\expandafter's, \futurelet's and \afterassignments and one wonders in 
what universe one has ended up


Hans


___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] What does \c! means?

2009-03-14 Thread Wei-Wei Guo

Thank you, Taco and Alan.


Best wishes,
Wei-Wei

Taco Hoekwater 写道:

Alan Stone wrote:

On Sat, Mar 14, 2009 at 5:32 AM, Wei-Wei Guo wwgu...@gmail.com wrote:


Dear all,

I'm reading the source file of t-bib. I find there are lots of '\c!',
'\s!', and
'\v!'. What do they mean? I searched in wiki, TeXBook, ConTeXt 
manual, TeX

impatient,
and mail list. Those commands appear some times, but no explanation.



http://archive.contextgarden.net/message/20080629.104105.40e28a70.el.html


Also generally helpful for a low-level understanding of context are
these wiki pages:

  http://wiki.contextgarden.net/System_Macros



___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] How to use my own BibTeX style (bst)?

2009-03-13 Thread Wei-Wei Guo

Taco Hoekwater 写道:


In mkiv (and xetex also, I assume), that just works, assuming you have a
working typescript for the combination of scripts. Example attached (the
example uses AdobeMingStd-Light)



You might misunderstand. I was providing an example to you in my previous email,
not asking you to give me an example file. But it is fine since I can describe
my problem clear based on the PDF file generated from 'runme.tex'.

Here is what I want:

  English Bibliogrphy (Aamport, et al.,1986).
  中文文献(姓名一, 等, 1986)。

  Aamport, L. A., Aamport, L. A., Aamport, L. A. and Aamport, L. A. (1986).
 The gnats and gnus document preparation system. G-Animal's Journal, 41(7),
 73-83. This is a full ARTICLE entry.
  姓名一, 姓名二, 姓名三 和 姓名四(1986).一篇文章的名字.一本杂志的名字, 41(7),
 73-82. This is a full ARTICLE entry.


Here is what 'runme.tex' provides:

  English Bibliogrphy (Aamport, et al.,1986).
  中文文献(姓名一, etal, 1986)。

  Aamport, L. A., Aamport, L. A., Aamport, L. A. and Aamport, L. A. (1986).
 The gnats and gnus document preparation system. G-Animal's Journal, 41(7),
 73-83. This is a full ARTICLE entry.
  姓名一,姓名二,姓名三and姓名四(1986).一篇文章的名字.一本杂志的名字, 41(7),
 73-82. This is a full ARTICLE entry.


Compare those two results:

- Chinese citation uses '等' instead of 'et al'.
- Chinese bibliography uses '和' instead of 'and'.

Of course, the comparison is not complete.

My question: Since I can write 'bibl-my-en.tex' for English entries and
'bibl-my-zh.tex' for Chinese entries, can I use both of them when I have both
English and Chinese citations in one paper? If not, could you give some advises
about how to implement it?

Hope I made it clear this time.


Best wishes,
Wei-Wei


___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] How to use my own BibTeX style (bst)?

2009-03-13 Thread Wei-Wei Guo

Thank you very much!

Best wishes,
Wei-Wei


Taco Hoekwater 写道:

The long answer: although you cannot make it depend on the language
of the citation, you can make it change depending on an explicit
language switch. This takes a bit of work, but it is better than
nothing, I guess.

Here is how:

* first, edit the bibl-my file so that it contains calls to
  \labeltext{} instead of literal tests, for example:

   \setupcite
   [authoryears]
   [andtext={ \labeltext{and} },
otherstext={ \labeltext{etal}},
 % many more are needed, of course

  you can invent wnatever you like in the argument of \labeltext,
  because you will define them in the next step.

* second, define all the label texts you used in the previous
  step for the all languages you need.  Short example:

  \setuplabeltext[en][etal={et al.}, and={and}]
  \setuplabeltext[cn][etal={等},and={和}]

* third, you now need to do a \mainlanguage switch before every \cite
  that does not use the main language of your paper. So assuming
  your paper is uses \mainlanguage[cn], then you need to create
  a definition like this for the english citations:

\def\encite[#1]{{\mainlanguage[en]\cite[#1]}}

  and you have to use \encite[article=full] in your paper.

that takes care of the citations in the running text of your paper.
For the publication list:

* first, you have to redefine one of the t-bib macros.
  The new definition of \lang (to be put in your setup) should become

  \unprotect
  \def\lang#1%
   {\def\biblanguage{#1}%
\ifcsname \??pb @l...@#1\endcsname
\expanded{\mainlanguage[\getvalue{\??pb @l...@#1}]}%
\expanded{\language[\getvalue{\??pb @l...@#1}]}%
 \fi \ignorespaces}
   \protect

* two, you have to a language field to each bibtex data item.


* three, you need a \setbiblanguage command for every language name
  that appears in your bib file. This will connect \lang arguments
  to context language keys.

  For example:

\setbiblanguage{chinese}{cn}
\setbiblanguage{english}{en}

  you may need a few of those, depending on how consistent your
  bibtex data is.


After all of that, it will probably work, in most cases. Incidentally,
one of the reasons why the bib modules doesn't do this is because all
of that mucking about with \mainlanguage not very nice. Another is that
a simple string replacement is usually not sufficient to have proper
localization. A third reason is that many publishers want to have
citation data in the language of the paper, regardless of the
language of the cited publications.

For completeness' I have attached my example again, with all these
points applied.

Best wishes,
Taco

___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] What does \c! means?

2009-03-13 Thread Wei-Wei Guo

Dear all,

I'm reading the source file of t-bib. I find there are lots of '\c!', '\s!', and
'\v!'. What do they mean? I searched in wiki, TeXBook, ConTeXt manual, TeX 
impatient,
and mail list. Those commands appear some times, but no explanation.

Another question is related the following codes from Taco (thank you, Taco). 
There
are tokens like '\??pb @l...@`. What does it mean? Could you tell me, to get 
deep
understanding, what to read or which part to read in TeXBook or some other 
manuals.
I don't know what to search to find related topics.


  \unprotect
  \def\lang#1%
   {\def\biblanguage{#1}%
\ifcsname \??pb @l...@#1\endcsname
\expanded{\mainlanguage[\getvalue{\??pb @l...@#1}]}%
\expanded{\language[\getvalue{\??pb @l...@#1}]}%
 \fi \ignorespaces}
   \protect



Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] How to use my own BibTeX style (bst)?

2009-03-12 Thread Wei-Wei Guo

Thank you, Mojca and Taco. I finally get my t-bib working. Now I can
continue working on my bibl style.

Taco Hoekwater 写道:

I don't know those styles get adapted automatically when language is
changed. Taco should answer (I should take a closer look, but no time
now).


They do not. You have to give a setup command like

  \setuppublications[alternative=my-zh] % for bibl-my-zh.tex


I'm not sure if you can use different style for different books based
on language the book was written in (maybe possible, but tedious, the
style would have to be rewritten completely).


With a suitable \setuppublicationlayout this should be possible:
you can decide based on the value of the current language, which is
set from the bibtex language field automatically. But I have never
actually tried to do this, so I have no example code available for you.



I'm still confused. Is it possible to use different bibl based on the value
of \lang. Or I can only implement it with bunch of \if in *one* bibl file?

Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] How to use my own BibTeX style (bst)?

2009-03-12 Thread Wei-Wei Guo

Taco Hoekwater 写道:

Wei-Wei Guo wrote:




I'm still confused. Is it possible to use different bibl based on the 
value
of \lang. 


I am not sure what \lang is now, but you cannot get a different bibl
file based on the current \language or \mainlanguage in the document.



The \lang that I said is the entry field in \startpublications. It is listed
in the t-bib manual.


I was talking about influencing one (or more) of the entries in the
bibliography list based on the language of that actual entry. With
quite some trickery, that could be made to work (but not easy either).



Maybe it is better to provide a simple example. For example, I have try.bbl
as following.


  \startpublication[k=article-full,t=article,
  a={{Aamport},{}},y=1986,
  n=1,s=86]
  \artauthor[]{Leslie~A.}[L.~A.]{}{Aamport}
  \artauthor[]{Leslie~A.}[L.~A.]{}{Aamport}
  \artauthor[]{Leslie~A.}[L.~A.]{}{Aamport}
  \artauthor[]{Leslie~A.}[L.~A.]{}{Aamport}
  \pubyear{1986}
  \arttitle{The gnats and gnus document preparation system}
  \journal{\mbox{G-Animal's} Journal}
  \volume{41}
  \issue{7}
  \pages{73--83}
  \month{7}
  \note{This is a full ARTICLE entry}
  \stoppublication

  \startpublication[k=c-article-full,t=article,
  a={{姓名一},{}},y=1986,
  n=2,s=86]
  \lang{chinese}
  \artauthor[]{}[]{}{姓名一}
  \artauthor[]{}[]{}{姓名二}
  \artauthor[]{}[]{}{姓名三}
  \artauthor[]{}[]{}{姓名四}
  \pubyear{1986}
  \arttitle{一篇文章的名字}
  \journal{一本杂志的名字}
  \volume{41}
  \issue{7}
  \pages{73--82}
  \month{7}
  \note{This is a full ARTICLE entry}
  \stoppublication


And I cite those two entries in my main text.


  English Bibliogrphy \cite[article-full].

  中文文献 \cite[c-article-full]。


I want to get


  English Bibliogrphy (Aamport, et al.,1986).
  中文文献(姓名一, 等, 1986)。


Could you give some clues about how to implement it?

Another question: How to get Hoekwater(2009) instead of (Hoekwater, 2009)?
I mean the equal command of \citet in LaTeX.


Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] t-bib cannot do with Chinese.

2009-03-11 Thread Wei-Wei Guo

Dear all,

My .tex and .bib files are at the end of the email. The commands I run are

  context bibtry  context bibtry

The first `context bibtry` is ok but no .bbl file generated. The second one
complains

  publications   : loading database from bibtry.bbl
  (bibtry.bbl
  ! Text line contains an invalid utf-8 sequence.
  l.22 n=2,s=
 ?0?2?0?2?0?2?0?286]

Can t-bib do with Chinese bib entry? or is it just a problem of bibtex?

I'm using MkIV(current trunk) and t-bib(march 2, 2009).


BTW. Is only absolute path can be used in \setupbibtex?


Thanks.

Best wishes,
Wei-Wei Guo


 bibtry.tex ===

\usemodule[bib]

\setupbibtex[database=~/mytry.bib]

\starttext

English Bibliogrphy \cite[article-full].

 \cite[c-article-full] ??

\completepublications

\stoptext

==


= mytry.bib ==

@ARTICLE{article-full,
   author = {L[eslie] A. Aamport and L[eslie] A. Aamport and L[eslie] A. 
Aamport and L[eslie] A. Aamport},
   title = {The Gnats and Gnus Document Preparation System},
   journal = {\mbox{G-Animal's} Journal},
   year = 1986,
   volume = 41,
   number = 7,
   pages = 73--83,
   month = jul,
   note = This is a full ARTICLE entry,
}

@ARTICLE{c-article-full,
   author = {?? and ?? and ?? and ??},
   title = {},
   journal = {??},
   year = 1986,
   volume = 41,
   number = 7,
   pages = 73--82,
   month = jul,
   note = This is a full ARTICLE entry,
   language = chinese
}


___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] t-bib cannot do with Chinese.

2009-03-11 Thread Wei-Wei Guo

Thanks for answering my questions.

Taco Hoekwater :


Wei-Wei Guo wrote:

Dear all,

My .tex and .bib files are at the end of the email. The commands I run are

  context bibtry  context bibtry

The first `context bibtry` is ok but no .bbl file generated. The second one
complains

  publications   : loading database from bibtry.bbl
  (bibtry.bbl
  ! Text line contains an invalid utf-8 sequence.
  l.22 n=2,s=
 ?0?2?0?2?0?2?0?286]

Can t-bib do with Chinese bib entry? or is it just a problem of bibtex?


The bib module should be able to handle anything as long as it
is encoded in utf-8 (especially in mkiv). I have no idea what
bibtex does/doesn't accept as input, but I am sure it will not
reencode the database for you, so perhaps it is just a simple
encoding issue.



I'm sure that the files are encoded in UTF-8. Do you get any error with the
example files posted in my previous email?


Best wishes,
Taco



Best wishes,
Wei-Wei
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] t-bib cannot do with Chinese.

2009-03-11 Thread Wei-Wei Guo

Thanks for replying.

I'm just a ordinary user. Studying another package might be too cost for me. :)


Best wishes,
Wei-Wei


Hans Hagen :

Wei-Wei Guo wrote:

you might want to look into mlbibtex then (it supports context)

Hans


___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] How to use my own BibTeX style (bst)?

2009-03-07 Thread Wei-Wei Guo

Dear all,

I have both English and Chinese citations in my paper. Because Chinese citation
has some special requirements, such as using ?? instead of et al. I made a
bst file to solve the localization problem. But after reading the manual of
t-bib and searched in garden and mailing list, I find it might be tricky to
make t-bib use my own bst file. Could you tell my how to do it?

Thanks a lot!

Best wishes,
Wei-Wei Guo


___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] How to increase weight of a font?

2009-03-06 Thread Wei-Wei Guo

It works, but is what I want. Sorry, I didn't describe my problem clear enough.
I want to set weighted font for chapter title. How do this?

Thanks,

Wei-Wei Guo


Hans Hagen 写道:

Wei-Wei Guo wrote:

Hi Hans,

Do you mean

  \definefontsynonym[ZhSerif][name:SimSun][properties=???]

Could you tell me how to do?



\starttext

\startproperty[both]
\input tufte
\stopproperty

\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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] How to increase weight of a font?

2009-03-06 Thread Wei-Wei Guo

Thanks, it works.

Best wishes,
Wei-Wei Guo

Yanrui Li 写道:

2009/3/6 Wei-Wei Guo wwgu...@gmail.com:

It works, but is what I want. Sorry, I didn't describe my problem clear
enough.
I want to set weighted font for chapter title. How do this?




\setuphead
  [chapter]
  [before={\startproperty[both]}, after={\stopproperty}]


___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] How to increase weight of a font?

2009-03-06 Thread Wei-Wei Guo
I guess you are asking the equal feature provided by xetex, so my answer is 
'yes'.

Does ConTeXt have the 'embolden' feature? If yes, how to use it?


Best wishes,
Wei-Wei Guo


Yue Wang 写道:
 the embolden feature provided by xetex and dvipdfmx?
 
 On Fri, Mar 6, 2009 at 6:31 PM, Wei-Wei Guo wwgu...@gmail.com wrote:
 It works, but is what I want. Sorry, I didn't describe my problem clear
 enough.
 I want to set weighted font for chapter title. How do this?

 Thanks,

 Wei-Wei Guo


 Hans Hagen 写道:
 Wei-Wei Guo wrote:
 Hi Hans,

 Do you mean

  \definefontsynonym[ZhSerif][name:SimSun][properties=???]

 Could you tell me how to do?

 \starttext

 \startproperty[both]
 \input tufte
 \stopproperty

 \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  : https://foundry.supelec.fr/projects/contextrev/
 wiki : http://contextgarden.net
 ___

 ___
 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  : https://foundry.supelec.fr/projects/contextrev/
 wiki : http://contextgarden.net
 ___
 
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] How to increase weight of a font?

2009-03-05 Thread Wei-Wei Guo

Hi everyone,


I need to increase the eight of a Chinese font to make it look like a bold 
font. Is there anyway to do so?


Thanks,

Best wishes,
Wei-Wei Guo
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] New LilyPond module

2009-03-05 Thread Wei-Wei Guo

It comes right in time. Thank you!

Is it possible to make the temp lily file in the format of PNG instead of PDF?
MkIV here cannot insert PDF figure properly recently.

Best wishes,
Wei-Wei Guo



ntg-context-requ...@ntg.nl 写道:
 Dear music lovers,

 I just uploaded a new version of the LilyPond module, see
 http://modules.contextgarden.net/t-lilypond
 http://wiki.contextgarden.net/LilyPond

 It works now with LilyPond 2.12 and fixes some bugs - i.e. all
 settings should work now, and with

 \lilypond[fragment=yes,time=no,clef=no]{c''8 d'' e'' f'' g''}

 it should now produce proper fragments (snippets).


 Greetlings from Lake Constance!
 Hraban
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] How to increase weight of a font?

2009-03-05 Thread Wei-Wei Guo

Hi Hans,

Do you mean

  \definefontsynonym[ZhSerif][name:SimSun][properties=???]

Could you tell me how to do?

Thank you!

Best wishes,
Wei-Wei Guo


ntg-context-requ...@ntg.nl 写道:

Message: 3
Date: Thu, 05 Mar 2009 17:13:16 +0100
From: Hans Hagen pra...@wxs.nl
Subject: Re: [NTG-context] How to increase weight of a font?
To: mailing list for ConTeXt users ntg-context@ntg.nl
Message-ID: 49affa1c.8040...@wxs.nl
Content-Type: text/plain; charset=ISO-8859-1; format=flowed

Wei-Wei Guo wrote:

Hi everyone,


I need to increase the eight of a Chinese font to make it look like a 
bold font. Is there anyway to do so?


properties

-
   Hans Hagen | PRAGMA ADE
   Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
  | www.pragma-pod.nl
-

___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] lilypond results do not show.

2009-02-25 Thread Wei-Wei Guo

Hi everyone,

I tried the tex file attached in this email, but the lily figure not shown. The result pdf file and log file are also 
attached.


I also find that there are two files, mytry-lilypond-l.tmp and mytry-lilypond-2.tmp, generated. Those two generated 
files contain codes for lilypond. I run command LILYPOND on them and get mytry-lilypond-1.pdf, but not 
mytry-lilypond-2.pdf. I run MTXRUN on mytry.tex again and can only get an error because of existence of 
mytry-lilypond-1.pdf.


I searched in ntg-context mail list and found Olivier Gu??ry had the same problem before 
(http://www.ntg.nl/pipermail/ntg-context/2008/033582.html). It seems the problem solved in the new lilypond module. But 
the new module doesn't work here.


Any help is appreciated!

Best wishes,
Wei-Wei
(mytry.tex

ConTeXt  ver: 2008.11.10 21:40 MKIV  fmt: 2009.2.25  int: english/english

system : cont-new loaded
(/usr/local/share/texmf/tex/context/base/cont-new.tex
systems : beware: some patches loaded from cont-new.tex
(/usr/local/share/texmf/tex/context/base/cont-new.mkiv) 
(/usr/local/share/texmf/tex/context/base/cont-mtx.tex))
system : cont-fil loaded
(/usr/local/share/texmf/tex/context/base/cont-fil.tex
loading: Context File Synonyms
)
system : cont-sys.rme loaded
(/usr/local/share/texmf/tex/context/user/cont-sys.rme 
(/usr/local/share/texmf/tex/context/base/type-tmf.tex) 
(/usr/local/share/texmf/tex/context/base/type-siz.tex) 
(/usr/local/share/texmf/tex/context/base/type-otf.tex))
bodyfont   : 12pt rm is loaded
specials   : pdftex loaded
language   : language en is active
system : mytry.top loaded
(mytry.top)
system : module lilypond loaded
(/usr/local/share/texmf/tex/context/third/lilypond/t-lilypond.tex
loading: LilyPond module
) (mytry.tuo) (mytry.tuo)
systems: begin file mytry at line 4
color  : mpcmyk color space is supported
color  : mpspot color space is supported
color  : system rgb is local activated
color  : mpcmyk color space is supported
color  : mpspot color space is supported
color  : system rgb is local activated
color  : mpcmyk color space is supported
color  : mpspot color space is supported
color  : system rgb is local activated
color  : mpcmyk color space is supported
color  : mpspot color space is supported
color  : system rgb is local activated
fonts  : resetting map file list
{/usr/local/share/texmf/fonts/map/pdftex/context/original-empty.map}
fonts  : using map file: original-base
{/usr/local/share/texmf/fonts/map/pdftex/context/original-base.map}
fonts  : using map file: lm-math
{/usr/share/texmf-dist/fonts/map/dvips/lm/lm-math.map}
fonts  : using map file: lm-rm
{/usr/share/texmf-dist/fonts/map/dvips/lm/lm-rm.map}
fonts  : using map file: original-ams-base
{/usr/local/share/texmf/fonts/map/pdftex/context/original-ams-base.map}
fonts  : using map file: original-ams-euler
{/usr/local/share/texmf/fonts/map/pdftex/context/original-ams-euler.map}
fonts  : using map file: original-public-lm
{/usr/local/share/texmf/fonts/map/pdftex/context/original-public-lm.map} [1.1]
systems: end file mytry at line 18
system : cont-err loaded
(/usr/local/share/texmf/tex/context/base/cont-err.tex
systems: no file 'cont-sys.tex', using 'cont-sys.rme' instead
) 
)/usr/share/texmf-dist/fonts/opentype/public/lm/lmmono8-regular.otf/usr/share/texmf-dist/fonts/opentype/public/lm/lmroman12-regular.otf
mkiv lua stats : used config path  - /etc/texmf/web2c/texmf.cnf
mkiv lua stats : used cache path   - /var/cache/texmf
mkiv lua stats : modules/dumps/instances   - 94/26/1
mkiv lua stats : input load time   - 0.125 seconds
mkiv lua stats : startup time  - 2.121 seconds (including runtime 
option file processing)
mkiv lua stats : jobdata time  - 0.001 seconds saving, 0.000 
seconds loading
mkiv lua stats : fonts load time   - 1.804 seconds
mkiv lua stats : xml load time - 0.000 seconds, lpath calls: 0, 
cached calls: 0
mkiv lua stats : lxml load time- 0.000 seconds preparation, 
backreferences: 0
mkiv lua stats : mps conversion time   - 0.000 seconds
mkiv lua stats : node processing time  - 0.001 seconds including kernel
mkiv lua stats : kernel processing time- 0.001 seconds
mkiv lua stats : attribute processing time - 0.004 seconds
mkiv lua stats : language load time- 0.046 seconds, n=2
mkiv lua stats : graphics processing time  - 0.090 seconds including tex, n=4
mkiv lua stats : metapost processing time  - 0.000 seconds, loading: 0.000 
seconds, execution: 0.000 seconds, n: 0
mkiv lua stats : current memory usage  - 47 MB (ctx: 48 MB)
mkiv lua stats : cleaned up reserved nodes - 22 nodes, 8 lists of 100
mkiv lua stats : node memory usage - 20 glue_spec, 2 dir
mkiv