Windows Vista Forums
Vista Forums Home Join Vista Forums Windows 7 Forum Vista Tutorials Tags
Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks.

Go Back   Vista Forums > Misc Newsgroups > Avalon

Vista - How do I customize the look of the NavigationWindow?

 
 
Old 01-10-2006   #1 (permalink)
Philippe Lavoie


 
 

How do I customize the look of the NavigationWindow?

I'd like to know how to customize the look of the NavigationWindow.

I'd like to change the font color, the gradiant and also add a logo on
the top right of it.

Any leads are appreciated thanks.

Phil

My System SpecsSystem Spec
Old 01-10-2006   #2 (permalink)
Drew Marsh


 
 

Re: How do I customize the look of the NavigationWindow?

Philippe Lavoie wrote:

> I'd like to know how to customize the look of the NavigationWindow.
>
> I'd like to change the font color, the gradiant and also add a logo on
> the top right of it.
>
> Any leads are appreciated thanks.


You need to define a new Style that replaces the NavigationWindow chrome.
For example, this would remove the chrome altogether:

<Style x:Key="{x:Type NavigationWindow}" TargetType="{x:Type NavigationWindow}">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type NavigationWindow}">
<ContentPresenter ClipToBounds="True" Content="{TemplateBinding Window.Content}"
/>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>

So, with that simple definition as a starting point, you can now do whatever
you desire around that ContentPresenter to make it look however you like.
Keep in mind that you will need to provide your own navigation controls now.

What I find interesting, and maybe Microsoft can address this, is that, AFAIK,
there's no NavigateForward/Backward commands that you can just raise that
will cause the NavigationWindow to actually navigate. So this means you need
to hook event handlers to some UI elements and control the NavigationWindow
yourself. Maybe I just can't find them... I would expect the commands to
be fields off of NavigationWindow itself.

HTH,
Drew

___________________________________
Drew Marsh
Chief Software Architect
Mimeo.com, Inc. - http://www.mimeo.com
Weblog - http://blog.hackedbrain.com/


My System SpecsSystem Spec
Old 01-10-2006   #3 (permalink)
Drew Marsh


 
 

Re: How do I customize the look of the NavigationWindow?

I wrote:

> What I find interesting, and maybe Microsoft can address this, is
> that, AFAIK, there's no NavigateForward/Backward commands that you can
> just raise that will cause the NavigationWindow to actually navigate.
> So this means you need to hook event handlers to some UI elements and
> control the NavigationWindow yourself. Maybe I just can't find them...
> I would expect the commands to be fields off of NavigationWindow
> itself.


I had thought I searched for this also, but it turns out there is a NavigationCommands
class inside System.Windows.Input that contains the commands I was thinking
of. So if you just bind the command to your custom buttons in your template
it should "just work".

HTH,
Drew


My System SpecsSystem Spec
 

« Sparkle? | Dock »
Thread Tools


Similar Threads
Thread Forum
How do I customize? General Discussion


Vista Forums is an independent web site and has not been authorized,
sponsored, or otherwise approved by Microsoft Corporation.
"Windows Vista", the Start Orb, and related materials are trademarks of Microsoft Corp.
© Designer Media Ltd

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46