ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* Overfull hbox issues: different font,
@ 2019-09-03 21:17 Julian G
  2019-09-04 15:10 ` Wolfgang Schuster
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Julian G @ 2019-09-03 21:17 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Hello everyone,
I apologize if this has been brought up already (or if my mistake is painfully obvious), but I'm having a slight issue with overfull hboxes. I think it is connected to hyphenation and/or using different fonts.

Test file: at the end of this mail or at https://gist.github.com/JulianGmp/fe20df633554f5aff02e02eb47a6780f
The output PDF I got: https://i.imgur.com/c8S7Di5.png

Best regards,
Julian



% Compiled document (screenshot):
% https://i.imgur.com/c8S7Di5.png

\setuppapersize[A4]
\showframe

\setuplayout[
	topspace=1cm,
	header=0cm,
	width=16cm,
	footer=0cm,
	bottom=1cm,
]

\definefontfamily[arialFamily]   [sans]  [Arial]
\definefontfamily[calibriFamily] [sans]  [Calibri]
% \setupbodyfont[myfontfamily, 12pt]

\define\printExample{Es kann allerdings ein Problem auftreten: Es ist nicht immer eindeutig, ob die gemessen Phasenerschiebung eine komplette Umdrehung enthaltem. Angenommen sei eine gemessene Verschiebung von \m{\Delta_{\varphi}}, visualisiert in Abbildung 10 ... \blank[small] Zwar wird dadurch eine gewisse Übersicht geschaffen, jedoch werden potentielle Namens-
konflikte nicht verhindert.}

\starttext

\language[de]


\section{Standard Font}
	\subsection{German}
	\language[de] \printExample{}
	\subsection{English}
	\language[en] \printExample{}


\switchtobodyfont[arialFamily, 12pt]
\section{Arial 12pt}
	\subsection{German}
	\language[de] \printExample{}
	\subsection{English}
	\language[en] \printExample{}

\page

\switchtobodyfont[calibriFamily, 14pt]
\section{Calibri 14pt}
	\subsection{German}
	\language[de] \printExample{}
	\subsection{English}
	\language[en] \printExample{}

\stoptext
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Overfull hbox issues: different font,
  2019-09-03 21:17 Overfull hbox issues: different font, Julian G
@ 2019-09-04 15:10 ` Wolfgang Schuster
  2019-09-04 16:25 ` Hans Hagen
  2019-09-08 14:25 ` Pablo Rodriguez
  2 siblings, 0 replies; 4+ messages in thread
From: Wolfgang Schuster @ 2019-09-04 15:10 UTC (permalink / raw)
  To: mailing list for ConTeXt users, Julian G

Julian G schrieb am 03.09.2019 um 23:17:
> Hello everyone,
> I apologize if this has been brought up already (or if my mistake is painfully obvious), but I'm having a slight issue with overfull hboxes. I think it is connected to hyphenation and/or using different fonts.
>
> Test file: at the end of this mail or at https://gist.github.com/JulianGmp/fe20df633554f5aff02e02eb47a6780f
> The output PDF I got: https://i.imgur.com/c8S7Di5.png
>
> Best regards,
> Julian
>
>
>
> % Compiled document (screenshot):
> % https://i.imgur.com/c8S7Di5.png
>
> \setuppapersize[A4]
> \showframe
>
> \setuplayout[
> 	topspace=1cm,
> 	header=0cm,
> 	width=16cm,
> 	footer=0cm,
> 	bottom=1cm,
> ]
>
> \definefontfamily[arialFamily]   [sans]  [Arial]
> \definefontfamily[calibriFamily] [sans]  [Calibri]
> % \setupbodyfont[myfontfamily, 12pt]
>
> \define\printExample{Es kann allerdings ein Problem auftreten: Es ist nicht immer eindeutig, ob die gemessen Phasenerschiebung eine komplette Umdrehung enthaltem. Angenommen sei eine gemessene Verschiebung von \m{\Delta_{\varphi}}, visualisiert in Abbildung 10 ... \blank[small] Zwar wird dadurch eine gewisse Übersicht geschaffen, jedoch werden potentielle Namens-
> konflikte nicht verhindert.}
\setuptolerance[verytolerant]

