hifenização mais inteligente para colunas estreitas?

hifenização mais inteligente para colunas estreitas?

Eu sei como desativar a hifenização via \nohyphens{.....}(dehifenizar). Mas o que eu realmente gostaria seria hifenizar de forma inteligente. Esperamos que o que quero dizer com isso fique claro no exemplo a seguir.

À esquerda está um trecho de texto de uma coluna de uma tabela, renderizado com o \nohyphens{...}comando. Isso deixa muito espaço em branco aberto. À direita está o mesmo texto escrito por vanilla XeLaTeX. Como você pode ver, éaindadeixa um grande espaço em branco no meio do texto, e também introduz a estranha hifenização, "or-phaning", em vez de, por exemplo, as "correções" mais naturais.
Sem hifenização Comportamento padrão

Aqui está uma versão mais inteligente feita por mim, introduzindo "correções" no código-fonte:

alguns ajustes manuais

Aos meus olhos, pelo menos, isso parece muito melhor do que qualquer uma das versões acima.

Portanto, a questão básica é: posso fazer com que o LaTeX faça isso automaticamente para mim, por exemplo, especificando o espaço em branco entre palavras mais longo e aceitável?

PS. Outra solução mais complexa seria especificar uma "largura alvo" para as colunas da minha tabela, por exemplo, .25\textwidthe então fazer com que o sistema otimize para produzir uma tabela que me aproxime o mais possível da pontuação de espaço em branco especificada e da largura da tabela, minimizando ao mesmo tempo o número de palavras hifenizadas... mas não sei se o LaTeX pode fazer esse tipo de otimização dinâmica em diversas variáveis! Aqui está uma última imagem em que me livrei totalmente da hifenização, passando para .27\textwidthas colunas for. Esta parece ser a versão mais legível até agora.

insira a descrição da imagem aqui

Responder1

Ao tentar compor texto em medidas muito restritas, às vezes é melhor (menos pior?!) usar a \sloppydiretiva, como é feito no exemplo a seguir.

Também pode ser útil em tais situações definir \righthyphenmin2. (Para textos em inglês, o valor padrão deste parâmetro é 3.)

insira a descrição da imagem aqui

\documentclass[12pt,letterpaper]{article}
\usepackage[showframe,margin=3.38in]{geometry} 
  % \textwidth = 8.5"-2*3.38" = 1.74"
\frenchspacing
\righthyphenmin2
\sloppy
\usepackage{fontspec}
\setmainfont[Ligatures=TeX]{Linux Libertine O}
\begin{document}
\noindent
Quality control is handled with corrections and the ``orphaning'' mechanism in case 
of nonresponsive authors. Some articles are world-writeable, as in the wiki model.
\end{document}

Responder2

Não sei por que você está usando, \nohyphenspensei que você queria mais e não menos. Usando a tabela vinculada, já que você não fornece código para o exemplo da pergunta, entendo isso, o que não é tão ruim, embora obviamente possa ser ajustado um pouco mais.

insira a descrição da imagem aqui

\documentclass[article,a4paper,12pt,twoside]{memoir}

\usepackage{hyphenat}

\setlrmarginsandblock{40mm}{20mm}{*}
\setulmarginsandblock{20mm}{20mm}{*}

\begin{document}

\renewcommand{\arraystretch}{1.5}
\begin{table}
\begin{center}
\raisebox{3in}{\small
\begin{tabular}{|*{3}{>{\hyphenpenalty0 }p{.25\textwidth}|}}
\hline
% \multicolumn{1}{p{.25\textwidth}}{\textbf{Relevance}}
\begin{center}(PM)
\end{center}

Ultimately relevance depends on peer review, and irrelevant content
may be deleted. Mechanisms to ensure that relevant content
\emph{will} be added could be improved. &
\begin{center}(WP)
\end{center}
People contribute articles about what
they're interested in; apart from this, rules like WP:WEIGHT come into
play.&
\begin{center}(DO)
\end{center}

Anyone can upload projects (for ``full projects'', one time approval
is needed), but getting changes into the core requires considerably
more vetting. \\
%\multicolumn{1}{p{.25\textwidth}}{\textbf{Quality}}
Quality control is handled with corrections and the ``orphaning'' mechanism
in case of nonresponsive authors. Some articles are world-writeable,
as in the wiki model. & Automated tools for spam and vandalism detection
combined with a system of editorial oversight, in which Jimmy Wales
has last say. & In addition to bug reports and feature requests handled
through the issue tracker, modules can make use of an automated patch
testing system.\\
%\multicolumn{1}{p{.25\textwidth}}{\textbf{Scalability}}
Peer review is distributed. Links are handled automatically. Caching
is deployed where relevant; in particular, interlinking features are
kept up to date. & The database and other infrastructure is massively
scaled. There are many bots that help with small tasks. & In theory,
anyone can join. Earl Miles, NYCCamp 2012 keynote: ``\emph{There are
no insiders, except Dries; there are no outsiders, only resumes.}''
\\
% \multicolumn{1}{p{.25\textwidth}}{\textbf{Consistency}}
Although automatic links and corrections can help with consistency,
mainly PM relies on standards for proof and expository quality.
&NPOV is the key rule, which works together with templates and other
process tools to maintain community standards about style and
content. & The project issue queues are the place to go when one
module's changes breaks another's. The core of the project has
considerable oversight in these
matters.\\
% \multicolumn{1}{p{.25\textwidth}}{\textbf{Motivation}}
People are solving some of their learning, exposition, and social
needs on the site by writing and reviewing articles and posting in the
forums.& As of 2006, over 50\% of the site had been written by less
than 1\% of the users; these days, paid editing is somewhat
notorious.& Miles continued: ``\emph{To build a resume, find someone
who needs help, and help them. Find something that needs doing, do
it.}'' \\ \hline
\end{tabular}
}
\end{center}
\caption{As typeset ``out of the box''}
\end{table}


\end{document}

Se você permitir um pouco de flexibilidade na margem direita e adicionar microtipo, obterá:

\usepackage{microtype}

...

\begin{tabular}{|*{3}{
   >{\hyphenpenalty0 \rightskip0pt plus .3em \emergencystretch2em}%
   p{.25\textwidth}|}}

insira a descrição da imagem aqui

informação relacionada