summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/biblatex-gb7714-2015/gb7714-2015ay.cbx
blob: 5c5a3d81af2162909909292420f5a26aa44a52c4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
\ProvidesFile{gb7714-2015ay.cbx}[2016/05/20 v1.0 biblatex citation style]

\RequireCitationStyle{authoryear}
%\RequireCitationStyle{numeric}

\ExecuteBibliographyOptions{
  %autocite  = superscript ,
  %autopunct = true       ,
  %sorting   = none        ,
}

%\DeclareCiteCommand{\cite}[\mkbibparens]{⟨precode⟩}{⟨loopcode⟩}{⟨sepcode⟩}{⟨postcode⟩}
%
\DeclareCiteCommand{\cite}[\mkbibparens]
  {\usebibmacro{prenote}}
  {\usebibmacro{citeindex}%
   \usebibmacro{cite}}
  {\multicitedelim}
  {\usebibmacro{postnote}}

\DeclareCiteCommand{\parencite}[\mkbibparens]
  {\usebibmacro{prenote}}
  {\usebibmacro{citeindex}%
   \usebibmacro{cite}}
  {\multicitedelim}
  {\usebibmacro{postnote}}

\newbibmacro*{postpages}{%
  \iffieldundef{postnote}
    {\printfield{pages}}
    {\printfield{postnote}}}

%修改括号外带页码的引用格式
\DeclareFieldFormat{postnote}{#1}

\DeclareCiteCommand{\pagescite}
  {\printtext{(}\usebibmacro{prenote}}
  {\usebibmacro{citeindex}%
   \usebibmacro{cite}}
  {\multicitedelim}
  {\printtext{)}\textsuperscript{\usebibmacro{postpages}}}