diff options
| author | kobarity | 2023-04-20 22:55:29 +0900 |
|---|---|---|
| committer | Eli Zaretskii | 2023-04-22 12:30:25 +0300 |
| commit | 3badd2358d5f0af71887ee1cc9d39c2f312b6888 (patch) | |
| tree | b35ebdec3b37b59f7bc236c9407c326713ef7844 /lisp/progmodes/python.el | |
| parent | c14a41c24c8e0f37749a5bbd19f09cfeb857b26f (diff) | |
| download | emacs-3badd2358d5f0af71887ee1cc9d39c2f312b6888.tar.gz emacs-3badd2358d5f0af71887ee1cc9d39c2f312b6888.zip | |
Improve docstring of python-indent-def-block-scale
* lisp/progmodes/python.el (python-indent-def-block-scale): Improve
docstring. (Bug#62696)
Diffstat (limited to 'lisp/progmodes/python.el')
| -rw-r--r-- | lisp/progmodes/python.el | 25 |
1 files changed, 24 insertions, 1 deletions
diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el index 9ae95ecfc1c..5bb15c60956 100644 --- a/lisp/progmodes/python.el +++ b/lisp/progmodes/python.el | |||
| @@ -1265,7 +1265,30 @@ For NODE, OVERRIDE, START, END, and ARGS, see | |||
| 1265 | :type '(repeat symbol)) | 1265 | :type '(repeat symbol)) |
| 1266 | 1266 | ||
| 1267 | (defcustom python-indent-def-block-scale 2 | 1267 | (defcustom python-indent-def-block-scale 2 |
| 1268 | "Multiplier applied to indentation inside multi-line def blocks." | 1268 | "Multiplier applied to indentation inside multi-line blocks. |
| 1269 | The indentation in parens in the block header will be the current | ||
| 1270 | indentation plus `python-indent-offset' multiplied by this | ||
| 1271 | variable. For example, the arguments are indented as follows if | ||
| 1272 | this variable is 1: | ||
| 1273 | |||
| 1274 | def do_something( | ||
| 1275 | arg1, | ||
| 1276 | arg2): | ||
| 1277 | print('hello') | ||
| 1278 | |||
| 1279 | if this variable is 2 (default): | ||
| 1280 | |||
| 1281 | def do_something( | ||
| 1282 | arg1, | ||
| 1283 | arg2): | ||
| 1284 | print('hello') | ||
| 1285 | |||
| 1286 | This variable has an effect on all blocks, not just def block. | ||
| 1287 | This variable only works if the opening paren is not followed by | ||
| 1288 | non-whitespace characters on the same line. Modify | ||
| 1289 | `python-indent-block-paren-deeper' to customize the case where | ||
| 1290 | non-whitespace characters follow the opening paren on the same | ||
| 1291 | line." | ||
| 1269 | :version "26.1" | 1292 | :version "26.1" |
| 1270 | :type 'integer | 1293 | :type 'integer |
| 1271 | :safe 'natnump) | 1294 | :safe 'natnump) |