From: Aditya Mahajan <adityam@umich.edu>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: Re: BibTeX in ConTeXt natbib style
Date: Tue, 27 Jan 2009 09:05:16 -0500 (EST) [thread overview]
Message-ID: <alpine.LNX.2.00.0901270900010.14119@ybpnyubfg.ybpnyqbznva> (raw)
In-Reply-To: <497F116C.8080003@gmail.com>
On Tue, 27 Jan 2009, J.A.J. Pater wrote:
> In LaTeX when using the natbib package I can use:
>
> \citet[p. 113]{Bell1992} to get: "Bell (1992, p.\ 112)"
\cite[alternative=authoryear, extras={, p. 112}][Bell1992]
> \cite[p. 113]{Bell1992} to get: "(Bell, 1992, p. 112)"
\cite[alternative=authoryears, extras={, p.\ 113}][Bell1992]
Aditya
> Trying to do this in ConTeXt I came up with this:
>
> \setupcite [author][left=,right=]
> \setupcite [year][left=,right=]
>
> \def\CiteP#1#2%
> {(\cite[author][{#2}]%
> ,\ \cite[year][{#2}]%
> ,\ {#1}
> )}
>
> \CiteP{p. 13}{article-full}
>
> And:
>
> \def\CiteA#1#2%
> {\cite[author][{#2}]%
> \ (\cite[year][{#2}]%
> ,\ {#1}
> )}
>
> \CiteA{p. 13}{article-full}
>
>
> It works alright, but it seems rather crude to me.
> Is there a more elegant way?
> Or maybe more to the point: a way in which I do not have to use \setupcite?
>
> Thanks in advance,
>
> Adriaan.
>
> P.S. I made my first contribution to the wiki:
> http://wiki.contextgarden.net/Version_Control
>
> ___________________________________________________________________________________
> 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
___________________________________________________________________________________
next prev parent reply other threads:[~2009-01-27 14:05 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-01-27 13:51 J.A.J. Pater
2009-01-27 14:05 ` Aditya Mahajan [this message]
2009-01-27 14:18 ` J.A.J. Pater
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=alpine.LNX.2.00.0901270900010.14119@ybpnyubfg.ybpnyqbznva \
--to=adityam@umich.edu \
--cc=ntg-context@ntg.nl \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).