Merge "Fix for the layout engine." into devel/master