溢出:滚动;在<td> [英] overflow:scroll; in <td>
问题描述
为什么 CSS 属性 我得到了一些东西 从这里! Andrew Fedoniouk 写道: 这实际上是我的问题:一个技术原因是溢出属性不适用于表."-为什么?这是什么原因? 我不是专家,但我相信这是只是为了向后兼容旧表行为.你可以检查自动"表格布局规范中的算法我很漂亮确定这个布局算法是与溢出不兼容财产(或更准确地说,布局算法永远不会导致需要任何溢出值除了可见"). 是的,这就是我问的原因.好像没有正式的理由为什么或不应该是可滚动的,但看起来像UA 供应商在这方面达成了一些无声的协议.也是如此问题. 规范与您一致到元素.表格单元格是应该尊重溢出,虽然至少,Mozilla 似乎没有这样做所以.我无法回答你的问题这个例子,虽然我仍然会猜测答案仍然与传统渲染. 主线程在这里.> Why does the CSS property From the CSS specs1,2, I can't see why. I got something from here! Andrew Fedoniouk wrote: This is actually my question:
"One technical reason is that the overflow property does not apply to
tables." - why? What is this reason? I'm no expert, but I believe this is
just for backward compatibility with
legacy table behavior. You can check
the "automatic" table layout
algorithm in the spec. I'm pretty
sure that this layout algorithm is
incompatible with the overflow
property (or, more accurately, the
layout algorithm will never result in
the need for any value of overflow
except 'visible'). Yep, this is why I am asking. Seems like there are no formal reasons
why or should not be scrollable but seems like
UA vendors reached some silent agreement in this area. So is the
question. The spec agrees with you with respect
to elements. Table cells are
supposed to respect overflow, although
Mozilla, at least, appears not to do
so. I can't answer your question in
this instance, although I would still
guess the answer is still tied to
legacy rendering. The main thread is here. 这篇关于溢出:滚动;在<td>的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!overflow:scroll;
在 中不起作用,而 overflow:hidden;
效果很好?<tr><td style="overflow:scroll; width:50px;">10000000000000000000000000000000000</td><td>200</td><td>300</td></tr>
overflow:scroll;
not work in <td>
, while overflow:hidden;
works well?<table border="1" style="table-layout:fixed; width:100px">
<tr>
<td style="overflow:scroll; width:50px;">10000000000000000000000000000000000</td>
<td>200</td>
<td>300</td>
</tr>
</table>
登录
关闭