简体   繁体   English

如何在Xul中调整元素的大小?

[英]How to make element resizable, in xul?

I'm trying to add resize ability to the network panel of Firefox devtools. 我正在尝试为Firefox devtools的网络面板添加调整大小功能。 I used DOM inspector to add a <resizer> element after the top label element, then set element=request-menu-file-header-box attribute using the DOM Node inspector, but it doesn't let me resize the column: 我使用DOM检查<resizer>在顶部标签元素之后添加<resizer>元素,然后使用DOM节点检查器设置element=request-menu-file-header-box 属性 ,但它不允许我调整列大小:

文件栏右侧的调整大小

I tried fiddling with the width of the columns, thinking it wouldn't resize because of set width, but it doesn't seem to make a difference. 我试着摆弄列的宽度,以为它不会因为设置的宽度而调整大小,但似乎没有什么不同。 Is there a way to make these elements resizable? 有没有办法使这些元素可调整大小?

What you want is a <splitter> . 您想要的是<splitter> Using the following after the request-menu-file-header-box element seems to work for me (Nightly on OSX) request-menu-file-header-box元素之后使用以下request-menu-file-header-box似乎对我有用(在OSX上为夜间)

<splitter resizebefore="closest" resizeafter="closest"/>

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM