another try on fixing the cursor; finally fixed #24