Character#isAlphabetic is from Java 7, so duplicate logic here.