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

Updates to the CMake Tools Status Bar and Side Bar #3423

Open
sinemakinci1 opened this issue Nov 3, 2023 · 26 comments
Open

Updates to the CMake Tools Status Bar and Side Bar #3423

sinemakinci1 opened this issue Nov 3, 2023 · 26 comments
Assignees
Milestone

Comments

@sinemakinci1
Copy link
Contributor

sinemakinci1 commented Nov 3, 2023

Available now in the official 1.16.29 release, the CMake Tools extension UI has been updated to incorporate the feedback we have received from our users in our first experimental implementation, while taking into consideration customer requests to de-clutter the status bar. In that, we have provided a customizable UI, and more notification and docs to support the user through this change.

You should see this notification once you are updated to the new experience:
cmake notification

The status bar will now only contain commonly used CMake actions by default- Build, Debug, and Run.
cmake-new-status-bar

We have added options to the CMake Tools side bar for users to select their active Configure, Build, and Test Presets, kits and variants, and active targets. There are new options up at the top of the Project Status View for Deleting Cache and Reconfiguring and access CMake settings.
Both the new status bar and side bar are customizable, so you can configure your view across the status bar and side bar to add other options you may want to the status bar or exclude ones you don't need from the side bar.

To learn more about how you can customize this view, please see: our view configuration docs.

If you would like to opt-back to the previous side bar with all the available CMake options, please set the CMake Status Bar Visibility setting in the VS Code Settings to visible

cmake-visibility-v2

Please comment any feedback you have on this experience on this issue. Our goals are to add CMake tasks to the side bar in the near future.

@github-actions github-actions bot added the triage label Nov 3, 2023
@sinemakinci1 sinemakinci1 pinned this issue Nov 3, 2023
@benmcmorran benmcmorran added this to Triage in 1.16 via automation Nov 3, 2023
@benmcmorran benmcmorran added this to the 1.16 milestone Nov 3, 2023
@benmcmorran benmcmorran moved this from Triage to In progress in 1.16 Nov 3, 2023
@Zingam
Copy link
Contributor

Zingam commented Nov 4, 2023

It looks a bit ugly and confusing. I hope you continue improving on the new UI. The older status bar UI felt more intuitive.

@saierd
Copy link

saierd commented Nov 4, 2023

Thank you for keeping the status bar. This update was a much better experience than when the status bar suddenly disappeared last time :)

The new configurability of the status bar is really nice! I want to see some more things in it, but I can see how the new default configuration is cleaner for many people and the notification works well for the transition.

@snehara99
Copy link
Contributor

thanks for your feedback @Zingam, if you have any specific suggestions, we'd love to hear them as well. The UI is a work in progress, but something to note though is that our implementation of the VSCode Extension Tree View API for the sidebar limits us a bit in customizing its appearance. We may switch to a more flexible view in the future once the team has more bandwidth though.

@snehara99
Copy link
Contributor

thank you for your feedback @saierd! We tried not to make the transition as jarring this time haha. You mentioned that you would like to see more in the status bar configurability; would you mind sharing some of your ideas? Did you mean that you wish the default configuration of the status bar had more or that you wanted more configuration options?

@findNextStep
Copy link

how to disable this part
image
I try every option in json and cannt hidden it

@gcampbell-msft
Copy link
Collaborator

how to disable this part image I try every option in json and cannt hidden it

@snehara99 FYI

@snehara99
Copy link
Contributor

@findNextStep I apologize the "cmake.options.advanced" setting had a bug with the "variant" option. This should now be fixed in the 1.16.25 pre-release version of CMake Tools!

How to set that status bar option to be hidden:
"cmake.options.advanced": { "variant": { "statusBarVisibility": "hidden" } }

@quyykk
Copy link

quyykk commented Nov 9, 2023

I would like to see a bit more in the default status bar:

  • Switching build presets. It is common to switch between Debug/Release, so I think having that in the status bar makes sense.
  • The "Run CTest" button. Running tests is a pretty common thing to want to do I would say. (you could probably just add the icon and drop the text though)
  • Switching test presets. Switching test presets is also a pretty common thing to do, at least in my workflow.

