blob: 1a73681721b1408713238ad39f8acf924fd16dc4 (
plain)
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
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
|
<!DOCTYPE html>
<html>
<head>
<title>Table rowspan</title>
<script src="../../resources/check-layout.js"></script>
<style>
td { font: 15px/1 Ahem }
#div-table { display: table; border-spacing: 2px }
#div-row, #span-row { display: table-row }
#div-cell, #span-cell { display: table-cell }
#div-table, #div-row, #span-row, #div-cell, #span-cell{ border: 1px solid black }
</style>
</head>
<body onload="checkLayout('tr')">
<h3>Test for chromium bug : <a href="https://code.google.com/p/chromium/issues/detail?id=249600">249600</a>. Extra logical height is not properly spread over the rows in a row-spanning cell.</h3>
<h4>Rows in rowspan should get proportional height.</h4>
<h5>Test 1 - Three rowSpan cells</h5>
<table border="1">
<tbody>
<tr>
<td>row0 col0</td>
</tr>
<tr data-expected-height="19">
<td rowspan="4">row1 col0 - rowspan=4</td>
<td>row1 col1</td>
</tr>
<tr data-expected-height="19">
<td>row2 col1</td>
</tr>
<tr data-expected-height="19">
<td>row3 col1</td>
</tr>
<tr data-expected-height="19">
<td>row4 col1</td>
</tr>
<tr data-expected-height="19">
<td>row5 col0</td>
</tr>
<tr>
<td>row6 col0</td>
</tr>
<tr data-expected-height="57">
<td>row7 col0</td>
<td rowspan="4" style="height:300px">row7 col1 - rowspan=4</td>
</tr>
<tr data-expected-height="57">
<td>row8 col0</td>
</tr>
<tr data-expected-height="74">
<td>row9 col0</td>
</tr>
<tr data-expected-height="75">
<td>row10 col0</td>
</tr>
<tr data-expected-height="19">
<td>row11 col0</td>
<td>row11 col1</td>
</tr>
<tr>
<td>row12 col0</td>
</tr>
<tr data-expected-height="59">
<td>row13 col0</td>
<td rowspan="4" style="height:300px">row13 col1 - rowspan=4</td>
</tr>
<tr data-expected-height="74">
<td style="height:70px">row14 col0</td>
</tr>
<tr data-expected-height="34">
<td style="height:30px">row15 col0</td>
</tr>
<tr data-expected-height="104">
<td style="height:100px">row16 col0</td>
</tr>
<tr data-expected-height="54">
<td style="height:50px">row17 col0</td>
<td>row17 col1</td>
</tr>
</tbody>
</table>
<h5>Test 2 - Three rowSpan cell and specified table width</h5>
<table border="1" width="607">
<tbody>
<tr data-expected-height="19">
<td rowspan="5">row0 col0 - rowspan=5</td>
<td>row0 col1</td>
</tr>
<tr data-expected-height="19">
<td>row1 col1</td>
</tr>
<tr data-expected-height="19">
<td>row2 col1</td>
</tr>
<tr data-expected-height="19">
<td>row3 col1</td>
</tr>
<tr data-expected-height="19">
<td>row4 col1</td>
</tr>
<tr>
<td>row5 col0</td>
</tr>
<tr data-expected-height="57">
<td>row6 col0</td>
<td rowspan="4" style="height:300px">row6 col1 - rowspan=4</td>
</tr>
<tr data-expected-height="57">
<td>row7 col0</td>
</tr>
<tr data-expected-height="74">
<td>row8 col0</td>
</tr>
<tr data-expected-height="75">
<td>row9 col0</td>
</tr>
<tr data-expected-height="19">
<td>row10 col0</td>
<td>row10 col1</td>
</tr>
<tr>
<td>row11 col0</td>
</tr>
<tr data-expected-height="59">
<td>row12 col0</td>
<td rowspan="4" style="height:300px">row12 col1 - rowspan=4</td>
</tr>
<tr data-expected-height="74">
<td style="height:70px">row13 col0</td>
</tr>
<tr data-expected-height="34">
<td style="height:30px">row14 col0</td>
</tr>
<tr data-expected-height="104">
<td style="height:100px">row15 col0</td>
</tr>
<tr data-expected-height="54">
<td style="height:50px">row16 col0</td>
<td>row16 col1</td>
</tr>
</tbody>
</table>
<h5>Test 3 - Continuous 3 rowSpan cells</h5>
<table border="1">
<tbody>
<tr>
<td>row0 col0</td>
</tr>
<tr data-expected-height="19">
<td rowspan="4">row1 col0 - rowspan=4</td>
<td>row1 col1</td>
</tr>
<tr data-expected-height="19">
<td>row2 col1</td>
</tr>
<tr data-expected-height="19">
<td>row3 col1</td>
</tr>
<tr data-expected-height="19">
<td>row4 col1</td>
</tr>
<tr data-expected-height="57">
<td>row5 col0</td>
<td rowspan="4" style="height:300px">row5 col1 - rowspan=4</td>
</tr>
<tr data-expected-height="57">
<td>row6 col0</td>
</tr>
<tr data-expected-height="74">
<td>row7 col0</td>
</tr>
<tr data-expected-height="75">
<td>row8 col0</td>
</tr>
<tr data-expected-height="59">
<td>row9 col0</td>
<td rowspan="4" style="height:300px">row9 col1 - rowspan=4</td>
</tr>
<tr data-expected-height="74">
<td style="height:70px">row10 col0</td>
</tr>
<tr data-expected-height="34">
<td style="height:30px">row11 col0</td>
</tr>
<tr data-expected-height="104">
<td style="height:100px">row12 col0</td>
</tr>
<tr data-expected-height="54">
<td style="height:50px">row13 col0</td>
<td>row13 col1</td>
</tr>
</tbody>
</table>
<h5>Test 4 - Two rowSpan cells, 2 rows in first spanning cell have percent height and 2 rows in second spanning cell have fixed height</h5>
<table border="1">
<tbody>
<tr>
<td>row0 col0</td>
</tr>
<tr data-expected-height="21">
<td rowspan="4" style="height:300px">row1 col0 - rowspan=4</td>
<td>row1 col1</td>
</tr>
<tr data-expected-height="199" style="height:20%">
<td>row2 col1</td>
</tr>
<tr data-expected-height="19">
<td>row3 col1</td>
</tr>
<tr data-expected-height="74" style="height:30%">
<td>row4 col1</td>
</tr>
<tr data-expected-height="19">
<td>row5 col0</td>
</tr>
<tr>
<td>row6 col0</td>
</tr>
<tr data-expected-height="58">
<td>row7 col0</td>
<td rowspan="4" style="height:300px">row7 col1 - rowspan=4</td>
</tr>
<tr data-expected-height="50" style="height:50px">
<td>row8 col0</td>
</tr>
<tr data-expected-height="89">
<td>row9 col0</td>
</tr>
<tr data-expected-height="70" style="height:70px">
<td>row10 col0</td>
</tr>
<tr data-expected-height="19">
<td>row11 col0</td>
<td>row11 col1</td>
</tr>
<tr>
<td>row12 col0</td>
</tr>
</tbody>
</table>
</table>
<h5>Test 5 - Two rowSpan cells, in first spanning cell, 2 rows have percent height and 2 rows have fixed height and in second spanning cell, 1 row have fixed height, 1 row have percent height and remaining are auto.</h5>
<table border="1">
<tbody>
<tr>
<td>row0 col0</td>
</tr>
<tr data-expected-height="64">
<td rowspan="4" style="height:300px">row1 col0 - rowspan=4</td>
<td style="height:60px">row1 col1</td>
</tr>
<tr data-expected-height="152" style="height:20%">
<td>row2 col1</td>
</tr>
<tr data-expected-height="40" style="height:40px">
<td>row3 col1</td>
</tr>
<tr data-expected-height="19" style="height:30%">
<td>row4 col1</td>
</tr>
<tr data-expected-height="19">
<td>row5 col0</td>
</tr>
<tr>
<td>row6 col0</td>
</tr>
<tr data-expected-height="19">
<td>row7 col0</td>
<td rowspan="4" style="height:300px">row7 col1 - rowspan=4</td>
</tr>
<tr data-expected-height="218" style="height:30%">
<td>row8 col0</td>
</tr>
<tr data-expected-height="20">
<td>row9 col0</td>
</tr>
<tr data-expected-height="50" style="height:50px">
<td>row10 col0</td>
</tr>
<tr data-expected-height="19">
<td>row11 col0</td>
<td>row11 col1</td>
</tr>
<tr>
<td>row12 col0</td>
</tr>
</tbody>
</table>
<h5>Test 6 - RowSpan and ColSpan. </h5>
<table border="1" width="607">
<tbody>
<tr data-expected-height="34">
<td>row0 col0</td>
<td rowspan="3" colspan="2">row0 col1 - rowspan=3 colspan=2</td>
<td>row0 col2</td>
</tr>
<tr data-expected-height="34">
<td>row1 col0</td>
</tr>
<tr data-expected-height="34">
<td>row2 col0</td>
</tr>
<tr data-expected-height="19">
<td colspan="3">row3 col0 - colspan=3</td>
</tr>
<tr data-expected-height="34">
<td>row4 col0</td>
</tr>
</tbody>
</table>
<h5>Test 7 - Mix of baseline aligned and non-baseline aligned cells.</h5>
<table border="1" width="607">
<tbody>
<tr data-expected-height="104">
<td style="height:100px">row0 col0</td>
<td style="vertical-align:top">row0 col1 vertical-align=top</td>
<td style="vertical-align:bottom">row0 col2 vertical-align=bottom</td>
</tr>
<tr data-expected-height="19">
<td>row1 col0</td>
</tr>
<tr data-expected-height="77">
<td rowspan="4" style="vertical-align:text-top; height:300px">row2 col0 - rowspan=4 vertical-align=text-top</td>
<td style="vertical-align:sub">row2 col1 vertical-align=sub</td>
</tr>
<tr data-expected-height="77">
<td style="vertical-align:middle">row3 col1 vertical-align=middle</td>
</tr>
<tr data-expected-height="69">
<td style="vertical-align:super">row4 col1 vertical-align=super</td>
</tr>
<tr data-expected-height="91">
<td style="vertical-align:text-bottom">row5 col1 vertical-align=text-bottom</td>
</tr>
<tr data-expected-height="19">
<td>row6 col0</td>
</tr>
</tbody>
</table>
<h5>Test 8 - CSS Table.</h5>
<div id="div-table">
<span id="span-row">
<span id="span-cell">row0 col0</span>
<div id="div-cell">row0 col1</div>
<span id="span-cell">row0 col2</span>
</span>
<div id="div-row">
<div id="div-cell">row1 col0</div>
<span id="span-cell">row1 col1</span>
<div id="div-cell">row1 col2</div>
</div>
<div id="div-row">
<span id="span-cell">row2 col0</span>
</div>
<span id="span-row">
<div id="div-cell">row3 col0</div>
</span>
<span id="span-row">
<span id="span-cell">row4 col0</span>
<span id="span-cell">row4 col1</span>
<span id="span-cell">row4 col2</span>
</span>
<div id="div-row">
<span id="span-cell">row5 col0</span>
<div id="div-cell">row5 col1</div>
<span id="span-cell">row5 col2</span>
</div>
<span id="span-row">
<div id="div-cell">row6 col0</div>
<span id="span-cell">row6 col1</span>
</span>
<div id="div-row">
<div id="div-cell">row7 col0</div>
</div>
<span id="span-row">
<span id="span-cell">row8 col0</span>
</span>
<div id="div-row">
<div id="div-cell">row9 col0</div>
</div>
<div id="div-row">
<div id="div-cell">row10 col0</div>
</div>
</div>
<h5>Test 9 - Table Similar to CSS table with rowspan.</h5>
<table border="1px">
<tr data-expected-height="21">
<td rowspan=5 style="height:300px">row0 col0</td>
<td>row0 col1</td>
<td>row0 col2</td>
</tr>
<tr data-expected-height="87">
<td rowspan=3 style="height:200px">row1 col1</td>
<td rowspan=2 style="height:100px">row1 col2</td>
<td>row1 col3</td>
</tr>
<tr data-expected-height="96">
<td>row2 col3</td>
</tr>
<tr data-expected-height="40">
<td>row3 col2</td>
</tr>
<tr data-expected-height="24">
<td>row4 col1</td>
<td>row4 col2</td>
<td>row4 col3</td>
</tr>
<tr data-expected-height="19">
<td>row5 col0</td>
<td>row5 col1</td>
<td>row5 col2</td>
</tr>
<tr data-expected-height="0">
<td rowspan=5 style="height:200px">row6 col0</td>
<td rowspan=5 style="height:100px">row6 col1</td>
</tr>
<tr data-expected-height="37">
<td>row7 col1</td>
</tr>
<tr data-expected-height="38">
<td>row8 col1</td>
</tr>
<tr data-expected-height="49">
<td>row9 col1</td>
</tr>
<tr data-expected-height="49">
<td>row10 col1</td>
</tr>
</table>
</body>
</html>
|