Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • vaclab/ptb-latex
  • andre.waehlisch/ptb-latex
2 results
Show changes
Showing
with 1272 additions and 0 deletions
% Rolf Niepraschk, Rolf.Niepraschk@ptb.de
\ProvidesFile{ptbletter-new-engines.clo}%
[2017/12/05 v0.1b PTB-Brief -- new engines (RN)]
\RequirePackage{fontspec}
\RequirePackage{unicode-math}
\setromanfont{texgyrepagella}[
Ligatures=TeX,
Scale=MatchUppercase,
Extension=.otf,
UprightFont=*-regular,
BoldFont=*-bold,
ItalicFont=*-italic,
BoldItalicFont=*-bolditalic]
\setsansfont{texgyreheros}[
Ligatures=TeX,
Extension=.otf,
UprightFont=*-regular,
BoldFont=*-bold,
ItalicFont=*-italic,
BoldItalicFont=*-bolditalic]
\setmonofont{DejaVuSansMono}[%
Scale=0.9,
UprightFont = *,
ItalicFont=*-Oblique,
BoldFont=*-Bold,
BoldItalicFont=*-BoldOblique,
Extension = .ttf]
\RequirePackage{newunicodechar}
\newunicodechar{^^^^20ac}{\officialeuro}
\endinput
% Rolf Niepraschk, Rolf.Niepraschk@ptb.de
\ProvidesFile{ptbletter-old-engines.clo}%
[2017/12/05 v0.1b PTB-Brief -- old engines (RN)]
\RequirePackage[utf8]{inputenc}
\RequirePackage[T1]{fontenc}
\usepackage[scaled=0.9]{DejaVuSansMono}
\RequirePackage{textcomp}
\RequirePackage{mathpazo}
\RequirePackage{tgpagella}
\RequirePackage{tgheros}
\endinput
% Rolf Niepraschk, Rolf.Niepraschk@gmx.de
\setcounter{errorcontextlines}{100} \listfiles
\NeedsTeXFormat{LaTeX2e}[1999/12/01]
\ProvidesClass{ptbletter}[2023/04/21 v0.4c PTB-Brief-Klasse (RN)]
\let\ptb@tempdima=\@ovxx
\let\ptb@tempdimb=\@ovyy
\let\ptb@tempdimc=\@ovdx
\let\ptb@tempdimd=\@clnwd
\let\ptb@tempdime=\@clnht
\let\ptb@tempdimf=\@dashdim
\newif\ifPTB@useCMYK \PTB@useCMYKfalse % vorerst
\RequirePackage{graphicx,xcolor}
\ifPTB@useCMYK
\definecolor{PTBcolor}{cmyk}{1,0.32549,0.12549,0.12549}% ???
% icc:model: Europe ISO Coated FOGRA27
\else
\definecolor{PTBcolor}{RGB}{0,155,206}
\fi
\newif\ifptb@BLN \ptb@BLNtrue
\newif\ifptb@serif \ptb@seriftrue
\newcommand*\ptb@lang{main=ngerman}
\newcount\ptb@head \ptb@head=1 %
\newcommand*\ptb@tempa{}
\newcommand*\ptb@tempb{}
\DeclareOption{german}{\def\ptb@lang{main=ngerman}}
\DeclareOption{ngerman}{\def\ptb@lang{main=ngerman}}
\DeclareOption{de}{\def\ptb@lang{main=ngerman}}
\DeclareOption{english}{\def\ptb@lang{main=english}}
\DeclareOption{en}{\def\ptb@lang{main=english}}
\DeclareOption{BS}{\ptb@BLNfalse}
\DeclareOption{BLN}{\ptb@BLNtrue}
\DeclareOption{sanserif}{\ptb@seriffalse}
\DeclareOption{serif}{\ptb@seriftrue}
\DeclareOption{head0}{\ptb@head=0}
\DeclareOption{head1}{\ptb@head=1}
\DeclareOption{head2}{\ptb@head=2}
\DeclareOption{visualize}{%
\PassOptionsToClass{\CurrentOption}{scrlttr2}
\AtEndOfClass{%
\showfields{head,address,location,refline,foot}%
%\showfields{refline}%
\addtokomafont{field}{\color{lightgray}}%
\setshowstyle{rule}%
%\setshowstyle{edges}%
%\setshowstyle{frame}% default
}
}
%\DeclareOption*{\PassOptionsToClass{\CurrentOption}{scrlttr2}}
\ExecuteOptions{pagesize}
\ProcessOptions\relax
\PassOptionsToPackage{usegeometry=true}{typearea}
\LoadClass[%
,fontsize=11pt
%,DINmtext
,backaddress=plain
,refline=nodate
,enlargefirstpage
,pagenumber=no
,parskip=never
,firstfoot=true
]{scrlttr2}
\LoadLetterOption{DINmtext}
\RequirePackage[%
,verbose
,left=1in
,textwidth=165mm
]{geometry}
\raggedbottom
\RequirePackage{hyphsubst}% Trennregeln austauschen
\HyphSubstIfExists{ngerman-x-latest}{%
\HyphSubstLet{ngerman}{ngerman-x-latest}}{}
\HyphSubstIfExists{german-x-latest}{%
\HyphSubstLet{german}{german-x-latest}}{}
\RequirePackage{ifxetex,ifluatex,url,array,tabularx,picture}
\newif\ifXeOrLua \XeOrLuafalse
\ifxetex\XeOrLuatrue\else\ifluatex\XeOrLuatrue\fi\fi
\RequirePackage[right]{eurosym}
\ifXeOrLua% XeLaTeX oder luaLaTeX
\input{ptbletter-new-engines.clo}
\else
\input{ptbletter-old-engines.clo}
\fi
\def\tiny{\@setfontsize\tiny{7}{8.17}}
\ifptb@serif
\renewcommand*\familydefault{\rmdefault}
\else
\renewcommand*\familydefault{\sfdefault}
\fi
\let\texteuro=\officialeuro
\RequirePackage[\ptb@lang]{babel}
\RequirePackage{etoolbox,iflang,trimspaces}
\AtEndPreamble{%
\IfLanguageName{ngerman}{%
\RequirePackage[autostyle=true,german=guillemets,maxlevel=3]{csquotes}%
}{%
\RequirePackage[babel=once]{csquotes}
\useshorthands*{"}
}%
\MakeAutoQuote{»}{«}
\defineshorthand{"`}{\openautoquote}
\defineshorthand{"'}{\closeautoquote}\shorthandon{"}
}
\AtEndOfClass{%
\@ifpackageloaded{inputenc}{}{%
\catcode`=\active
\catcode`=\active
}%
}
\setplength{toaddrhpos}{72bp}
\setplength{toaddrvpos}{124bp}
\setplength{lochpos}{-354bp}% "-" --> vom linken Blattand aus
\setplength{locvpos}{146bp}% --> vom oberen Blattand aus
\setplength{locwidth}{212bp}
\setplength{locheight}{139bp}
\setplength{refvpos}{304bp}
%\setplength{refwidth}{40mm}
\setplength{refaftervskip}{\z@}
\setplength{firstheadhpos}{72bp}
\setplength{firstheadvpos}{50bp}
\setplength{firstheadwidth}{469bp}
\setplength{firstfoothpos}{72bp}
\setplength{firstfootvpos}{764bp}
\setplength{firstfootwidth}{\useplength{firstheadwidth}}
\setplength{subjectaftervskip}{23bp}
%\setplength{sigindent}{3em}
\setplength{sigbeforevskip}{3mm}%
\setlength{\textheight}{235mm}
\setlength{\footskip}{2mm}
\setlength{\footheight}{30bp}
%\widowpenalties 2 10000 0 %
\usepackage[defaultlines=2]{nowidow}
\setnowidow% keine einzelne Zeile am Seitenbeginn (keine "Hurenkinder")
% https://tex.stackexchange.com/questions/21983/how-to-avoid-page-breaks-inside-paragraphs
\let\raggedsignature=\raggedright
\removereffields
\addtokomafont{addressee}{\sffamily}
\setkomafont{refname}{\sffamily\tiny}
\setkomafont{refvalue}{\normalfont\footnotesize}
\setkomavar{firsthead}{%
\ifcase\ptb@head
\or% 1
\begin{picture}(0,30bp )
\unitlength=1bp % ???
\put(0,0) {%
\includegraphics[width=308bp]{PTB-logo-2015.pdf}%
}
\put(0,-5bp) {%
\linethickness{1bp}%
%\textcolor{PTBcolor}{\line(1,0){\linewidth}}%
\textcolor{PTBcolor}{\line(1,0){494bp}}%
}
\end{picture}
\or% 2
\begin{minipage}[b]{\linewidth}%
\sffamily\bfseries\huge%
Physikalisch-Technische Bundesanstalt\\[3bp]%
%%%\large
Braunschweig und Berlin
\end{minipage}%
\fi
}
\setkomavar{location}{%
\begingroup
\extrarowheight=-1bp %
\begin{tabular}%
{@{}>{\usekomafont{refname}}l<{:}@{~\,}>{\usekomafont{refvalue}}l@{}}
\usekomavar*{yourref} & \usekomavar{yourref}\\
\usekomavar*{yourmail} & \usekomavar{yourmail}\\
\usekomavar*{myref} & \usekomavar{myref}\\
\usekomavar*{mymail} & \usekomavar{mymail}\\
\multicolumn{2}{@{}l@{}}{} \\
\usekomavar*{handledby} & \usekomavar{handledby}\\
\usekomavar*{myphone} & \usekomavar{myphone}\\
\usekomavar*{myfax} & \usekomavar{myfax}\\
\usekomavar*{emailseparator} & \usekomavar{fromemail}\\
\multicolumn{2}{@{}l@{}}{} \\
\usekomavar*{date} & \usekomavar{date}
\end{tabular}
\endgroup
}
\setkomavar{firstfoot}{% TODO: engl/dt
\parbox{\useplength{firstfootwidth}}{%
\sffamily\tiny
\begin{tabular}{@{}l@{}}
\IfLanguageName{ngerman}{Hausadresse, Lieferanschrift:}{Domicile:} \\
\ifptb@BLN Abbestr. 2--12 \else Bundesallee 100 \fi \\
\ifptb@BLN 10587 Berlin \else 38116 Braunschweig\fi \\
\IfLanguageName{ngerman}{DEUTSCHLAND}{GERMANY} \\
\end{tabular}%
\hfill
\begin{tabular}{@{}l@{~}l@{}}
\usekomavar*{fromphone} & \ifptb@BLN +49 30 3481-0 \else +49 531 592-0 \fi \\
\usekomavar*{fromfax} & \ifptb@BLN +49 30 3481-7490 \else +49 531 592-9292 \fi \\
\usekomavar*{fromemail} & \ifptb@BLN poststelle\_ib@ptb.de \else poststelle@ptb.de \fi \\
Internet: & http://www.ptb.de
\end{tabular}%
\hfill
\begin{tabular}{@{}l@{~}l@{}}
\multicolumn{2}{@{}l@{}}{Deutsche Bundesbank, Filiale Leipzig} \\
IBAN: & DE38 8600 0000 0086 0010 40 \\
BIC: & MARKDEF1860 \\
VAT-Nr.: & DE 811 240 952
\end{tabular}%
\hfill
\begin{tabular}{@{}l@{}}
\ifptb@BLN PTB Braunschweig \else PTB Berlin-Charlottenburg \fi \\
\ifptb@BLN Bundesallee 100 \else Abbestr. 2--12 \fi \\
\ifptb@BLN 38116 Braunschweig \else 10587 Berlin \fi \\
\IfLanguageName{ngerman}{DEUTSCHLAND}{GERMANY}
\end{tabular}%
\hfill \mbox{}
}%
}
\setkomavar{backaddressseparator}{\,\,\textbullet\,\,}
\ifptb@BLN
\setkomavar{backaddress}{PTB\\Abbestr. 2--12\\10587 Berlin}
\else
\setkomavar{backaddress}{PTB\\Postfach 33 45\\38023 Braunschweig}
\fi
\newcommand*\ptb@setcommand[3][]{% #1=default (opt.), #2=macro, #3=value
\edef\ptb@tempa{\trim@spaces@noexp{#3}}%
\expandafter\protected@edef\csname #2\endcsname{%
\ifx\@empty\ptb@tempa #1\else\ptb@tempa\fi}%
}
\newcommand*\ptb@setkomavar[2]{%
\ptb@setcommand{ptb@tempb}{#2}%
\edef\ptb@tempa{\noexpand\setkomavar{#1}{\ptb@tempb}}%
\ptb@tempa
}
\newcommand*\handledby[1]{\ptb@setkomavar{handledby}{#1}}
\newcommand*\myref[1]{\ptb@setkomavar{myref}{#1}}
\newcommand*\mymail[1]{\ptb@setkomavar{mymail}{#1}}
\newcommand*\myphone[1]{\ptb@setkomavar{myphone}{#1}}
\newcommand*\myfax[1]{\ptb@setkomavar{myfax}{#1}}
\newcommand*\myemail[1]{\ptb@setkomavar{fromemail}{#1}}
\newcommand*\yourref[1]{\ptb@setkomavar{yourref}{#1}}
\newcommand*\yourmail[1]{\ptb@setkomavar{yourmail}{#1}}
\newcommand*\backaddress[1]{\ptb@setkomavar{backaddress}{#1}}
\newcommand*\subject[1]{\setkomavar{subject}{#1}}
\renewcommand*\date[1]{\ptb@setkomavar{date}{#1}}
\newkomavar[\mymailname]{mymail}
\newkomavar[\myphonename]{myphone}
\newkomavar[\myfaxname]{myfax}
\newkomavar[\handledbyname]{handledby}
\newcommand*\ptb@bgTextI{}
\newcommand*\ptb@bgTextII{}
\newcommand*\bgText{%
\@ifstar{\@tempswatrue\ptb@bgText}{\@tempswafalse\ptb@bgText}%
}
\newcommand*\ptb@bgText[1]{%
\if@tempswa
\xdef\ptb@bgTextI{#1}%
\else
\xdef\ptb@bgTextII{#1}%
\fi
}
\RequirePackage{eso-pic}
\definecolor{bgTextColor}{gray}{0.9}
\AtBeginDocument{%
\ifx\ptb@bgTextI\@empty
\ifx\ptb@bgTextII\@empty\else
\AddToShipoutPictureBG{%
\AtTextCenter{%
\makebox(0,0)[c]{\resizebox{\textwidth}{!}{%
\rotatebox{54.7}{%
\textnormal{\textsf{\textbf{%
\color{bgTextColor}\ptb@bgTextII}}}}}}%
}%
}%
\fi
\else
\AddToShipoutPictureBG*{%
\AtTextCenter{%
\makebox(0,0)[c]{\resizebox{\textwidth}{!}{%
\rotatebox{54.7}{%
\textnormal{\textsf{\textbf{%
\color{bgTextColor}\ptb@bgTextI}}}}}}%
}%
}%
\fi
}
\defcaptionname{american,australian,british,canadian,%
english,newzealand,UKenglish,USenglish}\yourrefname{Your reference}%
\defcaptionname{american,australian,british,canadian,%
english,newzealand,UKenglish,USenglish}\yourmailname{Your letter of}%
\defcaptionname{american,australian,british,canadian,%
english,newzealand,UKenglish,USenglish}\myrefname{My reference}%
\defcaptionname{american,australian,british,canadian,%
english,newzealand,UKenglish,USenglish}\mymailname{My letter of}%
\defcaptionname{american,australian,british,canadian,%
english,newzealand,UKenglish,USenglish}\myphonename{Telephone}%
\defcaptionname{american,australian,british,canadian,%
english,newzealand,UKenglish,USenglish}\myfaxname{Fax}%
\defcaptionname{american,australian,british,canadian,%
english,newzealand,UKenglish,USenglish}\handledbyname{Handled by}%
\defcaptionname{german,ngerman,austrian,naustrian,%
swissgerman,nswissgerman}\yourrefname{Ihr Zeichen}%
\defcaptionname{german,ngerman,austrian,naustrian,%
swissgerman,nswissgerman}\yourmailname{Ihre Nachricht vom}%
\defcaptionname{german,ngerman,austrian,naustrian,%
swissgerman,nswissgerman}\myrefname{Mein Zeichen}%
\defcaptionname{german,ngerman,austrian,naustrian,%
swissgerman,nswissgerman}\mymailname{Meine Nachricht vom}%
\defcaptionname{german,ngerman,austrian,naustrian,%
swissgerman,nswissgerman}\myphonename{Telefondurchwahl}%
\defcaptionname{german,ngerman,austrian,naustrian,%
swissgerman,nswissgerman}\myfaxname{Telefaxdurchwahl}%
\defcaptionname{german,ngerman,austrian,naustrian,%
swissgerman,nswissgerman}\handledbyname{Bearbeitet von}%
\defcaptionname{german,ngerman,austrian,naustrian,%
swissgerman,nswissgerman}\enclname{Anlagen}%
\AtBeginDocument{%
\ifxetex\else
\RequirePackage[%
,factor=1500
,protrusion=true
,expansion=true
,verbose=true
,final=true
,letterspace=100
,babel=true
]{microtype}
\fi
\shorthandon{"}%
}
\RequirePackage{enumitem}
\setlist{leftmargin=*,nosep,topsep=.5em,itemsep=.25em}
\setlist[1]{labelindent=1em}
\IfLanguageName{ngerman}{%
\newcommand*\MFG{Mit freundlichen Gr\"u\ss en}
\newcommand*\MFg{Mit freundlichem Gru\ss}
\newcommand*\MHG{Mit herzlichen Gr\"u\ss en}
}{%
\newcommand*\MFG{Yours sincerely,}
\newcommand*\MFg{Sincerely,}
\newcommand*\MHG{With kind regards,}
}
\endinput
ptbposter/George.png

42.6 KiB

ptbposter/John.png

55.8 KiB

# Rolf Niepraschk, 2019/05/13, Rolf.Niepraschk@ptb.de
.SUFFIXES : .tex .ltx .dvi .ps .pdf .eps
DOC1 = ptbposter-doc-1
DOC2 = ptbposter-doc-2
ARCHNAME = ptbposter-$(shell date +%Y-%m-%d).zip
all : $(DOC1).pdf $(DOC2).pdf tcb-example1.pdf tcb-example2.pdf
$(DOC1).pdf $(DOC2).pdf tcb-example2.pdf : $(ADDINPUTS)
%.pdf : %.tex
pdflatex $<
tcb-example1.pdf : tcb-example1.tex
lualatex $<
#%.mps : %.eps
# purifyeps $< - | sed -e "s/0 0 0 setrgbcolor/%/g" > $@
# "purifyeps" macht aktuell Probleme # 2017-10-18
clean :
$(RM) $(addprefix $(DOC1), .log .aux .out)
$(RM) $(addprefix $(DOC2), .log .aux .out)
veryclean : clean
$(RM) $(addprefix $(DOC1), .pdf)
$(RM) $(addprefix $(DOC2), .pdf)
arch :
zip $(ARCHNAME) $(DOC1).tex $(DOC2).tex $(ADDINPUTS) Makefile
@ echo $(ARCHNAME)
ptbposter/Paul.png

40.6 KiB

## ptbposter
LaTeX-Dokumentenklasse und andere Komponenten zur
Erzeugung eines PTB-konformen Posters. Näheres siehe Dokumentation [Teil
1](ptbposter-doc-1.pdf) und [Teil 2](ptbposter-doc-2.pdf) sowie die
Beispiele, die die Verwendung positionierbarer Boxen
[(tcolobox)](https://www.ctan.org/pkg/tcolorbox) sowie die Einbeziehung des
Grafikpakets [TikZ](https://www.ctan.org/pkg/pgf) zeigen:
[tcb-example1](tcb-example1.pdf) und [tcb-example2](tcb-example2.pdf).
Rolf Niepraschk, 2025-03-13
ptbposter/Ringo.png

50.5 KiB

File added
This diff is collapsed.
This diff is collapsed.
\ProvidesPackage{ptbposter-add}[2019/02/20 v0.1b supplements for ptbposter (RN)]
\RequirePackage{ragged2e}
\newif\ifPTB@temp
\newcommand*\putPicture{%
\@ifstar{\PTB@temptrue\PTB@putPicture}{\PTB@tempfalse\PTB@putPicture}%
}
\newcommand\PTB@putPicture[4][t]{%
\trivlist\item\relax
\noindent\begin{minipage}[t]{\linewidth}%
\small
\@begin@tempboxa\hbox{#2}%
\ifx\relax#3\relax\mbox{}\hfill\fi
\begin{minipage}[#1]{\width}%
\if#1t%
\raisebox{\dimexpr\ht\strutbox-\height}{\usebox\@tempboxa}%
\else
\usebox\@tempboxa
\fi
\end{minipage}%
\hfill
\ifx\relax#3\relax
\mbox{}
\else
\begin{minipage}[#1]{\dimexpr\linewidth-\width-\columnsep}%
\hspace{0pt}\ifPTB@temp\RaggedRight\fi#3
\end{minipage}
\fi
\par\ifx\relax#4\relax\else\vskip.75\columnsep #4\fi
\@end@tempboxa
\end{minipage}%
\endtrivlist
}
\newcommand\putInTwoColumn[2]{%
\trivlist\item\relax
\noindent\begin{minipage}[t]{\linewidth}%
\columnsep=.5\columnsep
\begin{minipage}[t]{\dimexpr.5\linewidth-\columnsep}%
#1
\end{minipage}%
\hfill
\begin{minipage}[t]{\dimexpr.5\linewidth-\columnsep}%
#2
\end{minipage}%
\end{minipage}%
\endtrivlist
}
\endinput
File added
This diff is collapsed.
File added
This diff is collapsed.
This diff is collapsed.
% Rolf Niepraschk, Rolf.Niepraschk@ptb.de
\ProvidesFile{ptbposter-old-engines.clo}%
[2020/03/09 v0.1c `PTB-Poster' old engines (RN/PTB)]
\RequirePackage[utf8]{inputenc}
\RequirePackage[T1]{fontenc}
\RequirePackage{textcomp}
\RequirePackage{tgpagella}
\RequirePackage{tgheros}
\RequirePackage[ttdefault=true,scale=1.034]{AnonymousPro}
\makeatletter % wegen Laden aus normalem LaTeX-Dokument
\@ifundefined{ifSERIF}{%
\newif\ifSERIF \SERIFfalse
}{}
\ifSERIF
\RequirePackage{qpxmath}
\else
%%%\renewcommand*\familydefault{\sfdefault}
%%%\RequirePackage{sfmath}
\@latex@error{works only with `LuaLaTeX' or `XeLaTeX'}{%
type:\MessageBreak
lualatex \jobname.tex\MessageBreak
or\MessageBreak
xelatex \jobname.tex
}%
\@@end
\fi
\endinput
This diff is collapsed.