黑夜的狼

沮丧吗,那就是一种无病呻吟!留恋它就是一种高度近视!目光应该放得更远一点! 别不想飞,只是要一步跨过太平洋!

  博客园 :: 首页 :: 博问 :: 闪存 :: 新随笔 :: 联系 :: 订阅 订阅 :: 管理 ::
上一页 1 ··· 4 5 6 7 8 9 10 11 12 13 下一页

2011年1月22日

摘要: 运行环境: Silverlight 3.0(未在2.0下面做过测试,貌似本方法不支持2.0,因为2.0下面,ResourceDictionary没有Source属性)[代码]只要将ResourceDictionary.Source属性设置为合适的Uri,则可以通过Key来获取需要的对象。 补充:刚才又发现一个利用ResourceDictionary的场景在创建自定义控件时,我们有可能需要在Generic.xaml中定义多个控件的Style,定义的多了找起来就很麻烦,如果在单个文件里定义好,然后在Generic.xaml中包含(include)岂不是很好,看到了Telerik.RedContro 阅读全文
posted @ 2011-01-22 02:57 anncesky 阅读(934) 评论(0) 推荐(0) 编辑

2011年1月19日

摘要: Themes for Silverlight ApplicationsA theming system for Silverlight 2 apps... this post steps you through creating a set of theme assets, adding customizability of themes (colors and fonts in the sample), and using them in an application, including selecting a theme dynamically... complete with sour 阅读全文
posted @ 2011-01-19 23:38 anncesky 阅读(324) 评论(0) 推荐(0) 编辑

摘要: Silverlight学习资源和方法(持续更新总结)2010-09-24 11:43 by 撞破南墙, 354 visits, 网摘, 收藏, 编辑更新时间2010年10月27日11:37上午1书籍Silverlight 4 in ActionPete Brown's Site and BlogSource code (73 MB)2博客3综合网站4展示5框架6素材资源7Silverlight具体技术文章索引8游戏9相关技术================================2nasa综合型,包括深度一些的游戏解决办法http://www.cnblogs.com/nasa/cate 阅读全文
posted @ 2011-01-19 23:35 anncesky 阅读(347) 评论(1) 推荐(1) 编辑

2010年12月15日

摘要: Silverlight的旋转动画需要用到MatrixTransform属性的变化,这个是仿射矩阵变换的函数,它可以让图片产生视觉的旋转。他的原理并不是真正让图片的位置变化,而是变化平面x,y的坐标系,间接地让图片的坐标发生转变,而如何让坐标系的旋转精确地控制图片的旋转,这个就是仿射变换矩阵的作用:仿射变换(AffineTransformation)将一个仿射变换矩阵Ma解析为Ms×Mr×Mt,式中Ms为缩放矩阵,Mr为旋转矩阵,Mt为平移矩阵。仿射矩阵不应包含错切成分。具体操作可分为一下几步。1.平移矩阵的获取 Ms×Mr×Mt的过程中,位于Ma41,Ma42,Ma43的平移因子不会改变,故: 阅读全文
posted @ 2010-12-15 07:34 anncesky 阅读(516) 评论(0) 推荐(0) 编辑

摘要: 二维图形几何变换有平移,缩放,旋转,错切,反射等几种。二维图形由点或直线段组成的,而直线段又由两个端点连接而成的,从而对二维图形的变换都全部转换成点的变换。所以下面我们就点的变换原因来讨论。在讨论下面的问题之前,我们得先学习一个 System.Drawing.Drawing2.Matrix类,该类是坐标变换的最常用的类,当然你可以自己进行矩阵运算。1. 平移变换:平移变换的变换矩阵为: Tm= ,对应的Matrix定义为 Matrix m = new Matrix(1,0,0,1,Mx,My); 其中Mx是水平方向移动的距离,My是垂直方向的距离,向左负向右正,向下负向上正。2. 缩放变换 平 阅读全文
posted @ 2010-12-15 07:10 anncesky 阅读(396) 评论(0) 推荐(0) 编辑

2010年12月14日

摘要: 这只是基本的拖拽SL3.0以上,可以实现拖放目标的事件AllowDropDragEnterDragLeaveDragOverDrop 阅读全文
posted @ 2010-12-14 01:58 anncesky 阅读(250) 评论(0) 推荐(0) 编辑

2010年12月12日

摘要: 最近闲着无事,自定义了一个图片控件,主要是图片放大显示方式,图片加载显示,单击传出BitmapImage数据图片大小,我是写死了,因为我用的就是86×86的,腌就不管你们死活了!废话少说,直接看代码 阅读全文
posted @ 2010-12-12 02:56 anncesky 阅读(247) 评论(0) 推荐(0) 编辑

2010年12月11日

摘要: What happens when you create a Control? When do overrides get called and events get raised? When do styles get applied?In response to this thread on silverlight.net, I've whipped this simple table up. There are some subtle differences between instantiating a control in XAML, and instantiating it via 阅读全文
posted @ 2010-12-11 15:51 anncesky 阅读(168) 评论(0) 推荐(0) 编辑

2010年12月9日

摘要: What if you want to use a single animation object (let's say DoubleAnimation) to target multiple objects?This is especially useful when you have a large number of objects that have similar animations applied to them. For example, you are displaying rows of images and you want to use an animation to 阅读全文
posted @ 2010-12-09 18:43 anncesky 阅读(198) 评论(0) 推荐(0) 编辑

2010年12月8日

摘要: Silverlight图片相对路径的设置这个问题也困扰了我很久.经常在Project里包含一些图片,然后在应用里指定路径,结果就是Load不上,遇到ImageError的错误。这里列出一些常用的设置Image 相对路径的几种方法:假设我有这样一个solution,包括: MyImageLibrary,其中包含一个文件夹"Images\MyImage1.png"; MyLoadImage是我的Silverlight Application里面也有一个Images\MyImage2.png, 页面中有一Image控件来分别显示这两个图片那么有如下几种选择:Build Action="Resourc 阅读全文
posted @ 2010-12-08 22:52 anncesky 阅读(234) 评论(0) 推荐(0) 编辑

上一页 1 ··· 4 5 6 7 8 9 10 11 12 13 下一页