From 3650657f3e41690a1051c2f3e14e67acaf60f6b2 Mon Sep 17 00:00:00 2001 From: Ludovic Court`es Date: Fri, 29 Jun 2007 11:39:01 +0000 Subject: `lncs' package: Honor `:sort-bib-refs'. * src/guile/skribilo/package/lncs.scm (bib-ref+): Honor `:sort-bib-refs'. git-archimport-id: lcourtes@laas.fr--2006-libre/skribilo--devo--1.2--patch-82 --- src/guile/skribilo/package/lncs.scm | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'src') diff --git a/src/guile/skribilo/package/lncs.scm b/src/guile/skribilo/package/lncs.scm index 25b1e5a..8546b14 100644 --- a/src/guile/skribilo/package/lncs.scm +++ b/src/guile/skribilo/package/lncs.scm @@ -230,13 +230,17 @@ (format #t "\\cite{~a}" (markup-ident entry))))) (markup-writer 'bib-ref+ latex - :options '(:text :bib) + :options '(:text :bib :sort-bib-refs) :action (lambda (n e) - (let ((entries (map (lambda (bib-ref) - (handle-ast (markup-body bib-ref))) - (markup-body n)))) + (let ((entries (map (lambda (bib-ref) + (handle-ast (markup-body bib-ref))) + (markup-body n))) + (sort-proc (markup-option n :sort-bib-refs))) (format #t "\\cite{~a}" - (string-join (map markup-ident entries) + (string-join (map markup-ident + (if (procedure? sort-proc) + (sort entries sort-proc) + entries)) ","))))) (markup-writer '&the-bibliography latex -- cgit v1.2.3