Files
zed/crates
Smit Barmase c8dac876af buffer: Fix broken auto indent when pasting code starting with new line (#28134)
Closes #26907

Currently, in case of new line to find delta, it is comparing old first
line indent with new second line indent. This results into incorrect
indentation. This PR fixes this delta calculation by passing correct
second line indent in that particular case.

- [X] Add Test

Before:


https://github.com/user-attachments/assets/065deba0-be19-4643-a784-d248a8e7c891

After:


https://github.com/user-attachments/assets/a0037043-4bd8-460f-b8ba-b7da7bdbe1ea

Release Notes:

- Fixed issue where pasting code starting with new line resulted
incorrect auto indent.
2025-04-05 22:18:02 -05:00
..
2025-04-05 22:17:56 -05:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-05 22:17:56 -05:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-05 22:17:56 -05:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-05 22:17:56 -05:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-05 22:17:56 -05:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-05 22:18:02 -05:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-05 22:18:02 -05:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00
2025-04-02 13:26:34 -07:00