New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
new_cmds.tex in NEMO/trunk/doc/latex/global – NEMO

source: NEMO/trunk/doc/latex/global/new_cmds.tex @ 11433

Last change on this file since 11433 was 11433, checked in by nicolasmartin, 5 years ago

Pre-implementation of new cover page and new headings style for reference manuals

Cover page

The layout of the frontpage has been completely redesigned,
a coloured banner has been added to emphasize the title and easily identify each manual
between them.
The chosen color for each document (blue for NEMO, gray for SI3 and green for TOP) will be
used throughout the manual for the links and in the chapter headings.
The list of authors (writers/editors/reviewers) for the version of the manual is given next to
the abstract, which is now included in the frontpage.
A link to an existing ORCID profile for the author precedes its name.
Few settings have been added to each definitions.tex in order to adjust the rendering of the cover page (vertical spaces above and below the title, a subtitle, the width for authors list and
abstract section)

Headings

  • header: chapter number and title for even pages, same infos for section otherwise
  • footer: name of the manual and page numbering with the total number of pages (reverse order between odd/even pages)

For the chapter heading, a new style 'Bjornstrup' from fncychap package is now use.

Abstract

Split the section in two paragraphs for all manuals

  1. Common description with almost the same sentences only customized by the general infos of the model
  2. Specific part for the characteristics of the model

Troubleshooting

As announced, I have introduced some icons from academicons and fontawesome packages.
It required to switch from pdflatex to xelatex for the compilation and it prevents from now
the building of the whole document.
Also the PDF generated does not look nice due to the font

Work in progress...

File size: 1.9 KB
Line 
1%% Global custom commands: \newcommand{<name>}[<args>][<first argument value>]{<code>}
2%% ==============================================================================
3
4%% Include references and index for compilation of single subfile
5\newcommand{\mtoc}{\minitoc}
6\newcommand{\biblio}{ \bibliography{../main/bibliography} }
7\newcommand{\pindex}{\printindex}
8
9%% NEMO and Fortran in small capitals
10\newcommand{\NEMO   }{\textsc{nemo}}
11\newcommand{\SIcube }{\textsc{si$^3$}}
12\newcommand{\TOP    }{\textsc{top}}
13\newcommand{\fortran}{\textsc{Fortran}}
14\newcommand{\fninety}{\textsc{Fortran 90}}
15
16%% Common aliases
17\renewcommand{\deg}[1][]{\ensuremath{^{\circ}#1}}
18\newcommand{\zstar }{\ensuremath{z^\star}}
19\newcommand{\sstar }{\ensuremath{s^\star}}
20\newcommand{\ztilde}{\ensuremath{\tilde z}}
21\newcommand{\stilde}{\ensuremath{\tilde s}}
22\newcommand{\ie}{\ensuremath{i.e.}}
23\newcommand{\eg}{\ensuremath{e.g.}}
24
25%% Inline maths
26\newcommand{\fractext}[2]{\textstyle \frac{#1}{#2}}
27\newcommand{\rdt}{\Delta t}
28
29%% Gurvan's comments
30\newcommand{\gmcomment}[1]{}
31
32%% Maths
33\newcommand{\lt}{\left}
34\newcommand{\rt}{\right}
35\newcommand{\vect}[1]{\ensuremath{ \mathbf{#1} }}
36\newcommand{\pd}[2][]{\ensuremath{\frac{\partial #1}{\partial #2}}}
37
38%% Convert chapter/section headings to lowercase
39\renewcommand{\chaptermark}[1]{\markboth{#1}{}}
40\renewcommand{\sectionmark}[1]{\markright{#1}{}}
41
42%% Retrieve month name
43\renewcommand{\today}{
44  \ifcase \month\or January\or February\or March\or
45                    April\or   May\or      June\or
46                    July\or    August\or   September\or
47                    October\or November\or December
48  \fi, \number \year
49}
50
51%% Macro for link to orcid profile
52\newcommand{\orcid}[1]{ \href{http://orcid.org/#1}{\textcolor{orcidcolor} \aiOrcidSquare} }
53
54%% Workaround for issue with \listoffigures
55\DeclareRobustCommand{\triad}[6][]{\ensuremath{ {}_{#2}^{#3} { \mathbb{#4}_{#1} }_{#5}^{\,#6} }}
Note: See TracBrowser for help on using the repository browser.