xhtml_report_generator 1.0.2 → 1.0.3
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 73681f6205d779fd838e3870c1f8461f4b755848
|
4
|
+
data.tar.gz: c8067dad0fb2a14099585499abbab552cd18a4a4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f6c8d8cec60652be6c196b0195cc7bc4c4baa3efb4e97aa088be880fce2e8e864426b1c1b6b52b043f72ab757f2d8898b2e6149bb627a8f00bb5190954b7a55c
|
7
|
+
data.tar.gz: de4f343621b86ecb75f64e2e5bfb23816a06cdf7a322a28cf423cff3b5cb4b2b2e8e234c835447f24c4ffebb95c5d2ebba4de67c63bf2994f375131e22a05796
|
@@ -10,8 +10,12 @@ module Custom
|
|
10
10
|
# only add the layout if it is not already there
|
11
11
|
if !@layout
|
12
12
|
@body.add_element("div", {"class" => "head"})
|
13
|
-
@body.add_element("div", {"class" => "lefttoc", "id" => "ltoc"})
|
14
|
-
|
13
|
+
div = @body.add_element("div", {"class" => "lefttoc", "id" => "ltoc"})
|
14
|
+
div.add_text("Table of Contents")
|
15
|
+
div.add_element("br")
|
16
|
+
div = @body.add_element("div", {"class" => "righttoc", "id" => "rtoc"})
|
17
|
+
div.add_text("Quick Links")
|
18
|
+
div.add_element("br");div.add_element("br")
|
15
19
|
@div_middle = @body.add_element("div", {"class" => "middle"})
|
16
20
|
@layout = true
|
17
21
|
end
|
@@ -159,10 +163,12 @@ module Custom
|
|
159
163
|
# 2 is only the first column and 3 is both, first row and first column as <th> elements. Every other number
|
160
164
|
# is equivalent to the bitwise AND of the two least significant bits with 1, 2 or 3
|
161
165
|
def table (table_data, headers=0, table_attrs={}, tr_attrs={}, th_attrs={}, td_attrs={})
|
162
|
-
|
166
|
+
|
167
|
+
temp = REXML::Element.new("table")
|
168
|
+
temp.add_attributes(table_attrs)
|
163
169
|
|
164
170
|
for i in 0..table_data.length-1 do
|
165
|
-
row =
|
171
|
+
row = temp.add_element("tr", tr_attrs)
|
166
172
|
for j in 0..table_data[i].length-1 do
|
167
173
|
if (i == 0 && (0x1 & headers)==0x1)
|
168
174
|
col = row.add_element("th", th_attrs)
|
@@ -177,6 +183,9 @@ module Custom
|
|
177
183
|
end
|
178
184
|
end
|
179
185
|
|
186
|
+
@div_middle.insert_after(@current, temp)
|
187
|
+
@current = temp
|
188
|
+
return @current
|
180
189
|
end
|
181
190
|
|
182
191
|
# Appends a new heading element to body, and sets current to this new heading
|
@@ -3,7 +3,7 @@ body {
|
|
3
3
|
background: #FFFFFF;
|
4
4
|
font: 100% Arial, Helvetica, sans-serif;
|
5
5
|
color: #555555;
|
6
|
-
line-height:
|
6
|
+
line-height: 110%;
|
7
7
|
margin: 0;
|
8
8
|
}
|
9
9
|
|
@@ -11,7 +11,7 @@ p {
|
|
11
11
|
background: #FFFFFF;
|
12
12
|
font: 100% Arial, Helvetica, sans-serif;
|
13
13
|
color: #555;
|
14
|
-
line-height:
|
14
|
+
line-height: 110%;
|
15
15
|
text-align: left;
|
16
16
|
}
|
17
17
|
|
@@ -29,30 +29,6 @@ div.head {
|
|
29
29
|
z-index: 99;
|
30
30
|
}
|
31
31
|
|
32
|
-
/* div.headleft{
|
33
|
-
margin-top:40px;
|
34
|
-
margin-left:20px;
|
35
|
-
float:left;
|
36
|
-
width:20%;
|
37
|
-
}
|
38
|
-
|
39
|
-
div.headmiddle{
|
40
|
-
float:left;
|
41
|
-
width:39%;
|
42
|
-
margin-top:10px;
|
43
|
-
}
|
44
|
-
|
45
|
-
div.headright{
|
46
|
-
float:right;
|
47
|
-
width:40%;
|
48
|
-
margin-top:10px;
|
49
|
-
} */
|
50
|
-
div.overlay {
|
51
|
-
position: fixed;
|
52
|
-
size: auto;
|
53
|
-
display: none;
|
54
|
-
}
|
55
|
-
|
56
32
|
div.lefttoc {
|
57
33
|
position: fixed;
|
58
34
|
width: 25%;
|
@@ -90,6 +66,7 @@ pre {
|
|
90
66
|
background: #E5F1F4;
|
91
67
|
font-size: 80%;
|
92
68
|
border: 1px dotted;
|
69
|
+
line-height: 100%;
|
93
70
|
}
|
94
71
|
|
95
72
|
/*default highlight yellow*/
|
@@ -159,6 +136,7 @@ h3:before {
|
|
159
136
|
}
|
160
137
|
|
161
138
|
/*End of work-around*/
|
139
|
+
|
162
140
|
form {
|
163
141
|
margin: 1em 0;
|
164
142
|
padding: .2em 20px;
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: xhtml_report_generator
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Manuel Widmer
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2015-01-06 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: "The generator can be used to create xhtml files. It comes with some
|
14
14
|
default utility functions.\n== Here is an example usage\n gen1 = XhtmlReportGenerator::Generator.new\n
|