/// <summary> /// /// </summary> /// <param name="languageName"></param> public ScriptForm(Feng.Scripts.Host host) { InitializeComponent(); 打开OToolStripButton.Image = Feng.Windows.ImageResource.Get("Feng", "Icons.Document.Open.png").Reference; 保存SToolStripButton.Image = Feng.Windows.ImageResource.Get("Feng", "Icons.Document.Save.png").Reference; 复制CToolStripButton.Image = Feng.Windows.ImageResource.Get("Feng", "Icons.Document.Copy.png").Reference; 粘贴PToolStripButton.Image = Feng.Windows.ImageResource.Get("Feng", "Icons.Document.Paste.png").Reference; this.txtScript.KeyDown += new System.Windows.Forms.KeyEventHandler(this.richTextBox1_KeyDown); this.txtScript.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.Form1_KeyPress); txtScript.BackColor = _backColor; txtScript.ForeColor = _inputColor; txtScript.ShortcutsEnabled = true; m_host = host; _history = new CommandHistory(); ResetConsole(); m_host.Scope.SetVariable("scriptTextBox", this.txtScript); m_host.Runtime.Globals.SetVariable("prompt", PromptString); }
/// <summary> /// /// </summary> /// <param name="languageName"></param> public ScriptForm(Feng.Scripts.Host host) { InitializeComponent(); 打开OToolStripButton.Image = Feng.Windows.ImageResource.Get("Feng", "Icons.Document.Open.png").Reference; 保存SToolStripButton.Image = Feng.Windows.ImageResource.Get("Feng", "Icons.Document.Save.png").Reference; 制CToolStripButton.Image = Feng.Windows.ImageResource.Get("Feng", "Icons.Document.Copy.png").Reference; 粘贴PToolStripButton.Image = Feng.Windows.ImageResource.Get("Feng", "Icons.Document.Paste.png").Reference; this.txtScript.KeyDown += new System.Windows.Forms.KeyEventHandler(this.richTextBox1_KeyDown); this.txtScript.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.Form1_KeyPress); txtScript.BackColor = _backColor; txtScript.ForeColor = _inputColor; txtScript.ShortcutsEnabled = true; m_host = host; _history = new CommandHistory(); ResetConsole(); m_host.Scope.SetVariable("scriptTextBox", this.txtScript); m_host.Runtime.Globals.SetVariable("prompt", PromptString); }