Added helper functions for checking current layout.