public treeGraph() { InitializeComponent(); AnalyseFuction af; if (Program.curFileNamepath == "C:\\FishGame") { af = new AnalyseFuction("./test.txt"); } else { af = new AnalyseFuction("./calls.txt"); } af.readFile(); pieces = af.getPieceList(); //pieces[1].isHidden = true; //pieces[2].isHidden = true; //pieces[81].isHidden = true; //pieces[61].isHidden = true; // pieces[1].isHighlight = true; tc = new TreeControl(drawingSurface,pieces); //tc.setBranchHidden(86); //tc.setBranchHidden("fillColor"); tc.drawTree(); scrollViewer.ScrollToHorizontalOffset(pieces[0].topLeftCorner.X - this.Width/2 - 75); }
public elementBox(int _position,TreeControl _tc, ref ScrollViewer _scrollViewer) { this.InitializeComponent(); position = _position; tc = _tc; scrollViewer = _scrollViewer; // 在此点之下插入创建对象所需的代码。 }