Sync text with the Qt Viewer