You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
kev/Drawer/UCDraw/SigmaDrawerWellElement/WellPropLayerSettings.cs

202 lines
5.5 KiB
C#

1 month ago
using System.ComponentModel;
using System.Drawing.Design;
using System.Xml.Serialization;
using GeoSigma.SigmaDrawerStyle;
using SigmaDrawerStyle;
namespace GeoSigma.SigmaDrawerElement
{
#pragma warning disable SA1402 // File may only contain a single type
#pragma warning disable SA1600 // Elements should be documented
#pragma warning disable SA1649 // File name should match first type name
/// <summary>
/// 设置分层
/// </summary>
[XmlRoot("Pcg")]
[TypeConverter(typeof(PropertySorter))]
public class WellPropLayerSettings : baseInTrackObj
{
private const string propLayerCategory = "\t\t设置分层";
private const string vDepthCategory = "\t垂深";
[XmlIgnore]
[Category(propLayerCategory)]
[DisplayName("顶深")]
[PropertyOrder(0)]
public double TopDepth
{
get => Sand.Top;
set => Sand.Top = value;
}
[XmlIgnore]
[Category(propLayerCategory)]
[DisplayName("底深")]
[PropertyOrder(1)]
public double BottomDepth
{
get => Sand.Bottom;
set => Sand.Bottom = value;
}
[XmlIgnore]
[Category(propLayerCategory)]
[DisplayName("层名")]
[PropertyOrder(2)]
public string LayerName
{
get => Sand.Name;
set => Sand.Name = value;
}
[XmlIgnore]
[Category(propLayerCategory)]
[DisplayName("有效厚度")]
[PropertyOrder(3)]
public double ValidThickness
{
get => Sand.PureThickness;
set => Sand.PureThickness = value;
}
[XmlIgnore]
[Category(propLayerCategory)]
[DisplayName("解释结果")]
[PropertyOrder(4)]
[ListBoxEditor("InterpResult")]
[Editor(typeof(PropertyEditorListBox), typeof(UITypeEditor))]
public string InterpretationResult
{
get => Sand.FinalVerdict;
set => Sand.FinalVerdict = value;
}
[XmlAttribute("Version")]
[Browsable(false)]
public int Version { get; set; }
[Browsable(false)]
[XmlElement("Sand")]
public WellPropLayerSettingsSand Sand { get; set; }
//[XmlIgnore]
//[Category(vDepthCategory)]
//[DisplayName("顶深")]
//[ReadOnly(true)]
//[PropertyOrder(1)]
//public string topStr
//{
// get
// {
// if (vdpeth.vid == 0)
// return "";
// else
// return vdpeth.top.ToString();
// }
//}
//[XmlIgnore]
//[Category(vDepthCategory)]
//[DisplayName("底深")]
//[ReadOnly(true)]
//[PropertyOrder(2)]
//public string bottomStr
//{
// get
// {
// if (vdpeth.vid == 0)
// return "";
// else
// return vdpeth.bottom.ToString();
// }
//}
//[XmlElement("VerticalDepth")]
//[Browsable(false)]
//public VerticalDepth vdpeth { get; set; }
}
public class WellPropLayerSettingsSand
{
[XmlAttribute("Name")]
public string Name { get; set; }
[XmlAttribute("Top")]
public double Top { get; set; }
[XmlAttribute("Bottom")]
public double Bottom { get; set; }
[XmlAttribute("PureThickness")]
public double PureThickness { get; set; }
[XmlAttribute("FinalVerdict")]
public string FinalVerdict { get; set; }
[XmlAttribute("TestVerdict")]
public string TestVerdict { get; set; }
[XmlAttribute("Facies")]
public string Facies { get; set; }
[XmlElement("RenderStyle")]
public WellPropLayerSettingsRenderStyle RenderStyle { get; set; }
}
public class WellPropLayerSettingsRenderStyle
{
[XmlAttribute("Type")]
public string Type { get; set; }
[XmlAttribute("LayerBorderColor")]
public string LayerBorderColor { get; set; }
[XmlAttribute("LayerBorderWidth")]
public double LayerBorderWidth { get; set; }
[XmlAttribute("LayerNameSpace")]
public double LayerNameSpace { get; set; }
[XmlAttribute("ReversePattern")]
public bool ReversePattern { get; set; }
[XmlAttribute("ShowLayerName")]
public bool ShowLayerName { get; set; }
[XmlAttribute("ShowPureThickness")]
public bool ShowPureThickness { get; set; }
[XmlAttribute("ShowTextMultiLine")]
public bool ShowTextMultiLine { get; set; }
[XmlAttribute("ShowThickness")]
public bool ShowThickness { get; set; }
[XmlAttribute("TextSpace")]
public double TextSpace { get; set; }
[XmlAttribute("ThicknessFormat")]
public string ThicknessFormat { get; set; }
[XmlElement("TextBackBrush")]
public TextBackBrush TextBackBrush { get; set; }
}
public class TextBackBrush
{
[XmlAttribute("Style")]
public string Style { get; set; }
[XmlAttribute("BackColor")]
public string BackColor { get; set; }
[XmlAttribute("ForeColor")]
public string ForeColor { get; set; }
}
#pragma warning restore SA1649 // File name should match first type name
#pragma warning restore SA1600 // Elements should be documented
#pragma warning restore SA1402 // File may only contain a single type
}