Lester's WPF\SL Blog


Simple, Easy & Beautiful


 

August, 2006

Blog - Post Feedback Form(CAPTCHA)
  • Lester's WPF\Silverlight Blog

    Collapsing animation in WPF

    • 2 Comments
    its been some time since my last post.. so to get things going heres some simple animation code which collapses objects and the one above takes its place (something on the lines of tetrix :) ) .. the main part of this code is a small snippet which I came across some time ago (written by Bob Shogren) <EventTrigger RoutedEvent="Mouse.PreviewMouseDown"> <BeginStoryboard> <Storyboard> <DoubleAnimation Storyboard.TargetProperty = "Opacity" To = "0" BeginTime = "0:0:0" Duration = "0:0:2" /> <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty = "Visibility "> <DiscreteObjectKeyFrame KeyTime="0:0:2" Value="{x:Static Visibility.Collapsed}" /> </ObjectAnimationUsingKeyFrames> </Storyboard> </BeginStoryboard>...
  • Lester's WPF\Silverlight Blog

    Using WPF for creating gadgets/desktop apps

    • 2 Comments
    In the June CTP we have the AllowsTransparency property made available at the Window level. This takes away lot of pain from using HwndSources. It makes life a lot easeir since all that is needed is to set the properties: AllowsTransparency="true" Background="transparent" and WindowStyle="none". As in the case of HwndSource this would remove the title bar and to provide the drag functionality we would have to use a Thumb. I tried putting these new properties to good use by creating a simple gadget ( more of a desktop app) which is just eye candy :).... So its a rotating globe... which has a circular thumb for dragging it along and the ever so useful Close button. And yeah there is no minimized button; thats by design :) couldnt resist...
  • Lester's WPF\Silverlight Blog

    Maximizing window (with WindowStyle=None) considering Taskbar

    • 4 Comments
    Sainuu ... for people wondering what that is - its HI in Mongolian.. So here I am in Mongolia on my vacation and its going great... My blog will be neglected by me for the next couple of weeks..:) Ok now back to WPF.. One interesting problem that comes to mind is the Window occupying all screen space on Maximizing when the WindowStyle is set to None. So this means that even if we do have the taskbar visible the window would appear on top of that. This would not happen in the case of the normal window with the TitleBar. To get this scenario working, we would have to include a small piece of code ( by Josh Zana ) in the Window. public override void OnApplyTemplate() { System.IntPtr handle = (new WinInterop.WindowInteropHelper(this)).Handle;...
Page 1 of 1 (3 items)