From 2a53c68bd520e833705b7275c1a83d5f01d7f275 Mon Sep 17 00:00:00 2001 From: Sébastien Dailly Date: Sun, 4 Oct 2020 19:42:45 +0200 Subject: Update table presentation --- Makefile | 5 +---- resources/10_preamble.tex | 22 ---------------------- resources/table.tex | 9 +++++++++ 3 files changed, 10 insertions(+), 26 deletions(-) create mode 100644 resources/table.tex diff --git a/Makefile b/Makefile index 4fc9dfb..8abfcb7 100644 --- a/Makefile +++ b/Makefile @@ -39,7 +39,7 @@ tmp/%.tex: %.rst $(INCLUDED_TEX) $(SOURCES) $(CHAPTERS)| tmp $$(command -v rst2latex rst2latex.py | head -n 1) \ --no-section-subtitles \ --no-section-numbering \ - --table-style=borderless \ + --table-style=booktabs \ --use-latex-citations \ --use-latex-docinfo \ --documentclass=article \ @@ -48,9 +48,6 @@ tmp/%.tex: %.rst $(INCLUDED_TEX) $(SOURCES) $(CHAPTERS)| tmp --stylesheet=$(PACKAGES),$(TEX_STYLE) \ $< $@ sed -i -e 's/{c}{\\hfill ... continued on next page/{r}{... suite sur la page suivante/;s|^%$$||' $@ - #sed -i -e 's/\endfirsthead/\endfirsthead\\tableHeaderStyle/g' $@ - sed -i -e 's/longtable\*/mytable/g' $@ - #sed -i -e 's/p{[0-9]\.[0-9]*\\DUtablewidth}/X/g' $@ # Generate each pdf with latex tmp/%.pdf: tmp/%.tex $(BIBS) | tmp diff --git a/resources/10_preamble.tex b/resources/10_preamble.tex index 2959639..bcbdc1c 100644 --- a/resources/10_preamble.tex +++ b/resources/10_preamble.tex @@ -23,28 +23,6 @@ {\begin{flushleft}\normalsize\CaviarDreamsFont{#1}\end{flushleft}} } -\usepackage{longtable} -%\usepackage{tabu} -%% alternate rowcolors for all long-tables -\newenvironment{mytable}[2][c]% -{\longtable[#1]{#2}}% -{\endlongtable} -% -% -%% This red commes from a triad on the blue -%\colorlet{tableHeader}{redColor} -%\definecolor{tableLineOne}{RGB}{245, 245, 245} -%\definecolor{tableLineTwo}{RGB}{224, 224, 224} -% -%\newcommand{\tableHeaderStyle}{ -% \rowfont{\leavevmode\color{black}\bfseries} -% \rowcolor{tableHeader} -%} -% -%\taburowcolors[2] 2{tableLineOne .. tableLineTwo} -%\tabulinesep = ^4mm_3mm -%\everyrow{\tabucline[.4mm white]{}} - \usepackage{etoolbox} \patchcmd{\quote}{\rightmargin}{\leftmargin 0em \rightmargin}{}{} diff --git a/resources/table.tex b/resources/table.tex new file mode 100644 index 0000000..c1a6324 --- /dev/null +++ b/resources/table.tex @@ -0,0 +1,9 @@ +\colorlet{tableHeader}{redColor!60!white} +\definecolor{tableLineOne}{RGB}{245, 245, 245} +\definecolor{tableLineTwo}{RGB}{224, 224, 224} +\rowcolors{1}{tableLineOne}{tableLineTwo} +\def\toprule{\rowcolor{tableHeader}} +\let\oldm\midrule +\def\midrule{} +\def\bottomrule{} + -- cgit v1.2.3