implement text macros for new locale UI
import initial draft of locale UI function