本文整理匯總了C#中Altaxo.GetStringAttribute方法的典型用法代碼示例。如果您正苦於以下問題:C# Altaxo.GetStringAttribute方法的具體用法?C# Altaxo.GetStringAttribute怎麽用?C# Altaxo.GetStringAttribute使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Altaxo
的用法示例。
在下文中一共展示了Altaxo.GetStringAttribute方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。
示例1: Deserialize
public object Deserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent)
{
string colorSetName = info.GetString("Name");
var colorSetLevel = (Altaxo.Main.ItemDefinitionLevel)info.GetEnum("Level", typeof(Altaxo.Main.ItemDefinitionLevel));
var creationDate = info.GetDateTime("CreationDate");
var isPlotColorSet = info.GetBoolean("IsPlotColorSet");
int count = info.OpenArray("Colors");
var colors = new NamedColor[count];
for (int i = 0; i < count; ++i)
{
string name = info.GetStringAttribute("Name");
string cvalue = info.GetString("e");
colors[i] = new NamedColor(AxoColor.FromInvariantString(cvalue), name);
}
info.CloseArray(count);
return new ColorSet(colorSetName, colors);
}
示例2: ColorSet
private ColorSet(Altaxo.Serialization.Xml.IXmlDeserializationInfo info)
{
_name = info.GetString("Name");
int count = info.OpenArray("Colors");
_innerList = new NamedColor[count];
for (int i = 0; i < count; ++i)
{
string name = info.GetStringAttribute("Name");
string cvalue = info.GetString("e");
_innerList[i] = new NamedColor(AxoColor.FromInvariantString(cvalue), name, this);
}
info.CloseArray(count);
InitLazyVariables();
}