File: rcs.sty.patch

package info (click to toggle)
rcs-latex 3.1-1
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 288 kB
  • ctags: 31
  • sloc: makefile: 154; lisp: 29; sh: 8
file content (93 lines) | stat: -rw-r--r-- 3,760 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
From - Thu Dec  2 23:39:06 1999
Path: newsr2.u-net.net!peer.news.bb.u-net.net!peer.news.th.u-net.net!u-net!colt.net!diablo.theplanet.net!diablo2!news.theplanet.net!newspost.theplanet.net!arpad.thegreen.private!cc047
From: Jeffrey Goldberg <J.Goldberg@Cranfield.ac.uk>
Newsgroups: comp.text.tex
Subject: Patch for rcs.sty to work with \today under babel
Date: Thu, 2 Dec 1999 10:52:40 +0000
Organization: Cranfield University Computer Centre
Lines: 71
Message-ID: <Pine.LNX.4.20.9912021044390.28857-100000@arpad.thegreen.private>
Reply-To: Jeffrey Goldberg <J.Goldberg@Cranfield.ac.uk>
NNTP-Posting-Host: modem-14.lover.dialup.pol.co.uk
Mime-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII
X-Trace: newsg2.svr.pol.co.uk 944166156 22641 62.136.115.14 (2 Dec 1999 20:22:36 GMT)
NNTP-Posting-Date: 2 Dec 1999 20:22:36 GMT
X-Complaints-To: abuse@theplanet.net
X-Sender: cc047@arpad.thegreen.private
To: Joachim Schrod <schrod@iti.informatik.th-darmstadt.de>
X-Disclaimer: Unless indicated otherwise in the message the views contained are personal statements only and are not to be taken as opinion or policy of Cranfield University or the Cranfield University Computer Centre
X-Received-Date: Thu, 02 Dec 1999 20:22:53 GMT (newsr2.u-net.net)
Xref: newsr2.u-net.net comp.text.tex:43546

rcs.sty v2.9 does not pick up a babel redefined \today since it expands
\today (in an \xdef) before babel redefines it.  Below is a patch which
seems to work, but has not been extensively tested.

Also note that since rcs.sty is under revision control, I didn't feel like
tinkering with the revision numbers, so I haven't chnaged any file date
and information data and will leave that up to the maintainer if he
wishes to include my patch.

The diff is below my sig

-j

-- 
Jeffrey Goldberg                +44 (0)1234 750 111 x 2826
 Cranfield Computer Centre      FAX         751 814
 J.Goldberg@Cranfield.ac.uk     http://WWW.Cranfield.ac.uk/public/cc/cc047/
Relativism is the triumph of authority over truth, convention over justice.
Disclaimer: Unless indicated otherwise, opinions are my own.  Whose else?


*** rcs-orig.sty	Sat Oct 23 01:32:55 1999
--- rcs.sty	Thu Dec  2 10:43:51 1999
***************
*** 1,6 ****
--- 1,8 ----
  % $StyleId: rcs.doc,v 2.9 1995/08/02 12:09:07 schrod Exp $
+ % With modifications by Jeff Goldberg, December 2, 1999
  %----------------------------------------------------------------------
  % Written by Joachim Schrod <schrod@iti.informatik.th-darmstadt.de>.
+ % Minor modification by Jeffrey Goldberg <J.Goldberg@Cranfield.ac.uk>
  % Copyright conditions see below.
  
  %
***************
*** 424,437 ****
  %%% definition of |\today|. This way language-specific styles (e.g., from
  %%% the \textsf{babel} system) may supply their own way to present a date.
  
  %%% \beginprog
  \def\rcs_set_date #1/#2/#3 #4\end_date{%
      \begingroup
  	\day #3			% <-- space!
  	\month #2		% <-- space!
  	\year #1		% <-- space!
! 	\expandafter\xdef \csname RCS\RCS_keyword\endcsname {\today}%
!     \endgroup
      \def\RCSTime{#4}%
      }
  %%% \endprog
--- 426,444 ----
  %%% definition of |\today|. This way language-specific styles (e.g., from
  %%% the \textsf{babel} system) may supply their own way to present a date.
  
+ %%% Modified put the group and |\day|, |\month|, and |\year| setting
+ %%% within the definition of RCSDate to avoid having to do an edef
+ %%% which would expand |\today| before babel could redefine it.  ---JPG
+ 
  %%% \beginprog
  \def\rcs_set_date #1/#2/#3 #4\end_date{%
+     \expandafter\def \csname RCS\RCS_keyword\endcsname {%
      \begingroup
  	\day #3			% <-- space!
  	\month #2		% <-- space!
  	\year #1		% <-- space!
! 	\today
!     \endgroup }
      \def\RCSTime{#4}%
      }
  %%% \endprog