Issue #5803: Fixed a bug about Layout background

Issue #5803: Fixed a bug about Layout background