Skip to content

Commit

Permalink
Document new tests
Browse files Browse the repository at this point in the history
  • Loading branch information
moewew committed Oct 25, 2017
1 parent fe29f47 commit c873099
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 3 deletions.
17 changes: 17 additions & 0 deletions doc/latex/biblatex/biblatex.tex
Original file line number Diff line number Diff line change
Expand Up @@ -9184,6 +9184,23 @@ \subsubsection{Stand-alone Tests}

As \cmd{ifend$<$datetype$>$dateuncertain} but for use in \cmd{mkbibdate*} formatting commands (\secref{aut:fmt:lng}) inside which the appropriate \cmd{ifend$<$datetype$>$dateuncertain} command is aliased to this command.

\cmditem{iflabeldateisdate}{true}{false}

Expands to \prm{true} if labeldate is defined and was obtained from date, and to \prm{false} otherwise.

\cmditem{ifdatehasyearonlyprecision}{datetype}{true}{false}

Expands to \prm{true} if the \prm{datetype}date is defined and would be shown with year precision \cmd{print$<$datetype$>$date}, and to false otherwise.

\cmditem{ifdatehastime}{datetype}{true}{false}

Expands to \prm{true} if the \prm{datetype}date is defined, has a time component and \opt{$<$datetype$>$dateusetime} is true, and to false otherwise.

\cmditem{ifdateshavedifferentprecision}{datetype1}{datetype2}{true}{false}

Expands to \prm{true} if the two dates \prm{datetype1} and \prm{datetype2} would show in different precision when printed with \cmd{print$<$datetype1$>$date} and \cmd{print$<$datetype2$>$date} respectively, and to \prm{false} otherwise.


\cmditem{ifcaselang}[language]{true}{false}

Expands to \prm{true} if the the optional \prm{language} is one of those
Expand Down
6 changes: 3 additions & 3 deletions tex/latex/biblatex/biblatex.sty
Original file line number Diff line number Diff line change
Expand Up @@ -3356,17 +3356,17 @@
and
(test {\iffieldequalstr{labeldatesource}{}}
or test {\iffieldequalstr{labeldatesource}{year}})}}
\def\blx@imc@ifdatehasyearonlyprecision#1{%
\ifboolexpr{not test {\iffieldundef{#1year}}
and (test {\ifcsstring{blx@dateformat@#1date}{year}}
or (test {\iffieldundef{#1month}}
and test {\iffieldundef{#1season}}))}}
\def\blx@imc@ifdatehastime#1{%
\ifboolexpr{togl {blx@#1dateusetime}
and not test {\iffieldundef{#1hour}}}}
\def\blx@imc@ifdateshavedifferentprecision#1#2{%
\ifboolexpr{ (test {\ifdatehasyearonlyprecision{#1}}
and not test {\ifdatehasyearonlyprecision{#2}})
Expand Down

0 comments on commit c873099

Please sign in to comment.