xrdp-ng: refactor text drawing