z35-spinner-003.zul
来自「ZK是一个Ajax Java Web框架」· ZUL 代码 · 共 23 行
ZUL
23 行
<zk>
<vbox>
<label style="font-weight:bold">modify spinner constraint at run time:</label>
<label>1. Originally, the spinner has no constrant;</label>
<label>2. Make spinner's value up & down until over the 10 or -10.</label>
<label>3. Click the button will set the spinner to init value = 1, min = -10 & max = 10, step = 2</label>
<label>4. Make spinner's value up & down, watch it's behavior.</label>
</vbox>
<window title="Spinner test" border="normal" width="200px">
<spinner id="sp"/>
<separator />
<button label="set spinner constraint">
<attribute name="onClick"><![CDATA[
sp.setValue(new Integer(1));
sp.setStep(2);
sp.setConstraint("min -10 max 10");
]]></attribute>
</button>
</window>
</zk>
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?