Add Preserve function and simplify trailing whitespace commands