Asp.net源码专业站
首页->控件应用->简单WEB流程图组件Demo源码>>WorkFlowChart_Source/WorkFlowChart/NodeAttributes.cs>>源码在线查看
温馨提示:代码在线浏览功能只能做为源码浏览参考,如果想更进一步了解该代码请下载:简单WEB流程图组件Demo源码
当前文件:文件类型 WorkFlowChartDemo/WorkFlowChart_Source/WorkFlowChart/NodeAttributes.cs[2K,2009-6-12 11:58:39]打开代码结构图
普通视图
		            
1namespace WorkFlowChart 2{ 3 using System; 4 using System.Collections.Generic; 5 using System.Drawing; 6 7 public class NodeAttributes 8 { 9 private Dictionary<AbstractNode, AbstractNode> _backNodes = new Dictionary<AbstractNode, AbstractNode>(); 10 private Dictionary<AbstractNode, AbstractNode> _breakNodes = new Dictionary<AbstractNode, AbstractNode>(); 11 private Graphics _g; 12 private System.Drawing.Pen _pen; 13 14 public void BackAdd(AbstractNode NodeStart, AbstractNode NodeEnd) 15 { 16 this._backNodes.Add(NodeStart, NodeEnd); 17 } 18 19 public void BreakAdd(AbstractNode NodeStart, AbstractNode NodeEnd) 20 { 21 this._breakNodes.Add(NodeStart, NodeEnd); 22 } 23 24 public void Draw() 25 { 26 int i = 0; 27 int j = 0; 28 foreach (AbstractNode node in this._backNodes.Keys) 29 { 30 i++; 31 node.DrawOneLineBack(this.G, this.Pen, this._backNodes[node], this.BackCount + (10 * i)); 32 } 33 foreach (AbstractNode node in this._breakNodes.Keys) 34 { 35 j++; 36 node.DrawOneLineBreak(this.G, this.Pen, this._breakNodes[node], this.BreakCount + (10 * j)); 37 } 38 } 39 40 public void Draw(Graphics g) 41 { 42 int i = 0; 43 int j = 0; 44 foreach (AbstractNode node in this._backNodes.Keys) 45 { 46 i++; 47 node.DrawOneLineBack(g, this.Pen, this._backNodes[node], this.BackCount + (10 * i)); 48 } 49 foreach (AbstractNode node in this._breakNodes.Keys) 50 { 51 j++; 52 node.DrawOneLineBreak(g, this.Pen, this._breakNodes[node], this.BreakCount + (10 * j)); 53 } 54 } 55 56 public int BackCount 57 { 58 get 59 { 60 return this._backNodes.Count; 61 } 62 } 63 64 public int BreakCount 65 { 66 get 67 { 68 return this._breakNodes.Count; 69 } 70 } 71 72 public Graphics G 73 { 74 get 75 { 76 return this._g; 77 } 78 set 79 { 80 this._g = value; 81 } 82 } 83 84 public System.Drawing.Pen Pen 85 { 86 get 87 { 88 return this._pen; 89 } 90 set 91 { 92 this._pen = value; 93 } 94 } 95 } 96} 97 98
还没有找到您心仪的内容?请用.net源码大搜捕
代码片断 打包下载该项目完整源码:简单WEB流程图组件Demo源码
51Aspx.com 版权所有 CopyRight © 2006-2010. 京ICP备06046876号 本站法律顾问:ITlaw-庄毅雄律师
返回顶部
客户服务:点击这里进行客户咨询 业务合作:点击这里洽谈业务合作 合作热线:010-68880146