added support for both margin and scale