Thoughts?

@sinemakinci1
Copy link
Contributor Author

I would like to see a bit more in the default status bar:

  • Switching build presets. It is common to switch between Debug/Release, so I think having that in the status bar makes sense.
  • The "Run CTest" button. Running tests is a pretty common thing to want to do I would say. (you could probably just add the icon and drop the text though)
  • Switching test presets. Switching test presets is also a pretty common thing to do, at least in my workflow.

Thoughts?

Thank you for your feedback - we chose our historically most commonly performed actions to put in the status bar by default which were Build, Debug, and Launch to keep the integrity of a simplified status bar but appreciate the verbal feedback on your workflows. You can configure the status bar to have all of these by default via your settings.json for now and we can take these thoughts into consideration in future designs.

@findNextStep
Copy link

@findNextStep I apologize the "cmake.options.advanced" setting had a bug with the "variant" option. This should now be fixed in the 1.16.25 pre-release version of CMake Tools!

How to set that status bar option to be hidden: "cmake.options.advanced": { "variant": { "statusBarVisibility": "hidden" } }

update to 1.16.26 and it work fine ! thx

@Zingam
Copy link
Contributor

Zingam commented Nov 13, 2023

Thank you for keeping the status bar. This update was a much better experience than when the status bar suddenly disappeared last time :)

The new configurability of the status bar is really nice! I want to see some more things in it, but I can see how the new default configuration is cleaner for many people and the notification works well for the transition.

Thank you for the work. It is definitely a step in the right direction and an a improvement but as I said before the UI is confusing because of that tree view and it wasn't clear to me what I saw before I saw the message warning about the new side bar implementation. Instead of a tree view something like a standard toolbar would be preferable or a widget panel similar to Visual Studio.

@tonygould
Copy link

For me, seeing the configure preset in full is essential as I often switch compilers and need to see which one I'm in. However I'd welcome the ability to have everything else as an icon; in particular the build and test presets aren't important. I can't see a way to do this via advanced options, or am I missing something?

@sinemakinci1
Copy link
Contributor Author

@tonygould You can set any setting you want to be an icon via the "statusBarVisibility" variable for that respective setting. i.e.

        "buildPreset": { 
            "statusBarVisibility": "icon", 
        }

That being said, some of these features don't have icons (Configure, Build Target, Launch Target).

@tonygould
Copy link

tonygould commented Nov 17, 2023

@tonygould You can set any setting you want to be an icon via the "statusBarVisibility" variable for that respective setting. i.e.

        "buildPreset": { 
            "statusBarVisibility": "icon", 
        }

That being said, some of these features don't have icons (Configure, Build Target, Launch Target).

Perfect, thanks for the help.

Edit in case it helps anyone, I have:

  "cmake.options.statusBarVisibility": "visible",
  "cmake.showOptionsMovedNotification": false,
  "cmake.options.advanced": {
    "buildPreset": {
      "statusBarVisibility": "icon"
    },
    "testPreset": {
      "statusBarVisibility": "icon"
    },
    "build": {
      "statusBarVisibility": "icon"
    },
    "debug": {
      "statusBarVisibility": "icon"
    }
  },

@jhuels
Copy link

jhuels commented Nov 17, 2023

You can configure the status bar to have all of these by default via your settings.json

sinemakinci1, Can you point to the documentation for these settings? Not seeing anything in docs/cmake-settings.md.

EDIT: Nevermind I found it in a different doc here: https://github.com/microsoft/vscode-cmake-tools/blob/main/docs/cmake-options-configuration.md

@Zingam
Copy link
Contributor

Zingam commented Nov 20, 2023

In my project I have one folder and no Test Presets. Also I don't think that Debug and Launch makes sense without a launch.json settings file. Can unnecessary elements be hidden on the side bar?

@sinemakinci1
Copy link
Contributor Author

