0

the label of the title and number are overlapping and I have 0 experience with latex, the sty file I believe to be sections.sty

in the text is a simple: \part{Part Tres: NPCs}

but in the sty is

%%%%%%%%%%%%%% \part
\titleformat{\part}
[display]
{\thispagestyle{part}\nodesto\fontsize{50pt}{50pt}\selectfont\color{title1}\filcenter}
{\partname \thepart}
{-15pt}
{\Large}

\titlespacing*{\part}{0pt}{-54pt}{0pt}


%%%%%%%%%%%%%% \chapter

this is the main tex

\documentclass[10pt,a4paper,twocolumn,openany]{book}
%\documentclass[10pt,a4paper,openany]{book}

\usepackage[bg-letter]{lib/rpg-book} % Options: bg-a4, bg-letter, 
 bg-full, bg-print, bg-none.
\usepackage[portuguese]{babel}
%\usepackage[utf8]{inputenc}
\usepackage{lipsum}


% Start document
\begin{document}
\fontfamily{ppl}
\selectfont % Set text font
\frontmatter

\rpgMakeCover[
image = img/part-cover,
logo = img/logo,
title = Memorias da Terra Media e Dru Hill ,
subtitle = Created by Maikon
]

\tableofcontents

% Your content goes here
% ----------------------------------------- 
\chapter{Resumo de Hist\'orias e Contos entre A Terra e Dru Hill}

\mainmatter

\part{Campanhas e Hist\'orias}

what matters is the part item, which the definition is in the sty I provided.

also the full design is here:

https://github.com/Krozark/RPG-LaTeX-Template

enter image description here

3
  • 4
    Welcome to tex.sx. There's not enough information here for us to do anything but guess -- different document classes treat parts differently. Please add a compilable example, starting with \documentclass and ending with \end{document}, that demonstrates the problem, that potential helpers can use to experiment. Commented Jun 18, 2023 at 20:01
  • the full code is in github.com/Krozark/RPG-LaTeX-Template Commented Jun 19, 2023 at 6:42
  • 2
    Please copy the relevant code to your question. Links rot over time and thus your question will not be useful to others as they cannot see the code.
    – daleif
    Commented Jun 19, 2023 at 8:05

1 Answer 1

1

What is needed is to enlarge the part number box.

a

% !TeX TS-program = xelatex

\documentclass[10pt,a4paper,twocolumn,openany]{book}

\usepackage[bg-letter]{lib/rpg-book} % Options: bg-a4, bg-letter, bg-full, bg-print, bg-none.
\usepackage[portuguese]{babel}

\usepackage{lipsum}

\titleformat{\part}
[display]
{\thispagestyle{part}\nodesto\fontsize{50pt}{50pt}\selectfont\color{title1}\filcenter}
{\partname~\thepart}% changed <<<<<<<
{-15pt}
{\Large}

%************************ added <<<<<<<<
\newlength{\extrawidth}% 
\settowidth{\extrawidth}{VIII} % the width of "VIII"
\addtolength{\cftpartnumwidth}{\extrawidth}% expand the box of the part number
%*********************************

% Start document
\begin{document}
    \fontfamily{ppl}
    \selectfont % Set text font
    \frontmatter
    
    \rpgMakeCover[
    image = img/cover,
    logo = img/logo,
    title = Memorias da Terra Media e Dru Hill ,
    subtitle = Created by Maikon
    ]
    
    \tableofcontents
    
    % Your content goes here
    % ----------------------------------------- 

    
    \mainmatter
    
    \part{Campanhas e Hist\'orias}
    \lipsum[1-20]
    
    \part{Personalidades}
    
\end{document}

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .