Ribbon contextual tab and docking:ToolWindow

Ribbon for WPF Forum

Posted 4 years ago by Stephane Franiatte
Version: 14.2.0611
Avatar

Hi,

I was wondering, what would be the way to go to have a Ribbon contextual tab to appear only when a particular docking:ToolWindow is active?

Thanks,

Stephane

Comments (4)

Posted 4 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar

Hi Stephane,

You would programmatically set the ContexutalTabGroup.IsActive property to true while the tab group should be visible (when the tool window is active) and back to false when another window becomes active.


Actipro Software Support

Posted 4 years ago by Stephane Franiatte
Avatar

Yes, of course, I know that. This is the easy part.

My question is:

how to link it to the activation of a given docking:ToolWindow? There is no IsActive in this control, for instance.

Posted 4 years ago by Michel Chami - Software Engineer, Safe Engineering Services & technologies ltd.
Avatar

I believe Stephane was referering more precisly to what to bind to the ContexutalTabGroup.IsActive Property and I was wondering the same thing.

Answer - Posted 4 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar

I believe you could watch the DockSite.LastActiveToolWindow property to know which is active.  There also is a DockSite.LastActiveToolWindowChanged event that you could handle to know when that property changes.


Actipro Software Support

The latest build of this product (v2018.1 build 0675) was released 1 month ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.