问题
I have this following code in dojo wich using dojox/form/CheckedMultiSelect :
var checkedMultiSelect = new CheckedMultiSelect ({
id:"something",
dropDown: true,
multiple: true,
labelText:"something",
store: dataStore,
style : {width:"240px"} // this doesn't work
}, "placeholder");
How do I set a width to this widget ? I use dojo 1.9 Best regards
回答1:
Check out this fiddle:
http://jsfiddle.net/phusick/qrSWu/
stolen from this post:
Dojo CheckedMultiSelect text wrap and horizontal scrolling
You have to overwrite some css styles...
.narrow .dojoxCheckedMultiSelectWrapper {
width: 200px;
}
回答2:
If I am not wrong, then this is what you want to add the following style:
.dojoxCheckedMultiSelectSelect{
width: 240px;
}
来源:https://stackoverflow.com/questions/18046335/how-to-set-width-to-dojox-form-checkedmultiselect