reorder layout functionality initial commit (function defined)