Setting-->Editor-->margins and caret-->caret的color中设置:就可以了,这里附上我的参考连接点击打开链接
对了修改完以后,要把code blocks给关掉重新打开,否则设置是不起作用的。