.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month

Home >> Articles >> Silverlight >> Post New Resource Bookmark and Share   

 Subscribe to Articles

Adding Reflection to the Text

Posted By:Nikhil Kumar       Posted Date: August 01, 2010    Points: 25    Category: Silverlight    URL: http://www.dotnetspark.com  

Adding Reflection to the Text

Adding Reflection to the Text




You can make your text elements look more attractive by adding avrious special effects to the text.

One such effect that can be implemented on the TextBlock element is Reflection you can create a new TextBlock to contain the reflection of the text written in the original TextBlock.You can then place the new TextBlock under the original TextBlock.

The reflection effect can be created by transforming the desired element by using the RenderTransform property of the element.




Consider the following code snippet:






The preceding code snippet creates two TextBlocks.The first TextBlock is created to display the actual text, whereas the second TextBlock is created to display the reflection of the text contained in the first TextBlock. The ScaleTransform tag scale the Y axis of the second TextBlock with a negative value to invert the text contained in it.


The following figure shows the output of the preceding code snippet


 Subscribe to Articles


Further Readings:


No response found. Be the first to respond this post

Post Comment

You must Sign In To post reply
Find More Articles on C#, ASP.Net, Vb.Net, SQL Server and more Here

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend