1 |
--- |
2 |
pms.cls | 61 ++++++++++++++++++++++++++++++++++++++----------------------- |
3 |
1 files changed, 38 insertions(+), 23 deletions(-) |
4 |
|
5 |
Updated patch to apply against latest HEAD. |
6 |
|
7 |
diff --git a/pms.cls b/pms.cls |
8 |
index 5188190..05d44b0 100644 |
9 |
--- a/pms.cls |
10 |
+++ b/pms.cls |
11 |
@@ -21,15 +21,12 @@ |
12 |
fontenc, % Load extended font sets |
13 |
isodate, % Date formatting and conversions |
14 |
typearea, % Set page layout |
15 |
- caption, % Extended float environment formatting |
16 |
inputenc, % Allow input methods apart from ASCII |
17 |
booktabs, % Nicer formatting of tables |
18 |
color, % Support more than black&white |
19 |
enumitem, |
20 |
- float, % More control over float environments |
21 |
fullpage, |
22 |
graphicx, % Image support |
23 |
- hyperref, % Support for hyperlinks |
24 |
ifthen, % Comfortable conditional routines |
25 |
longtable, % Extend tables over more than one page |
26 |
lscape, % Rotating pages |
27 |
@@ -37,9 +34,18 @@ |
28 |
paralist, % Additional list environments |
29 |
parskip, % Space between paragraps instead of intendation |
30 |
pdfpages, % Insert whole PDF documents as separate pages |
31 |
- verbatim, % Extend the print-as-is functionality |
32 |
- algorithm, % |
33 |
- algorithmic % Set algorithms |
34 |
+ verbatim % Extend the print-as-is functionality |
35 |
+} |
36 |
+ |
37 |
+% tex4ht workaround: hyperref needs to be loaded /after/ tex4ht injects itself |
38 |
+\g@addto@macro\@documentclasshook{ |
39 |
+ \RequirePackage{ |
40 |
+ caption, % Extended float environment formatting |
41 |
+ float, % More control over float environments |
42 |
+ hyperref, % Support for hyperlinks |
43 |
+ algorithm, % |
44 |
+ algorithmic % Set algorithms |
45 |
+ } |
46 |
} |
47 |
\ClassInfo{pms}{Capsulation of LaTeX stuff for the Package Manager |
48 |
Specification, loaded baseclass: \ClassToLoad\MessageBreak} |
49 |
@@ -59,9 +65,12 @@ |
50 |
\setboolean{TEX4HT-HACKS}{true} |
51 |
\fi |
52 |
|
53 |
-\floatstyle{plaintop} |
54 |
-\newfloat{listing}{tbp}{lol}[chapter] |
55 |
-\floatname{listing}{Listing} |
56 |
+% tex4ht workaround: these need to happen after loading the float package |
57 |
+\g@addto@macro\@documentclasshook{ |
58 |
+ \floatstyle{plaintop} |
59 |
+ \newfloat{listing}{tbp}{lol}[chapter] |
60 |
+ \floatname{listing}{Listing} |
61 |
+} |
62 |
\newcommand{\listoflistings}{\listof{listing}{Listings}} |
63 |
% Define own label and reference commands, that display the label in |
64 |
% the page margin. |
65 |
@@ -74,7 +83,10 @@ |
66 |
|
67 |
% Some shorthands for the lazy ones. |
68 |
\renewcommand{\t}[1]{\texttt{#1}} |
69 |
-\renewcommand{\i}[1]{\textit{#1}} |
70 |
+% tex4ht workaround: this needs to happen after loading hyperref |
71 |
+\g@addto@macro\@documentclasshook{ |
72 |
+ \renewcommand{\i}[1]{\textit{#1}} |
73 |
+} |
74 |
\newcommand{\e}[1]{\emph{#1}} |
75 |
\renewcommand{\b}[1]{\textbf{#1}} |
76 |
\newcommand{\note}[1]{\paragraph{Note:} #1} |
77 |
@@ -124,19 +136,22 @@ |
78 |
} |
79 |
|
80 |
% Define some PDF meta-data. |
81 |
-\hypersetup{% |
82 |
- urlcolor=black, |
83 |
- colorlinks=true, |
84 |
- citecolor=black, |
85 |
- linkcolor=black, |
86 |
- pdftitle={Package Manager Specification}, |
87 |
- pdfauthor={Stephen P. Bennett, Ciaran McCreesh}, |
88 |
- pdfcreator={pdfLaTeX and hyperref}, |
89 |
- pdfsubject={Defining a feature set for package managers in the |
90 |
- Gentoo world}, |
91 |
- pdflang={en}, |
92 |
- pdfkeywords={Gentoo, package manager, specification}, |
93 |
- pdfproducer={pdfLaTeX and hyperref}, |
94 |
+% tex4ht workaround: this needs to happen after loading hyperref |
95 |
+\g@addto@macro\@documentclasshook{ |
96 |
+ \hypersetup{% |
97 |
+ urlcolor=black, |
98 |
+ colorlinks=true, |
99 |
+ citecolor=black, |
100 |
+ linkcolor=black, |
101 |
+ pdftitle={Package Manager Specification}, |
102 |
+ pdfauthor={Stephen P. Bennett, Ciaran McCreesh}, |
103 |
+ pdfcreator={pdfLaTeX and hyperref}, |
104 |
+ pdfsubject={Defining a feature set for package managers in the |
105 |
+ Gentoo world}, |
106 |
+ pdflang={en}, |
107 |
+ pdfkeywords={Gentoo, package manager, specification}, |
108 |
+ pdfproducer={pdfLaTeX and hyperref}, |
109 |
+ } |
110 |
} |
111 |
% Some metadata needed for the title page generation |
112 |
\title{Package Manager Specification} |
113 |
-- |
114 |
1.6.2.3 |