fixed text drawing bug #24