Fix up enumeration mismatch issues

Fix up enumeration mismatch issues (CTLineBreakMode vs NSLineBreakMode), and use system function instead of rolling our own for NSTextAlignmentFromCTTextAlignment