[FIX] (Legend Align) Two bugs in layout code that would cause misalignments.