Mercurial > vim
comparison src/option.h @ 28765:38698deeda58 v8.2.4907
patch 8.2.4907: some users do not want a line comment always inserted
Commit: https://github.com/vim/vim/commit/2bf875f881f7c6f6900bc0eb2a93a552db894109
Author: Bram Moolenaar <Bram@vim.org>
Date: Sat May 7 14:54:11 2022 +0100
patch 8.2.4907: some users do not want a line comment always inserted
Problem: Some users do not want a line comment always inserted.
Solution: Add the '/' flag to 'formatoptions' to not repeat the comment
leader after a statement when using "o".
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sat, 07 May 2022 16:00:03 +0200 |
parents | 16bd027b039e |
children | d0241e74bfdb |
comparison
equal
deleted
inserted
replaced
28764:076c0d937e60 | 28765:38698deeda58 |
---|---|
139 // Formatting options for p_fo 'formatoptions' | 139 // Formatting options for p_fo 'formatoptions' |
140 #define FO_WRAP 't' | 140 #define FO_WRAP 't' |
141 #define FO_WRAP_COMS 'c' | 141 #define FO_WRAP_COMS 'c' |
142 #define FO_RET_COMS 'r' | 142 #define FO_RET_COMS 'r' |
143 #define FO_OPEN_COMS 'o' | 143 #define FO_OPEN_COMS 'o' |
144 #define FO_NO_OPEN_COMS '/' | |
144 #define FO_Q_COMS 'q' | 145 #define FO_Q_COMS 'q' |
145 #define FO_Q_NUMBER 'n' | 146 #define FO_Q_NUMBER 'n' |
146 #define FO_Q_SECOND '2' | 147 #define FO_Q_SECOND '2' |
147 #define FO_INS_VI 'v' | 148 #define FO_INS_VI 'v' |
148 #define FO_INS_LONG 'l' | 149 #define FO_INS_LONG 'l' |
157 #define FO_REMOVE_COMS 'j' // remove comment leaders when joining lines | 158 #define FO_REMOVE_COMS 'j' // remove comment leaders when joining lines |
158 #define FO_PERIOD_ABBR 'p' // don't break a single space after a period | 159 #define FO_PERIOD_ABBR 'p' // don't break a single space after a period |
159 | 160 |
160 #define DFLT_FO_VI "vt" | 161 #define DFLT_FO_VI "vt" |
161 #define DFLT_FO_VIM "tcq" | 162 #define DFLT_FO_VIM "tcq" |
162 #define FO_ALL "tcroq2vlb1mMBn,aw]jp" // for do_set() | 163 #define FO_ALL "tcro/q2vlb1mMBn,aw]jp" // for do_set() |
163 | 164 |
164 // characters for the p_cpo option: | 165 // characters for the p_cpo option: |
165 #define CPO_ALTREAD 'a' // ":read" sets alternate file name | 166 #define CPO_ALTREAD 'a' // ":read" sets alternate file name |
166 #define CPO_ALTWRITE 'A' // ":write" sets alternate file name | 167 #define CPO_ALTWRITE 'A' // ":write" sets alternate file name |
167 #define CPO_BAR 'b' // "\|" ends a mapping | 168 #define CPO_BAR 'b' // "\|" ends a mapping |
194 #define CPO_JOINCOL 'q' // with "3J" use column after first join | 195 #define CPO_JOINCOL 'q' // with "3J" use column after first join |
195 #define CPO_REDO 'r' | 196 #define CPO_REDO 'r' |
196 #define CPO_REMMARK 'R' // remove marks when filtering | 197 #define CPO_REMMARK 'R' // remove marks when filtering |
197 #define CPO_BUFOPT 's' | 198 #define CPO_BUFOPT 's' |
198 #define CPO_BUFOPTGLOB 'S' | 199 #define CPO_BUFOPTGLOB 'S' |
199 #define CPO_TAGPAT 't' | 200 #define CPO_TAGPAT 't' // tag pattern is used for "n" |
200 #define CPO_UNDO 'u' // "u" undoes itself | 201 #define CPO_UNDO 'u' // "u" undoes itself |
201 #define CPO_BACKSPACE 'v' // "v" keep deleted text | 202 #define CPO_BACKSPACE 'v' // "v" keep deleted text |
202 #define CPO_CW 'w' // "cw" only changes one blank | 203 #define CPO_CW 'w' // "cw" only changes one blank |
203 #define CPO_FWRITE 'W' // "w!" doesn't overwrite readonly files | 204 #define CPO_FWRITE 'W' // "w!" doesn't overwrite readonly files |
204 #define CPO_ESC 'x' | 205 #define CPO_ESC 'x' |