Refactor and simplify ChatItem, implement full selection, use qreal where appropriate