ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Hans Hagen <pragma@wxs.nl>
Cc: ntg-context@ntg.nl
Subject: Re: Bibtex and context?
Date: Fri, 11 Jun 1999 22:08:55 +0200	[thread overview]
Message-ID: <37616CD7.D27DAA7D@wxs.nl> (raw)
In-Reply-To: <375FB5CF.F0EA300F@gmd.de>

Hi Matthew,

> Does Context have a bibliography mechanism?  I don't recall reading
> anything about it in the doco.  More specifically, is there any way of
> getting my bibtex entries in?  I think this is the last requirement for
> my total replacement of latex with context (apart from more mathematics
> macros, which has already been discussed.)
> 
> I've done a bit of bst file editing before.  I guess appropriate bst
> files
> are all that are needed to put bibtex-generated entries into context
> files.
> I could have a crack at this, if it hasn't been done already.  It's
> probably about time I put something back in ;P

Some time ago I defined a general mechanism for collection sof sorted
things, using existing mechanisms. I'll send you the test file (which
defines some macros you need)

It comes down to something:

% definition with two sort keys

\definesortset
  [somepublication]
  [author,title]
  [    type=article,
     author=,title=,
    journal=,volume=,number=,pages=,year=,
    edition=,
       note=,URL=]

% when called by author or title:

\definesortsetitem
  [publication][somepublication][author]
  [(\field{author})]

\definesortsetitem
  [publication][somepublication][title]
  [(\field{title}, by \field{author})]

% or by number as typeset in the list

\definesortsetreference
  [someone][somepublication][{[\fieldnum]}]
  [\FinalPublicationList]

% using a macro:

\def\FinalPublicationList%
  {[\fieldnum]\spatie
   \doif{\field{type}}{article}
     {\doifsomething{\field{author}}{\field{author},\spatie}%
      \doifsomething{\field {title}}{{\sl\field{title}}.\spatie}%
      \doifsomething{\field  {year}}{(\field{year}).\spatie}}
   \par}

% the list itself

\definesortsetlist
  [publicationsbyauthor][somepublication][author][criterium=alles]

% some definitions

\somepublication
  [hagenj-tt,thisthat]
  [author={Hagen, J},
    title={This or That}]

\somepublication
  [ottenaf-ss,suchso]
  [author={Otten, A.F.},
    title={Such and So}]

\somepublication
  [hagenj-ht,herethere]
  [author={Hagen, J},
    title={Here and There}]

\somepublication
  [ottenaf-tt,thickthin]
  [author={Otten, A.F.},
    title={Thick and Thin}]

% a sample

\starttekst

test \publication[author][ottenaf-tt]

test \publication[title][hagenj-tt]

test \someone[ottenaf-ss]

test \someone[hagenj-ht]

\publicationsbyauthor

\stoptekst

So, what we need is a few perl scripts converting existing bib things
into this scheme. 

Hans 

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


  reply	other threads:[~1999-06-11 20:08 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-06-10 12:55 Matthew Baker
1999-06-11 20:08 ` Hans Hagen [this message]
1999-06-14 10:37 ` Taco Hoekwater
1999-06-14 17:43   ` Tobias Burnus
1999-06-15  9:21     ` Hans Hagen
1999-06-15 12:03 ` Gnuplot Taco Hoekwater
1999-06-14  7:53 Bibtex and context? Gilbert van den Dobbelsteen
1999-06-14 11:45 ` Hans Hagen

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=37616CD7.D27DAA7D@wxs.nl \
    --to=pragma@wxs.nl \
    --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).