Index: src/Deltares.DSoilModel.Forms/CPTLookup2DControl.Designer.cs =================================================================== diff -u -r252 -r253 --- src/Deltares.DSoilModel.Forms/CPTLookup2DControl.Designer.cs (.../CPTLookup2DControl.Designer.cs) (revision 252) +++ src/Deltares.DSoilModel.Forms/CPTLookup2DControl.Designer.cs (.../CPTLookup1DControl.Designer.cs) (revision 253) @@ -1,6 +1,6 @@ namespace Deltares.DSoilModel.Forms { - partial class CPTLookup2DControl + partial class CPTLookup1DControl { /// /// Required designer variable. @@ -29,159 +29,60 @@ private void InitializeComponent() { this.OffsetGroupControl = new DevExpress.XtraEditors.GroupControl(); - this.XLabel = new DevExpress.XtraEditors.LabelControl(); - this.ZEdit = new DevExpress.XtraEditors.SpinEdit(); - this.XEdit = new DevExpress.XtraEditors.SpinEdit(); - this.ZLabel = new DevExpress.XtraEditors.LabelControl(); - this.CPTNameLabelControl = new DevExpress.XtraEditors.LabelControl(); - this.ProfileNameLabelControl = new DevExpress.XtraEditors.LabelControl(); this.CPTNameTextEdit = new DevExpress.XtraEditors.TextEdit(); - this.ProfileNameTextEdit = new DevExpress.XtraEditors.TextEdit(); + this.CPTNameLabelControl = new DevExpress.XtraEditors.LabelControl(); ((System.ComponentModel.ISupportInitialize)(this.OffsetGroupControl)).BeginInit(); this.OffsetGroupControl.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.ZEdit.Properties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.XEdit.Properties)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.CPTNameTextEdit.Properties)).BeginInit(); - ((System.ComponentModel.ISupportInitialize)(this.ProfileNameTextEdit.Properties)).BeginInit(); this.SuspendLayout(); // // OffsetGroupControl // - this.OffsetGroupControl.Controls.Add(this.ProfileNameTextEdit); this.OffsetGroupControl.Controls.Add(this.CPTNameTextEdit); - this.OffsetGroupControl.Controls.Add(this.ProfileNameLabelControl); this.OffsetGroupControl.Controls.Add(this.CPTNameLabelControl); - this.OffsetGroupControl.Controls.Add(this.XLabel); - this.OffsetGroupControl.Controls.Add(this.ZEdit); - this.OffsetGroupControl.Controls.Add(this.XEdit); - this.OffsetGroupControl.Controls.Add(this.ZLabel); this.OffsetGroupControl.Dock = System.Windows.Forms.DockStyle.Top; this.OffsetGroupControl.Location = new System.Drawing.Point(0, 0); - this.OffsetGroupControl.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); this.OffsetGroupControl.Name = "OffsetGroupControl"; - this.OffsetGroupControl.Size = new System.Drawing.Size(347, 174); + this.OffsetGroupControl.Size = new System.Drawing.Size(260, 68); this.OffsetGroupControl.TabIndex = 8; this.OffsetGroupControl.Text = "CPT Lookup"; // - // XLabel + // CPTNameTextEdit // - this.XLabel.Location = new System.Drawing.Point(21, 41); - this.XLabel.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); - this.XLabel.Name = "XLabel"; - this.XLabel.Size = new System.Drawing.Size(50, 16); - this.XLabel.TabIndex = 6; - this.XLabel.Text = "X Offset "; + this.CPTNameTextEdit.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); + this.CPTNameTextEdit.Location = new System.Drawing.Point(145, 32); + this.CPTNameTextEdit.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2); + this.CPTNameTextEdit.Name = "CPTNameTextEdit"; + this.CPTNameTextEdit.Size = new System.Drawing.Size(100, 20); + this.CPTNameTextEdit.TabIndex = 12; // - // ZEdit - // - this.ZEdit.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); - this.ZEdit.EditValue = new decimal(new int[] { - 0, - 0, - 0, - 0}); - this.ZEdit.EnterMoveNextControl = true; - this.ZEdit.Location = new System.Drawing.Point(200, 69); - this.ZEdit.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); - this.ZEdit.Name = "ZEdit"; - this.ZEdit.Properties.DisplayFormat.FormatType = DevExpress.Utils.FormatType.Numeric; - this.ZEdit.Properties.EditFormat.FormatString = "F3"; - this.ZEdit.Properties.EditFormat.FormatType = DevExpress.Utils.FormatType.Numeric; - this.ZEdit.Properties.HideSelection = false; - this.ZEdit.Size = new System.Drawing.Size(133, 22); - this.ZEdit.TabIndex = 9; - // - // XEdit - // - this.XEdit.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); - this.XEdit.EditValue = new decimal(new int[] { - 0, - 0, - 0, - 0}); - this.XEdit.EnterMoveNextControl = true; - this.XEdit.Location = new System.Drawing.Point(200, 37); - this.XEdit.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); - this.XEdit.Name = "XEdit"; - this.XEdit.Properties.DisplayFormat.FormatType = DevExpress.Utils.FormatType.Numeric; - this.XEdit.Properties.EditFormat.FormatString = "F3"; - this.XEdit.Properties.EditFormat.FormatType = DevExpress.Utils.FormatType.Numeric; - this.XEdit.Properties.HideSelection = false; - this.XEdit.Size = new System.Drawing.Size(133, 22); - this.XEdit.TabIndex = 7; - // - // ZLabel - // - this.ZLabel.Location = new System.Drawing.Point(21, 73); - this.ZLabel.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); - this.ZLabel.Name = "ZLabel"; - this.ZLabel.Size = new System.Drawing.Size(43, 16); - this.ZLabel.TabIndex = 8; - this.ZLabel.Text = "Z offset"; - // // CPTNameLabelControl // - this.CPTNameLabelControl.Location = new System.Drawing.Point(21, 110); - this.CPTNameLabelControl.Margin = new System.Windows.Forms.Padding(4); + this.CPTNameLabelControl.Location = new System.Drawing.Point(11, 34); this.CPTNameLabelControl.Name = "CPTNameLabelControl"; - this.CPTNameLabelControl.Size = new System.Drawing.Size(23, 16); + this.CPTNameLabelControl.Size = new System.Drawing.Size(19, 13); this.CPTNameLabelControl.TabIndex = 10; this.CPTNameLabelControl.Text = "CPT"; // - // ProfileNameLabelControl + // CPTLookup1DControl // - this.ProfileNameLabelControl.Location = new System.Drawing.Point(21, 143); - this.ProfileNameLabelControl.Margin = new System.Windows.Forms.Padding(4); - this.ProfileNameLabelControl.Name = "ProfileNameLabelControl"; - this.ProfileNameLabelControl.Size = new System.Drawing.Size(36, 16); - this.ProfileNameLabelControl.TabIndex = 11; - this.ProfileNameLabelControl.Text = "Profile"; - // - // CPTNameTextEdit - // - this.CPTNameTextEdit.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); - this.CPTNameTextEdit.Location = new System.Drawing.Point(200, 107); - this.CPTNameTextEdit.Name = "CPTNameTextEdit"; - this.CPTNameTextEdit.Size = new System.Drawing.Size(133, 22); - this.CPTNameTextEdit.TabIndex = 12; - // - // ProfileNameTextEdit - // - this.ProfileNameTextEdit.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); - this.ProfileNameTextEdit.Location = new System.Drawing.Point(200, 140); - this.ProfileNameTextEdit.Name = "ProfileNameTextEdit"; - this.ProfileNameTextEdit.Size = new System.Drawing.Size(133, 22); - this.ProfileNameTextEdit.TabIndex = 13; - // - // CPTLookupControl - // - this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 16F); + this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.Controls.Add(this.OffsetGroupControl); - this.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); - this.Name = "CPTLookupControl"; - this.Size = new System.Drawing.Size(347, 737); + this.Name = "CPTLookup1DControl"; + this.Size = new System.Drawing.Size(260, 599); ((System.ComponentModel.ISupportInitialize)(this.OffsetGroupControl)).EndInit(); this.OffsetGroupControl.ResumeLayout(false); this.OffsetGroupControl.PerformLayout(); - ((System.ComponentModel.ISupportInitialize)(this.ZEdit.Properties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.XEdit.Properties)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.CPTNameTextEdit.Properties)).EndInit(); - ((System.ComponentModel.ISupportInitialize)(this.ProfileNameTextEdit.Properties)).EndInit(); this.ResumeLayout(false); } #endregion private DevExpress.XtraEditors.GroupControl OffsetGroupControl; - private DevExpress.XtraEditors.LabelControl XLabel; - private DevExpress.XtraEditors.SpinEdit ZEdit; - private DevExpress.XtraEditors.SpinEdit XEdit; - private DevExpress.XtraEditors.LabelControl ZLabel; - private DevExpress.XtraEditors.TextEdit ProfileNameTextEdit; private DevExpress.XtraEditors.TextEdit CPTNameTextEdit; - private DevExpress.XtraEditors.LabelControl ProfileNameLabelControl; private DevExpress.XtraEditors.LabelControl CPTNameLabelControl; } Index: src/Deltares.DSoilModel.Forms/CPTLookup2DControl.cs =================================================================== diff -u -r252 -r253 --- src/Deltares.DSoilModel.Forms/CPTLookup2DControl.cs (.../CPTLookup2DControl.cs) (revision 252) +++ src/Deltares.DSoilModel.Forms/CPTLookup2DControl.cs (.../CPTLookup1DControl.cs) (revision 253) @@ -6,23 +6,20 @@ namespace Deltares.DSoilModel.Forms { - public partial class CPTLookup2DControl : UserControl, IPropertyControl + public partial class CPTLookup1DControl : UserControl, IPropertyControl { - private ConePenetrationTestLookup2D conePenetrationTestLookup; + private ConePenetrationTestLookup1D conePenetrationTestLookup; - public CPTLookup2DControl() + public CPTLookup1DControl() { InitializeComponent(); const string caption = "CPT Lookup"; ((IPropertyControl)this).Name = LocalizationManager.GetTranslatedText(this, caption); + + BindSupport.BindTextValueAndUnit(this, CPTNameLabelControl, CPTNameTextEdit, typeof(ConePenetrationTestLookup1D), "Name"); - BindSupport.BindTextValueAndUnit(this, XLabel, XEdit, typeof(ConePenetrationTestLookup2D), "Xlocal"); - BindSupport.BindTextValueAndUnit(this, ZLabel, ZEdit, typeof(ConePenetrationTestLookup2D), "Zlocal"); - BindSupport.BindTextValueAndUnit(this, CPTNameLabelControl, CPTNameTextEdit, typeof(ConePenetrationTestLookup2D), "CPTName"); - BindSupport.BindTextValueAndUnit(this, ProfileNameLabelControl, ProfileNameTextEdit, typeof(ConePenetrationTestLookup2D), "SoilProfileName"); - OffsetGroupControl.Text = caption; LocalizationSupport.RegisterAndTranslate(typeof(CPTControl), OffsetGroupControl); FormsSupport.RepairRightAnchoredControls(this); @@ -38,7 +35,7 @@ } set { - var lookup = value as ConePenetrationTestLookup2D; + var lookup = value as ConePenetrationTestLookup1D; if (lookup != null) { conePenetrationTestLookup = lookup; Index: src/Deltares.DSoilModel.Forms/Deltares.DSoilModel.Forms.csproj =================================================================== diff -u -r252 -r253 --- src/Deltares.DSoilModel.Forms/Deltares.DSoilModel.Forms.csproj (.../Deltares.DSoilModel.Forms.csproj) (revision 252) +++ src/Deltares.DSoilModel.Forms/Deltares.DSoilModel.Forms.csproj (.../Deltares.DSoilModel.Forms.csproj) (revision 253) @@ -199,6 +199,12 @@ BoringLookup1DControl.cs + + UserControl + + + CPTLookup1DControl.cs + UserControl @@ -307,6 +313,10 @@ BoringLookup1DControl.cs + + CPTLookup1DControl.cs + Designer + CPTControl.cs Designer Index: src/Deltares.DSoilModel.Forms/DSoilModelPlugin.cs =================================================================== diff -u -r252 -r253 --- src/Deltares.DSoilModel.Forms/DSoilModelPlugin.cs (.../DSoilModelPlugin.cs) (revision 252) +++ src/Deltares.DSoilModel.Forms/DSoilModelPlugin.cs (.../DSoilModelPlugin.cs) (revision 253) @@ -890,6 +890,7 @@ typeof(CenterCrestLocation)); mainForm.DynamicPropertyControl.BuildDelayedPropertyControlsForType(typeof(ConePenetrationTestData), () => new CPTControl()); + mainForm.DynamicPropertyControl.BuildDelayedPropertyControlForTypes(() => new CPTLookup1DControl(), typeof(ConePenetrationTestLookup1D)); mainForm.DynamicPropertyControl.BuildDelayedPropertyControlForTypes(() => new CPTLookup2DControl(), typeof(ConePenetrationTestLookup2D)); mainForm.DynamicPropertyControl.BuildDelayedPropertyControlsForType(typeof(Boring), () => new BoringControl());