Template:Static row numbers
外观
| 本模板使用以下模板样式: |
给表格添加横栏号。
例子
[编辑]代码:
{{static row numbers}}
{| class="wikitable sortable static-row-numbers"
|-
! rowspan="2" | 颜色
! colspan="3" | 资料
|- class="static-row-header"
! 甲 !! 乙 !! 丙
|-
| 品红 || 1 || 2 || 3
|-
| 黄 || 4 || 5 || 6
|-
| 青 || 7 || 8 || 9
|- class="sortbottom static-row-header"
| '''合计''' || 12 || 15 || 18
|- class="sortbottom static-row-header"
| '''均值''' || 4 || 5 || 6
|}
效果:
| 颜色 | 资料 | ||
|---|---|---|---|
| 甲 | 乙 | 丙 | |
| 品红 | 1 | 2 | 3 |
| 黄 | 4 | 5 | 6 |
| 青 | 7 | 8 | 9 |
| 合计 | 12 | 15 | 18 |
| 均值 | 4 | 5 | 6 |
参见
[编辑]更多调整表格效果模板样式:
- {{Column style}}
- {{sticky header}} - 滚动浏览表格数据时,将栏标题冻结到页顶。
- {{sticky table start}} - 在滚动区域内冻结行列。
- {{sort under}} - 将排序箭头移到表头文字下方。
- {{row hover highlight}} - 凸显鼠标悬停的横栏,亦支持换用白色底色。
- {{table nowrap}} -将某纵栏设定为不换行。
- {{table alignment}} - 指定特定纵栏的对齐方式
- {{table vertical alignment}} - 同上,但设定垂直对齐。
- {{shy}} - 可通过在单词中添加软连字符,使其能够换行,让列宽缩窄。