You are on page 1of 3

Event Aggregator

http://msdn.microsoft.com/en-us/library/ff647984.aspx
The EventAggregator service is primarily a container for events that allow decoupling of
publishers and subscribers so they can evolve independently. This decoupling is useful in
modularized applications because new modules can be added that respond to events defined
by the shell or, more likely, other modules.
In the Composite Application Library, EventAggregator allows subscribers or publishers to
locate a specific EventBase.
The EventAggregator class is offered as a service in the container and can be retrieved through
the IEventAggregator interface. The event aggregator is responsible for locating or building
events and for keeping a collection of the events in the system.

StaticResource
xmlns:Commands="clr-
namespace:Microsoft.Practices.Composite.Presentation.Commands;assembly=Microsoft.Practices.Composite.Presenta
tion"
<Window.Resources>
<Style x:Key="BigFontButtonStyle">
<Setter Property="Control.FontFamily" Value="Times New Roman" />
<Setter Property="Control.FontSize" Value="18" />
<Setter Property="Control.FontWeight" Value="Bold" />
</Style>
</Window.Resources>

This style object holds a Setters collection with three Setter objects, one for each property you
want to set.

http://windowsclient.net/wpf/white-papers/thenewiteration.aspx

The most significant areas where XAML exposes power to enhance the designer/developer
collaboration are styles, triggers, control templates, data templates, data binding, and
animation.

Styling is a proven technique to decouple content from its appearance. WPF not only supports
styles to be defined using XAML; but when you couple styles with triggers and templates, you
end up with more flexibility to create rich user interfaces while still keeping content separate
from its look and feel.

Data binding. In WPF, data binding is pervasive; because of XAML's extensibility, data binding is
accessible from markup (and from tools, like Expression Blend), making it easy for a designer to
wire basic bindings between user interface and business objects or XML data.
Animation. WPF has a very rich animation system that can be represented and triggered via
XAML; this enables a designer to create the interactions for user events - like a glow effect on a
button when mouse enters - without having to write any code.

You might also like