<?xml version="1.0" encoding="utf-8"?>
<rss xmlns:atom="https://www.w3.org/2005/Atom" xmlns:sy="https://purl.org/rss/1.0/modules/syndication/" xmlns:dc="https://purl.org/dc/elements/1.1/" xmlns:content="https://purl.org/rss/1.0/modules/content/" xmlns:wfw="https://wellformedweb.org/CommentAPI/" xmlns:slash="https://purl.org/rss/1.0/modules/slash/"
  version="2.0">
  <channel>
    <title>WPF/E Developer Content</title>
    <atom:link
      href="https://docs.microsoft.com/archive/blogs/wpfedevcon/feed.xml"
      rel="self"
      type="application/rss+xml" />
    <link>https://docs.microsoft.com/archive/blogs/wpfedevcon/feed.xml</link>
    <description />
    <lastBuildDate>Wed, 17 Apr 2019 03:27:17 GMT</lastBuildDate>
    <language>en-US</language>
    <sy:updatePeriod>hourly</sy:updatePeriod>
    <sy:updateFrequency>1</sy:updateFrequency>
    <item>
      <title>We've Moved to a New Location</title>
      <link>https://docs.microsoft.com/archive/blogs/wpfedevcon/weve-moved-to-a-new-location</link>
      <pubDate>Sat, 05 May 2007 00:30:00 GMT</pubDate>
      <dc:creator><![CDATA[wpfedevcon]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/wpfedevcon/2007/05/05/weve-moved-to-a-new-location/</guid>
      <description><![CDATA[&nbsp;
With the release of Silverlight 1.0 Beta and Silverlight 1.1 Alpha, the WPF/E Developer...]]></description>
      <content:encoded><![CDATA[<P><IMG src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/02/42/09/92/Silverlight_lutw.png" original-url="https://blogs.msdn.com/photos/silverlightsdk/images/2420992/original.aspx" mce_src="https://blogs.msdn.com/photos/silverlightsdk/images/2420992/original.aspx">&nbsp;</P>
<P>With the release of Silverlight 1.0 Beta and Silverlight 1.1 Alpha, the WPF/E Developer Content blog is now the <A class="" title="Silverlight SDK" href="https://blogs.msdn.com/silverlight_sdk" mce_href="https://blogs.msdn.com/silverlight_sdk">Silverlight SDK</A> blog. Visit us at our new location!</P>
<P>Thanks,<BR><FONT face=Verdana color=#808080 size=1>Silverlight SDK Team</FONT></P>]]></content:encoded>
    </item>
    <item>
      <title>Uninstalling the old template after a VS 2005 SP1 upgrade.</title>
      <link>https://docs.microsoft.com/archive/blogs/wpfedevcon/uninstalling-the-old-template-after-a-vs-2005-sp1-upgrade</link>
      <pubDate>Thu, 08 Feb 2007 14:30:00 GMT</pubDate>
      <dc:creator><![CDATA[wpfedevcon]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/wpfedevcon/2007/02/08/uninstalling-the-old-template-after-a-vs-2005-sp1-upgrade/</guid>
      <description><![CDATA[The initial release of the WPF/E template did not consider Visual Studio 2005&nbsp;SP1 during the...]]></description>
      <content:encoded><![CDATA[<P>The initial release of the WPF/E template did not consider Visual Studio 2005&nbsp;SP1 during the install process and fails the prerequites when Web Application Projects is uninstalled for the SP1 installation. The SP1 upgrade changes how it installs Web Application Projects and breaks the registry key used to check the prerequisites. This is a problem if you've already gone through the time consuming trouble of installing SP1 and now&nbsp;can't uninstall the template. Here are some instructions on how to fix the issue.</P>
<P><STRONG>Note:</STRONG> You only need to do this if&nbsp;the following dialog appears during uninstall AFTER you've installed Visual Studio 2005 SP1. </P>
<P><IMG title="template uninstall error" alt="template uninstall error" src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/63/04/08/WAPerror.jpg" original-url="https://blogs.msdn.com/photos/wpfedevcon/images/1630408/original.aspx" mce_src="https://blogs.msdn.com/photos/wpfedevcon/images/1630408/original.aspx"></P>
<P mce_keep="true"><BR><BR>1) Add the following registry key (the attached reg file allows you to quickly add it):</P>
<P><SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Palatino Linotype','serif'; mso-fareast-font-family: Calibri; mso-fareast-theme-font: minor-latin; mso-bidi-font-family: 'Times New Roman'; mso-ansi-language: EN-US; mso-fareast-language: EN-US; mso-bidi-language: AR-SA">[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Installer\Products\E8032D1D4E8BAF1498CA286FB5A952A5]<BR>"ProductName"="Web Application Projects"</SPAN></P>
<P mce_keep="true">2) Uninstall "WPF/E Visual Studio 2005 Template CTP (Dec 2006)".</P>
<P mce_keep="true">3) Remove the registry key you added in Step 1.</P>
<P mce_keep="true">4) Install the new template available&nbsp;in the WPF/E CTP (Feb 2007) SDK.&nbsp;</P>
<P mce_keep="true"><SPAN style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Palatino Linotype','serif'; mso-fareast-font-family: Calibri; mso-fareast-theme-font: minor-latin; mso-bidi-font-family: 'Times New Roman'; mso-ansi-language: EN-US; mso-fareast-language: EN-US; mso-bidi-language: AR-SA"></SPAN>&nbsp;</P>
<p><a href="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/62/93/13/WAP.reg" original-url="https://blogs.msdn.com/cfs-file.ashx/__key/communityserver-components-postattachments/00-01-62-93-13/WAP.reg">WAP.reg</a></p>]]></content:encoded>
    </item>
    <item>
      <title>New API for the February WPF/E  CTP</title>
      <link>https://docs.microsoft.com/archive/blogs/wpfedevcon/new-api-for-the-february-wpfe-ctp</link>
      <pubDate>Mon, 05 Feb 2007 16:14:00 GMT</pubDate>
      <dc:creator><![CDATA[wpfedevcon]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/wpfedevcon/2007/02/05/new-api-for-the-february-wpfe-ctp/</guid>
      <description><![CDATA[&nbsp;
If you haven't already heard, the February CTP of WPF/E has been released (go here for more...]]></description>
      <content:encoded><![CDATA[<P mce_keep="true">&nbsp;</P>
<P>If you haven't already heard, the February CTP of WPF/E has been released (go <A href="https://msdn2.microsoft.com/en-us/asp.net/bb187358.aspx" mce_href="https://msdn2.microsoft.com/en-us/asp.net/bb187358.aspx">here</A> for more information). There are a number of sources detailing the new features added with this release, but I thought it would be worth while to list out all the new API. The API are grouped by object. The new objects and members are listed first, then the new API on existing objects are listed.</P>
<H3>New Objects</H3><A href="https://msdn2.microsoft.com/en-us/library/bb232870.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232870.aspx">Downloader Control</A> &nbsp;&nbsp; 
<TABLE class="" width="100%" border=1>
<TBODY>
<TR>
<TH class="" width="25%" bgColor=lightgrey><B>API</B></TH>
<TH class="" bgColor=lightgrey><B>Notes</B></TH></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232880.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232880.aspx">DownloadProgress Property</A></TD>
<TD class="">Gets a value that indicates the percentage of downloaded content.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232881.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232881.aspx">ResponseText Property</A></TD>
<TD class="">Gets a string representation of the downloaded data.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232882.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232882.aspx">Status Property</A></TD>
<TD class="">Gets the current status of the Downloader object request.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232883.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232883.aspx">StatusText Property</A></TD>
<TD class="">Gets the current status of the Downloader object request.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232884.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232884.aspx">URI Property</A></TD>
<TD class="">Gets the Uniform Resource Identifier (URI) of the download request.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232857.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232857.aspx">Abort Method</A></TD>
<TD class="">Cancels the downloader request and resets properties to their initial state.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232858.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232858.aspx">Open Method</A></TD>
<TD class="">Initializes the download request.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232859.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232859.aspx">Send Method</A></TD>
<TD class="">Executes a download request.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232848.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232848.aspx">Completed Event</A></TD>
<TD class="">Occurs when the state of the download request has changed.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232849.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232849.aspx">DownloadProgressChanged Event</A></TD>
<TD class="">Occurs while content is being downloaded during a download request.</TD></TR></TBODY></TABLE>(For more information on the Downloader control, see the <A href="https://msdn2.microsoft.com/en-us/library/bb232904.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232904.aspx">Using a Downloader Object</A> topic in the SDK.) 
<P mce_keep="true">&nbsp;</P><A href="https://msdn2.microsoft.com/en-us/library/bb232872.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232872.aspx">KeyboardEventArgs</A> &nbsp;&nbsp; 
<TABLE class="" width="100%" border=1>
<TBODY>
<TR>
<TH class="" width="25%" bgColor=lightgrey><B>API</B></TH>
<TH class="" bgColor=lightgrey><B>Notes</B></TH></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232885.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232885.aspx">Ctrl Property</A></TD>
<TD class="">Gets a value specifying whether the ctrl key was down when the event occurred.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232886.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232886.aspx">Key Property</A></TD>
<TD class="">Gets the keyboard key associated with the event.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232887.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232887.aspx">PlatformCodeKey Property</A></TD>
<TD class="">Gets a value representing the platform key associated with the event. </TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232889.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232889.aspx">Shift Property</A></TD>
<TD class="">Gets a value specifying whether the ctrl key was down when the event occurred.</TD></TR></TBODY></TABLE>(For more information on keyboard events, see the <A href="https://msdn2.microsoft.com/en-us/library/bb232905.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232905.aspx">WPF/E Keyboard Support</A> topic in the SDK.) 
<P mce_keep="true">&nbsp;</P><A href="https://msdn2.microsoft.com/en-us/library/bb232875.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232875.aspx">MouseEventArgs</A> 
<TABLE class="" width="100%" border=1>
<TBODY>
<TR>
<TH class="" width="25%" bgColor=lightgrey><B>API</B></TH>
<TH class="" bgColor=lightgrey><B>Notes</B></TH></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232891.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232891.aspx">Ctrl Property</A></TD>
<TD class="">Gets a value specifying whether the ctrl key was down when the event occurred.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232892.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232892.aspx">Shift Property</A></TD>
<TD class="">Gets a value specifying whether the Shift key was down when the event occurred.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232893.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232893.aspx">X Property</A></TD>
<TD class="">Gets the x-coordinates of the mouse pointer position relative to the root canvas.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232894.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232894.aspx">Y Property</A></TD>
<TD class="">Gets the y-coordinates of the mouse pointer position relative to the root canvas.</TD></TR></TBODY></TABLE>
<P mce_keep="true">&nbsp;</P>
<H3>New Enumeration Objects</H3>
<TABLE class="" width="100%" border=1>
<TBODY>
<TR>
<TD class="" width="25%"><A href="https://msdn2.microsoft.com/en-us/library/bb232871.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232871.aspx">Key</A></TD>
<TD class="">Specifies the portable key code that is not operating system-specific.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232873.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232873.aspx">MediaState</A></TD>
<TD class="">Defines the potential states of a MediaElement.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232874.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232874.aspx">MouseCursor</A></TD>
<TD class="">Specifies the image used to represent the mouse pointer. </TD></TR></TBODY></TABLE>
<P mce_keep="true">&nbsp;</P>
<H3>New API on existing objects</H3><A href="https://msdn2.microsoft.com/en-us/library/bb188406.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb188406.aspx">WPF/E Control</A> 
<TABLE class="" width="100%" border=1>
<TBODY>
<TR>
<TH class="" width="25%" bgColor=lightgrey><B>API</B></TH>
<TH class="" bgColor=lightgrey><B>Notes</B></TH></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb229206.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb229206.aspx">ActualHeight Property</A></TD>
<TD class="">Specifies the height of the rendering area of the WPF/E control.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb229693.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb229693.aspx">ActualWidth Property</A></TD>
<TD class="">Specifies the width of the rendering area of the WPF/E control.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb229694.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb229694.aspx">FullScreen Property</A></TD>
<TD class="">Determines whether the WPF/E control displays as a full-screen control.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb229695.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb229695.aspx">IsLoaded Property</A></TD>
<TD class="">Gets a value that indicates whether the WPF/E control is loaded.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232901.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232901.aspx">Version Property</A></TD>
<TD class="">https://msdn2.microsoft.com/en-us/library/bb232865.aspx</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232865.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232865.aspx">CreateFromXamlDownloader Method</A></TD>
<TD class="">Creates XAML content dynamically using downloader content.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232866.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232866.aspx">CreateObject Method</A></TD>
<TD class="">Creates a specified object and returns a reference to it.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb229205.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb229205.aspx">FullScreenChanged Event</A></TD>
<TD class="">Occurs whenever the FullScreen property of the WPF/E control changes.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb229691.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb229691.aspx">OnLoad Event</A></TD>
<TD class="">Occurs when the WPF/E control has loaded.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232856.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232856.aspx">OnResized Event</A></TD>
<TD class="">Occurs whenever the ActualHeight or ActualWidth property of the WPF/E control change.</TD></TR></TBODY></TABLE>(For more information on full screen, see the <A href="https://msdn2.microsoft.com/en-us/library/bb229696.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb229696.aspx">WPF/E Full Screen Support</A> topic in the SDK.) 
<P mce_keep="true">&nbsp;</P><A href="https://msdn2.microsoft.com/en-us/library/bb188312.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb188312.aspx">Canvas</A> (Note, these events are only available on the root canvas.) 
<TABLE class="" width="100%" border=1>
<TBODY>
<TR>
<TH class="" width="25%" bgColor=lightgrey><B>API</B></TH>
<TH class="" bgColor=lightgrey><B>Notes</B></TH></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232853.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232853.aspx">KeyDown Event</A></TD>
<TD class="">Occurs when the key is pressed while the content has focus.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232854.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232854.aspx">KeyUp Event</A></TD>
<TD class="">Occurs when the key is released while the control has focus.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232852.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232852.aspx">GotFocus Event</A></TD>
<TD class="">Occur when an object receives focus.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232855.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232855.aspx">LostFocus Event</A></TD>
<TD class="">Occurs when an object loses focus.</TD></TR></TBODY></TABLE>
<P mce_keep="true">&nbsp;</P><A href="https://msdn2.microsoft.com/en-us/library/bb188404.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb188404.aspx">UIElement</A> 
<TABLE class="" width="100%" border=1>
<TBODY>
<TR>
<TH class="" width="25%" bgColor=lightgrey><B>API</B></TH>
<TH class="" bgColor=lightgrey><B>Notes</B></TH></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232899.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232899.aspx">Cursor Property</A></TD>
<TD class="">Gets or sets the cursor that displays when the mouse pointer is over this element.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232860.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232860.aspx">AddEventListener Method</A></TD>
<TD class="">Registers an event listener on the event target object.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232863.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232863.aspx">RemoveEventListener Method</A></TD>
<TD class="">Unregisters an event listener on the event target object.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232861.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232861.aspx">GetHost Method</A></TD>
<TD class="">Gets a reference to the containing WPF/E control.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232862.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232862.aspx">GetParent Method</A></TD>
<TD class="">Gets the parent object of the calling object.</TD></TR></TBODY></TABLE>
<P mce_keep="true">&nbsp;</P><A href="https://msdn2.microsoft.com/en-us/library/bb188356.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb188356.aspx">MediaElement</A> 
<TABLE class="" width="100%" border=1>
<TBODY>
<TR>
<TH class="" width="25%" bgColor=lightgrey><B>API</B></TH>
<TH class="" bgColor=lightgrey><B>Notes</B></TH></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232890.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232890.aspx">CurrentState Property</A></TD>
<TD class="">Gets the status of the MediaElement.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb190677.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb190677.aspx">AutoPlay Property</A></TD>
<TD class="">Gets or sets a value indicating whether media will automatically begin playback when the Source property is set.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232864.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232864.aspx">SetSource Method</A></TD>
<TD class="">(NOTE: SetSource is also exposed on Image and ImageBrush) Sets the source value of an object with downloaded content.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232850.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232850.aspx">CurrentStateChanged Method</A></TD>
<TD class="">Occurs when the value of the CurrentState property changes.</TD></TR></TBODY></TABLE>(For more information on using audio and video in WPF/E, see the <A href="https://msdn2.microsoft.com/en-us/library/bb232903.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232903.aspx">Audio and Video Overview</A> in the SDK.) 
<P mce_keep="true">&nbsp;</P><A href="https://msdn2.microsoft.com/en-us/library/bb188394.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb188394.aspx">TextBlock</A> 
<TABLE class="" width="100%" border=1>
<TBODY>
<TR>
<TH class="" width="25%" bgColor=lightgrey><B>API</B></TH>
<TH class="" bgColor=lightgrey><B>Notes</B></TH></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232897.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232897.aspx">ActualHeight</A></TD>
<TD class="">Gets the rendered height of the TextBlock.</TD></TR>
<TR>
<TD class=""><A href="https://msdn2.microsoft.com/en-us/library/bb232898.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb232898.aspx">ActualWidth</A></TD>
<TD class="">Gets the rendered width of the TextBlock.</TD></TR></TBODY></TABLE>
<P mce_keep="true">&nbsp;</P><B>Collection Methods:</B><BR>Add, Clear, GetItem, Insert, Remove, and RemoveAt have been added to the following collection types: PathFigureCollection, GradientStopCollection, ColorKeyFrameCollection, DoubleKeyFrameCollection, PointKeyFrameCollection, PathSegmentCollection, TriggerCollection, TriggerActionCollection. 
<P>--Brian </P>]]></content:encoded>
    </item>
    <item>
      <title>WPF/E Drag and Drop: Coco's Dress Up Kit</title>
      <link>https://docs.microsoft.com/archive/blogs/wpfedevcon/wpfe-drag-and-drop-cocos-dress-up-kit</link>
      <pubDate>Mon, 05 Feb 2007 00:20:00 GMT</pubDate>
      <dc:creator><![CDATA[wpfedevcon]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/wpfedevcon/2007/02/05/wpfe-drag-and-drop-cocos-dress-up-kit/</guid>
      <description><![CDATA[Drag and drop is a very useful feature of interactive content. You can easily add drag and drop to...]]></description>
      <content:encoded><![CDATA[<!-- Begin blog posting -->
<P><FONT face=Verdana size=2>Drag and drop is a very useful feature of interactive content. You can easily add drag and drop to your WPF/E control by implementing simple event handlers on mouse events. This posting illustrates the use of drag and drop functionality in a creative WPF/E application.</FONT></P>
<P><FONT face=Verdana size=2>The Zip file (<FONT color=#808080><STRONG><A href="https://blogs.msdn.com/wpfedevcon/attachment/1600003.ashx" mce_href="https://blogs.msdn.com/wpfedevcon/attachment/1600003.ashx">CocoDressUpKit.zip</A></STRONG></FONT>) contains all the files used for this application. You can also view the WPF/E application at:<BR><BR>&nbsp;&nbsp;&nbsp; <A href="https://wpfesdk.members.winisp.net/samples/coco" mce_href="https://wpfesdk.members.winisp.net/samples/coco">https://wpfesdk.members.winisp.net/samples/coco</A></FONT></P>
<P><STRONG><FONT face=Verdana color=#004080 size=2>Using Drag and Drop in a WPF/E Control</FONT></STRONG><FONT face=Verdana size=2><BR>The <FONT color=#808080><B>Coco's Dress Up Kit </B></FONT>application allows you to&nbsp;drag and drop decorative objects from a panel onto an image:</FONT></P>
<P align=center><A href="https://wpfesdk.members.winisp.net/samples/coco" mce_href="https://wpfesdk.members.winisp.net/samples/coco"><IMG height=282 alt="click to run sample" src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/60/00/00/cocokit_01.png" original-url="https://blogs.msdn.com/photos/wpfedevcon/images/1600000/original.aspx" width=500 border=0 mce_src="https://blogs.msdn.com/photos/wpfedevcon/images/1600000/original.aspx"></A><BR><B><FONT face=Verdana size=1>Coco's Dress Up Kit</FONT></B></P>
<P><FONT face=Verdana size=2>Each decorative object that is on the panel is defined as a <B>Canvas</B> object, and provides event handlers for the mouse events: <B>MouseLeftButtonDown</B>, <B>MouseLeftButtonUp</B>, and <B>MouseMove</B>. Here is the XAML content definition for one of the purple ribbons:</FONT></P><FONT color=#0000ff size=2>
<P><FONT face="Courier New">&lt;</FONT></FONT><FONT face="Courier New"><FONT color=#800000 size=2>Canvas</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>x:Name</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>Ribbon_01</FONT><FONT size=2>"<BR>&nbsp; </FONT><FONT color=#ff0000 size=2>MouseLeftButtonDown</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>javascript:onMouseDown</FONT><FONT size=2>"<BR>&nbsp; </FONT><FONT color=#ff0000 size=2>MouseLeftButtonUp</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>javascript:onMouseUp</FONT><FONT size=2>"<BR>&nbsp; </FONT><FONT color=#ff0000 size=2>MouseMove</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>javascript:onMouseMove</FONT><FONT size=2>"<BR>&nbsp; </FONT><FONT color=#ff0000 size=2>Canvas.Top</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>440</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Canvas.Left</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>140</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt;<BR>&nbsp; &lt;</FONT><FONT color=#800000 size=2>Canvas.RenderTransform</FONT><FONT color=#0000ff size=2>&gt;<BR>&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>RotateTransform</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Angle</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>135</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> /&gt;<BR>&nbsp; &lt;/</FONT><FONT color=#800000 size=2>Canvas.RenderTransform</FONT><FONT color=#0000ff size=2>&gt;<BR>&nbsp; &lt;</FONT><FONT color=#800000 size=2>Polygon</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Points</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>0,0 100,30 100,0 0,30</FONT><FONT size=2>"<BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#ff0000 size=2>Fill</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>#c71585</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>/&gt;<BR>&nbsp; &lt;</FONT><FONT color=#800000 size=2>Ellipse</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Canvas.Left</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>35</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Canvas.Top</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>5</FONT><FONT size=2>"<BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#ff0000 size=2>Height</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>20</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Width</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>30</FONT><FONT size=2>"<BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#ff0000 size=2>Fill</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>#cf1f8f</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>/&gt;<BR>&lt;/</FONT><FONT color=#800000 size=2>Canvas</FONT></FONT><FONT color=#0000ff size=2><FONT face="Courier New">&gt;</FONT></P></FONT>
<P><FONT face=Verdana size=2>All decorative objects share the same three mouse event handlers, since the drag and drop functionality is implemented the same for all the objects.</FONT></P>
<TABLE class="" id=table1 width="100%" border=0>
<TBODY>
<TR>
<TD class="" width=20>&nbsp;</TD>
<TD class="" vAlign=top width=50><B><FONT face=Verdana color=#800000 size=2>Note: </FONT></B></TD>
<TD class="" width=400><FONT face=Verdana size=2>The <B>Canvas</B> object is used to group all the elements that make up a decorative object. This allows the whole group to act as a unit during drag and drop operations. Likewise, any <B>RenderTransform</B> applied to the <B>Canvas</B> object affects all the elements of the object.</FONT></TD></TR></TBODY></TABLE>
<P><STRONG><FONT face=Verdana color=#004080 size=2>Event Handlers for Drag and Drop Operations</FONT></STRONG><FONT face=Verdana size=2><BR>A drag and drop operation is a sequence of three steps:</FONT></P>
<UL>
<LI><FONT face=Verdana size=2><B><FONT color=#808080>Mouse Down</FONT></B>—the object is selected. The object must ensure it has exclusive access to all mouse events generated by the WPF/E control.</FONT></LI>
<LI><FONT face=Verdana size=2><B><FONT color=#808080>Mouse Move</FONT></B>—the object moves to a new position, relative to the current position of the mouse.</FONT></LI>
<LI><FONT face=Verdana size=2><B><FONT color=#808080>Mouse </FONT></B><FONT color=#808080><B>Up</B></FONT>—the object stops responding to mouse events.</FONT></LI></UL>
<P><FONT face=Verdana size=2>Let's look at how each of these steps is implemented in a WPF/E control. The <B><FONT color=#808080>onMouseDown</FONT></B> event handler in the eventhandler.js file initiates the drag and drop operation by storing the beginning position of the mouse, setting a flag to indicate the drag and drop operation is in effect, and gaining exclusive access to mouse events by invoking the <B><A href="https://msdn2.microsoft.com/en-us/library/bb190645.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb190645.aspx">CaptureMouse</A></B> method:</FONT></P><FONT color=#008000 size=2>
<P><FONT face="Courier New">// Start drag and drop operation.<BR></FONT></FONT><FONT face="Courier New"><FONT color=#0000ff size=2>function</FONT><FONT size=2> onMouseDown(sender, mouseEventArgs)<BR>{<BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#008000 size=2>// Set the beginning position of the mouse.<BR>&nbsp;&nbsp;&nbsp; </FONT><FONT size=2>beginX = mouseEventArgs.x;<BR>&nbsp;&nbsp;&nbsp; beginY = mouseEventArgs.y;<BR><BR>&nbsp;&nbsp;&nbsp; isMouseDown = </FONT><FONT color=#0000ff size=2>true</FONT><FONT size=2>;<BR>&nbsp;&nbsp;&nbsp; updateStatus(sender.name);<BR><BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#008000 size=2>// Ensure object receives all mouse events.<BR></FONT><FONT size=2>&nbsp;&nbsp;&nbsp; sender.captureMouse();<BR>}</FONT></FONT></P>
<P><FONT face=Verdana size=2>The <B><FONT color=#808080>onMouse</FONT></B><FONT color=#808080><B>Move</B></FONT> event handler in the eventhandler.js file determines whether the drag and drop operation is in effect by testing the value of the <B><FONT color=#808080>isMouseDown </FONT></B>variable. If the drag and drop operation is in effect, the incremental difference between the last stored mouse position and the current mouse position is applied to the object's <B><FONT color=#808080>Canvas.Top</FONT></B> and <B><FONT color=#808080>Canvas.Left</FONT></B> values:</FONT></P><FONT color=#008000 size=2>
<P><FONT face="Courier New">// Reposition object during drag and drop operation.<BR></FONT></FONT><FONT face="Courier New"><FONT color=#0000ff size=2>function</FONT><FONT size=2> onMouseMove(sender, mouseEventArgs)<BR>{<BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#008000 size=2>// Determine whether the mouse button is down.<BR>&nbsp;&nbsp;&nbsp; // If so, move the object.<BR>&nbsp; </FONT><FONT color=#0000ff size=2>&nbsp; if</FONT><FONT size=2> (isMouseDown == </FONT><FONT color=#0000ff size=2>true</FONT><FONT size=2>)<BR>&nbsp;&nbsp;&nbsp; {<BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#008000 size=2>&nbsp;&nbsp;&nbsp; // Retrieve the current position of the mouse.<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT><FONT color=#0000ff size=2>var</FONT></FONT><FONT size=2><FONT face="Courier New"> currX = mouseEventArgs.x;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></FONT><FONT face="Courier New" color=#0000ff size=2>var</FONT><FONT size=2><FONT face="Courier New"> currY = mouseEventArgs.y;<BR><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></FONT><FONT face="Courier New" color=#008000 size=2>// Reset the location of the object.<BR></FONT><FONT face="Courier New" size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; sender[</FONT><FONT face="Courier New" color=#800000 size=2>"Canvas.Left"</FONT><FONT face="Courier New" size=2>] += currX - beginX;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; sender[</FONT><FONT face="Courier New" color=#800000 size=2>"Canvas.Top"</FONT><FONT size=2><FONT face="Courier New">] += currY - beginY;<BR><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></FONT><FONT face="Courier New" color=#008000 size=2>// Update the beginning position of the mouse.<BR></FONT><FONT size=2><FONT face="Courier New">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; beginX = currX;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; beginY = currY;<BR>&nbsp;&nbsp;&nbsp; }<BR>}</FONT></P></FONT>
<P><FONT face=Verdana size=2>The <B><FONT color=#808080>onMouse</FONT></B><FONT color=#808080><B>Up</B></FONT> event handler in the eventhandler.js file stops the drag and drop operation by invoking the <B><A href="https://msdn2.microsoft.com/en-us/library/bb190646.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb190646.aspx">ReleaseMouseCapture</A></B> method on the object. This method releases the object's exclusive access to the WPF/E control's mouse events. This means that all objects can now receive mouse events:</FONT></P><FONT color=#008000 size=2>
<P><FONT face="Courier New">// Stop drag and drop operation.<BR></FONT></FONT><FONT face="Courier New"><FONT color=#0000ff size=2>function</FONT><FONT size=2> onMouseUp(sender, mouseEventArgs)<BR>{<BR>&nbsp;&nbsp;&nbsp; isMouseDown = </FONT><FONT color=#0000ff size=2>false</FONT><FONT size=2>;<BR>&nbsp;&nbsp;&nbsp; updateStatus(</FONT><FONT color=#800000 size=2>""</FONT><FONT size=2>);<BR><BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#008000 size=2>// Allow all objects to receive mouse events.<BR></FONT></FONT><FONT size=2><FONT face="Courier New">&nbsp;&nbsp;&nbsp; sender.releaseMouseCapture();<BR>}</FONT></P></FONT>
<P><FONT face=Verdana size=2><STRONG><FONT color=#004080>How Mouse Capture Enables Drag and Drop</FONT></STRONG><BR>The reason why all the decorative objects can share mouse event handlers is that each object enables mouse capture during the drag and drop operation. The end result is that when you drag an object, such as the sunglasses, no mouse events are sent to other objects. So when the sunglasses is dragged under the flower, the flower does not receive mouse events, even though the mouse cursor is directly over the flower:</FONT></P>
<P><IMG height=236 src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/60/06/73/cocokit_02.png" original-url="https://blogs.msdn.com/photos/wpfedevcon/images/1600673/original.aspx" width=423 border=0 mce_src="https://blogs.msdn.com/photos/wpfedevcon/images/1600673/original.aspx"><BR><B><FONT face=Verdana size=1>&nbsp;&nbsp; Dragging the sunglasses does not trigger mouse events for the flower</FONT></B></P>
<P><FONT face=Verdana size=2>Mouse capture also enables drag and drop operations when you move the mouse quickly. As long as mouse capture is enabled, the mouse cursor does not need to be exactly on the object being dragged. Eventually, the object being dragged will&nbsp;render under the mouse cursor.</FONT></P>
<P><FONT face=Verdana><FONT size=2>Enjoy,<BR>Lorin<BR></FONT><FONT color=#808080 size=1>WPF/E Developer Content Team</FONT></FONT><FONT face=Verdana color=#808080 size=1><BR></FONT><FONT face=Verdana size=2><BR>and my dog, Coco<BR><BR><IMG height=150 alt="Coco's signature" src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/60/05/59/cocokit_03.png" original-url="https://blogs.msdn.com/photos/wpfedevcon/images/1600559/original.aspx" width=150 border=0 mce_src="https://blogs.msdn.com/photos/wpfedevcon/images/1600559/original.aspx"><BR>&nbsp;</FONT></P><!-- End blog posting -->
<p><a href="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/60/00/03/CocoDressUpKit.zip" original-url="https://blogs.msdn.com/cfs-file.ashx/__key/communityserver-components-postattachments/00-01-60-00-03/CocoDressUpKit.zip">CocoDressUpKit.zip</a></p>]]></content:encoded>
    </item>
    <item>
      <title>WPF/E QuickStart Updated for the February 2007 CTP</title>
      <link>https://docs.microsoft.com/archive/blogs/wpfedevcon/wpfe-quickstart-updated-for-the-february-2007-ctp</link>
      <pubDate>Fri, 02 Feb 2007 17:40:00 GMT</pubDate>
      <dc:creator><![CDATA[wpfedevcon]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/wpfedevcon/2007/02/02/wpfe-quickstart-updated-for-the-february-2007-ctp/</guid>
      <description><![CDATA[We've updated the WPF/E QuickStart for the February 2007 CTP version of WPF/E. You can check it out...]]></description>
      <content:encoded><![CDATA[<P>We've updated the WPF/E QuickStart for the February 2007 CTP version of WPF/E. You can check it out at the following location: <A href="https://go.microsoft.com/fwlink/?LinkID=82158"><FONT face=Verdana>https://go.microsoft.com/fwlink/?LinkID=82158</FONT></A>. </P>
<P><A href="https://go.microsoft.com/fwlink/?LinkID=82158"><IMG title="WPF/E QuickStart" style="WIDTH: 506px; HEIGHT: 426px" height=509 alt="WPF/E QuickStart" src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/58/54/05/quickstart.jpg" original-url="https://blogs.msdn.com/photos/wpfedevcon/images/1585405/original.aspx" width=653 border=0 mce_src="https://blogs.msdn.com/photos/wpfedevcon/images/1585405/original.aspx"></A></P>
<P>~m jacobs</P>]]></content:encoded>
    </item>
    <item>
      <title>Use Transforms and Opacity Masks to Create a Reflection in WPF/E</title>
      <link>https://docs.microsoft.com/archive/blogs/wpfedevcon/use-transforms-and-opacity-masks-to-create-a-reflection-in-wpfe</link>
      <pubDate>Fri, 05 Jan 2007 11:15:00 GMT</pubDate>
      <dc:creator><![CDATA[wpfedevcon]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/wpfedevcon/2007/01/05/use-transforms-and-opacity-masks-to-create-a-reflection-in-wpfe/</guid>
      <description><![CDATA[Reflections&nbsp;are neat. You can use them&nbsp;to create the illusion of depth, transforming a...]]></description>
      <content:encoded><![CDATA[<P>Reflections&nbsp;are neat. You can use them&nbsp;to create the illusion of depth, transforming a plain white background into a sheet of glossy white glass. In this post, I'll walk you through the process of using a <A href="https://msdn2.microsoft.com/en-us/library/bb188382.aspx">ScaleTransform</A> and an <A href="https://msdn2.microsoft.com/en-us/library/bb188553.aspx">opacity mask</A> to create a reflection in WPF/E. </P>
<P>You'll create a reflection for the following image.</P>
<P><IMG alt="An image of a gear, all by itself." src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/40/72/36/gear_large.png" original-url="https://blogs.msdn.com/photos/wpfedevcon/images/1407236/original.aspx" mce_src="https://blogs.msdn.com/photos/wpfedevcon/images/1407236/original.aspx"></P>
<P>The following illustration shows the completed reflection.</P>
<P><IMG alt="It's that same gear again, but now it has an awesome reflection." src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/41/17/64/final_reflection.jpg" original-url="https://blogs.msdn.com/photos/wpfedevcon/images/1411764/original.aspx"></P>
<OL>
<LI>
<DIV mce_keep="true">Download the following zip file and extract it: <A href="https://blogs.msdn.com/wpfedevcon/attachment/1407255.ashx">reflection_examples.zip</A>. From the directory where you extracted the file, navigate to the <CODE>reflection_examples\reflection_example</CODE> subfolder. It contains four files: <CODE>aghost.js</CODE>, <CODE>gear_large.png</CODE>, <CODE>reflection.html</CODE>, and <CODE>reflection.xaml</CODE>. </DIV></LI>
<LI>
<DIV mce_keep="true">Open the file named <CODE>reflection.xaml</CODE>.&nbsp;It contains the following markup.</DIV>
<DIV style="PADDING-RIGHT: 2px; MARGIN-TOP: 5px; PADDING-LEFT: 2px; FONT-WEIGHT: bold; FONT-SIZE: 10pt; BACKGROUND: #dddddd; PADDING-BOTTOM: 2px; PADDING-TOP: 2px">XAML (reflection.xaml)</DIV>
<DIV style="PADDING-RIGHT: 2px; PADDING-LEFT: 2px; BACKGROUND: #eeeeee; PADDING-BOTTOM: 2px; PADDING-TOP: 2px; FONT-FAMILY: ': Courier New', Courier, monospace">
<P>&lt;<FONT color=#800000 size=2>Canvas</FONT><FONT color=#0000ff size=2> <BR>&nbsp; </FONT><FONT color=#ff0000 size=2>xmlns</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>https://schemas.microsoft.com/client/2007</FONT><FONT size=2>"<BR>&nbsp; </FONT><FONT color=#ff0000 size=2>xmlns:x</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>https://schemas.microsoft.com/winfx/2006/xaml</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt;<BR>&nbsp;&nbsp;<BR>&nbsp; &lt;!--</FONT><FONT color=#008000 size=2> The object to reflect. </FONT><FONT color=#0000ff size=2>--&gt;<BR>&nbsp; &lt;</FONT><FONT color=#800000 size=2>Image</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Source</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>gear_large.png</FONT><FONT size=2>"<BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#ff0000 size=2>Canvas.Left</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>75</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Canvas.Top</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>20</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt;<BR>&nbsp; &lt;/</FONT><FONT color=#800000 size=2>Image</FONT><FONT color=#0000ff size=2>&gt;<BR><BR>&lt;/</FONT><FONT color=#800000 size=2>Canvas</FONT><FONT color=#0000ff size=2>&gt;</FONT></P></DIV>
<P>To run the sample, open the file named <CODE>reflection.html</CODE> in a browser. You should see the following output.</P><IMG alt="A gear, without a reflection." src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/41/81/95/starting_gear.jpg" original-url="https://blogs.msdn.com/photos/wpfedevcon/images/1418195/original.aspx" border=1> </LI>
<LI>Create a duplicate image to serve as the reflection.</LI>
<DIV style="PADDING-RIGHT: 2px; MARGIN-TOP: 5px; PADDING-LEFT: 2px; FONT-WEIGHT: bold; FONT-SIZE: 10pt; BACKGROUND: #dddddd; PADDING-BOTTOM: 2px; PADDING-TOP: 2px">XAML (reflection.xaml)</DIV>
<DIV style="PADDING-RIGHT: 2px; PADDING-LEFT: 2px; BACKGROUND: #eeeeee; PADDING-BOTTOM: 2px; PADDING-TOP: 2px; FONT-FAMILY: ': Courier New', Courier, monospace">
<P>&lt;<FONT color=#800000 size=2>Canvas</FONT><FONT color=#0000ff size=2> <BR>&nbsp; </FONT><FONT color=#ff0000 size=2>xmlns</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>https://schemas.microsoft.com/client/2007</FONT><FONT size=2>"<BR>&nbsp; </FONT><FONT color=#ff0000 size=2>xmlns:x</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>https://schemas.microsoft.com/winfx/2006/xaml</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt;<BR><BR></FONT>&nbsp; &lt;!--<FONT color=#008000 size=2> The object to reflect. </FONT><FONT color=#0000ff size=2>--&gt;<BR>&nbsp; &lt;</FONT><FONT color=#800000 size=2>Image</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Source</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>gear_large.png</FONT><FONT size=2>"<BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#ff0000 size=2>Canvas.Left</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>75</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Canvas.Top</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>20</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt;<BR>&nbsp; &lt;/</FONT><FONT color=#800000 size=2>Image</FONT><FONT color=#0000ff size=2>&gt;<BR><BR><STRONG>&nbsp; &lt;!--</STRONG><FONT color=#008000 size=2><STRONG> The reflection. </STRONG></FONT><STRONG>--&gt;<BR>&nbsp; &lt;</STRONG><FONT color=#800000 size=2><STRONG>Image</STRONG></FONT> <FONT color=#ff0000 size=2><STRONG>Source</STRONG></FONT>=<FONT size=2><STRONG>"</STRONG></FONT><STRONG>gear_large.png</STRONG><FONT size=2><STRONG>" <BR>&nbsp;&nbsp;&nbsp; </STRONG></FONT><FONT color=#ff0000 size=2><STRONG>Canvas.Left</STRONG></FONT>=<FONT size=2><STRONG>"</STRONG></FONT><STRONG>75</STRONG><FONT size=2><STRONG>"</STRONG></FONT> <FONT color=#ff0000 size=2><STRONG>Canvas.Top</STRONG></FONT>=<FONT size=2><STRONG>"</STRONG></FONT><STRONG>20</STRONG><FONT size=2><STRONG>"</STRONG></FONT>&gt;<STRONG><BR>&nbsp; &lt;/</STRONG><FONT color=#800000 size=2><STRONG>Image</STRONG></FONT>&gt; <BR><BR>&lt;/<FONT color=#800000 size=2>Canvas</FONT><FONT color=#0000ff size=2>&gt;</FONT></FONT></P></DIV>
<LI>To flip the reflection so that it's upside down, create a <STRONG>ScaleTransform</STRONG> and set its <A href="https://msdn2.microsoft.com/en-us/library/bb188510.aspx">ScaleY</A> property to <CODE>-1</CODE>. 
<DIV style="PADDING-RIGHT: 2px; MARGIN-TOP: 5px; PADDING-LEFT: 2px; FONT-WEIGHT: bold; FONT-SIZE: 10pt; BACKGROUND: #dddddd; PADDING-BOTTOM: 2px; PADDING-TOP: 2px">XAML (reflection.xaml)</DIV>
<DIV style="PADDING-RIGHT: 2px; PADDING-LEFT: 2px; BACKGROUND: #eeeeee; PADDING-BOTTOM: 2px; PADDING-TOP: 2px; FONT-FAMILY: ': Courier New', Courier, monospace">
<P>&lt;<FONT color=#800000 size=2>Canvas</FONT><FONT color=#0000ff size=2> <BR>&nbsp; </FONT><FONT color=#ff0000 size=2>xmlns</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>https://schemas.microsoft.com/client/2007</FONT><FONT size=2>"<BR>&nbsp; </FONT><FONT color=#ff0000 size=2>xmlns:x</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>https://schemas.microsoft.com/winfx/2006/xaml</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt;<BR><BR></FONT>&nbsp; &lt;!--<FONT color=#008000 size=2> The object to reflect. </FONT><FONT color=#0000ff size=2>--&gt;<BR>&nbsp; &lt;</FONT><FONT color=#800000 size=2>Image</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Source</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>gear_large.png</FONT><FONT size=2>"<BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#ff0000 size=2>Canvas.Left</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>75</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Canvas.Top</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>20</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt;<BR>&nbsp; &lt;/</FONT><FONT color=#800000 size=2>Image</FONT><FONT color=#0000ff size=2>&gt;<BR><BR>&nbsp; &lt;!--<FONT color=#008000 size=2> The reflection. </FONT>--&gt;<BR>&nbsp; &lt;<FONT color=#800000 size=2>Image</FONT> <FONT color=#ff0000 size=2>Source</FONT>=<FONT size=2>"</FONT>gear_large.png<FONT size=2>" <BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#ff0000 size=2>Canvas.Left</FONT>=<FONT size=2>"</FONT>75<FONT size=2>"</FONT> <FONT color=#ff0000 size=2>Canvas.Top</FONT>=<FONT size=2>"</FONT>20<FONT size=2>"</FONT>&gt;<BR><STRONG>&nbsp;&nbsp;&nbsp; &lt;</STRONG></FONT><FONT color=#800000 size=2><STRONG>Image.RenderTransform</STRONG></FONT><FONT color=#0000ff size=2><STRONG>&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;</STRONG></FONT><FONT color=#800000 size=2><STRONG>ScaleTransform</STRONG></FONT><FONT color=#0000ff size=2><STRONG> </STRONG></FONT><FONT color=#ff0000 size=2><STRONG>ScaleY</STRONG></FONT><FONT color=#0000ff size=2><STRONG>=</STRONG></FONT><FONT size=2><STRONG>"</STRONG></FONT><FONT color=#0000ff size=2><STRONG>-1</STRONG></FONT><FONT size=2><STRONG>"</STRONG></FONT><FONT color=#0000ff size=2><STRONG> /&gt; <BR>&nbsp;&nbsp;&nbsp; &lt;/</STRONG></FONT><FONT color=#800000 size=2><STRONG>Image.RenderTransform</STRONG></FONT><FONT color=#0000ff size=2><STRONG>&gt; </STRONG><BR>&nbsp; &lt;/<FONT color=#800000 size=2>Image</FONT>&gt; <BR><BR>&lt;/<FONT color=#800000 size=2>Canvas</FONT><FONT color=#0000ff size=2>&gt;</FONT></FONT></P></DIV>
<P>When you run the sample, notice that the second image has been flipped almost out of sight.</P>
<P><IMG alt="The second gear is almost totally flipped out of the canvas. You need to move it down." src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/41/16/99/flipped_gear.jpg" original-url="https://blogs.msdn.com/photos/wpfedevcon/images/1411699/original.aspx" border=1></P></LI>
<LI>Move the flipped image so that it is below the original image. The most straightforward way to do this is to adjust the <A href="https://msdn2.microsoft.com/en-us/library/bb188510.aspx">Canvas.Top</A> property of the second image. 
<DIV style="PADDING-RIGHT: 2px; MARGIN-TOP: 5px; PADDING-LEFT: 2px; FONT-WEIGHT: bold; FONT-SIZE: 10pt; BACKGROUND: #dddddd; PADDING-BOTTOM: 2px; PADDING-TOP: 2px">XAML (reflection.xaml)</DIV>
<DIV style="PADDING-RIGHT: 2px; PADDING-LEFT: 2px; BACKGROUND: #eeeeee; PADDING-BOTTOM: 2px; PADDING-TOP: 2px; FONT-FAMILY: ': Courier New', Courier, monospace">
<P>&lt;<FONT color=#800000 size=2>Canvas</FONT><FONT color=#0000ff size=2> <BR>&nbsp; </FONT><FONT color=#ff0000 size=2>xmlns</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>https://schemas.microsoft.com/client/2007</FONT><FONT size=2>"<BR>&nbsp; </FONT><FONT color=#ff0000 size=2>xmlns:x</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>https://schemas.microsoft.com/winfx/2006/xaml</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt;<BR><BR></FONT>&nbsp; &lt;!--<FONT color=#008000 size=2> The object to reflect. </FONT>--&gt;<FONT color=#0000ff size=2><BR>&nbsp; &lt;</FONT><FONT color=#800000 size=2>Image</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Source</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>gear_large.png</FONT><FONT size=2>"<BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#ff0000 size=2>Canvas.Left</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>75</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Canvas.Top</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>20</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt;<BR>&nbsp; &lt;/</FONT><FONT color=#800000 size=2>Image</FONT><FONT color=#0000ff size=2>&gt;<BR><BR>&nbsp; </FONT>&lt;!--<FONT color=#0000ff size=2><FONT color=#008000 size=2> The reflection. </FONT></FONT>--&gt;<FONT color=#0000ff size=2><BR>&nbsp; &lt;<FONT color=#800000 size=2>Image</FONT> <FONT color=#ff0000 size=2>Source</FONT>=<FONT size=2>"</FONT>gear_large.png<FONT size=2>" <BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#ff0000 size=2>Canvas.Left</FONT>=<FONT size=2>"</FONT>75<FONT size=2>"</FONT> <FONT color=#ff0000 size=2><STRONG>Canvas.Top</STRONG></FONT>=<FONT size=2><STRONG>"258"</STRONG></FONT>&gt;<BR>&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>Image.RenderTransform</FONT><FONT color=#0000ff size=2>&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>ScaleTransform</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>ScaleY</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>-1</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> /&gt; <BR>&nbsp;&nbsp;&nbsp; &lt;/</FONT><FONT color=#800000 size=2>Image.RenderTransform</FONT><FONT color=#0000ff size=2>&gt; </FONT><FONT color=#0000ff size=2><BR>&nbsp; &lt;/<FONT color=#800000 size=2>Image</FONT>&gt; <BR><BR>&lt;/<FONT color=#800000 size=2>Canvas</FONT><FONT color=#0000ff size=2>&gt;</FONT></FONT></P></DIV>
<P>The markup now produces the following output.</P>
<P><IMG alt="A gear with a simple reflection." src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/41/17/16/fipped_translated_gear.jpg" original-url="https://blogs.msdn.com/photos/wpfedevcon/images/1411716/original.aspx" border=1></P></LI>
<LI>Now for some finishing touches. Use an <A href="https://msdn2.microsoft.com/en-us/library/bb188553.aspx">opacity mask</A> to fade the reflected image into the background. 
<DIV style="PADDING-RIGHT: 2px; MARGIN-TOP: 5px; PADDING-LEFT: 2px; FONT-WEIGHT: bold; FONT-SIZE: 10pt; BACKGROUND: #dddddd; PADDING-BOTTOM: 2px; PADDING-TOP: 2px">XAML (reflection.xaml)</DIV>
<DIV style="PADDING-RIGHT: 2px; PADDING-LEFT: 2px; BACKGROUND: #eeeeee; PADDING-BOTTOM: 2px; PADDING-TOP: 2px; FONT-FAMILY: ': Courier New', Courier, monospace">
<P>&lt;<FONT color=#800000 size=2>Canvas</FONT><FONT color=#0000ff size=2> <BR>&nbsp; </FONT><FONT color=#ff0000 size=2>xmlns</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>https://schemas.microsoft.com/client/2007</FONT><FONT size=2>"<BR>&nbsp; </FONT><FONT color=#ff0000 size=2>xmlns:x</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>https://schemas.microsoft.com/winfx/2006/xaml</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt;<BR><BR></FONT>&nbsp; &lt;!--<FONT color=#008000 size=2> The object to reflect. </FONT><FONT color=#0000ff size=2>--&gt;<BR>&nbsp; &lt;</FONT><FONT color=#800000 size=2>Image</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Source</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>gear_large.png</FONT><FONT size=2>"<BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#ff0000 size=2>Canvas.Left</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>75</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Canvas.Top</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>20</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt;<BR>&nbsp; &lt;/</FONT><FONT color=#800000 size=2>Image</FONT><FONT color=#0000ff size=2>&gt;<BR><BR>&nbsp; &lt;!--<FONT color=#008000 size=2> The reflection. </FONT>--&gt;<BR>&nbsp; &lt;<FONT color=#800000 size=2>Image</FONT> <FONT color=#ff0000 size=2>Source</FONT>=<FONT size=2>"</FONT>gear_large.png<FONT size=2>" <BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#ff0000 size=2>Canvas.Left</FONT>=<FONT size=2>"</FONT>75<FONT size=2>"</FONT> <FONT color=#ff0000 size=2>Canvas.Top</FONT>=<FONT size=2>"258"</FONT>&gt;<BR>&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>Image.RenderTransform</FONT><FONT color=#0000ff size=2>&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>ScaleTransform</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>ScaleY</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>-1</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> /&gt; <BR>&nbsp;&nbsp;&nbsp; &lt;/</FONT><FONT color=#800000 size=2>Image.RenderTransform</FONT><FONT color=#0000ff size=2>&gt; <BR><STRONG>&nbsp;&nbsp;&nbsp; &lt;</STRONG></FONT><FONT color=#800000 size=2><STRONG>Image.OpacityMask</STRONG></FONT><FONT color=#0000ff size=2><STRONG>&gt;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;</STRONG></FONT><FONT color=#800000 size=2><STRONG>LinearGradientBrush</STRONG></FONT><FONT color=#0000ff size=2><STRONG> </STRONG></FONT><FONT color=#ff0000 size=2><STRONG>StartPoint</STRONG></FONT><FONT color=#0000ff size=2><STRONG>=</STRONG></FONT><FONT size=2><STRONG>"</STRONG></FONT><FONT color=#0000ff size=2><STRONG>0.5,0.0</STRONG></FONT><FONT size=2><STRONG>"</STRONG></FONT><FONT color=#0000ff size=2><STRONG> </STRONG></FONT><FONT color=#ff0000 size=2><STRONG>EndPoint</STRONG></FONT><FONT color=#0000ff size=2><STRONG>=</STRONG></FONT><FONT size=2><STRONG>"</STRONG></FONT><FONT color=#0000ff size=2><STRONG>0.5,1.0</STRONG></FONT><FONT size=2><STRONG>"</STRONG></FONT><FONT color=#0000ff size=2><STRONG>&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;</STRONG></FONT><FONT color=#800000 size=2><STRONG>GradientStop</STRONG></FONT><FONT color=#0000ff size=2><STRONG> </STRONG></FONT><FONT color=#ff0000 size=2><STRONG>Offset</STRONG></FONT><FONT color=#0000ff size=2><STRONG>=</STRONG></FONT><FONT size=2><STRONG>"</STRONG></FONT><FONT color=#0000ff size=2><STRONG>0.0</STRONG></FONT><FONT size=2><STRONG>"</STRONG></FONT><FONT color=#0000ff size=2><STRONG> </STRONG></FONT><FONT color=#ff0000 size=2><STRONG>Color</STRONG></FONT><FONT color=#0000ff size=2><STRONG>=</STRONG></FONT><FONT size=2><STRONG>"</STRONG></FONT><FONT color=#0000ff size=2><STRONG>#00000000</STRONG></FONT><FONT size=2><STRONG>"</STRONG></FONT><FONT color=#0000ff size=2><STRONG> /&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;</STRONG></FONT><FONT color=#800000 size=2><STRONG>GradientStop</STRONG></FONT><FONT color=#0000ff size=2><STRONG> </STRONG></FONT><FONT color=#ff0000 size=2><STRONG>Offset</STRONG></FONT><FONT color=#0000ff size=2><STRONG>=</STRONG></FONT><FONT size=2><STRONG>"</STRONG></FONT><FONT color=#0000ff size=2><STRONG>1.0</STRONG></FONT><FONT size=2><STRONG>"</STRONG></FONT><FONT color=#0000ff size=2><STRONG> </STRONG></FONT><FONT color=#ff0000 size=2><STRONG>Color</STRONG></FONT><FONT color=#0000ff size=2><STRONG>=</STRONG></FONT><FONT size=2><STRONG>"</STRONG></FONT><FONT color=#0000ff size=2><STRONG>#FF000000</STRONG></FONT><FONT size=2><STRONG>"</STRONG></FONT><FONT color=#0000ff size=2><STRONG> /&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/</STRONG></FONT><FONT color=#800000 size=2><STRONG>LinearGradientBrush</STRONG></FONT><FONT color=#0000ff size=2><STRONG>&gt; <BR>&nbsp;&nbsp;&nbsp; &lt;/</STRONG></FONT><FONT color=#800000 size=2><STRONG>Image.OpacityMask</STRONG></FONT><FONT color=#0000ff size=2><STRONG>&gt; </STRONG><BR>&nbsp; &lt;/<FONT color=#800000 size=2>Image</FONT>&gt; <BR><BR>&lt;/<FONT color=#800000 size=2>Canvas</FONT><FONT color=#0000ff size=2>&gt;</FONT></FONT> </P></DIV>
<P>As you can see in the following output, the second image now fades into the background.</P>
<P><IMG alt="The second gear now fades into the background." src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/41/17/32/gear_with_opacity_mask.jpg" original-url="https://blogs.msdn.com/photos/wpfedevcon/images/1411732/original.aspx" border=1></P></LI>
<LI>Add some distortion to the reflection by changing the <STRONG>ScaleY</STRONG> value of the <STRONG>ScaleTransform</STRONG> from <CODE>-1</CODE> to <CODE>-0.75</CODE>. 
<DIV style="PADDING-RIGHT: 2px; MARGIN-TOP: 5px; PADDING-LEFT: 2px; FONT-WEIGHT: bold; FONT-SIZE: 10pt; BACKGROUND: #dddddd; PADDING-BOTTOM: 2px; PADDING-TOP: 2px">XAML (reflection.xaml)</DIV>
<DIV style="PADDING-RIGHT: 2px; PADDING-LEFT: 2px; BACKGROUND: #eeeeee; PADDING-BOTTOM: 2px; PADDING-TOP: 2px; FONT-FAMILY: ': Courier New', Courier, monospace">
<P>&lt;<FONT color=#800000 size=2>Canvas</FONT><FONT color=#0000ff size=2> <BR>&nbsp; </FONT><FONT color=#ff0000 size=2>xmlns</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>https://schemas.microsoft.com/client/2007</FONT><FONT size=2>"<BR>&nbsp; </FONT><FONT color=#ff0000 size=2>xmlns:x</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>https://schemas.microsoft.com/winfx/2006/xaml</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt;<BR><BR></FONT>&nbsp; &lt;!--<FONT color=#008000 size=2> The object to reflect. </FONT><FONT color=#0000ff size=2>--&gt;<BR>&nbsp; &lt;</FONT><FONT color=#800000 size=2>Image</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Source</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>gear_large.png</FONT><FONT size=2>"<BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#ff0000 size=2>Canvas.Left</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>75</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Canvas.Top</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>20</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt;<BR>&nbsp; &lt;/</FONT><FONT color=#800000 size=2>Image</FONT><FONT color=#0000ff size=2>&gt;<BR><BR>&nbsp; &lt;!--<FONT color=#008000 size=2> The reflection. </FONT>--&gt;<BR>&nbsp; &lt;<FONT color=#800000 size=2>Image</FONT> <FONT color=#ff0000 size=2>Source</FONT>=<FONT size=2>"</FONT>gear_large.png<FONT size=2>" <BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#ff0000 size=2>Canvas.Left</FONT>=<FONT size=2>"</FONT>75<FONT size=2>"</FONT> <FONT color=#ff0000 size=2>Canvas.Top</FONT>=<FONT size=2>"258"</FONT>&gt;<BR>&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>Image.RenderTransform</FONT><FONT color=#0000ff size=2>&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>ScaleTransform</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2><STRONG>ScaleY</STRONG></FONT><FONT color=#0000ff size=2><STRONG>=</STRONG></FONT><FONT size=2><STRONG>"</STRONG></FONT><FONT color=#0000ff size=2><STRONG>-0.75</STRONG></FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> /&gt; <BR>&nbsp;&nbsp;&nbsp; &lt;/</FONT><FONT color=#800000 size=2>Image.RenderTransform</FONT><FONT color=#0000ff size=2>&gt; <BR>&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>Image.OpacityMask</FONT><FONT color=#0000ff size=2>&gt;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>LinearGradientBrush</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>StartPoint</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>0.5,0.0</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>EndPoint</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>0.5,1.0</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>GradientStop</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Offset</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>0.0</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Color</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>#00000000</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> /&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>GradientStop</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Offset</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>1.0</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Color</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>#FF000000</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> /&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/</FONT><FONT color=#800000 size=2>LinearGradientBrush</FONT><FONT color=#0000ff size=2>&gt; <BR>&nbsp;&nbsp;&nbsp; &lt;/</FONT><FONT color=#800000 size=2>Image.OpacityMask</FONT><FONT color=#0000ff size=2>&gt; </FONT><FONT color=#0000ff size=2><BR>&nbsp; &lt;/<FONT color=#800000 size=2>Image</FONT>&gt; <BR><BR>&lt;/<FONT color=#800000 size=2>Canvas</FONT><FONT color=#0000ff size=2>&gt;</FONT></FONT> </P></DIV>
<P>The sample now produces the following output. Notice that the reflected image appears to have changed position.</P>
<P><IMG alt="Now the second gear is distorted, but it's too far away from the first gear." src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/41/17/43/distorted_reflection.jpg" original-url="https://blogs.msdn.com/photos/wpfedevcon/images/1411743/original.aspx" border=1></P></LI>
<LI>Move the reflected image so that it is just below the original image. 
<DIV style="PADDING-RIGHT: 2px; MARGIN-TOP: 5px; PADDING-LEFT: 2px; FONT-WEIGHT: bold; FONT-SIZE: 10pt; BACKGROUND: #dddddd; PADDING-BOTTOM: 2px; PADDING-TOP: 2px">XAML (reflection.xaml)</DIV>
<DIV style="PADDING-RIGHT: 2px; PADDING-LEFT: 2px; BACKGROUND: #eeeeee; PADDING-BOTTOM: 2px; PADDING-TOP: 2px; FONT-FAMILY: ': Courier New', Courier, monospace">
<P>&lt;<FONT color=#800000 size=2>Canvas</FONT><FONT color=#0000ff size=2> <BR>&nbsp; </FONT><FONT color=#ff0000 size=2>xmlns</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>https://schemas.microsoft.com/client/2007</FONT><FONT size=2>"<BR>&nbsp; </FONT><FONT color=#ff0000 size=2>xmlns:x</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>https://schemas.microsoft.com/winfx/2006/xaml</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt;<BR><BR></FONT>&nbsp; &lt;!--<FONT color=#008000 size=2> The object to reflect. </FONT><FONT color=#0000ff size=2>--&gt;<BR>&nbsp; &lt;</FONT><FONT color=#800000 size=2>Image</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Source</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>gear_large.png</FONT><FONT size=2>"<BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#ff0000 size=2>Canvas.Left</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>75</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Canvas.Top</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>20</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt;<BR>&nbsp; &lt;/</FONT><FONT color=#800000 size=2>Image</FONT><FONT color=#0000ff size=2>&gt;<BR><BR>&nbsp; &lt;!--<FONT color=#008000 size=2> The reflection. </FONT>--&gt;<BR>&nbsp; &lt;<FONT color=#800000 size=2>Image</FONT> <FONT color=#ff0000 size=2>Source</FONT>=<FONT size=2>"</FONT>gear_large.png<FONT size=2>" <BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#ff0000 size=2>Canvas.Left</FONT>=<FONT size=2>"</FONT>75<FONT size=2>"</FONT> <FONT color=#ff0000 size=2><STRONG>Canvas.Top</STRONG></FONT>=<FONT size=2><STRONG>"228"</STRONG></FONT>&gt;<BR>&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>Image.RenderTransform</FONT><FONT color=#0000ff size=2>&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>ScaleTransform</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>ScaleY</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>-0.75</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> /&gt; <BR>&nbsp;&nbsp;&nbsp; &lt;/</FONT><FONT color=#800000 size=2>Image.RenderTransform</FONT><FONT color=#0000ff size=2>&gt; <BR>&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>Image.OpacityMask</FONT><FONT color=#0000ff size=2>&gt;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>LinearGradientBrush</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>StartPoint</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>0.5,0.0</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>EndPoint</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>0.5,1.0</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>GradientStop</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Offset</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>0.0</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Color</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>#00000000</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> /&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>GradientStop</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Offset</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>1.0</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Color</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>#FF000000</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> /&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/</FONT><FONT color=#800000 size=2>LinearGradientBrush</FONT><FONT color=#0000ff size=2>&gt; <BR>&nbsp;&nbsp;&nbsp; &lt;/</FONT><FONT color=#800000 size=2>Image.OpacityMask</FONT><FONT color=#0000ff size=2>&gt; </FONT><FONT color=#0000ff size=2><BR>&nbsp; &lt;/<FONT color=#800000 size=2>Image</FONT>&gt; <BR><BR>&lt;/<FONT color=#800000 size=2>Canvas</FONT><FONT color=#0000ff size=2>&gt;</FONT></FONT> </P></DIV>
<P>As you can see in the following output, the reflected image is now in the correct position.</P>
<P><IMG alt="The gear, with a suitably distorted reflection." src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/41/17/56/distorted_reflection_transl.jpg" original-url="https://blogs.msdn.com/photos/wpfedevcon/images/1411756/original.aspx" border=1></P></LI>
<LI>For the final finishing touch, make the reflection fade into the background a little bit more by setting its opacity to <CODE>0.75</CODE>. 
<DIV style="PADDING-RIGHT: 2px; MARGIN-TOP: 5px; PADDING-LEFT: 2px; FONT-WEIGHT: bold; FONT-SIZE: 10pt; BACKGROUND: #dddddd; PADDING-BOTTOM: 2px; PADDING-TOP: 2px">XAML (reflection.xaml)</DIV>
<DIV style="PADDING-RIGHT: 2px; PADDING-LEFT: 2px; BACKGROUND: #eeeeee; PADDING-BOTTOM: 2px; PADDING-TOP: 2px; FONT-FAMILY: ': Courier New', Courier, monospace">
<P>&lt;<FONT color=#800000 size=2>Canvas</FONT><FONT color=#0000ff size=2> <BR>&nbsp; </FONT><FONT color=#ff0000 size=2>xmlns</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>https://schemas.microsoft.com/client/2007</FONT><FONT size=2>"<BR>&nbsp; </FONT><FONT color=#ff0000 size=2>xmlns:x</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>https://schemas.microsoft.com/winfx/2006/xaml</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt;<BR><BR></FONT>&nbsp; &lt;!--<FONT color=#008000 size=2> The object to reflect. </FONT><FONT color=#0000ff size=2>--&gt;<BR>&nbsp; &lt;</FONT><FONT color=#800000 size=2>Image</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Source</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>gear_large.png</FONT><FONT size=2>"<BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#ff0000 size=2>Canvas.Left</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>75</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Canvas.Top</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>20</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt;<BR>&nbsp; &lt;/</FONT><FONT color=#800000 size=2>Image</FONT><FONT color=#0000ff size=2>&gt;<BR><BR>&nbsp; &lt;!--<FONT color=#008000 size=2> The reflection. </FONT>--&gt;<BR>&nbsp; &lt;<FONT color=#800000 size=2>Image</FONT> <FONT color=#ff0000 size=2>Source</FONT>=<FONT size=2>"</FONT>gear_large.png<FONT size=2>" <BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#ff0000 size=2>Canvas.Left</FONT>=<FONT size=2>"</FONT>75<FONT size=2>"</FONT> <FONT color=#ff0000 size=2>Canvas.Top</FONT>=<FONT size=2>"228"<BR>&nbsp;&nbsp;&nbsp; <SPAN class=style1><STRONG>Opacity</STRONG></SPAN></FONT>=<FONT size=2><STRONG>"0.75"</STRONG></FONT>&gt;<BR>&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>Image.RenderTransform</FONT><FONT color=#0000ff size=2>&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>ScaleTransform</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>ScaleY</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>-0.75</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> /&gt; <BR>&nbsp;&nbsp;&nbsp; &lt;/</FONT><FONT color=#800000 size=2>Image.RenderTransform</FONT><FONT color=#0000ff size=2>&gt; <BR>&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>Image.OpacityMask</FONT><FONT color=#0000ff size=2>&gt;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>LinearGradientBrush</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>StartPoint</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>0.5,0.0</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>EndPoint</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>0.5,1.0</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>GradientStop</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Offset</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>0.0</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Color</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>#00000000</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> /&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>GradientStop</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Offset</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>1.0</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Color</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>#FF000000</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> /&gt; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/</FONT><FONT color=#800000 size=2>LinearGradientBrush</FONT><FONT color=#0000ff size=2>&gt; <BR>&nbsp;&nbsp;&nbsp; &lt;/</FONT><FONT color=#800000 size=2>Image.OpacityMask</FONT><FONT color=#0000ff size=2>&gt; </FONT><FONT color=#0000ff size=2><BR>&nbsp; &lt;/<FONT color=#800000 size=2>Image</FONT>&gt; <BR><BR>&lt;/<FONT color=#800000 size=2>Canvas</FONT><FONT color=#0000ff size=2>&gt;</FONT></FONT> </P></DIV>
<P>The following illustration shows the completed reflection.</P>
<P><IMG alt="The gear, with a reflection." src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/41/17/64/final_reflection.jpg" original-url="https://blogs.msdn.com/photos/wpfedevcon/images/1411764/original.aspx" border=1></P></LI></OL>
<P>-m jacobs&nbsp;&nbsp;</P>
<H3>Related Topics</H3>
<UL>
<LI><A href="https://msdn2.microsoft.com/en-us/library/bb190691.aspx">Transforms Overview</A>: Describes how to use WPF/E transforms to scale, skew, translate, and rotate objects.</LI>
<LI><A href="https://msdn2.microsoft.com/en-us/library/bb188570.aspx">Brushes Overview</A>: Describes how to paint with WPF/E brush objects, such as <STRONG>LinearGradientBrush</STRONG> and <STRONG>RadialGradientBrush</STRONG>. </LI></UL>
<p><a href="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/40/72/55/reflection_examples.zip" original-url="https://blogs.msdn.com/cfs-file.ashx/__key/communityserver-components-postattachments/00-01-40-72-55/reflection_5F00_examples.zip">reflection_examples.zip</a></p>]]></content:encoded>
    </item>
    <item>
      <title>Using Opacity with a WPFE / Virtual Earth Mashup</title>
      <link>https://docs.microsoft.com/archive/blogs/wpfedevcon/using-opacity-with-a-wpfe-virtual-earth-mashup</link>
      <pubDate>Tue, 02 Jan 2007 16:30:00 GMT</pubDate>
      <dc:creator><![CDATA[wpfedevcon]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/wpfedevcon/2007/01/02/using-opacity-with-a-wpfe-virtual-earth-mashup/</guid>
      <description><![CDATA[Opacity is a very useful property for creating graphical effects in a WPF/E application. This is...]]></description>
      <content:encoded><![CDATA[<!-- Begin blog posting -->
<P><FONT face=Verdana size=2>Opacity is a very useful property for creating graphical effects in a WPF/E application. This is particularly true when creating mashups, in which you overlay custom content on other Web content. This posting illustrates the use of opacity in a Microsoft Virtual Earth mashup that allows you to display selected landmarks in New York City.</FONT></P>
<P><FONT face=Verdana size=2>At the bottom of this posting, you can find an attached Zip file (<FONT color=#808080><STRONG>Landmarks.zip</STRONG></FONT>) that contains all the files used for this mashup. You can also view the WPF/E application at:<BR>&nbsp;&nbsp;&nbsp; <A href="https://wpfesdk.members.winisp.net/samples/landmarks" mce_href="https://wpfesdk.members.winisp.net/samples/landmarks">https://wpfesdk.members.winisp.net/samples/landmarks</A></FONT></P>
<P><STRONG><FONT face=Verdana color=#004080 size=2>Using Animated Opacity to Fade In Text</FONT></STRONG><FONT face=Verdana size=2><BR>When the <B><FONT color=#808080>nyc landmarks</FONT></B> mashup loads, the title fades into view:</FONT></P>
<P align=center><IMG height=122 alt="nyc landmarks title" src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/39/43/94/Title_01.png" original-url="https://blogs.msdn.com/photos/wpfedevcon/images/1394394/original.aspx" width=499 border=0 mce_src="https://blogs.msdn.com/photos/wpfedevcon/images/1394394/original.aspx"><BR><B><FONT face=Verdana size=1>Title fades in as partially translucent text</FONT></B></P>
<P><FONT face=Verdana size=2>The title is simply a pair of <B>TextBlock</B> objects whose parent <B>Opacity</B> property value is animated when the WPF/E control loads it. You can achieve this effect by creating a WPF/E control with the <B>WindowlessMode</B> property set to <FONT color=#000080><B>true</B></FONT>, and setting the <B>BackgroundColor</B> value to be transparent. The <B>BackgroundColor</B> value setting, <B><FONT color=#808080>#00000000</FONT></B>, represents a 16-bit RGB value with alpha transparency (#AARRGGBB). The end result is that the <B>TextBlock</B> text is overlaid directly on the map data.</FONT></P><FONT size=2>
<P></FONT><FONT face="Courier New"><FONT color=#0000ff size=2>new</FONT><FONT size=2> agHost(<BR>&nbsp; </FONT><FONT color=#800000 size=2>"WpfeControlHost_1"</FONT><FONT size=2>,&nbsp;&nbsp;&nbsp; </FONT><FONT color=#008000 size=2>// DIV tag id.<BR>&nbsp; </FONT><FONT color=#800000 size=2>"WpfeControl_1"</FONT><FONT size=2>, </FONT><FONT color=#008000 size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // WPF/E control id.<BR>&nbsp; </FONT><FONT color=#800000 size=2>"440"</FONT><FONT size=2>,&nbsp; </FONT></FONT><FONT color=#008000 size=2><FONT face="Courier New">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // Width.<BR>&nbsp; </FONT></FONT><FONT face="Courier New"><FONT color=#800000 size=2>"80"</FONT><FONT size=2>, </FONT></FONT><FONT color=#008000 size=2><FONT face="Courier New">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // Height.<BR>&nbsp; </FONT></FONT><FONT face="Courier New"><FONT color=#800000 size=2>"#00000000"</FONT><FONT size=2>,&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></FONT><FONT face="Courier New" color=#008000 size=2>// Background is transparent,<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; //&nbsp;&nbsp; since alpha value is 0.<BR>&nbsp; </FONT><FONT face="Courier New"><FONT color=#0000ff size=2>null</FONT><FONT size=2>,&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></FONT><FONT color=#008000 size=2><FONT face="Courier New">// SourceElement not used.<BR>&nbsp; </FONT></FONT><FONT face="Courier New"><FONT color=#800000 size=2>"xaml/Title.xaml"</FONT><FONT size=2>,&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></FONT><FONT color=#008000 size=2><FONT face="Courier New">// Source property value.<BR>&nbsp; </FONT></FONT><FONT face="Courier New"><FONT color=#800000 size=2>"true"</FONT><FONT size=2>);&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></FONT><FONT color=#008000 size=2><FONT face="Courier New">// WindowlessMode enabled.</FONT></P></FONT>
<P><FONT face=Verdana size=2>The title text fades in by defining an animation for the <B>TextBlock</B> objects.&nbsp; Notice that the <B>To</B> property is set to 0.7, which means the title is partially translucent, allowing the map to show through just a little:</FONT></P><FONT color=#0000ff size=2>
<P><FONT face="Courier New">&lt;</FONT></FONT><FONT face="Courier New"><FONT color=#800000 size=2>Canvas.Triggers</FONT><FONT color=#0000ff size=2>&gt;<BR>&nbsp; &lt;</FONT><FONT color=#800000 size=2>EventTrigger</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>RoutedEvent</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>Canvas.Loaded</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt;<BR>&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>EventTrigger.Actions</FONT></FONT><FONT face="Courier New" color=#0000ff size=2>&gt;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT face="Courier New" color=#800000 size=2>BeginStoryboard</FONT><FONT face="Courier New" color=#0000ff size=2>&gt;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT face="Courier New" color=#800000 size=2>Storyboard</FONT><FONT face="Courier New" color=#0000ff size=2>&gt;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT face="Courier New" color=#800000 size=2>DoubleAnimation</FONT><FONT color=#0000ff size=2><FONT face="Courier New"><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></FONT><FONT face="Courier New"><FONT color=#ff0000 size=2>Storyboard.TargetName</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>title</FONT></FONT><FONT size=2><FONT face="Courier New">"<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></FONT><FONT face="Courier New"><FONT color=#ff0000 size=2>Storyboard.TargetProperty</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>Opacity</FONT></FONT><FONT size=2><FONT face="Courier New">"<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></FONT><FONT face="Courier New"><FONT color=#ff0000 size=2>BeginTime</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>0:0:3</FONT></FONT><FONT size=2><FONT face="Courier New">"<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></FONT><FONT face="Courier New"><FONT color=#ff0000 size=2>To</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>0.7</FONT><FONT size=2>"<BR><FONT color=#0000ff>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></FONT><FONT color=#ff0000 size=2>Duration</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>0:0:3</FONT><FONT size=2>"</FONT></FONT><FONT face="Courier New" color=#0000ff size=2> /&gt;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/</FONT><FONT face="Courier New" color=#800000 size=2>Storyboard</FONT><FONT face="Courier New" color=#0000ff size=2>&gt;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/</FONT><FONT face="Courier New" color=#800000 size=2>BeginStoryboard</FONT><FONT face="Courier New" color=#0000ff size=2>&gt;<BR>&nbsp;&nbsp;&nbsp; &lt;/</FONT><FONT face="Courier New" color=#800000 size=2>EventTrigger.Actions</FONT><FONT face="Courier New" color=#0000ff size=2>&gt;<BR>&nbsp; &lt;/</FONT><FONT face="Courier New" color=#800000 size=2>EventTrigger</FONT><FONT face="Courier New" color=#0000ff size=2>&gt;<BR>&lt;/</FONT><FONT face="Courier New" color=#800000 size=2>Canvas.Triggers</FONT><FONT color=#0000ff size=2><FONT face="Courier New">&gt;</FONT></P></FONT>
<P><STRONG><FONT face=Verdana color=#004080 size=2>Creating a Drop Shadow Effect</FONT></STRONG><FONT face=Verdana size=2><BR>The title text is defined as a pair of <B>TextBlock</B> objects. The top object displays the primary text, while the bottom object, offset slightly, displays the same text in a darker color. This creates a drop shadow effect. Notice that the <B>TextBlock</B> objects are contained within a <B>Canvas</B> object. Although the animation is applied to this containing <B>Canvas</B> object, the effects of the animation are applied to the <B>Canvas</B> object and <FONT color=#800000><I><B>all</B></I></FONT> its descendants.</FONT></P><FONT color=#0000ff size=2>
<P><FONT face="Courier New">&lt;</FONT></FONT><FONT face="Courier New"><FONT color=#800000 size=2>Canvas<BR>&nbsp; </FONT><FONT color=#ff0000 size=2>x:Name</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>title</FONT><FONT size=2>"<BR>&nbsp; </FONT><FONT color=#ff0000 size=2>Opacity</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>0.0</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> &gt;<BR><BR></FONT><FONT color=#008000 size=2>&nbsp; &lt;!-- Shadow text below --&gt;<BR></FONT><FONT color=#0000ff size=2>&nbsp; &lt;</FONT><FONT color=#800000 size=2>TextBlock<BR>&nbsp; </FONT><FONT color=#ff0000 size=2>&nbsp; Canvas.Top</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>4</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Canvas.Left</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>4</FONT><FONT size=2>"<BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#ff0000 size=2>FontFamily</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>Verdana</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>FontWeight</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>Bold</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>FontSize</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>48</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2><BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#ff0000 size=2>Foreground</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>Black</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> &gt;<BR></FONT><FONT size=2>&nbsp;&nbsp;&nbsp; nyc landmarks<BR></FONT><FONT color=#0000ff size=2>&nbsp; &lt;/</FONT><FONT color=#800000 size=2>TextBlock</FONT><FONT color=#0000ff size=2>&gt;<BR><BR></FONT><FONT color=#008000 size=2>&nbsp; &lt;!-- Primary text above --&gt;<BR></FONT><FONT color=#0000ff size=2>&nbsp; &lt;</FONT></FONT><FONT face="Courier New" color=#800000 size=2>TextBlock<BR>&nbsp; </FONT><FONT face="Courier New"><FONT color=#ff0000 size=2>&nbsp; FontFamily</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>Verdana</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>FontWeight</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>Bold</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>FontSize</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>48</FONT><FONT size=2>"<BR>&nbsp;&nbsp; </FONT><FONT color=#0000ff size=2>&nbsp;</FONT><FONT color=#ff0000 size=2>Foreground</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>Gold</FONT><FONT size=2>"</FONT></FONT><FONT color=#0000ff size=2><FONT face="Courier New"> &gt;<BR>&nbsp; </FONT></FONT><FONT face="Courier New" size=2>&nbsp; nyc landmarks<BR></FONT><FONT face="Courier New" color=#0000ff size=2>&nbsp; &lt;/</FONT><FONT face="Courier New" color=#800000 size=2>TextBlock</FONT><FONT face="Courier New" color=#0000ff size=2>&gt;<BR><BR>&lt;/</FONT><FONT face="Courier New" color=#800000 size=2>Canvas</FONT><FONT color=#0000ff size=2><FONT face="Courier New">&gt;</FONT></P></FONT>
<P><STRONG><FONT face=Verdana color=#004080 size=2>Using the WindowlessMode Property with an Alpha Value</FONT></STRONG><FONT face=Verdana size=2><BR>The landsmarks list panel also fades into view using animated opacity. In order to allow the underlying map to show through, the <B>Canvas</B> and <B>TextBlock</B> objects that comprise the panel are set to less than 100% opacity:</FONT></P>
<P align=center><IMG height=324 alt="Landmarks panel fades into view" src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/39/43/95/Panel_01.png" original-url="https://blogs.msdn.com/photos/wpfedevcon/images/1394395/original.aspx" width=357 border=0 mce_src="https://blogs.msdn.com/photos/wpfedevcon/images/1394395/original.aspx"><BR><B><FONT face=Verdana size=1>Panel fades in as partially translucent text and background</FONT></B></P>
<P><FONT face=Verdana size=2>Notice the translucent outline around the border of the panel. Like the title, the panel is defined as a WPF/E control with the <B>WindowlessMode</B> property set to <FONT color=#000080><B>true</B></FONT>. However, in this case the alpha value of the <B>BackgroundColor</B> property value, <B><FONT color=#808080>#40000000</FONT></B>, is set to be semi-transparent, which means a black color value with 25% opacity is blended with the underlying map data.</FONT></P><FONT size=2>
<P></FONT><FONT face="Courier New"><FONT color=#0000ff size=2>new</FONT><FONT size=2> agHost(<BR>&nbsp; </FONT><FONT color=#800000 size=2>"WpfeControlHost_2"</FONT><FONT size=2>,&nbsp;&nbsp;&nbsp; </FONT><FONT color=#008000 size=2>// DIV tag id.<BR>&nbsp; </FONT><FONT color=#800000 size=2>"WpfeControl_2"</FONT><FONT size=2>, </FONT><FONT color=#008000 size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // WPF/E control id.<BR>&nbsp; </FONT><FONT color=#800000 size=2>"220"</FONT><FONT size=2>,&nbsp; </FONT></FONT><FONT face="Courier New" color=#008000 size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // Width.<BR>&nbsp; </FONT><FONT face="Courier New"><FONT color=#800000 size=2>"260"</FONT><FONT size=2>, </FONT></FONT><FONT face="Courier New" color=#008000 size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // Height.<BR>&nbsp; </FONT><FONT face="Courier New"><FONT color=#800000 size=2>"#40000000"</FONT><FONT size=2>,&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></FONT><FONT face="Courier New" color=#008000 size=2>// Background partially transparent,<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; //&nbsp;&nbsp; since alpha value is 25%.<BR>&nbsp; </FONT><FONT face="Courier New"><FONT color=#0000ff size=2>null</FONT><FONT size=2>,&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></FONT><FONT face="Courier New" color=#008000 size=2>// SourceElement not used.<BR>&nbsp; </FONT><FONT face="Courier New"><FONT color=#800000 size=2>"xaml/LandMarks.xaml"</FONT><FONT size=2>,&nbsp; </FONT></FONT><FONT face="Courier New" color=#008000 size=2>// Source property value.<BR>&nbsp; </FONT><FONT face="Courier New"><FONT color=#800000 size=2>"true"</FONT><FONT size=2>);&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></FONT><FONT color=#008000 size=2><FONT face="Courier New">// WindowlessMode enabled.</FONT></P></FONT>
<P><STRONG><FONT face=Verdana color=#004080 size=2>Using the Opacity Property to Indicate Focus and Selection</FONT></STRONG><FONT face=Verdana size=2><BR>When you move the mouse over a landmark name, the text in the <B>TextBlock</B> darkens. When you select a landmark name, a blue-green selection rectangle appears under the clicked <B>TextBlock</B>.</FONT></P>
<P align=center><IMG height=395 alt="Landmarks panel showing focus and selection" src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/39/43/96/Panel_02.png" original-url="https://blogs.msdn.com/photos/wpfedevcon/images/1394396/original.aspx" width=510 border=0 mce_src="https://blogs.msdn.com/photos/wpfedevcon/images/1394396/original.aspx"><BR><B><FONT face=Verdana size=1>Focus and selection uses opacity</FONT></B></P>
<P align=left><FONT face=Verdana size=2>To indicate focus, each <B>TextBlock</B> object representing a landmark name defines a <B>MouseEnter</B> and <B>MouseLeave</B> event. Notice that the <B>Opacity</B> value is set to "0.8":</FONT></P><FONT color=#0000ff size=2>
<P><FONT face="Courier New">&lt;</FONT></FONT><FONT color=#800000 size=2><FONT face="Courier New">TextBlock<BR>&nbsp; </FONT></FONT><FONT face="Courier New"><FONT color=#ff0000 size=2>x:Name</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>Staten Island Ferry</FONT></FONT><FONT size=2><FONT face="Courier New">"<BR>&nbsp; </FONT></FONT><FONT face="Courier New"><FONT color=#ff0000 size=2>Canvas.Left</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>20</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Canvas.Top</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>120</FONT></FONT><FONT size=2><FONT face="Courier New">"<BR>&nbsp; </FONT></FONT><FONT face="Courier New"><FONT color=#ff0000 size=2>FontFamily</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>Verdana</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>FontWeight</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>Bold</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>FontSize</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>12</FONT></FONT><FONT size=2><FONT face="Courier New">"<BR>&nbsp; </FONT></FONT><FONT face="Courier New"><FONT color=#ff0000 size=2>Opacity</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>0.8</FONT></FONT><FONT size=2><FONT face="Courier New">"<BR>&nbsp; </FONT></FONT><FONT face="Courier New"><FONT color=#ff0000 size=2>MouseLeftButtonDown</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>javascript:landmarkSelected</FONT></FONT><FONT size=2><FONT face="Courier New">"<BR>&nbsp; </FONT></FONT><FONT face="Courier New"><FONT color=#ff0000 size=2>MouseEnter</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>javascript:mouseEnter</FONT></FONT><FONT size=2><FONT face="Courier New">"<BR>&nbsp; </FONT></FONT><FONT face="Courier New"><FONT color=#ff0000 size=2>MouseLeave</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>javascript:mouseLeave</FONT><FONT size=2>"</FONT></FONT><FONT color=#0000ff size=2><FONT face="Courier New"> &gt;<BR></FONT></FONT><FONT face="Courier New" size=2>&nbsp; Staten Island Ferry<BR></FONT><FONT face="Courier New" color=#0000ff size=2>&lt;/</FONT><FONT face="Courier New" color=#800000 size=2>TextBlock</FONT><FONT color=#0000ff size=2><FONT face="Courier New">&gt;</FONT></P></FONT>
<P><FONT face=Verdana size=2>The event handling functions for all the <B>MouseEnter</B> and <B>MouseLeave</B> events are defined as:</FONT></P><FONT color=#008000 size=2>
<P><FONT face="Courier New">//<BR>// Toggle the opacity of the TextBlock to indicate focus.<BR>//<BR></FONT></FONT><FONT face="Courier New"><FONT color=#0000ff size=2>function</FONT><FONT size=2> mouseEnter(sender) {<BR>&nbsp;&nbsp;&nbsp; sender.opacity = 1.0;<BR>}<BR><BR></FONT><FONT color=#0000ff size=2>function</FONT><FONT size=2> mouseLeave(sender) {<BR>&nbsp;&nbsp;&nbsp; sender.opacity = 0.8;<BR>}</FONT></FONT></P>
<P><FONT face=Verdana size=2>To indicate selection, a transparent <B>Rectangle</B> object is defined, so that it is below the rendering order of the <B>TextBlock</B> objects:</FONT></P><FONT color=#0000ff size=2>
<P><FONT face="Courier New">&lt;</FONT></FONT><FONT face="Courier New"><FONT color=#800000 size=2>Rectangle<BR>&nbsp; </FONT><FONT color=#ff0000 size=2>x:Name</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>selectionRect</FONT><FONT size=2>"<BR>&nbsp; </FONT><FONT color=#ff0000 size=2>Canvas.Left</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>0</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Canvas.Top</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>-20</FONT><FONT size=2>"<BR>&nbsp; </FONT><FONT color=#ff0000 size=2>Height</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>20</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Width</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>180</FONT><FONT size=2>"<BR>&nbsp; </FONT><FONT color=#ff0000 size=2>Fill</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>Teal</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Opacity</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>0.0</FONT><FONT size=2>"</FONT></FONT><FONT color=#0000ff size=2><FONT face="Courier New"> /&gt;</FONT></P></FONT>
<P><FONT face=Verdana size=2>The event handler function for the <B>MouseLeftButtonDown</B> event of each <B>TextBlock</B> object calls the custom SetMapToLandmark function which repositions the the selection rectangle underneath the clicked <B>TextBlock</B> object, and sets its <B>Opacity</B> value to 0.5:</FONT></P><FONT color=#008000 size=2>
<P><FONT face="Courier New">//<BR>// Set the selection rectangle.<BR>// Then set the Birdseye view to the landmark.<BR>//<BR></FONT></FONT><FONT face="Courier New" color=#0000ff size=2>function</FONT><FONT size=2><FONT face="Courier New"> SetMapToLandmark(landmark, top) {<BR>&nbsp;&nbsp;&nbsp; </FONT></FONT><FONT face="Courier New"><FONT color=#0000ff size=2>if</FONT><FONT size=2> (selectionRect[</FONT><FONT color=#800000 size=2>"Canvas.Top"</FONT><FONT size=2>] == top) </FONT><FONT color=#0000ff size=2>return</FONT></FONT><FONT face="Courier New" size=2>;<BR><BR>&nbsp;&nbsp;&nbsp; selectionRect[</FONT><FONT face="Courier New" color=#800000 size=2>"Canvas.Top"</FONT><FONT size=2><FONT face="Courier New">] = top;<BR>&nbsp;&nbsp;&nbsp; selectionRect.opacity = 0.5;<BR><BR>&nbsp;&nbsp;&nbsp; map.LoadMap(<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT></FONT><FONT face="Courier New" color=#0000ff size=2>new</FONT><FONT size=2><FONT face="Courier New"> VELatLong(landmark.Latitude, landmark.Longitude),<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 2,<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; VEMapStyle.Oblique);<BR>}</FONT></P></FONT>
<P><STRONG><FONT face=Verdana color=#004080 size=2>Creating Virtual Earth Mashups</FONT></STRONG><FONT face=Verdana size=2><BR>This mashup uses the the <A href="https://dev.live.com/virtualearth/sdk/" mce_href="https://dev.live.com/virtualearth/sdk/">Virtual Earth Map Control SDK, version 4.0</A>, which allows you to create client-side Web apps. The <A href="https://dev.live.com/virtualearth/" mce_href="https://dev.live.com/virtualearth/">Virtual Earth Development</A> portal provides you samples, tutorials, and other developer content to get you started creating mashups.</FONT></P>
<P><FONT face=Verdana><FONT size=2>Enjoy,<BR>Lorin<BR></FONT><FONT color=#808080 size=1>WPF/E Developer Content Team</FONT></FONT></P><!-- End blog posting -->
<p><a href="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/39/44/05/Landmarks.zip" original-url="https://blogs.msdn.com/cfs-file.ashx/__key/communityserver-components-postattachments/00-01-39-44-05/Landmarks.zip">Landmarks.zip</a></p>]]></content:encoded>
    </item>
    <item>
      <title>New WPF/E QuickStart Released Online</title>
      <link>https://docs.microsoft.com/archive/blogs/wpfedevcon/new-wpfe-quickstart-released-online</link>
      <pubDate>Sat, 23 Dec 2006 03:00:00 GMT</pubDate>
      <dc:creator><![CDATA[wpfedevcon]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/wpfedevcon/2006/12/23/new-wpfe-quickstart-released-online/</guid>
      <description><![CDATA[A refresh of the WPF/E SDK has just been posted to the WPF/E DevCenter and MSDN Library.&nbsp; For...]]></description>
      <content:encoded><![CDATA[<P><FONT face=Verdana size=2>A refresh of the WPF/E SDK has just been posted to the WPF/E DevCenter and MSDN Library.&nbsp; For more information on downloading the WPF/E SDK, see the <A href="https://www.msdn.com/wpfe" mce_href="https://www.msdn.com/wpfe">MSDN WPF/E Dev Center</A>. The SDK refresh includes:</FONT></P>
<UL>
<LI><FONT face=Verdana size=2>Updated SDK docs</FONT></LI>
<LI><FONT face=Verdana size=2>Updated QuickStart</FONT></LI>
<LI><FONT face=Verdana size=2>VS Template support for VS 2005 SP1</FONT></LI></UL>
<P><FONT face=Verdana size=2>The MSDN Library provides the <A href="https://msdn2.microsoft.com/en-us/library/bb188266.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb188266.aspx">WPF/E SDK</A> overviews and reference content for the exposed API set and XAML.</FONT></P>
<P><FONT face=Verdana size=2><STRONG><FONT color=#004080>WPF/E QuickStart</FONT></STRONG><BR>The WPF/E QuickStart is now available online at the following Web location:</FONT></P>
<P><FONT face=Verdana size=2>&nbsp;&nbsp; <A href="https://go.microsoft.com/fwlink/?LinkID=82158">WPF/E QuickStart</A></FONT></P>
<P><FONT face=Verdana size=2>The WPF/E QuickStart is designed to show you how to create a simple WPF/E application in a short time. <I><FONT color=#006699><B>Try it out!</B></FONT></I></FONT></P>
<P><A href="https://go.microsoft.com/fwlink/?LinkID=82158"><IMG height=482 alt="View the WPF/E QuickStart" src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/34/98/62/QuickStart_01.png" original-url="https://blogs.msdn.com/photos/wpfedevcon/images/1349862/original.aspx"></A><BR><BR><FONT face=Verdana><FONT size=2>Enjoy,<BR>Lorin<BR></FONT><FONT color=#808080 size=1>WPF/E Developer Content Team</FONT></FONT></P>]]></content:encoded>
    </item>
    <item>
      <title>WPF/E Control Model</title>
      <link>https://docs.microsoft.com/archive/blogs/wpfedevcon/wpfe-control-model</link>
      <pubDate>Wed, 06 Dec 2006 17:00:00 GMT</pubDate>
      <dc:creator><![CDATA[wpfedevcon]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/wpfedevcon/2006/12/06/wpfe-control-model/</guid>
      <description><![CDATA[Microsoft has just released the first pre-release version of WPF/E, which is a Web technology that...]]></description>
      <content:encoded><![CDATA[<P>Microsoft has just released the first pre-release version of WPF/E, which is a Web technology that uses a subset of WPF XAML (e<FONT color=#004080><B>X</B></FONT>tensible <FONT color=#004080><B>A</B></FONT>pplication <FONT color=#004080><B>M</B></FONT>arkup <FONT color=#004080><B>L</B></FONT>anguage). For more information on WPF/E, see <A href="https://www.msdn.com/wpfe" mce_href="https://www.msdn.com/wpfe">MSDN WPF/E Dev Center</A>.</P>
<P>The MSDN Library provides the <A href="https://msdn2.microsoft.com/en-us/library/bb188266.aspx" mce_href="https://msdn2.microsoft.com/en-us/library/bb188266.aspx">WPF/E SDK</A> overviews and reference content for the exposed API set and XAML. The WPF/E SDK can also be downloaded from the <A href="https://www.msdn.com/wpfe" mce_href="https://www.msdn.com/wpfe">MSDN WPF/E Dev Center</A>, and includes a <B><FONT color=#004080>WPF/E QuickStart Tutorial</FONT></B> that guides you through key features and concepts in building WPF/E applications.</P>
<P><STRONG><FONT color=#004080>WPF/E Control</FONT></STRONG><BR>When you install the WPF/E runtime components, you install a browser plug-in that exposes a WPF/E control. WPF/E content is displayed by using one or more WPF/E controls that are defined on an HTML page. The OBJECT and EMBED tags are the HTML tags that allow you to reference the WPF/E control. The OBJECT and EMBED tags direct the browser to load the WPF/E control, using the set of supplied parameter values. These tags also allow you to define an identifier which can be used to access the control at runtime.</P>
<P>The WPF/E control is packaged differently on the supported platforms. Internet Explorer on Windows uses an ActiveX model to host WPF/E controls, while all other browser and platform combinations use the Netscape plug-in technology to host WPF/E controls.</P>
<P>The following diagram shows the relationship of the Web page, the host WPF/E control, and its WPF/E content:</P>
<P><IMG height=328 alt="Relationship of Web page to WPF/E content" src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/23/11/61/WebPage_01.png" original-url="https://blogs.msdn.com/photos/wpfedevcon/images/1231161/original.aspx" width=452 border=0 mce_src="https://blogs.msdn.com/photos/wpfedevcon/images/1231161/original.aspx"><BR><B><FONT size=1>Relationship of Web page to WPF/E content</FONT></B></P>
<P>Once you have created the WPF/E control, you can reference its id value by using the Document Object Model (DOM) for the Web page. The following JavaScript example shows how to retrieve the id value of the WPF/E control by using the <B>document.getElementById</B> method:</P>
<P><FONT face="Courier New">var wpfeControl = document.getElementById("WpfeControl1");</FONT></P>
<P><STRONG><FONT color=#004080>WPF/E Object Hierarchy</FONT></STRONG><BR>When you add XAML objects to the WPF/E control, you are defining a hierarchical tree structure with a root object. For example, the following XAML example creates a object hierarchy containing a parent <B>Canvas</B> object and a child <B>TextBlock</B> and <B>Canvas</B> object. In this case, the first <B>Canvas</B> object defined is the root object for the tree structure.</P><FONT color=#0000ff size=2>
<P><FONT face="Courier New">&lt;</FONT></FONT><FONT face="Courier New"><FONT color=#800000 size=2>Canvas</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>xmlns</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>https://schemas.microsoft.com/client/2007</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> &gt;<BR><BR>&nbsp; &lt;!--</FONT><FONT color=#008000 size=2> Canvas objects can be a child of a Canvas object. </FONT><FONT color=#0000ff size=2>--&gt;<BR>&nbsp; &lt;</FONT><FONT color=#800000 size=2>Canvas</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Canvas.Left</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>20</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Canvas.Top</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>20</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt;<BR>&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>Rectangle</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Width</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>200</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Height</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>35</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Fill</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>PowderBlue</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> /&gt;<BR>&nbsp;&nbsp;&nbsp; &lt;</FONT><FONT color=#800000 size=2>TextBlock</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Canvas.Left</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>25</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Canvas.Top</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>5</FONT><FONT size=2>"<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT><FONT color=#ff0000 size=2>Foreground</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>Teal</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>FontFamily</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>Verdana</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt;<BR></FONT><FONT size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Sample Output<BR></FONT><FONT color=#0000ff size=2>&nbsp;&nbsp;&nbsp; &lt;/</FONT><FONT color=#800000 size=2>TextBlock</FONT><FONT color=#0000ff size=2>&gt;<BR>&nbsp; &lt;/</FONT><FONT color=#800000 size=2>Canvas</FONT><FONT color=#0000ff size=2>&gt;<BR><BR>&nbsp; &lt;</FONT><FONT color=#800000 size=2>TextBlock</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Canvas.Left</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>36</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2> </FONT><FONT color=#ff0000 size=2>Canvas.Top</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>80</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2><BR>&nbsp;&nbsp;&nbsp; </FONT><FONT color=#ff0000 size=2>Foreground</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>Maroon</FONT><FONT size=2>" </FONT><FONT color=#ff0000 size=2>FontFamily</FONT><FONT color=#0000ff size=2>=</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>Verdana</FONT><FONT size=2>"</FONT><FONT color=#0000ff size=2>&gt;<BR>&nbsp;&nbsp;&nbsp; </FONT><FONT size=2>Hello, world<BR>&nbsp; </FONT><FONT color=#0000ff size=2>&lt;/</FONT><FONT color=#800000 size=2>TextBlock</FONT><FONT color=#0000ff size=2>&gt;<BR><BR>&lt;/</FONT><FONT color=#800000 size=2>Canvas</FONT><FONT color=#0000ff size=2>&gt;</FONT></FONT></P>
<P>XAML content is converted into a a hierarchical tree structure with a root object. For example, the content in the previous XAML example is converted into the following tree structure:</P>
<P><IMG height=220 alt="XAML content as a tree structure" src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/23/11/63/VisualTree_01.png" original-url="https://blogs.msdn.com/photos/wpfedevcon/images/1231163/original.aspx" width=293 border=0 mce_src="https://blogs.msdn.com/photos/wpfedevcon/images/1231163/original.aspx"><BR><B><FONT size=1>XAML content as a tree structure</FONT></B></P>
<P>The tree structure determines the rendering ordering of WPF/E objects. The order of traversal starts with the root object, which is the top-most node in the tree structure. The root object's children are then traversed, left to right. If an object has children, its children are traversed before the object's siblings. This means the content of a child object is rendered in front of the object's own content. Here is the rendered output from the previous XAML example, showing the rendering order sequence:</P>
<P><IMG height=160 alt="Rendering order of XAML content" src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/01/23/11/66/XAMLOutput_01.png" original-url="https://blogs.msdn.com/photos/wpfedevcon/images/1231166/original.aspx" width=435 border=0 mce_src="https://blogs.msdn.com/photos/wpfedevcon/images/1231166/original.aspx"><BR><B><FONT size=1>Rendering order of XAML content</FONT></B></P>
<P><STRONG><FONT color=#004080>WPF/E XAML<BR></FONT></STRONG>For those of you who are familiar with WPF, the pre-release version of WPF/E will look familiar as far as XAML is concerned, even though it is a reduced subset. Try it out and see what you think!</P>
<P>Enjoy,<BR>Lorin<BR><FONT color=#808080 size=1>WPF/E Developer Content Team</FONT></P>]]></content:encoded>
    </item>
  </channel>
</rss>