microsoft / PTVS

Python Tools for Visual Studio
https://aka.ms/PTVS
Apache License 2.0
2.52k stars 673 forks source link

Support inlay hints #7898

Closed StellaHuang95 closed 1 month ago

StellaHuang95 commented 1 month ago

fixes https://github.com/microsoft/PTVS/issues/7888

Added these 2 options with tooltips that allow users to enable inlay hints in PTVS. image

Tooltips: image

With inlay hints: image

Without inlay hints: image

This UI and behavior is now consistent with other languages that support inlay hints in VS such as typescript.

StellaHuang95 commented 1 month ago

/AzurePipelines run

azure-pipelines[bot] commented 1 month ago
Azure Pipelines successfully started running 1 pipeline(s).
AdamYoblick commented 1 month ago

These look great!

Just a couple of random questions:

  1. We're supposed to go through the VS UI review board whenever we add strings like these, even to options. I don't think it's a big deal, but we should be doing it in the future. For example, I can almost guarantee you it wasn't done for the option before the ones you added:

image

  1. For the two options you added, they have the same hotkey. Notice that the 'E' is underlined for both of them. That makes keyboard navigation not work correctly. Each option in a specific group should have a unique hotkey. For example, look at these two even though they both start with 'S':

image

  1. Can you please verify that the narrator works on the two options you added so we don't get hit with accessibility bugs for these?

Thank you!

StellaHuang95 commented 1 month ago

@AdamYoblick Didn't even know the hotkeys exist. How are they supposed to work? Is it like when I hit the letter on the keyboard it jumps to that option?

Sure I can have the UI board review the changes, do you know how to reach out to them?

AdamYoblick commented 1 month ago

@AdamYoblick Didn't even know the hotkeys exist. How are they supposed to work? Is it like when I hit the letter on the keyboard it jumps to that option?

https://learn.microsoft.com/en-us/dotnet/desktop/winforms/controls/how-to-create-access-keys-for-windows-forms-controls?view=netframeworkdesktop-4.8

Sure I can have the UI board review the changes, do you know how to reach out to them?

From our onenote: https://microsoft.sharepoint.com/teams/python/_layouts/15/Doc.aspx?sourcedoc={30d33826-9f98-4d3e-890e-b7d198bbbcbe}&action=edit&wd=target%28Python%20VS%2FDev%20Docs.one%7Cd7206ce2-cf40-437b-8ce9-1e55f4bc2f44%2FSo%20you%20need%20to%E2%80%A6%7C35ffdcfc-33e1-4674-8118-1a9555f7ad91%2F%29&wdorigin=703

Scroll down to Make a change to Visual Studio UI (Tools -> Options, etc…)

StellaHuang95 commented 1 month ago
  1. Unique hotkeys So I've changed all the hotkeys to be unique and tested that the Alt + letter does act like user "clicks" the corresponding textbox/checkbox. image

  2. Accessibility support I have also tested the tooltips with both NVDA and JAWS, both narrators are reading the tooltips properly. Note that the other tooltips on this page currently lack support for screen readers, but I want this PR to focus on inlay hints so will address them separately.

  3. UXBoard Review Work item created at https://devdiv-design.visualstudio.com/D3%20Studio/_workitems/edit/17899

sonarcloud[bot] commented 1 month ago

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarCloud

StellaHuang95 commented 1 month ago

Done addressing feedback from UXBoard review:)