From 874da2835b26175695859d56d60e649cd33e2d00 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Novotn=C3=BD?= <witiko@mail.muni.cz> Date: Mon, 9 Mar 2020 00:42:42 +0100 Subject: [PATCH] \thesis@blocks@bibEntry now accomodates multiline texts --- fithesis.dtx | 2 +- style/mu/econ.dtx | 40 ++++++++++++++++++++++++++++++---------- 2 files changed, 31 insertions(+), 11 deletions(-) diff --git a/fithesis.dtx b/fithesis.dtx index 8a4a91c..2d89aad 100644 --- a/fithesis.dtx +++ b/fithesis.dtx @@ -56,7 +56,7 @@ \gdef\thesis@version@number{#1} \gdef\thesis@version@date{#2} \gdef\thesis@version{#2 #1 fithesis3 MU thesis class}} -\thesis@versiondef{v0.3.51-dev}{2018/06/15}} +\thesis@versiondef{v0.3.51-dev}{2020/03/09}} % {\newwrite\f\openout\f=VERSION\write\f{\thesis@version}\closeout\f} % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% diff --git a/style/mu/econ.dtx b/style/mu/econ.dtx index ef7b092..5aa4846 100644 --- a/style/mu/econ.dtx +++ b/style/mu/econ.dtx @@ -292,19 +292,39 @@ % in \texttt{style/mu/fithesis-econ.sty} in accordance with the % example documents. The patch was submitted by Jana Ratajská. % [VN]} +% \changes{v0.3.51}{2020/03/09}{The \cs{thesis@blocks@bibEntry} +% command now accomodates long titles and other information that +% may span multiple lines. [VN]} % \begin{macrocode} \def\thesis@blocks@bibEntry{% \thesis@blocks@clear - \noindent\begin{thesis@newtable@old}{@{}>{\bfseries}ll@{}} - \thesis@@{bib@author}: & \thesis@author \\ - \thesis@@{bib@thesisTitle}: & \thesis@title \\ - \ifthesis@english\else - \thesis@@{bib@thesisTitleEn}: & \thesis@titleEn \\ - \fi - \thesis@@{bib@department}: & \thesis@department \\ - \thesis@@{bib@advisor}: & \thesis@advisor \\ - \thesis@@{bib@year}: & \thesis@year \\ - \end{thesis@newtable@old}} + {\let\@A\relax\newlength{\@A} + \settowidth{\@A}{{\bf\thesis@@{bib@author}}} + \let\@B=\@A + \settowidth{\@A}{{\bf\thesis@@{bib@thesisTitle}}} + \ifdim\@A>\@B\let\@B=\@A\fi + \ifthesis@english\else + \settowidth{\@A}{{\bf\thesis@@{bib@thesisTitleEn}}} + \ifdim\@A>\@B\let\@B=\@A\fi + \fi + \settowidth{\@A}{{\bf\thesis@@{bib@department}}} + \ifdim\@A>\@B\let\@B=\@A\fi + \settowidth{\@A}{{\bf\thesis@@{bib@advisor}}} + \ifdim\@A>\@B\let\@B=\@A\fi + \settowidth{\@A}{{\bf\thesis@@{bib@year}}} + \ifdim\@A>\@B\let\@B=\@A\fi + \noindent\begin{thesis@newtable@old}{@{}>{\bfseries}% + p{\dimexpr(\@B + \tabcolsep)}% + p{\dimexpr(\textwidth - \@B - 2\tabcolsep)}@{}} + \thesis@@{bib@author}: & \thesis@author \\ + \thesis@@{bib@thesisTitle}: & \thesis@title \\ + \ifthesis@english\else + \thesis@@{bib@thesisTitleEn}: & \thesis@titleEn \\ + \fi + \thesis@@{bib@department}: & \thesis@department \\ + \thesis@@{bib@advisor}: & \thesis@advisor \\ + \thesis@@{bib@year}: & \thesis@year \\ + \end{thesis@newtable@old}}} % \end{macrocode} % \end{macro} % Note that there is no direct support for the seminar paper and -- GitLab