-
Notifications
You must be signed in to change notification settings - Fork 1.4k
[Feature] Ribbon control #3259
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
Hello, 'XamDR! Thanks for submitting a new feature request. I've automatically added a vote 👍 reaction to help get things started. Other community members can vote to help us prioritize this feature in the future! |
Thanks @XamDR for the issue. I know there's been a revival of this discussion lately. I can sync more with the WinUI folks about this topic, I know they're busy with WinUI 3, so that's why not as many of the new control requests are getting funded at the moment. A port of the WPF one at least could be an interesting starting point though. 🤔 |
I started creating a Ribbon control for the WCT at yoshiask/UWPRibbon. If you're interested in helping build or test a potential Ribbon control, you should check it out! |
I wrote this comment on the WinUI Ribbon proposal, I hope it's of some use while we figure out what features we want for a UWP ribbon. microsoft/microsoft-ui-xaml#168 (comment) |
@yoshiask let's sync middle of next week sometime and see where you're at and where we should be heading. I think there's something we could do in this space, but we should make sure we're aligning with future design directions too. |
@misuo I did those in Photoshop - I'd do them in Figma today though |
The mockups by @mdtauk and @shaheedmalik and the Word version all seem like they can be achieved with a tab and menu bars. Is this something we need a full control for? |
Just a few reasons |
These three are huge. |
As I said at the beginning of my post, sure you can use a TabView with a Command/Menu bar, but that's just a workaround and not a real solution. On the other hand, I don't think I have anything to add to what @mdtauk wrote earlier. The last 3 reasons are important enough, IMO, to have a full Ribbon control. |
For anyone who may not have seen it yet: The build pipeline is currently broken, but once it's fixed you should be able to install a preview build of the Toolkit and test it out for yourself! |
Here's what it looks like so far. The default background brushes are based on the very last design that @mdtauk shared (they can be changed if the dev doesn't plan on extending into the title bar, but I suspect most who use this control will). |
@yoshiask the pipeline is fixed, if your CI builds properly in the CI then a package will drop on the new Preview Package feed. |
Has anyone tried using the TabbedCommandBar preview yet? I'd like to gauge which features/fixes are required for an initial release of this control in v7.0. I've attached where it currently stands with regard to the initial WinUI proposal. I intend to at least finish the drop-in styles for SplitButton and ToggleButton, but anything else would likely mean missing the 7.0 release. My question to you all is would you rather have a very limited ribbon in the next release, with continued updates later, or skip 7.0 and wait until it's more fleshed-out? |
@yoshiask You may want to keep an eye on this spec. |
In my opinion this initial version of the control is a good starting point to have a more feature complete Ribbon in the future, so I think it would be great to include it in the 7.0 release and to continue improving it in next versions of the toolkit. I also would like to contribute reporting any bugs or giving some suggestions while I use the control in one of my projects. |
@yoshiask does your implementation use a NavigationView? If so, was pivot considered as well? I'm testing out your pr and the current implementation doesn't seem as smooth as in my Nightingale app. And Nightingale just uses a pivot. |
@dpaulino I did consider using a Pivot, and early iterations of the control actually used one, but I ultimately decided not to use it because it's not very flexible. With a NavigationView, I can add tab footers and headers, easily change styles, hide the content, and customize animations. While possible with a Pivot, it'd be much more difficult, and near impossible for a full Ribbon control down the line. |
Also, could you expand on what made it feel less smooth? |
The pivot control definitely needs some upgrades, and this is another example of how dull, static, and inflexible it is to use. |
@yoshiask After looking into it more, it seems that So in other words, ignore what I said about it being less smooth 😛 It was just an artifact of the animation, and not necessarily an issue with the navigation view control. |
Ah, yeah, that's a styling bug I haven't figured out how to fix without ugly stuff in the codebehind. |
<!-- 🚨 Please Do Not skip any instructions and information mentioned below as they are all required and essential to evaluate and test the PR. By fulfilling all the required information you will be able to reduce the volume of questions and most likely help merge the PR faster 🚨 --> ## Fixes #3259 <!-- Add the relevant issue number after the "#" mentioned above (for ex: Fixes #1234) which will automatically close the issue once the PR is merged. --> <!-- Add a brief overview here of the feature/bug & fix. --> ## PR Type What kind of change does this PR introduce? <!-- Please uncomment one or more that apply to this PR. --> <!-- - Bugfix --> Feature <!-- - Code style update (formatting) --> <!-- - Refactoring (no functional changes, no api changes) --> <!-- - Build or CI related changes --> <!-- - Documentation content changes --> Sample app changes <!-- - Other... Please describe: --> ## What is the current behavior? There is no ribbon or ribbon-like control for UWP. The current solution is to put CommandBars inside of a Pivot. ## What is the new behavior? Adds a TabbedCommandBar, which internally is almost identical to the current solutions, but provides a much friendlier developer experience. ## PR Checklist Please check if your PR fulfills the following requirements: - [ ] Tested code with current [supported SDKs](../readme.md#supported) - [ ] Pull Request has been submitted to the documentation repository [instructions](..\contributing.md#docs). Link: MicrosoftDocs/WindowsCommunityToolkitDocs#405 - [ ] Sample in sample app has been added / updated (for bug fixes / features) - [x] Icon has been created (if new sample) following the [Thumbnail Style Guide and templates](https://github.com/windows-toolkit/WindowsCommunityToolkit-design-assets) - [ ] Tests for the changes have been added (for bug fixes / features) (if applicable) - [ ] Header has been added to all new source files (run *build/UpdateHeaders.bat*) - [x] Contains **NO** breaking changes <!-- If this PR contains a breaking change, please describe the impact and migration path for existing applications below. Please note that breaking changes are likely to be rejected within minor release cycles or held until major versions. --> ## Other information I forgot to do my work on a feature branch, so this PR is basically a duplicate of #3551, with a little bit of cleanup.
🦙❤ Woot! This is so exciting to see be part of our next release. It'll be in our upcoming preview too. Excited for folks to try this out! Thanks @yoshiask! |
Describe the problem this feature would solve
Nowadays there is no Ribbon control for UWP development, so in order to develop apps with a style similar to Office apps, one has to use workarounds like implement similar behavior with a TabView and/or a CommandBar. But this just make things more complicated than it should be.
Describe the solution
Therefore in order to make easier to develop Office style apps, a new Ribbon control should be added to the toolkit. I want to notice that this has also been proposed in the Windows UI Library GitHub repo, specifically in this issue, but there hasn't been updates on when this control will be implemented. On the other hand, the WCT has usually been a pioneer in adding new controls and APIs that eventually are ported to the Windows UI Library, so I think this could be a similar case.
I also want to notice that there is already a Ribbon control for WPF, so in order to have relatively easy migrations, the future Ribbon for UWP should have a similar API to the WPF one. For that matter, the source code of the WPF Ribbon control is available here.
Describe alternatives you've considered
Currently the only solution in order to have a true Ribbon control in UWP apps is actually to develop a WPF app and then add UWP controls through XAML islands. This is not ideal because there is always some issues when mixing different technologies. Even if the opposite would be true (i.e., add WPF controls to UWP apps, which is not possible as far as I know), the issues with interoperability would persists somehow.
Additional context & Screenshots
Here I'd like to share some screenshots:
The text was updated successfully, but these errors were encountered: