Made check for (UI/NS)TextAlignment be an ifdef so that we supress the deprecation warnings