or

\setupalign[verytolerant]
> \starttext
>
> \language[de]
>
>
> \section{Standard Font}
> 	\subsection{German}
> 	\language[de] \printExample{}
> 	\subsection{English}
> 	\language[en] \printExample{}
>
>
> \switchtobodyfont[arialFamily, 12pt]
> \section{Arial 12pt}
> 	\subsection{German}
> 	\language[de] \printExample{}
> 	\subsection{English}
> 	\language[en] \printExample{}
>
> \page
>
> \switchtobodyfont[calibriFamily, 14pt]
> \section{Calibri 14pt}
> 	\subsection{German}
> 	\language[de] \printExample{}
> 	\subsection{English}
> 	\language[en] \printExample{}
>
> \stoptext
Wolfgang

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Overfull hbox issues: different font,
  2019-09-03 21:17 Overfull hbox issues: different font, Julian G
  2019-09-04 15:10 ` Wolfgang Schuster
@ 2019-09-04 16:25 ` Hans Hagen
  2019-09-08 14:25 ` Pablo Rodriguez
  2 siblings, 0 replies; 4+ messages in thread
From: Hans Hagen @ 2019-09-04 16:25 UTC (permalink / raw)
  To: Julian G, mailing list for ConTeXt users

On 9/3/2019 11:17 PM, Julian G wrote:
> Hello everyone,
> I apologize if this has been brought up already (or if my mistake is painfully obvious), but I'm having a slight issue with overfull hboxes. I think it is connected to hyphenation and/or using different fonts.
> 
> Test file: at the end of this mail or at https://gist.github.com/JulianGmp/fe20df633554f5aff02e02eb47a6780f
> The output PDF I got: https://i.imgur.com/c8S7Di5.png

give tex a bit more room for dealing with it:

\setupalign[tolerant]

or in large document where you don't want to tweak:

\setupalign[tolerant,stretch]

Hans

-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
        tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Overfull hbox issues: different font,
  2019-09-03 21:17 Overfull hbox issues: different font, Julian G
  2019-09-04 15:10 ` Wolfgang Schuster
  2019-09-04 16:25 ` Hans Hagen
@ 2019-09-08 14:25 ` Pablo Rodriguez
  2 siblings, 0 replies; 4+ messages in thread
From: Pablo Rodriguez @ 2019-09-08 14:25 UTC (permalink / raw)
  To: ntg-context

On 9/3/19 11:17 PM, Julian G wrote:
> Hello everyone,
> I apologize if this has been brought up already (or if my mistake is
> painfully obvious), but I'm having a slight issue with overfull
> hboxes. I think it is connected to hyphenation and/or using different
> fonts.

Hi Julian,

the bigger font size is, the higher probability to get issues with
hyphenation.

It is also relevant to know how the problematic words are hyphenated in
English and German:

    \startbuffer[text]
      {\em\currentlanguage}\\
        \hyphenatedword{gemessene Namens-konflikte Namenskonflikte}\\
      \setbreakpoints[compound]
        \hyphenatedword{gemessene Namens-konflikte Namenskonflikte}
    \stopbuffer

    \starttext
      \startTEXpage[offset=3em]
          \getbuffer[text]\\
        \language[de]
         \getbuffer[text]
      \stopTEXpage
    \stoptext

I hope it helps,

Pablo
--
http://www.ousia.tk
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2019-09-08 14:25 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-09-03 21:17 Overfull hbox issues: different font, Julian G
2019-09-04 15:10 ` Wolfgang Schuster
2019-09-04 16:25 ` Hans Hagen
2019-09-08 14:25 ` Pablo Rodriguez

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).