Docs / UI

Glossary: DefaultWindowTitleBar Style

The properties, methods and events of DefaultWindowTitleBar, in alphabetical order.

Color legend plain property dependency property method

The title bar every window starts with: a Background image filling the bar, a centered Title text and a CloseButton at the right. In a window it is DefaultSettings.DefaultWindowTitleThickness tall (30 units by default), and its close button is always 4 units smaller than that, square. The bar鈥檚 color comes from DefaultSettings.DefaultWindowTitleBarColor (see styles). Reach the parts through the window:

DefaultWindowTitleBar derives from BaseElement and has its members too. The layout page shows it in context, with code and screenshots.

Names are colored by what they are: a plain property, a method, an event or a dependency property, which a style, a binding or an animation can set.

Properties

Background 馃爢

Image 路 Read-only. The image that fills the bar and holds the title and the close button. Its BackgroundColor is the bar鈥檚 color.

CloseButton 馃爢

Button 路 Read-only. The close button at the right of the bar. It shows no text until you set its Text or Content. It is flat until the mouse is over it: its StyleOverride gives it a transparent NormalColor, so the button colors show only under the mouse and while it is pressed. Set its NormalColor to light it all the time.

OnCloseButtonClickAction 馃爢

Action 路 What a click on the close button does. In a window鈥檚 default title bar it is the window鈥檚 Hide.

Title 馃爢

Label 路 Read-only. The title text, centered in the bar. Set its Text and text style properties.

Methods

DefaultWindowTitleBar() 馃爢

DefaultWindowTitleBar(string name = null) 路 Creates a title bar, for example to use in a window of your own. Its close button does nothing until OnCloseButtonClickAction is set.

Parameter Type Description
name string The element鈥檚 Name, which GetElementByName finds it by. Default: null.