From cfab480121b3eac17f5ea18d62f029306b9e0a74 Mon Sep 17 00:00:00 2001 From: dimentox Date: Sun, 2 May 2010 18:07:45 +0000 Subject: [PATCH] git-svn-id: https://lsleditor.svn.sourceforge.net/svnroot/lsleditor@23 3f4676ac-adda-40fd-8265-58d1435b1672 --- trunk/EditForm.Designer.cs | 24 +++++++++++++----------- trunk/EditForm.cs | 20 +++++++++++++++++++- trunk/Editor/SyntaxRichTextBox.cs | 1 + trunk/LSLEditorForm.Designer.cs | 15 ++++++++++++++- trunk/LSLEditorForm.cs | 23 +++++++++++++++++++++++ trunk/Properties/Settings.Designer.cs | 2 +- trunk/Properties/Settings.settings | 2 +- trunk/app.config | 2 +- 8 files changed, 73 insertions(+), 16 deletions(-) diff --git a/trunk/EditForm.Designer.cs b/trunk/EditForm.Designer.cs index b77e4d3..c3be10c 100644 --- a/trunk/EditForm.Designer.cs +++ b/trunk/EditForm.Designer.cs @@ -31,8 +31,8 @@ namespace LSLEditor this.tabControl1 = new System.Windows.Forms.TabControl(); this.tabPage1 = new System.Windows.Forms.TabPage(); this.splitContainer1 = new System.Windows.Forms.SplitContainer(); - this.numberedTextBoxUC1 = new NumberedTextBox.NumberedTextBoxUC(); this.tvOutline = new System.Windows.Forms.TreeView(); + this.numberedTextBoxUC1 = new NumberedTextBox.NumberedTextBoxUC(); this.tabControl1.SuspendLayout(); this.tabPage1.SuspendLayout(); this.splitContainer1.Panel1.SuspendLayout(); @@ -64,6 +64,7 @@ namespace LSLEditor // // splitContainer1 // + this.splitContainer1.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D; this.splitContainer1.Dock = System.Windows.Forms.DockStyle.Fill; this.splitContainer1.Location = new System.Drawing.Point(3, 3); this.splitContainer1.Name = "splitContainer1"; @@ -79,28 +80,29 @@ namespace LSLEditor this.splitContainer1.Panel2.RightToLeft = System.Windows.Forms.RightToLeft.No; this.splitContainer1.RightToLeft = System.Windows.Forms.RightToLeft.No; this.splitContainer1.Size = new System.Drawing.Size(546, 232); - this.splitContainer1.SplitterDistance = 437; + this.splitContainer1.SplitterDistance = 397; this.splitContainer1.TabIndex = 7; // - // numberedTextBoxUC1 - // - this.numberedTextBoxUC1.Dock = System.Windows.Forms.DockStyle.Fill; - this.numberedTextBoxUC1.Location = new System.Drawing.Point(0, 0); - this.numberedTextBoxUC1.Name = "numberedTextBoxUC1"; - this.numberedTextBoxUC1.Size = new System.Drawing.Size(437, 232); - this.numberedTextBoxUC1.TabIndex = 4; - // // tvOutline // this.tvOutline.Dock = System.Windows.Forms.DockStyle.Fill; this.tvOutline.HotTracking = true; this.tvOutline.Location = new System.Drawing.Point(0, 0); this.tvOutline.Name = "tvOutline"; - this.tvOutline.Size = new System.Drawing.Size(105, 232); + this.tvOutline.Size = new System.Drawing.Size(141, 228); this.tvOutline.TabIndex = 6; + this.tvOutline.VisibleChanged += new System.EventHandler(this.tvOutline_VisibleChanged); this.tvOutline.AfterSelect += new System.Windows.Forms.TreeViewEventHandler(this.tvOutline_AfterSelect); this.tvOutline.NodeMouseClick += new System.Windows.Forms.TreeNodeMouseClickEventHandler(this.tvOutline_NodeMouseClick); // + // numberedTextBoxUC1 + // + this.numberedTextBoxUC1.Dock = System.Windows.Forms.DockStyle.Fill; + this.numberedTextBoxUC1.Location = new System.Drawing.Point(0, 0); + this.numberedTextBoxUC1.Name = "numberedTextBoxUC1"; + this.numberedTextBoxUC1.Size = new System.Drawing.Size(393, 228); + this.numberedTextBoxUC1.TabIndex = 4; + // // EditForm // this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); diff --git a/trunk/EditForm.cs b/trunk/EditForm.cs index c39fc83..d79a7ae 100644 --- a/trunk/EditForm.cs +++ b/trunk/EditForm.cs @@ -57,7 +57,7 @@ namespace LSLEditor private string m_FullPathName; private Guid m_Guid; - + private bool sOutline = true; public LSLEditorForm parent; private const int WM_NCACTIVATE = 0x0086; @@ -158,6 +158,14 @@ namespace LSLEditor imageList.Images.Add(new Bitmap(this.GetType(), "Images.States.gif")); this.tvOutline.ImageList = imageList; + if (lslEditorForm.outlineToolStripMenuItem.Checked) + { + splitContainer1.Panel2Collapsed = false; + } + else + { + splitContainer1.Panel2Collapsed = true; + } SetFont(); } @@ -486,5 +494,15 @@ namespace LSLEditor //this.TextBox.Select } + + private void splitContainer1_Click(object sender, EventArgs e) + { + + } + + private void tvOutline_VisibleChanged(object sender, EventArgs e) + { + this.tvOutline.ExpandAll(); + } } } \ No newline at end of file diff --git a/trunk/Editor/SyntaxRichTextBox.cs b/trunk/Editor/SyntaxRichTextBox.cs index 1b982af..807affd 100644 --- a/trunk/Editor/SyntaxRichTextBox.cs +++ b/trunk/Editor/SyntaxRichTextBox.cs @@ -2147,6 +2147,7 @@ namespace LSLEditor p.tvOutline.EndUpdate(); // p.tvOutline.Nodes.Add(states); p.tvOutline.ExpandAll(); + } } diff --git a/trunk/LSLEditorForm.Designer.cs b/trunk/LSLEditorForm.Designer.cs index 91ec2ef..a2cfd8d 100644 --- a/trunk/LSLEditorForm.Designer.cs +++ b/trunk/LSLEditorForm.Designer.cs @@ -141,6 +141,7 @@ namespace LSLEditor this.pageSetupDialog1 = new System.Windows.Forms.PageSetupDialog(); this.openFileDialog2 = new System.Windows.Forms.OpenFileDialog(); this.toolTip1 = new System.Windows.Forms.ToolTip(this.components); + this.outlineToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.tabControlExtended1 = new System.Windows.Forms.TabControlExtended(this.components); this.tabControlExtended2 = new System.Windows.Forms.TabControlExtended(this.components); this.tabPage1 = new System.Windows.Forms.TabPage(); @@ -639,7 +640,8 @@ namespace LSLEditor // toolStripMenuItem2 // this.toolStripMenuItem2.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.solutionExplorerToolStripMenuItem}); + this.solutionExplorerToolStripMenuItem, + this.outlineToolStripMenuItem}); this.toolStripMenuItem2.Name = "toolStripMenuItem2"; this.toolStripMenuItem2.Size = new System.Drawing.Size(44, 20); this.toolStripMenuItem2.Text = "View"; @@ -1026,6 +1028,16 @@ namespace LSLEditor // this.openFileDialog2.FileName = "openFileDialog2"; // + // outlineToolStripMenuItem + // + this.outlineToolStripMenuItem.Checked = true; + this.outlineToolStripMenuItem.CheckOnClick = true; + this.outlineToolStripMenuItem.CheckState = System.Windows.Forms.CheckState.Checked; + this.outlineToolStripMenuItem.Name = "outlineToolStripMenuItem"; + this.outlineToolStripMenuItem.Size = new System.Drawing.Size(163, 22); + this.outlineToolStripMenuItem.Text = "Outline"; + this.outlineToolStripMenuItem.CheckedChanged += new System.EventHandler(this.outlineToolStripMenuItem_CheckedChanged); + // // tabControlExtended1 // this.tabControlExtended1.Dock = System.Windows.Forms.DockStyle.Bottom; @@ -1220,5 +1232,6 @@ namespace LSLEditor private System.Windows.Forms.ToolStripSeparator toolStripSeparator17; private System.Windows.Forms.ToolStripMenuItem toolStripMenuItem8; private System.Windows.Forms.ToolTip toolTip1; + public System.Windows.Forms.ToolStripMenuItem outlineToolStripMenuItem; } } \ No newline at end of file diff --git a/trunk/LSLEditorForm.cs b/trunk/LSLEditorForm.cs index 8ba3f5f..44b9672 100644 --- a/trunk/LSLEditorForm.cs +++ b/trunk/LSLEditorForm.cs @@ -1877,6 +1877,29 @@ namespace LSLEditor NativeHelper.SendMyKeys.ClipBoardToApp("SecondLife", null); } + private void outlineToolStripMenuItem_Click(object sender, EventArgs e) + { + //old + } + + private void outlineToolStripMenuItem_CheckedChanged(object sender, EventArgs e) + { + foreach (Form k in this.Children) + { + EditForm editForm = k as EditForm; + if (editForm == null) + return; + if (outlineToolStripMenuItem.Checked) + { + editForm.splitContainer1.Panel2Collapsed = false; + } + else + { + editForm.splitContainer1.Panel2Collapsed = true; + } + } + } + } } \ No newline at end of file diff --git a/trunk/Properties/Settings.Designer.cs b/trunk/Properties/Settings.Designer.cs index 1bdea9e..a920ff7 100644 --- a/trunk/Properties/Settings.Designer.cs +++ b/trunk/Properties/Settings.Designer.cs @@ -37,7 +37,7 @@ namespace LSLEditor.Properties { [global::System.Configuration.ApplicationScopedSettingAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - [global::System.Configuration.DefaultSettingValueAttribute("2.40.0")] + [global::System.Configuration.DefaultSettingValueAttribute("2.40.1")] public string Version { get { return ((string)(this["Version"])); diff --git a/trunk/Properties/Settings.settings b/trunk/Properties/Settings.settings index ca55cd7..e8202ed 100644 --- a/trunk/Properties/Settings.settings +++ b/trunk/Properties/Settings.settings @@ -6,7 +6,7 @@ SecondLife Name - 2.40.0 + 2.40.1 False diff --git a/trunk/app.config b/trunk/app.config index cf6ff09..37ff254 100644 --- a/trunk/app.config +++ b/trunk/app.config @@ -244,7 +244,7 @@ - 2.40.0 + 2.40.1 Resource.ConfLSL.xml