--- loncom/interface/loncommon.pm 2011/12/26 13:47:18 1.1028.2.1 +++ loncom/interface/loncommon.pm 2011/12/27 19:47:02 1.1028.2.2 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # a pile of common routines # -# $Id: loncommon.pm,v 1.1028.2.1 2011/12/26 13:47:18 foxr Exp $ +# $Id: loncommon.pm,v 1.1028.2.2 2011/12/27 19:47:02 foxr Exp $ # # Copyright Michigan State University Board of Trustees # @@ -154,7 +154,8 @@ sub ssi_with_retries { # ----------------------------------------------- Filetypes/Languages/Copyright my %language; my %supported_language; -my %latex_language; # Language name LaTeX uses for selecting hyphenation. +my %latex_language; # For choosing hyphenation in +my %latex_language_bykey; # for choosing hyphenation from metadata my %cprtag; my %scprtag; my %fe; my %fd; my %fm; @@ -193,6 +194,7 @@ BEGIN { $supported_language{$key}=$sup; } if ($latex) { + $latex_language_bykey{$key} = $latex; $latex_language{$two} = $latex; } } @@ -3278,6 +3280,20 @@ sub latexlanguage { } =pod + +=item * &latexhyphenation() + +Same as above but what's supplied is the language as it might be stored +in the metadata. + +=cut + +sub latexhyphenation { + my $key = shift; + return $latex_language_bykey{$key}; +} + +=pod =item * ©rightids()