用形状填充文本 [英] Fill text with in a Shape
本文介绍了用形状填充文本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如何在C#Silverlight中以诸如圆形(或椭圆)(多边形)的形状填充文本(或标签). >
例如 http://www.sitepoint.com/create-type-within- a-shape-in-photoshop/ [ ^ ]
在此先感谢...
How to fill text(or)label with in a shape like circle(or)eclipse(or)polygon..................in C# Silverlight.
For example like http://www.sitepoint.com/create-type-within-a-shape-in-photoshop/[^]
Thanks in Advance...
推荐答案
在矩形内添加文本将帮助您解决问题.
Adding text inside a rectangle would help you solve the problem.
Rectangle r = new Rectangle() { Height = 100, Width = 100 };
TextBlock tb = new TextBlock();
除此之外,您还可以查看 http://silverlemma.blogspot.in /2009/03/creating-graphical-shapes-dynamically.html [ ^ ].
Apart from this, you can also look at things like http://silverlemma.blogspot.in/2009/03/creating-graphical-shapes-dynamically.html[^].
请参阅此内容,可能会对您有所帮助
http://weblogs.asp.net/psheriff/archive/2010/01/04/centering-text-within-a-wpf-shape-using-a-canvas.aspx [
Refer this, might help you
http://weblogs.asp.net/psheriff/archive/2010/01/04/centering-text-within-a-wpf-shape-using-a-canvas.aspx[^]
这篇关于用形状填充文本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文