restrict characters for word