How to set width to dojox/form/CheckedMultiSelect?

ⅰ亾dé卋堺 提交于 2020-01-06 01:07:07

问题


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

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!