diff --git a/README.md b/README.md index 93ae2384f0ba0f26dc6d4882e08e85c01aa99f35..dacaa1792c1d87167818b959d4a31647d617e6db 100644 --- a/README.md +++ b/README.md @@ -12,7 +12,7 @@ Recommended template for theses submitted at [Faculty of Information Technology] Version -------- -1.3.3, built 22. 6. 2024. The whole changelog can be found in the [Changelog file](changelog.md). +1.3.4, built 25. 6. 2024. The whole changelog can be found in the [Changelog file](changelog.md). Bugs and support diff --git a/changelog.md b/changelog.md index 9719bb193d89afac504770a32acc83d5d588f7f6..937f05670ec8465944b4d02abcc9538f9f54fc80 100644 --- a/changelog.md +++ b/changelog.md @@ -5,6 +5,14 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](http://keepachangelog.com/) and this project adheres to [Semantic Versioning](http://semver.org/). +# [1.3.4] - 25. 6. 2024 + +Added support for paragraphs as the deepest level of headings. + +### Added +- Added "paragraph" option for document class. If passed, it styles the paragraph command as another level of heading, adds number to it and shows it in ToC. Use with care! Normally, it is considered unwise to use it, since its too deep. + + # [1.3.3] - 22. 6. 2024 Fixed warning about header height. Update of arara compilation settings. diff --git a/ctufit-thesis.cls b/ctufit-thesis.cls index 3b5e24cbe18eaab8fadf8b89396d5f3c767b7367..146bfa0c0633dd211345a5d706027739bc5c96f4 100644 --- a/ctufit-thesis.cls +++ b/ctufit-thesis.cls @@ -51,10 +51,17 @@ \PassOptionsToPackage{english,main=slovak}{babel} \def\@ctufitlang{S} } +\DeclareOption{subsubsection}{ + \def\@ctufitsecdepth{3} +} +\DeclareOption{paragraph}{ + \def\@ctufitsecdepth{4} +} \PassOptionsToPackage{svgnames}{xcolor} \PassOptionsToPackage{newfloat}{minted} \DeclareOption*{\PassOptionsToClass{\CurrentOption}{book}} \ExecuteOptions{unicode} +\ExecuteOptions{subsubsection} \ProcessOptions\relax % main declarations, loading files @@ -281,13 +288,13 @@ \def\frontsubsectionfont{\large} \def\frontsubsubsectionfont{\bfseries} -\setcounter{secnumdepth}{4} % numbering sections; 4: paragraph +\setcounter{secnumdepth}{\@ctufitsecdepth} % numbering sections \newcommand{\stopTOCentries}{ \addtocontents{toc}{\protect\setcounter{tocdepth}{-1}} } \newcommand{\resumeTOCentries}{ - \addtocontents{toc}{\protect\setcounter{tocdepth}{4}} % table of content depth; 3: paragraph + \addtocontents{toc}{\protect\setcounter{tocdepth}{\@ctufitsecdepth}} % table of content depth } % frontmatter headings end % frontmatter pseudochapters: named part without printing actual chapter heading @@ -416,8 +423,10 @@ \titleformat{\subsubsection} {\large\bfseries\color{heading}}{{{\color{black}\thesubsubsection}}}{1em}{}%[\vskip -1em] -\titleformat{\paragraph} - {\bfseries\color{heading}}{{{\color{black}\theparagraph}}}{1em}{}%[\vskip -1em] +\ifnum\@ctufitsecdepth=4%if paragraph should be also styled + \titleformat{\paragraph} + {\bfseries\color{heading}}{{{\color{black}\theparagraph}}}{1em}{}%[\vskip -1em] +\fi } %%%%%%%%%%%%%%%%%%%% % MAINMATTER SETTINGS END diff --git a/ctufit-thesis.tex b/ctufit-thesis.tex index b35616c44c0be2a782bbf836f3a2ecf4fa4007eb..b07eecb9c57cf3ae1cc8f0a9c20d97a0fd2c7573 100644 --- a/ctufit-thesis.tex +++ b/ctufit-thesis.tex @@ -1,7 +1,7 @@ %% This is the ctufit-thesis example file. It is used to produce theses %% for submission to Czech Technical University, Faculty of Information Technology. %% -%% This is version 1.3.3, built 22. 6. 2024. +%% This is version 1.3.4, built 25. 6. 2024. %% %% Get the newest version from %% https://gitlab.fit.cvut.cz/theses-templates/FITthesis-LaTeX @@ -37,6 +37,7 @@ % thesis type: bachelor/master/dissertation % colour: bw for black&white OR no option for default colour scheme % electronic (oneside) or printed (twoside), twoside is default +% paragraph - if passed, this optional argument sets paragraphs as the deepest level of headers, styles it, numbers it and adds it to Table of Content. Use with care! Normally, it is considered unwise to use it, since its too deep. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \documentclass[czech,bachelor,unicode,oneside]{ctufit-thesis}