summaryrefslogtreecommitdiff
path: root/src/textformat.c
Commit message (Collapse)AuthorAgeFilesLines
* patch 9.0.1245: code is indented more than necessaryv9.0.1245Yegappan Lakshmanan2023-01-251-18/+18
| | | | | | Problem: Code is indented more than necessary. Solution: Use an early return where it makes sense. (Yegappan Lakshmanan, closes #11879)
* patch 9.0.1236: code in same_leader() can be simplifiedv9.0.1236zeertzjq2023-01-231-8/+1
| | | | | Problem: Code in same_leader() can be simplified. Solution: Simplify code that is executed only once. (closes #11867)
* patch 9.0.1225: reading past the end of a line when formatting textv9.0.1225Bram Moolenaar2023-01-211-1/+9
| | | | | Problem: Reading past the end of a line when formatting text. Solution: Check for not going over the end of the line.
* patch 9.0.0657: too many #ifdefsv9.0.0657Martin Tournoij2022-10-041-2/+0
| | | | | | Problem: Too many #ifdefs. Solution: Graduate the +cmdwin feature. Now the tiny and small builds are equal, drop the small build. (Martin Tournoij, closes #11268)
* patch 9.0.0634: evaluating "expr" options has more overhead than neededv9.0.0634Bram Moolenaar2022-10-011-1/+1
| | | | | | | Problem: Evaluating "expr" options has more overhead than needed. Solution: Use call_simple_func() for 'foldtext', 'includeexpr', 'printexpr', "expr" of 'spellsuggest', 'diffexpr', 'patchexpr', 'balloonexpr', 'formatexpr', 'indentexpr' and 'charconvert'.
* patch 9.0.0206: redraw flags are not named specificallyv9.0.0206Bram Moolenaar2022-08-141-3/+3
| | | | | Problem: Redraw flags are not named specifically. Solution: Prefix "UPD_" to the flags, for UPDate_screen().
* patch 9.0.0170: various minor code formatting issuesv9.0.0170Bram Moolenaar2022-08-081-1/+1
| | | | | Problem: Various minor code formatting issues. Solution: Improve code formatting.
* patch 9.0.0044: typos in comments, wrapping linesv9.0.0044Bram Moolenaar2022-07-061-1/+1
| | | | | Problem: Typos in comments, wrapping lines. Solution: Adjust comments. Wrap lines.
* patch 8.2.5013: after text formatting cursor may be in an invalid positionv8.2.5013Bram Moolenaar2022-05-241-0/+3
| | | | | Problem: After text formatting the cursor may be in an invalid position. Solution: Correct the cursor position after formatting.
* patch 8.2.5008: when 'formatoptions' contains "/" wrongly wrapping commentv8.2.5008Bram Moolenaar2022-05-231-0/+1
| | | | | | Problem: When 'formatoptions' contains "/" wrongly wrapping a long trailing comment. Solution: Pass the OPENLINE_FORMAT flag.
* patch 8.2.4993: smart/C/lisp indenting is optionalv8.2.4993Bram Moolenaar2022-05-211-12/+1
| | | | | | Problem: smart/C/lisp indenting is optional, which makes the code more complex, while it only reduces the executable size a bit. Solution: Graduate FEAT_CINDENT, FEAT_SMARTINDENT and FEAT_LISP.
* patch 8.2.4928: various white space and cosmetic mistakesv8.2.4928Bram Moolenaar2022-05-091-1/+1
| | | | | Problem: Various white space and cosmetic mistakes. Solution: Change spaces to tabs, improve comments.
* patch 8.2.4911: the mode #defines are not clearly namedv8.2.4911Bram Moolenaar2022-05-071-5/+5
| | | | | Problem: The mode #defines are not clearly named. Solution: Prepend MODE_. Renumber them to put the mapped modes first.
* patch 8.2.4908: no text formatting for // comment after a statementv8.2.4908Bram Moolenaar2022-05-071-1/+21
| | | | | Problem: No text formatting for // comment after a statement. Solution: format a comment when the 'c' flag is in 'formatoptions'.
* patch 8.2.4183: cannot use an import in 'formatexpr'v8.2.4183Bram Moolenaar2022-01-221-0/+3
| | | | | Problem: Cannot use an import in 'formatexpr'. Solution: Set the script context when evaluating 'formatexpr'.
* patch 8.2.3932: C line comment not formatted properlyv8.2.3932Bram Moolenaar2021-12-291-2/+11
| | | | | | Problem: C line comment not formatted properly. Solution: If a line comment follows after "#if" the next line is not the end of a paragraph.
* patch 8.2.3914: various spelling mistakes in commentsv8.2.3914Dominique Pelle2021-12-271-1/+1
| | | | | Problem: Various spelling mistakes in comments. Solution: Fix the mistakes. (Dominique Pellé, closes #9416)
* patch 8.2.3787: no proper formatting of a C line comment after a statementv8.2.3787Bram Moolenaar2021-12-121-1/+8
| | | | | | Problem: No proper formatting of a C line comment after a statement. Solution: Find the start of the line comment, insert the comment leader and indent the comment properly.
* patch 8.2.3754: undesired changing of the indent of the first formatted linev8.2.3754Bram Moolenaar2021-12-061-2/+8
| | | | | Problem: Undesired changing of the indent of the first formatted line. Solution: Do not indent the first formatted line.
* patch 8.2.3615: wrong indent in first line if re-formatting with indent exprv8.2.3615Christian Brabandt2021-11-181-1/+24
| | | | | | | Problem: When re-formatting with an indent expression the first line of a paragraph may get the wrong indent. (Martin F. Krafft) Solution: Apply the correct indenting function for the first line. (Christian Brabandt, closes #9150, closes #9056)
* patch 8.2.1898: command modifier parsing always uses global cmdmodv8.2.1898Bram Moolenaar2020-10-241-2/+2
| | | | | Problem: Command modifier parsing always uses global cmdmod. Solution: Pass in cmdmod_T to use. Rename struct fields consistently.
* patch 8.2.0901: formatting CJK text isn't optimalv8.2.0901Bram Moolenaar2020-06-041-7/+69
| | | | | Problem: Formatting CJK text isn't optimal. Solution: Properly break CJK lines. (closes #3875)
* patch 8.2.0674: some source files are too bigv8.2.0674Bram Moolenaar2020-05-011-0/+1088
Problem: Some source files are too big. Solution: Move text formatting functions to a new file. (Yegappan Lakshmanan, closes #6021)