summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/generic/babel-french
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2014-09-18 22:55:22 +0000
committerKarl Berry <karl@freefriends.org>2014-09-18 22:55:22 +0000
commit72a3407f1f7f62a992b22e01e21ee984c3a45327 (patch)
tree773bda75bbc9a60e106fbba892af64dcc8ed1949 /Master/texmf-dist/tex/generic/babel-french
parent4efeaac2183eaaf29d2eaf7274a58d73bf33231f (diff)
babel-french (18sep14)
git-svn-id: svn://tug.org/texlive/trunk@35192 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/generic/babel-french')
-rw-r--r--Master/texmf-dist/tex/generic/babel-french/frenchb.ldf57
-rw-r--r--Master/texmf-dist/tex/generic/babel-french/frenchb.lua45
2 files changed, 56 insertions, 46 deletions
diff --git a/Master/texmf-dist/tex/generic/babel-french/frenchb.ldf b/Master/texmf-dist/tex/generic/babel-french/frenchb.ldf
index fffb081fd38..210fea1533b 100644
--- a/Master/texmf-dist/tex/generic/babel-french/frenchb.ldf
+++ b/Master/texmf-dist/tex/generic/babel-french/frenchb.ldf
@@ -33,7 +33,7 @@
%% extension .ins) which are part of the distribution.
%%
\ProvidesLanguage{frenchb}
- [2014/06/21 v3.1a French support from the babel system]
+ [2014/09/16 v3.1b French support from the babel system]
%%
%% File `frenchb.ldf'
%% Babel package for LaTeX version 2e
@@ -541,11 +541,6 @@
\let\FBeveryparguill\FBguillopen
\ifFB@luatex@punct
\let\FBeverylineguill\FBguillopen
- \ifLaTeXe
- \let\local@leftbox\luatexlocalleftbox
- \else
- \let\local@leftbox\localleftbox
- \fi
\else
\let\FBeverylineguill\FBguillnone
\fi
@@ -578,12 +573,12 @@
\expandafter\csname fg\romannumeral\FBguill@level\endcsname
\else
\ifx\FBeverylineguill\FBguillopen
- \local@leftbox{\guillemotleft\kern.8\fontdimen2\font}%
+ \luatexlocalleftbox{\guillemotleft\kern.8\fontdimen2\font}%
\let\FBeverypar@quote\relax
\FB@og #1\ifFBcloseguill\FB@fg\fi
\else
\ifx\FBeverylineguill\FBguillclose
- \local@leftbox{\guillemotright\kern.8\fontdimen2\font}%
+ \luatexlocalleftbox{\guillemotright\kern.8\fontdimen2\font}%
\let\FBeverypar@quote\relax
\FB@og #1\ifFBcloseguill\FB@fg\fi
\else
@@ -690,16 +685,16 @@
\else
\providecommand*{\up}[1]{\leavevmode\raise1ex\hbox{\sevenrm #1}}
\fi
-\def\ieme{\up{\lowercase{e}}\xspace}
-\def\iemes{\up{\lowercase{es}}\xspace}
-\def\ier{\up{\lowercase{er}}\xspace}
-\def\iers{\up{\lowercase{ers}}\xspace}
-\def\iere{\up{\lowercase{re}}\xspace}
-\def\ieres{\up{\lowercase{res}}\xspace}
+\def\ieme{\up{e}\xspace}
+\def\iemes{\up{es}\xspace}
+\def\ier{\up{er}\xspace}
+\def\iers{\up{ers}\xspace}
+\def\iere{\up{re}\xspace}
+\def\ieres{\up{res}\xspace}
\newcommand*{\FrenchEnumerate}[1]{%
- #1\up{\lowercase{o}}\kern+.3em}
+ #1\up{o}\kern+.3em}
\newcommand*{\FrenchPopularEnumerate}[1]{%
- #1\up{\lowercase{o}})\kern+.3em}
+ #1\up{o})\kern+.3em}
\def\primo{\FrenchEnumerate1}
\def\secundo{\FrenchEnumerate2}
\def\tertio{\FrenchEnumerate3}
@@ -708,10 +703,10 @@
\def\fsecundo){\FrenchPopularEnumerate2}
\def\ftertio){\FrenchPopularEnumerate3}
\def\fquarto){\FrenchPopularEnumerate4}
-\DeclareRobustCommand*{\No}{N\up{\lowercase{o}}\kern+.2em}
-\DeclareRobustCommand*{\no}{n\up{\lowercase{o}}\kern+.2em}
-\DeclareRobustCommand*{\Nos}{N\up{\lowercase{os}}\kern+.2em}
-\DeclareRobustCommand*{\nos}{n\up{\lowercase{os}}\kern+.2em}
+\DeclareRobustCommand*{\No}{N\up{o}\kern+.2em}
+\DeclareRobustCommand*{\no}{n\up{o}\kern+.2em}
+\DeclareRobustCommand*{\Nos}{N\up{os}\kern+.2em}
+\DeclareRobustCommand*{\nos}{n\up{os}\kern+.2em}
\DeclareRobustCommand*{\bsc}[1]{\leavevmode\begingroup\kern0pt
\scshape #1\endgroup}
\ifLaTeXe\else\let\scshape\relax\fi
@@ -815,6 +810,7 @@
\global\let\Warning@nombre\relax
\fi
}
+\ifx\FBfigtabshape\@undefined \let\FBfigtabshape\scshape \fi
\StartBabelCommands*{\BabelLanguages}{captions}
[unicode, fontenc=EU1 EU2, charset=utf8]
\SetString{\refname}{Références}
@@ -839,8 +835,8 @@
\SetString{\listfigurename}{Table des figures}
\SetString{\listtablename}{Liste des tableaux}
\SetString{\indexname}{Index}
- \SetString{\figurename}{{\scshape Figure}}
- \SetString{\tablename}{{\scshape Table}}
+ \SetString{\figurename}{{\FBfigtabshape Figure}}
+ \SetString{\tablename}{{\FBfigtabshape Table}}
\SetString{\pagename}{page}
\SetString{\seename}{voir}
\SetString{\alsoname}{voir aussi}
@@ -981,6 +977,7 @@
\newif\ifFBPartNameFull \FBPartNameFulltrue
\newif\ifFBCustomiseFigTabCaptions \FBCustomiseFigTabCaptionsfalse
\newif\ifFBOldFigTabCaptions \FBOldFigTabCaptionsfalse
+\newif\ifFBSmallCapsFigTabcaptions \FBSmallCapsFigTabcaptionstrue
\newif\ifFBSuppressWarning \FBSuppressWarningfalse
\newif\ifFBINGuillSpace \FBINGuillSpacefalse
\edef\FB@french{\CurrentOption}
@@ -1113,10 +1110,17 @@
{\csname FBCustomiseFigTabCaptions#1\endcsname}%
\define@key{FB}{OldFigTabCaptions}[true]%
{\csname FBOldFigTabCaptions#1\endcsname
- \ifFBOldFigTabCaptions
- \FB@addto{extras}{\babel@save\FBCaption@Separator
- \def\FBCaption@Separator{\CaptionSeparator}}%
- \fi}%
+ \ifFBOldFigTabCaptions
+ \FB@addto{extras}{\babel@save\FBCaption@Separator
+ \def\FBCaption@Separator{\CaptionSeparator}}%
+ \fi}%
+ \define@key{FB}{SmallCapsFigTabCaptions}[true]%
+ {\csname FBSmallCapsFigTabCaptions#1\endcsname
+ \ifFBSmallCapsFigTabCaptions
+ \let\FBfigtabshape\scshape
+ \else
+ \let\FBfigtabshape\relax
+ \fi}%
\define@key{FB}{SuppressWarning}[true]%
{\csname FBSuppressWarning#1\endcsname
\ifFBSuppressWarning
@@ -1376,6 +1380,7 @@
SuppressWarning=true [false]\MessageBreak
CustomiseFigTabCaptions=false [true]\MessageBreak
OldFigTabCaptions=true [false]\MessageBreak
+ SmallCapsFigTabCaptions=false [true]\MessageBreak
INGuillSpace=true [false]\MessageBreak
InnerGuillSingle=true [false]\MessageBreak
EveryParGuill=open, close, none [open]\MessageBreak
diff --git a/Master/texmf-dist/tex/generic/babel-french/frenchb.lua b/Master/texmf-dist/tex/generic/babel-french/frenchb.lua
index 63c5cad1d94..d117f60a2a0 100644
--- a/Master/texmf-dist/tex/generic/babel-french/frenchb.lua
+++ b/Master/texmf-dist/tex/generic/babel-french/frenchb.lua
@@ -1,5 +1,5 @@
--
--- File `frenchb.lua' generated from frenchb.dtx [2014/06/21 v3.1a]
+-- File `frenchb.lua' generated from frenchb.dtx [2014/09/16 v3.1b]
--
-- Copyright (C) 2014 Daniel Flipo <daniel.flipo at free.fr>
-- License LPPL: see frenchb.dtx.
@@ -57,18 +57,22 @@ local guilst = guil10.stretch/65536/1.665
local guilsh = guil10.shrink/65536/1.11
local font_table = {}
local function new_glue_scaled (fid,width,stretch,shrink)
- local fp = font_table[fid]
- if not fp then
- font_table[fid] = font.getfont(fid).parameters
- fp = font_table[fid]
+ if fid > 0 then
+ local fp = font_table[fid]
+ if not fp then
+ font_table[fid] = font.getfont(fid).parameters
+ fp = font_table[fid]
+ end
+ local gl = new_node(GLUE,0)
+ local gl_spec = new_node(GSPEC)
+ gl_spec.width = width * fp.space
+ gl_spec.stretch = stretch * fp.space_stretch
+ gl_spec.shrink = shrink * fp.space_shrink
+ gl.spec = gl_spec
+ return gl
+ else
+ return nil
end
- local gl = new_node(GLUE,0)
- local gl_spec = new_node(GSPEC)
- gl_spec.width = width * fp.space
- gl_spec.stretch = stretch * fp.space_stretch
- gl_spec.shrink = shrink * fp.space_shrink
- gl.spec = gl_spec
- return gl
end
local addDPspace = luatexbase.attributes['FB@addDPspace']
local addGUILspace = luatexbase.attributes['FB@addGUILspace']
@@ -77,9 +81,9 @@ local function french_punctuation (head)
for item in node.traverse_id(GLYPH, head) do
local lang = item.lang
local char = item.char
+ local fid = item.font
local SIG = has_attribute(item, addGUILspace)
- if lang == FR and FB_punct_left[char] then
- local fid = item.font
+ if lang == FR and FB_punct_left[char] and fid > 0 then
local prev = item.prev
local prev_id, prev_subtype, prev_char
if prev then
@@ -96,7 +100,7 @@ local function french_punctuation (head)
glue_wd = glue_spec.width
end
glue = glue and glue_wd > 0
- if FB_punct_thin[char] or FB_punct_thick[char] then
+ if (FB_punct_thin[char] or FB_punct_thick[char]) then
local SBDP = has_attribute(item, addDPspace)
local fbglue
if FB_punct_thick[char] then
@@ -105,10 +109,10 @@ local function french_punctuation (head)
fbglue = new_glue_scaled(fid,thinwd,thinst,thinsh)
end
local auto =
- SBDP and SBDP > 0 and
- ((prev_char and not FB_punct_null[prev_char]) or
- (not prev_char and (prev_id ~= 0 or prev_subtype ~= 3))
- )
+ SBDP and SBDP > 0 and
+ ((prev_char and not FB_punct_null[prev_char]) or
+ (not prev_char and (prev_id ~= 0 or prev_subtype ~= 3))
+ )
if glue or auto then
if glue then
head = remove_node(head,prev,true)
@@ -129,7 +133,8 @@ local function french_punctuation (head)
end
end
end
- if lang == FR and FB_punct_right[char] and SIG and SIG > 0 then
+ if lang == FR and FB_punct_right[char] and fid > 0
+ and SIG and SIG > 0 then
local next = item.next
local next_id, next_subtype, next_char, kern_wd, nextnext
if next then