I saw the light WPF - Alexey Zakharov's Blog

Browse by Tags

All Tags » WPF (RSS)

A strange bug of Blend 4 RC by brainbox

We've been breaking our heads about a week because blend 4 RC stop showing visual states of controls in design view. Here is the simple blend projec t with single button style inside app.xaml. Could anybody see visual states changes of this button style...
Filed under: ,

Alternative Grid Layout for Silverlight suggestion by brainbox

I've proposed a suggestion to create alternative grid layout for Silverlight . Please vote for it if also faced the same problems. As i write before current Silverlight Grid Layout breakes best practices of HTML and Adobe Flex Grid layouts. Current defention...
Filed under: ,

Silverlight Grid Layout is pain by brainbox

I think one of the biggest mistake of Silverlight and WPF is its Grid layout. Imagine you have a data form with 2 columns and 5 rows. You need to place new row after the first one. As a result you need to rewrite Grid.Rows and Grid.Columns in all rows...
Filed under: , ,

Silverlight layout hack: Centered content with fixed maxwidth by brainbox

Today we need to create centered content with fixed maxwidth. It is very easy to implement it for fixed width, but is not clear how to achieve the same for maxwidth. The solution to the problem is Grid with 3 columns: <Grid> <Grid.ColumnDefenitions>...

Silverlight Commands Hacks: Passing EventArgs as CommandParameter to DelegateCommand triggered by EventTrigger by brainbox

Today I've tried to find a way how to pass EventArgs as CommandParameter to DelegateCommand triggered by EventTrigger. By reverse engineering of default InvokeCommandAction I find that blend team just ignores event args. To resolve this issue I have created...
Filed under: , , , ,

Connect ViewModel and View using Unity by brainbox

In this post i want to describe the approach of connecting View and ViewModel which I'm using in my last project. The main idea is to do it during resolve inside of unity container. It can be achived using InjectionFactory introduced in Unity 2.0 public...

Resharper live template for Dependency Properties by brainbox

Writing of Silverlight and WPF dependency properties is very annoying process. But with resharper live templates you can change the situation. Here you can download my version of such template and import to your resharper. Create dependency properties...

Blend Tip: How to remove gradient stop. by brainbox

It was a real headache for me to find how to remove gradient stop from the color slider. After 1 hour of mouse freestyling i found out that you can do it by dragging the stop down from the slider. =) No doubt this is lovely feature, but it is to hard...
Filed under: , ,
More Posts