fix clipboard paste issue on linux, the clipboard behavior is not consistent on MacOSX and X window