编辑成不可编辑的就可以的setEditable(false);
既然用了setEnable方法,就不能再选中JTextField中内容了若要复制JTextField里的内容,应该用copy方法
setEditable(false)
jTextField.setEditable(false);