Lester's WPF\SL Blog


Simple, Easy & Beautiful


 

February, 2006

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

    Part II : Creating Non-Rectangular Splash Screen - using WPF

    • 5 Comments
    There was a delay in posting this and guess what - the reason was that the feature was not available in the Jan CTP bits. So I had to wait for the Feb CTP bits to be released. So here is how a simple flash screen could be implemented in WPF. void OnClick( object sender, RoutedEventArgs e) { HwndSourceParameters s = new HwndSourceParameters ( "visual" ); HwndSourceParameters param = new HwndSourceParameters ( "vis" , 200, 200); param.UsesPerPixelOpacity = true ; HwndSource hwndSource = new HwndSource (param); using (System.IO. Stream xamlStream = System.IO. File .OpenRead( "XamlPad_Saved.xaml" )) { hwndSource.RootVisual = XamlReader .Load(xamlStream) as Visual ; } ShowWindow(hwndSource.Handle, 5); } [ DllImport ( "user32.dll" , CharSet...
  • Lester's WPF\Silverlight Blog

    WPF Feb CTP now Available!! - Link to Migration tool

    • 0 Comments
    The download links are listed below: WinFX Runtime Components Windows SDK Visual Studio "Orcas" Preview - Development Tools for WinFX Visual Studio Extensions for Workflow Foundation WinFX Runtime Components Feb CTP Readme In order to migrate from Jan CTP to Feb CTP the following tool could be used http://robrelyea.com/tools/XamlMigrate/
  • Lester's WPF\Silverlight Blog

    WPF: Using LocBaml for Localization

    • 0 Comments
    Localizing an app is critical if the goal is to reach all the masses. This has been made easy in WPF through the use of the LocBaml tool and certain msbuild flags. Localization using LocBaml is explained on the msdn site http://windowssdk.msdn.microsoft.com/library/default.asp?url=/library/en-us/wcp_conceptual/html/5001227e-9326-48a4-9dcd-ba1b89ee6653.asp You can also see an example of how this works at http://www.devx.com/dotnet/Article/29407 The above example is on older bits but it does show how the process works and is very descriptive. ciao
  • Lester's WPF\Silverlight Blog

    Creating Non-Rectangular Splash Screen - using Alpha Channel

    • 0 Comments
    For one of my apps that I created and I will be posting that soon, I wanted to have a splash screen just like the common desktop apps have. So that began my quest for a non-rectangular window. Fortunately WPF does have the capability, but my first attempt was using a Win32 Form and it came out pretty well. It takes a 32 bit bitmap and displays it within a form. So depending on the shape of the image you have a window. So lets look at the code. class Splash : Form { public Splash(Bitmap bitmap) { // Window settings this .TopMost = true ; this .ShowInTaskbar = false ; this .Size = bitmap.Size; this .StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen; this .Show(); // Must be called before setting bitmap this .SelectBitmap(bitmap...
Page 1 of 1 (4 items)