extjs: fieldset- setting the style of expand/collapse icon while setting blank title for the fieldset comp

StackOverflow https://stackoverflow.com/questions/5881805

Question

I defined a fieldset while setting blank title. however, in browser, the fieldset has a expand/collapse icon in right-top corner, while i want have it in left-top corner? what I am supposed to do?

thanks!

Was it helpful?

Solution

You can get it on the left corner like any normal fieldset with a title with some trick. You can get what you need by using unicode for "Narrow No-Break Space". The unicode is U+202F. So in your code, you will have to set your title as:

title: '\u202F',

keep in mind that you cannot completely box the fieldset with this trick. Here is a small gap in the fieldset border on the right side of the collapse button. You could also use other unicode characters like \u200B,\u200C etc. But they all provided me with the same result.

You can get a more better result by removing the CSS style right-margin: 3px applied to the legned of fieldset. I haven't tried to do that though.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top