From 7fa97d0a8390a36b4d7782ba5f6579d9fe6782b3 Mon Sep 17 00:00:00 2001 From: "Kevin M. Godby" Date: Thu, 28 Jan 2010 08:10:44 +0000 Subject: [PATCH] * Added code to make the classes compatible with the hyphenat package. git-svn-id: https://tufte-latex.googlecode.com/svn/trunk@144 516e2f36-ce3a-0410-bea4-1d4a03f5df72 --- tufte-common.def | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/tufte-common.def b/tufte-common.def index e36c7db..6bdf9fd 100644 --- a/tufte-common.def +++ b/tufte-common.def @@ -1670,9 +1670,13 @@ % A handy command to disable hyphenation for short bits of text. % Borrowed from Peter Wilson's `hyphenat' package. -\newlanguage\langwohyphens% define a language without hyphenation rules -\newcommand{\nohyphens}[1]{{\language\langwohyphens #1}}% used for short bits of text -\newcommand{\nohyphenation}{\language\langwohyphens}% can be used inside environments for longer text +\AtBeginDocument{% + \@ifpackageloaded{hyphenat}{}{% + \newlanguage\langwohyphens% define a language without hyphenation rules + \newcommand{\nohyphens}[1]{{\language\langwohyphens #1}}% used for short bits of text + \newcommand{\nohyphenation}{\language\langwohyphens}% can be used inside environments for longer text + }% +} %% % Redefine \bibsection to not mark the running heads.