Fix readline incorrect prompt size calculation

- Wrap ANSI escape codes to tell readline to ignore non-printing chars when
calculating the prompt size (Fixes command line text-wrapping)
- Use exact size calculation for uid symbol