I need to place tab control that should look like standard one:
Is there a style to apply to TabControl to make it look like ArcGIS Pro one?
I had the same task few months ago. As I know there is no style exposed to public, but you can make it by yourself. This is a listbox with separators and horizontal items placement. You can find some solutions on the internet. After you can tune your solution using WPF inspector or Snoop which lets you to look inside wpf based application UI. You can find font information, triggers and other useful information.
It would be nice to have exposed to public that listbox style for future compatibility.
Yes, I've inspected standard controls to see what styles ESRI use, but I hoped they expose this stuff for developers. Also I believe that should be TabControl with custom style instead of just ListBox with buttons with changing of main area on their clicks.
Anyway thank you!
I thought about TabControl too, but WPF inspector shows different:
I send you view of my work results with ListBox:
Stackoverflow.com rules ☺
Yes, I've implemented tab switchers as ListBox with custom items to mimic native ArcGIS Pro control. I hope Pro team will add this and other their controls to API.
As I recall there was an old sample on github that had a pane with the listbox panel selector code in it. Here is a link to the old file that had that code, you could try checking out that old branch and seeing it for yourself. I adapted that sample with some changes for my own controls and it did the trick.
Thanks. I've implemented tab switchers as ListBox with custom items using WPF Snoop to inspect ESRI styling.
With the ArcGIS Pro 2.2 release (to be released soon), a new ListBox style will be available that can be used to create the text items with the separators in between. You will be able to use this to get the same UI design as the Catalog pane in Pro.
I am testing ArcGIS Pro 2.3 Beta and new style does not work on it. It worked fine In previous version (2.2) Are changes in using new Esri_ListBoxPanelIndicator style?
The appearance for the tab control and the indicator has changed. When you run the Custom Catalog sample with 2.3, it looks like this (below) - which is different from 2.2. I made no code changes to the 2.2 sample, just ran it in 2.3 to see this. What do you see? Any errors?
Thanks for reply. Custom Catalog sample works like in your picture. I see that there is no vertical separator.
I have used my own usercontrol before 2.2 version. I have changed only my style to Esri_ListBoxPanelIndicator style in version 2.2 and it works fine. In 2.2 tabcontrol worked with simple IEnumerable which contained my own objects with tab information. As I understand it works now with List of TabControl items only.
Retrieving data ...