@Zingam You can hide any unnecessary elements from the side bar per the view configuration docs through their parent node setting and setting "projectStatusVisibility" to "hidden".
i.e. what I believe you are asking for is:

        "folder": { 
            "projectStatusVisibility": "hidden" 
        },
        "ctest": { 
            "projectStatusVisibility": "hidden" 
        }

Launch will launch the build target in a terminal, so it doesn't need a launch.json setting file.

@gcampbell-msft gcampbell-msft removed this from In progress in 1.16 Nov 20, 2023
@gcampbell-msft gcampbell-msft added this to the On Deck milestone Nov 29, 2023
@misner5
Copy link

misner5 commented Jan 5, 2024

Just a quick comment - I'm a daily user of VSCode and CMake Tools and am grateful your team has put lots of work into making a great coding environment.

However we are struggling with this change and wanted to point out the changes make it hard to switch between Debug & Release mode. We setup tons of test servers and this change increases the time and cognitive load to setup a dev environment. It adds to our training time for new members of the team as well, and means there is more obscure customization to get a basic setup.

I recommend you set "Status Bar Visibility" to visible by default... it is confusing to have it hidden. Switching Debug & Release is fundamental to C/C++ dev with CMake Tools and should be part of the default setup.

@xgdgsc
Copy link
Contributor

xgdgsc commented Jan 8, 2024

I also think visible should be the default. You said you want to "de-clutter". But searching for clutter only finds one issue #2657 with no votes. So I guess there isn' t actually any "clutter" for most people with sane dev machine / reasonable sized monitor. Or maybe you' ve seen other complaint sources that view these basic functionality as "clutter"? I personally have hundreds of extensions installed and uses multiple languages inside projects on a daily basis and don' t find it any clutter. I' d say clicking on sidebar and then the small edit button is more clutter than directly clicking on big status bar button.

@troberti
Copy link

I also find the hidden status bar to be less usable, and switched back to compact. I never use the "Run and Debug" sidebar, because that requires a launch.json file, which is cumbersome. The status bar is much more convenient and requires no additional configuration. The only thing that I found strange in the status bar is that the build and run target are specified independently. This does add extra 'clutter' as a target shows up twice.

@sinemakinci1
Copy link
Contributor Author

@xgdgsc Thank you for your feedback, there has been other feedback we've received that isn't using the exact wording of "clutter", but commenting on how much of the status bar was taken up by CMake Tools. Additionally, it can be argued that it is a good practice to put commonly used actions on the status bar and put anything else in an extension-specific side bar as some other extensions do, especially since the status bar is a shared space. This implementation was our best attempt at consolidating all levels of customer feedback and providing user flexibility. However, we really appreciate your feedback on your workflow and will take into consideration with the team!

@sinemakinci1
Copy link
Contributor Author

@misner5 That definitely makes sense, thank you for bringing this up! I opened an issue to track this request: #3555. The main concern with bringing out one level of presets is users may not know to go to the side bar for their other presets or it may create a disjointed workflow, but this seems like a valid request.

@sinemakinci1
Copy link
Contributor Author

@troberti Thank you for your feedback! Actually, better integrating with the "Run and Debug" sidebar is one of our open work items (#3380), but I do understand the need for the status bar specific run and debugs, which were left there to avoid need to go to the CMake side bar. But, again, appreciate the feedback on preferring the compact workflow and will take into consideration with the team with future implementations!

@H-G-Hristov
Copy link

If I change the build target in the side bar how do I re-select [Targets in Preset] again?

@sinemakinci1
Copy link
Contributor Author

@H-G-Hristov I don't think this functionality exists right now without resetting the entire extension, I opened a bug to look into this! #3587

@mrexodia
Copy link

I am trying to set up a workshop using GitHub Codespaces (dev containers) and it is majorly confusing that this 'Configure CMake Options Visibility' dialog pops up. I tried adding the following to my settings.json, but it complains that this is a user setting:

"cmake.showOptionsMovedNotification": false,

Is there a way to prevent this popup in dev containers or settings.json? I already had the cmake.options.statusBarVisibility option set to hidden, but it still pops up this warning...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: To Do
Development

No branches or pull requests