How to format comments with one space between // and words?

旧街凉风 提交于 2020-06-16 04:02:19

问题


How to automatically format comments with one space between // and words? For example, selecting format in my editors should convert

//login to // login

public interface LoginService {
    //login // -> // login
    SysAdminDO login(LoginForm form);
}

回答1:


You are probably looking for the setting

Editor ~> Code Style ~> Java(language) ~> Code Generation

Or else you can alternatively use Comment with line comment shortcut

Just type a line and on that line use the shortcut. e.g.

String var;
I would make this a comment [Press the shortcut]
// I would make this a comment


来源:https://stackoverflow.com/questions/46397105/how-to-format-comments-with-one-space-between-and-words

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!