I wonder how to set fixed width for dojox.form.DropDownSelect (version 1.3开发者_如何学Go). I tried the following:
<select id="selectNode" width="100px" dojoType="dojox.form.DropDownSelect" >
<option value="opt">Some option</option>
</select>
<select id="selectNode" style="width: 100px" dojoType="dojox.form.DropDownSelect" >
<select id="selectNode" class="myclass" dojoType="dojox.form.DropDownSelect" >
.myclass = { width: 100px }
You can't set width of DropDown Select less than width of biggest item. If you set width bigger - it would work OK. I propose to you if it possible use dijit.form.ComboBox instead of DropDownSelect . Width property for ComboBox will work in all cases. See example (last item - is ComboBox)
精彩评论