From fcb69d608481cdc29dc44bf1f5f7a7e63e7701fd Mon Sep 17 00:00:00 2001
From: Karl Berry <karl@freefriends.org>
Date: Wed, 25 Mar 2020 21:12:10 +0000
Subject: memoir (25mar20)

git-svn-id: svn://tug.org/texlive/trunk@54548 c570f23f-e606-0410-a88d-b1316a301751
---
 Master/texmf-dist/tex/latex/memoir/memoir.cls | 32 +++++++++++++++------------
 1 file changed, 18 insertions(+), 14 deletions(-)

(limited to 'Master/texmf-dist/tex/latex/memoir/memoir.cls')

diff --git a/Master/texmf-dist/tex/latex/memoir/memoir.cls b/Master/texmf-dist/tex/latex/memoir/memoir.cls
index c351805fbc4..5f8c4a9dcb4 100644
--- a/Master/texmf-dist/tex/latex/memoir/memoir.cls
+++ b/Master/texmf-dist/tex/latex/memoir/memoir.cls
@@ -28,8 +28,8 @@
 %% 
 \NeedsTeXFormat{LaTeX2e}
 \ProvidesClass{memoir}%
-  [2019/11/21 v3.7j configurable book, report, article document class]
-\newcommand\memversion{v3.7j, 2019/11/21}
+  [2020/03/25 v3.7k configurable book, report, article document class]
+\newcommand\memversion{v3.7k, 2020/03/25}
 \newcommand*{\@ptsize}{}
 \newcommand*{\@memptsize}{}
 \newlength{\onelineskip}
@@ -1377,6 +1377,7 @@
 }
 
 \AtBeginDocument{\mem@fixpagelayout}
+\let\refixpagelayout\mem@fixpagelayout
 
 \newcommand*{\fixpdflayout}{%
   \ClassWarning{memoir}{As of 2018, \string\fixpdflayout\ is no longer used}
@@ -1488,6 +1489,7 @@
     \advance\trimtop -0.5\trimtop
   \trimedge=\stockwidth \advance\trimedge -\paperwidth
     \advance\trimedge -0.5\trimedge}
+\let\setpagemm\setpagecc
 
 \setcounter{topnumber}{3}
 \renewcommand{\topfraction}{.85}
@@ -6016,13 +6018,11 @@
   \ifx\longtable\undefined
     \let\@BTswitch\@BTnormal
   \else\ifx\hline\LT@hline
+    \nobreak
     \let\@BTswitch\@BLTrule
   \else
-    \ifx\xltabular\undefined
-      \let\@BTswitch\@BTnormal
-    \else
-      \let\@BTswitch\@BLTrule
-  \fi\fi\fi
+    \let\@BTswitch\@BTnormal
+  \fi\fi
   \global\@thisrulewidth=#1\relax
   \ifnum\@thisruleclass=\tw@\vskip\@aboverulesep\else
   \ifnum\@lastruleclass=\z@\vskip\@aboverulesep\else
@@ -7134,10 +7134,12 @@
     \@esphack}
     }{}%
   }% end no nameref
-  \@ifpackageloaded{showkeys}{%
-    \renewcommand\sf@@memsub@label@hook[1]{%
-      \SK@\SK@@label{#1}%
-    }
+   \@ifpackageloaded{showkeys}{%
+     \ifdefined\SK@\relax
+       \renewcommand\sf@@memsub@label@hook[1]{%
+        \SK@\SK@@label{#1}%
+      }
+     \fi
   }{}
 } % end AtBeginDocument
 
@@ -8792,9 +8794,11 @@
 
 \newcommand{\memwritetoglo}[5]{\endgroup}
 \newcommand{\@ctualm@mwritetoglo}[5]{%
-  \immediate\write \memglofile{\string\glossaryentry{#1\@nameuse{memglsact\m@mgf}
-                    {\string\memgloterm{#2}}{\string\memglodesc{#3}}
-                    {\string\memgloref{#4}}\@nameuse{memglsnf\m@mgf}}{#5}}%
+  %\immediate\write \memglofile%
+  \immediate@protected@write\memglofile{}%
+        {\string\glossaryentry{#1\@nameuse{memglsact\m@mgf}
+        {\string\memgloterm{#2}}{\string\memglodesc{#3}}
+        {\string\memgloref{#4}}\@nameuse{memglsnf\m@mgf}}{#5}}%
   \endgroup}
 \AtBeginDocument{%
   \let\memwritetoglo\@ctualm@mwritetoglo}
-- 
cgit v1.2.3

