本文整理汇总了C#中System.Xml.XmlWriter.WriteAttributeBool方法的典型用法代码示例。如果您正苦于以下问题:C# XmlWriter.WriteAttributeBool方法的具体用法?C# XmlWriter.WriteAttributeBool怎么用?C# XmlWriter.WriteAttributeBool使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类System.Xml.XmlWriter
的用法示例。
在下文中一共展示了XmlWriter.WriteAttributeBool方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Save
public void Save(XmlWriter writer)
{
writer.WriteAttributeGuid("id", Id);
writer.WriteAttributeEnum("type", MatchType);
writer.WriteAttributeString("value", Value);
writer.WriteAttributeBool("ignorecase", IgnoreCase);
writer.WriteAttributeBool("isinclude", IsInverted);
}
示例2: WriteCoordinateSystem
void WriteCoordinateSystem(Drawing drawing, XmlWriter writer)
{
writer.WriteStartElement("Viewport");
writer.WriteAttributeDouble("Left", drawing.CoordinateSystem.MinimalVisibleX);
writer.WriteAttributeDouble("Top", drawing.CoordinateSystem.MaximalVisibleY);
writer.WriteAttributeDouble("Right", drawing.CoordinateSystem.MaximalVisibleX);
writer.WriteAttributeDouble("Bottom", drawing.CoordinateSystem.MinimalVisibleY);
var backgroundBrush = drawing.Canvas.Background as SolidColorBrush;
if (backgroundBrush != null && backgroundBrush.Color != Colors.White)
{
writer.WriteAttributeString("Color", backgroundBrush.Color.ToString());
}
if (drawing.CoordinateGrid.Locked)
{
writer.WriteAttributeBool("Locked", true);
}
if (drawing.CoordinateGrid.Visible)
{
writer.WriteAttributeBool("Grid", true);
writer.WriteAttributeBool("Axes", drawing.CoordinateGrid.ShowAxes);
}
writer.WriteEndElement();
}
示例3: Save
public void Save(XmlWriter writer)
{
writer.WriteAttributeString("file", File);
writer.WriteAttributeBool("followtail", FollowTail);
writer.WriteAttributeBool("showlinenumbers", ShowLineNumbers);
writer.WriteAttributeString("searchterm", SearchTerm);
writer.WriteAttributeEnum("levelfilter", LevelFilter);
writer.WriteAttributeBool("colorbylevel", ColorByLevel);
writer.WriteAttributeInt("visibleentryindex", (int) VisibleLogLine);
writer.WriteAttributeGuid("id", Id);
writer.WriteAttributeGuid("parentid", ParentId);
writer.WriteAttributeDateTime("lastviewed", LastViewed);
writer.WriteAttributeDouble("horizontaloffset", HorizontalOffset);
writer.WriteStartElement("activatedquickfilters");
foreach (Guid guid in ActivatedQuickFilters)
{
writer.WriteStartElement("quickfilter");
writer.WriteAttributeGuid("id", guid);
writer.WriteEndElement();
}
writer.WriteEndElement();
}
示例4: WriteXml
public virtual void WriteXml(XmlWriter writer)
{
if (!Visible)
{
writer.WriteAttributeString("Visible", "false");
}
if (Locked)
{
writer.WriteAttributeString("Locked", "true");
}
if (Style != null)
{
writer.WriteAttributeString("Style", Style.Name);
}
if (Flipped)
{
writer.WriteAttributeBool("Flipped", true);
}
}
示例5: Save
public void Save(XmlWriter writer)
{
writer.WriteAttributeBool("checkforupdates", CheckForUpdates);
writer.WriteAttributeBool("automaticallyinstallupdates", AutomaticallyInstallUpdates);
writer.WriteAttributeBase64("passwordsalt", _passwordSalt);
writer.WriteAttributeString("proxyserver", ProxyServer);
writer.WriteAttributeString("proxyusername", ProxyUsername);
writer.WriteAttributeBase64("proxypassword", _password);
}