Changeset 9360


Ignore:
Timestamp:
2018-02-26T15:41:49+01:00 (3 years ago)
Author:
nicolasmartin
Message:

Preamble.tex: some cleaning, use \path instead of \textit for path typeset, testing of 2 different ways to include source code with syntax highlighting, preliminary work on hyphenation to fix overfull errors

Location:
branches/2017/dev_merge_2017/DOC
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • branches/2017/dev_merge_2017/DOC/LaTeX2HTML.sh

    r9346 r9360  
    33sed -i -e 's#\\documentclass#%\\documentclass#' -e '/{document}/ s/^/%/' TexFiles/Chapters/*.tex 
    44sed -i    '30,${s#\\subfile{#\\include{#g}'                              NEMO_book.tex 
    5 latex NEMO_book && makeindex NEMO_book && bibtex NEMO_book 
     5latex -shell-escape NEMO_book && makeindex NEMO_book && bibtex NEMO_book 
    66mkdir -p html 
    77latex2html -local_icons -no_footnode -split 4 -link 2 -dir html $* 
  • branches/2017/dev_merge_2017/DOC/TexFiles/Chapters/Chap_STP.tex

    r6997 r9360  
    285285\label{STP_rst} 
    286286%--------------------------------------------namrun------------------------------------------- 
    287 \namdisplay{namrun}          
     287%\namdisplay{namrun} 
     288\lstinputlisting{Namelists/namrun} 
     289%\inputminted[fontsize=\tiny, breaklines=true, breakanywhere]{fortran}{Namelists/namrun} 
    288290%-------------------------------------------------------------------------------------------------------------- 
    289291 
  • branches/2017/dev_merge_2017/DOC/TexFiles/Chapters/Introduction.tex

    r9019 r9360  
    107107The namelist allows to input variables (character, logical, real and integer) into the code. There is one namelist file for each component of NEMO (dynamics, sea-ice, biogeochemistry...) containing all the FOTRAN namelists needed. The implementation in NEMO uses a two step process. For each FORTRAN namelist, two files are read: 
    108108\begin{enumerate} 
    109 \item A reference namelist ( in \textit{CONFIG/SHARED/namelist\_ref} ) is read first. This file contains all the namelist variables which are initialised to default values   
    110 \item A configuration namelist ( in \textit{CONFIG/CFG\_NAME/EXP00/namelist\_cfg} ) is read aferwards. This file contains only the namelist variables which are changed from default values, and overwrites those. 
    111 \end{enumerate} 
    112 A template can be found in \textit{NEMO/OPA\_SRC/module.example} 
     109\item A reference namelist (in \path{CONFIG/SHARED/namelist_ref}) is read first. This file contains all the namelist variables which are initialised to default values   
     110\item A configuration namelist (in \path{CONFIG/CFG_NAME/EXP00/namelist_cfg}) is read aferwards. This file contains only the namelist variables which are changed from default values, and overwrites those. 
     111\end{enumerate} 
     112A template can be found in \path{NEMO/OPA_SRC/module.example}. 
    113113The effective namelist, taken in account during the run, is stored at execution time in an output\_namelist\_dyn (or \_ice or \_top) file. 
    114114 \vspace{1cm} 
  • branches/2017/dev_merge_2017/DOC/TexFiles/Preamble.tex

    r9350 r9360  
    2020%\WarningsOff* 
    2121 
    22 %\usepackage[french]{babel} 
    23 %\usepackage{color} 
    2422\usepackage{graphicx}                            % allows insertion of pictures 
    25 %\usepackage{graphics}                           % allows insertion of pictures 
    2623\graphicspath{{Figures/}}                                  % Set global directory for pictures 
    27 %\DeclareGraphicsExtensions{.pdf,.eps}                      % Use .eps for LaTeX2HTML 
    28 %\usepackage{xcolor}                                       % Incompatibility with color -> graphicx 
    2924\usepackage[capbesideposition={top,center}]{floatrow}      % allows captions 
    3025\floatsetup[table]{style=plaintop}                         % beside pictures 
     
    3328\usepackage{enumitem}                                      % allows non-bold description items 
    3429\usepackage{longtable}                                     % allows multipage tables 
    35 %\usepackage{colortbl}                                     % gives coloured panels behind table columns 
    3630 
    3731%hyperref 
     32\usepackage[obeyspaces]{url} 
    3833\usepackage[pdftitle={NEMO ocean engine},pdfauthor={Gurvan Madec},pdfstartview=FitH, 
    3934bookmarks=true,bookmarksopen=true,breaklinks=true,colorlinks=true, 
     
    190185 
    191186\DeclareMathAlphabet{\mathpzc}{OT1}{pzc}{m}{it} 
     187 
     188\usepackage{hyphenat} 
     189\hyphenation{AGRIF FORTRAN NEMOVAR bi-laplacian off-line on-line sea-ice well-known} 
     190 
     191%% Add source code highlighting 
     192%% From LaTeX Wikibooks https://en.wikibooks.org/wiki/LaTeX/Source_Code_Listings 
     193\usepackage{listings} 
     194\usepackage{xcolor} 
     195%% Colors from Trac default style 
     196\definecolor{backgroundcode}{HTML}{f8f8f8} 
     197\definecolor{graycode}{HTML}{666666} 
     198\definecolor{greencode}{HTML}{008800} 
     199\definecolor{purplecode}{HTML}{AA22FF} 
     200\definecolor{redcode}{HTML}{BB4444} 
     201\definecolor{yellowcode}{HTML}{B8860B} 
     202\lstset{language=[90]Fortran, 
     203  backgroundcolor=\color{backgroundcode}, 
     204  basicstyle=\tiny, 
     205  breaklines=true, 
     206  commentstyle=\color{greencode}, 
     207  identifierstyle=\color{yellowcode}, 
     208  keywordstyle=\color{purplecode}, 
     209  numberstyle=\color{graycode}, 
     210  stringstyle=\color{redcode}, 
     211  title=\lstname, 
     212} 
     213 
     214\usepackage{minted} 
     215\usemintedstyle{emacs} 
Note: See TracChangeset for help on using the changeset viewer.