DotNetShoutout - Stories tagged with Attached behavior
3
Shouts

Automatically Showing ToolTips on a Trimmed TextBlock (Silverlight) | Colin Eberhardt's Adventures in WPF

published 867 days, 7 hours, 54 minutes ago posted by FantasticMrFishFantasticMrFish 869 days, 1 hour, 17 minutes ago
Saturday, January 08, 2011 1:43:30 AM GMT Thursday, January 06, 2011 8:20:33 AM GMT
Silverlight 4 added TextTrimming=”WordEllipsis”, which trims the text that a TextBlock displays based on the available width. This blog post describes a simple method for automatically showing the full text as a tooltip whenever the text is trimmed. This is presented as an attached behaviour. The TextTrimming feature of SL4 allows us to worry a little less about the layout of our applications, giving the option to use fixed widths when rendering text. This can be particularly useful if you have to loca... (more)
category: Metro | clicked: 0 | comment | | source: www.scottlogic.co.uk
tags: Attached behavior, Silverlight
6
Shouts

Developing a Lookless Silverlight Gauge Control (part 2) | Colin Eberhardt's Adventures in WPF

published 943 days, 21 hours, 49 minutes ago posted by FantasticMrFishFantasticMrFish 946 days, 12 hours, 57 minutes ago
Saturday, October 23, 2010 11:48:23 AM GMT Wednesday, October 20, 2010 8:40:26 PM GMT
In a previous blog post I described the process of creating a lookless gauge control. I introduced the concept of an attached view model which separates view specific concepts from the control. In this post I demonstrate how this allows for great flexibility when re-templating the control. In my previous post I described the development of a radial gauge control where I removed any view-specific logic and properties from the control by introducing an attached view model into the control’s template. My r... (more)
category: Metro | clicked: 0 | comment | | source: www.scottlogic.co.uk
tags: Attached behavior
7
Shouts

Developing a (very) Lookless Silverlight Radial Gauge Control | Colin Eberhardt's Adventures in WPF

published 1007 days, 15 hours, 54 minutes ago posted by FantasticMrFishFantasticMrFish 1008 days, 21 hours, 40 minutes ago
Friday, August 20, 2010 5:43:13 PM GMT Thursday, August 19, 2010 11:57:03 AM GMT
This blog post describes the development of a lookless radial gauge control. In this post I will explore the use of an attached view model in order to move view specific properties and logic out of the control code in order to give a truly lookless control. Today I had to get up far too early in order to catch an early morning flight to Copenhagen with a connection in Amsterdam. What to do for the six hours I would be travelling? Armed with a netbook and Visual Studio 2010 Express I thought it would be ... (more)
category: Metro | clicked: 0 | comment | | source: www.scottlogic.co.uk
tags: Attached behavior, MVVM
5
Shouts

Exposing and Binding to a Silverlight ScrollViewer’s Scrollbars | Colin Eberhardt's Adventures in WPF

published 1036 days, 18 hours, 40 minutes ago posted by FantasticMrFishFantasticMrFish 1037 days, 13 hours, 36 minutes ago
Thursday, July 22, 2010 2:57:55 PM GMT Wednesday, July 21, 2010 8:01:54 PM GMT
The Silverlight ScrollViewer exposes readonly properties which indicate the current vertical and horizontal scroll offset, and methods for setting the current offset. In this blog post I demonstrate a simple attached behaviour that exposes these offsets as read / write dependency properties allowing them to be bound to. The Silverlight ScrollViewer is a very useful control, if you have some content that is larger than the space available in your application, just sit it inside a ScrollViewer and it will... (more)
category: Metro | clicked: 2 | comment | | source: www.scottlogic.co.uk
tags: Attached behavior, Silverlight, scrollviewer
4
Shouts

Execute a command on a specified control when clicking on a button

published 1071 days, 20 hours, 1 minute ago posted by jmix90jmix90 1072 days, 20 hours, 3 minutes ago
Thursday, June 17, 2010 1:36:18 PM GMT Wednesday, June 16, 2010 1:34:47 PM GMT
Today another example of the powerful ramora pattern : execute a RoutedCommand on an Control when you click on a button outside of the aimed control scope. Our implementation will also show *how we can apply the "Weak Events pattern" with the dependency property trick *(attached property / ramora pattern). And of course this example can be adapted to subscribe on any event you wants and not only the click of a button. (more)
category: Smart Client | clicked: 4 | comment | | source: blog.lexique-du-net.com
tags: tricks, Command, Attached behavior, How-To, routed commands, Dependency Property, WPF, how to, Behavior, How, Tips, Tips & Tricks.