I'm dealing with a pesky hyphenation problem in my LaTeX document on Overleaf. I tried to fix it by using the \usepackage{hyphenat} package, but it didn't do the trick. Since my document is pretty long, manually tinkering with hyphenation isn't a viable option.
Is there any effective solution or a way to work around this document-wide hyphenation issue in LaTeX on Overleaf? I'd really appreciate any tips or suggestions.
my main packages:
\documentclass[dscexam]{coppe}
\usepackage[utf8]{inputenc}
\usepackage[english]{babel}
\usepackage{amsmath,amssymb}
\usepackage[dvipsnames]{xcolor}
\usepackage{bm} % parenteses do modo equação
\usepackage[unicode=true, bookmarks=true, breaklinks=false, pdfborder={0 0 0}, backref=false, colorlinks=true, hyphens]{hyperref}
\hypersetup{
linkcolor=black, % Cor dos links internos (seções, figuras, tabelas, etc.)
citecolor=black, % Cor das citações (usada com \cite{})
urlcolor=blue, % Cor dos URLs
filecolor=blue % Cor dos links para arquivos
}
\usepackage{graphicx}
\usepackage{booktabs}
\usepackage[flushleft]{threeparttable}
\usepackage{subcaption}
\usepackage{textcomp} % R com bolinha
\usepackage{verbatim} % Inclua o pacote verbatim para comentar trechos inteiros
% GRAPHICS
\usepackage{tikz}
\newenvironment{aasa}{$\displaystyle\aligned}{\endaligned$}
\usepackage{csvsimple}
\usepackage{pgfplots}
\pgfplotsset{compat=1.15}
\usepackage{float} %holding figures
\usepackage{indentfirst} %tira a identação do primeiro paragrafo
\usepackage[figurename=Figure]{caption}
\usepackage{chemfig} % figurinhas químicas
\usetikzlibrary{calc}
\usepackage{textgreek,stackengine}
\newcommand\textdot[1]{\stackon[1pt]{\csname text#1\endcsname}{.}}
\newcommand\textdots[1]{\stackon[1pt]{\csname text#1\endcsname}{..}}
\usepackage[version=3]{mhchem}
%%%%%%%%%%%%%%%%% TIKZ DOTS
\makeatletter % from: https://tex.stackexchange.com/a/101263/134144
\tikzset{
dot diameter/.store in=\dot@diameter,
dot diameter=1pt,
dot spacing/.store in=\dot@spacing,
dot spacing=5.5pt,
dots/.style={
line width=\dot@diameter,
line cap=round,
dash pattern=on 0pt off \dot@spacing
}
}
\makeatother
%%%%%%%%% TIKZ RED collor
\def\RED{\gdef\printatom##1{\color{red}\ensuremath{\mathrm{##1}}}}
\def\BLACK{\gdef\printatom##1{\color{black}\ensuremath{\mathrm{##1}}}}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\usepackage{epstopdf}
\usepackage[]{natbib}
%\usepackage{breakurl}
\makelosymbols
\makeloabbreviations
\usepackage{scalerel,amssymb}
\def\mcirc{\mathbin{\scalerel{\bigcirc}{t}}}
\def\msquare{\mathord{\scalerel{\Box}{gX}}}
%%%%%%%%%%%%%%%%%%%%%%%
\usepackage{fancyhdr}
% Define o estilo de página "mainmatterstyle"
\fancypagestyle{mainmatterstyle}{
\fancyhf{} % Limpa os cabeçalhos e rodapés anteriores
\fancyhead[RO]{\nouppercase{\rightmark}} % Capítulos e seções à direita
\fancyfoot[C]{\thepage} % Número da página no rodapé
\renewcommand{\headrulewidth}{0.4pt} % Espessura da linha do cabeçalho
\renewcommand{\footrulewidth}{0pt} % Sem linha no rodapé
}
\fancypagestyle{encerrado}{
\fancyhf{} % Limpa os cabeçalhos e rodapés
\fancyfoot[C]{\thepage} % Número da página no rodapé
\renewcommand{\headrulewidth}{0pt} % Sem linha no cabeçalho
\renewcommand{\footrulewidth}{0pt} % Sem linha no rodapé
}

\hyphenpenalty=10000. But be prepared for the spacing in your output to look dreadfully uneven. The hyphenated examples you show are correct under normal rules for English. – barbara beeton Aug 22 '23 at 21:33\usepackage[english]{babel}but a test file would allow people to test answers, and clarify your question. Originally all you said was hyphenation was not as you expected, but as we did not know the input how could we say if that was expected or not? – David Carlisle Aug 22 '23 at 22:12\showhyphens{differences characteristics}and those hyphenati0on points will be reported, along with others that might be used if the lines in the working text required breakpoints giving different lengths. – barbara beeton Aug 22 '23 at 22:15babelhad beenportuguesethe hyphenation would depend on the package (I know you know that:-) – David Carlisle Aug 22 '23 at 22:18\foreignlanguage). (By the way, the UK hyphenation may be different, but we don't have enough information to determine whether it's US or UK.) – barbara beeton Aug 22 '23 at 22:20characteristicsshould havechar|ac|ter|is|ticsas hyphenation points (see @barbara's comment). I'd infer you are looking at these words with the mindset of Portuguese rules, which definitely do not apply here. – Paulo Cereda Aug 22 '23 at 22:31