Skip to content
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

EditorConfig UI enhancements #53171

Closed
4 of 7 tasks
Youssef1313 opened this issue May 5, 2021 · 19 comments
Closed
4 of 7 tasks

EditorConfig UI enhancements #53171

Youssef1313 opened this issue May 5, 2021 · 19 comments

Comments

@Youssef1313
Copy link
Member

Youssef1313 commented May 5, 2021

  • 1. Font currently feels too large compared with other UI elements (e.g, solution explorer). Opened Update EditorConfig UI font size to be consistent with VS environment settings #54599 to fix that.

    image

  • 2. New line preferences has a typo (Carrage return should be Carriage return) and probably no need to have double \ before r or n. Being fixed in Fix typo: Carrage -> Carriage #53327

    image

  • 3. The grid columns should by default be expanded to fit the content if there is a space.

  • 4. "RemoveUnnecessaryImportsFixable" shouldn't probably exist on UI since it has "NotConfigurable" custom tag. (applies to IDE0005_gen as well)

    image

    Proposed fix is to add GetConfigurableDiagnosticDescriptors similar to GetNonCompilationEndDiagnosticDescriptors and call it here. (Disable severity combobox for non-configurable rules #53175)

  • 5. CA2016 is duplicated for some reason:

    image

  • 6. I'm not sure if the Category column is necessary, since the category is apparent from the parent node anyway. I also see that RS1023 is duplicated, so it seems like the previous point is general, wasn't specific to CA2016.

    image

  • 7. For some reason, I don't see any changes I make in UI in the actual .editorconfig text

Note: I was using Roslyn.sln while experimenting.

@dotnet-issue-labeler dotnet-issue-labeler bot added Area-IDE untriaged Issues and PRs which have not yet been triaged by a lead labels May 5, 2021
@Youssef1313 Youssef1313 changed the title EditorConfig UI font feels larger than it should be EditorConfig UI enhancements May 5, 2021
@Youssef1313
Copy link
Member Author

@jmarolf

@jmarolf jmarolf self-assigned this May 5, 2021
@jinujoseph jinujoseph added Concept-Continuous Improvement and removed untriaged Issues and PRs which have not yet been triaged by a lead labels May 5, 2021
@jinujoseph jinujoseph modified the milestones: 17.0, 16.10 May 5, 2021
@jinujoseph
Copy link
Contributor

cc @jmarolf
#2, #4, #5 could make it into 16.11
#7 is a priority bug if its reproducible

@jmarolf
Copy link
Contributor

jmarolf commented May 5, 2021

I'll investigate 7 today

@Youssef1313
Copy link
Member Author

I'll investigate 7 today

For reference, here are the steps I've done (I didn't have VS Preview on the machine I was working on - so I used main build):

  • Open Roslyn.sln using non-preview VS
  • Set build configuration to Release and set RoslynDeployment as startup project.
  • CTRL+F5 to start without debugging.
  • Opened Roslyn.sln in the second VS instance.
  • Opened .editorconfig by double clicking under Solution Items in Solution Explorer.

@jmarolf
Copy link
Contributor

jmarolf commented May 5, 2021

What specific items were not saved? or did literally nothing work?

@Youssef1313
Copy link
Member Author

@jmarolf What I have tried was changing a few severities from code style tab. Haven't tried something else.

@jmarolf
Copy link
Contributor

jmarolf commented May 5, 2021

Can you list the exact repo steps please? That would help a lot.

@Youssef1313
Copy link
Member Author

Is #53171 (comment) missing anything?

@jmarolf
Copy link
Contributor

jmarolf commented May 5, 2021

Which options? What did you set them to? how did you view the results? Did the editor mark the file as dirty or did nothing happen?

@Youssef1313
Copy link
Member Author

Youssef1313 commented May 5, 2021

@jmarolf I believe I have tried lots of options from code style tab with different values (so you could say it wasn't working at all for me when I tried). After modifying from UI, I attempted to save (while I could see there was no asterisk next to editorconfig file name - which means that no unsaved changes exists). Then, I did a git status to see if there are any changes to editorconfig, but there wasn't.

I'll check tomorrow if I could reproduce again.

Anything I can do if I was able to reproduce?

@jmarolf
Copy link
Contributor

jmarolf commented May 6, 2021

Looking into this today, it appears that a sequence of changes can cause the editor and the file buffer to get "out of sync". Unclear what the root cause is yet

@DotJoshJohnson
Copy link

I just ran into item 7 today. Fresh install of VS 2022, new project, new .editorconfig. I tried changing the "Namespace declarations" settings to "File scoped" and the underlying .editorconfig file was not changed.

@yodasad
Copy link

yodasad commented Nov 18, 2021

Yes, I ran into the item 7 too, fresh install of VS 2022, new project, new .editorconfig.

@Youssef1313
Copy link
Member Author

@jmarolf @jinujoseph Can this be prioritized?

@Sergio0694
Copy link
Contributor

I had the same issue the other day when I tried using the UI. Actually I could swear that in my case it not only not save the settings correctly, but it also kept resetting them back to some other values, seemingly at random. I just gave up and started editing the .editorconfig file manually after a bit 😅

@jmarolf jmarolf added User Story A single user-facing feature. Can be grouped under an epic. Epic Groups multiple user stories. Can be grouped under a theme. and removed User Story A single user-facing feature. Can be grouped under an epic. labels Dec 2, 2021
@jmarolf jmarolf added User Story A single user-facing feature. Can be grouped under an epic. and removed Epic Groups multiple user stories. Can be grouped under a theme. labels Dec 10, 2021
@Eli-Black-Work
Copy link

Ran into #7 with a fresh VS2022 install as well 🙂

@jmarolf jmarolf removed the User Story A single user-facing feature. Can be grouped under an epic. label Jan 6, 2022
@jmarolf jmarolf modified the milestones: 17.1, 17.2 Jan 11, 2022
@TheBeardedLlama
Copy link

Ran into point 7 too
VS2019 16.11.3

I was changing values in the Code Analyzers tab.
No asterisk to indicate values had changed and nothing happened when hitting save.
File remains the same as before.

@Nicholas-Westby
Copy link

I am also experiencing point 7 (editorconfig UI doesn't update the .editorconfig file). Here's the current commit I'm working with: https://github.com/rhythmagency/formulate/tree/48aa47296ad72477fef64f45899a3633054c1899

Here's the solution you can open: https://github.com/rhythmagency/formulate/blob/48aa47296ad72477fef64f45899a3633054c1899/src/Formulate.sln

Here's the editor config file: https://github.com/rhythmagency/formulate/blob/48aa47296ad72477fef64f45899a3633054c1899/src/.editorconfig

Here's a screenshot that shows the two items I attempted to change:

screenshot showing two highlighted editor config items

I tried CTRL+S, File Save, File Save As, and File Save All. None of them caused the file to be updated.

Note also that it shows the location as "Visual Studio Settings". At one point, that changed to list the path to the actual .editorconfig file in the solution, but I haven't been able to reproduce that again.

I'm using Visual Studio Professional 2022 64-bit version 17.0.4. I do not have Visual Studio 2019 installed (this is a pretty new machine). I'm using Windows 11. I think .Net 6 is installed and that .Net 5 is not installed. At least, I think when creating new projects in Visual Studio I'm only given .Net 6 as an option.

I was able to confirm that manually editing the .editorconfig file shows the file as updated in my Git GUI tool (SmartGit).

@jmarolf
Copy link
Contributor

jmarolf commented Mar 18, 2022

closing this in favor of tracking individual bugs

@jmarolf jmarolf closed this as completed Mar 18, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

10 participants