Fix alpha mode that broke with the expr addition
Rearrange some utility functions (to the top)