Updated layout and docref tool