Reputation:
I'd like to know if there is a way to reserve space for a vertical scrollbar in a grid panel with ExtJS 4.1.1. I remember that I was able to do this with ExtJS 3, but maybe this feature was removed?
The grid has a fixed height so a scrollbar appears when the amount of rows exceeds the height of the grid. There is also a "delete" action that allows to remove each row one by one. The problem is that the action moves to the right when the scrollbar is not required anymore. This is the behaviour I'd like to avoid.
Upvotes: 1
Views: 9261
Reputation: 2785
I think you're looking for reserveScrollbar
http://docs.sencha.com/extjs/4.2.1/#!/api/Ext.layout.container.Auto-cfg-reserveScrollbar
Upvotes: 1
Reputation: 4405
Add overflowY: 'scroll'
as a config param for your grid. See docs here: http://docs.sencha.com/extjs/4.2.1/#!/api/Ext.Component-cfg-overflowY.
Upvotes: 0