I encountered a problem when using FreeMarker as a view component for Spring MVC. Defining custom and properly configuring ObjectWrapper didn't work, all calls were still delegated to the default object wrapper. After analyzing both the code for Spring's FreeMarker integration and FreeMarker itself, I'm sure that this problem is caused by a bug in FreeMarker's AllHttpScopesHashModel.
The class AllHttpScopesHashModel should not contain a private field 'wrapper' containing the ObjectWrapper passed in the constructor. Instead, it should call 'setObjectWrapper(wrapper)' in the constructor and then all calls to 'wrapper.wrap(...)' should be replaced by 'getObjectWrapper().wrap(...)'. This will surely fix the whole problem.
(This bug is the same as 2938070, but I couldn't add a comment to it - I got strange error message about Group not set.)