-
Notifications
You must be signed in to change notification settings - Fork 327
Request for assistance with line break issue and potential feature modification #6710
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
I doubt it is a new feature; I'm not aware of any work in that area. I'm curious why you would use LF instead of CRLF on Windows? That's likely to break any number of things. I think there is some hard-coded reliance on CRLF in the Dart plugin. However, the Flutter plugin doesn't do anything to control line breaks while typing. That's all done in the Dart plugin. There's a discussion about formatting in the Dart plugin issue tracker. Also, this issue has some potentially relevant info. |
@stevemessick Here is why we changed all our files to LF:
What kind of problems will we get with CRLF? What number of things that's likely to break? |
When you say this:
Sorry, but I don't know the difference between Flutter plugin and Dart plugin, could you explain it to me please? When you say Dart plugin, do you mean Just to be clear, suppose I have the IDE allowing 100 char lines, and this code:
If I put the cared after the word
If then I change my mind and remove the words
In other words, it did not go back to the previous text in a single line. Now I have an useless extra line. I don't think this is related to Please, help me. Who should I talk to so that I can turn this off? |
The Dart plugin was created by JetBrains shortly after the Dart language was announced. It helps with Dart programming, but knows nothing about Flutter. The Flutter plugin was created shortly after Flutter was started specifically to help with Flutter tasks. When you set up a new Android Studio or IntelliJ IDE to work with Flutter the first thing you do is install the Dart and Flutter plugins. The formatter I have not tried this, but I believe that you could disable the Flutter plugin, then create a pure-Dart project, and repeat the example you described. You should see the same behavior. There's a link to the Dart issue tracker in my previous comment. I don't know if there is a way to disable this behavior. You could check
I have not used Windows lately, so perhaps it has become more accepting of alternate line endings, but most programs used to handle non-standard line endings incorrectly. Back then, Macs used CR as line terminators. If I coped a file from Mac to Windows and opened it in an editor, it was unreadable because everything was printed on a single line. |
I just noticed today that while typing strings or comments in the editor, the code seems to break automatically during the editing process. This behavior appears to have started after I switched to using LF instead of CRLF on Windows. Or maybe it's a new feature just recently introduced, altogether?
The automatic line breaks can be quite challenging to work with, especially when I add and then need to delete something and the rest of the text doesn't return to its original position. The result is a half-full line that looks odd. I understand that the intention behind this feature might be to assist users, but it can be counterproductive in certain scenarios.
In addition, I'd like to have control over how my code is formatted, including when and where strings break. I appreciate any efforts to make the editing experience smoother, but it's essential to have the flexibility to format my code as I see fit.
Could you kindly let me know if there's an existing option in the settings to disable this feature? If there isn't, I'd like to request that this feature either be removed or modified to allow users to opt-out. Additionally, it would be beneficial for future features to include the option to enable or disable them, giving users more control over their editing experience.
Apologies if I've overlooked an existing opt-out setting related to this issue. Your guidance on this matter would be greatly appreciated.
Thank you.
The text was updated successfully, but these errors were encountered: