Exemplo n.º 1
0
        public static XmlElement ToXmlElement(this Pen pen)
        {
            XmlElement res = XmlElementGenerator.FromString("Wheat", pen);

            res.AppendChildren(XmlElementGenerator.FromNamePropsOf(pen, "Width", "Color"));
            return(res);
        }
Exemplo n.º 2
0
        XmlElement IXmlSavable.ToXmlElement()
        {
            XmlElement result = XmlElementGenerator.FromString(((IXmlSavable)this).Name, this);

            result.AppendChildren(XmlElementGenerator.FromSavablePropsOf(this));
            return(result);
        }
Exemplo n.º 3
0
        public static XmlElement ToXmlElement(this BrushBase brush)
        {
            XmlElement res = XmlElementGenerator.FromString("Wheat", brush);

            res.AppendChildren(XmlElementGenerator.FromNameFieldsOf(brush, "pen", "font"));
            return(res);
        }
Exemplo n.º 4
0
            XmlElement IXmlSavable.ToXmlElement()
            {
                XmlElement res = XmlElementGenerator.FromString(((IXmlSavable)this).Name, this);

                res.AppendChildren(XmlElementGenerator.FromNamePropsOf(this, "Brush"));
                return(res);
            }
Exemplo n.º 5
0
        public static XmlElement ToXmlElement(this Font font)
        {
            XmlElement res = XmlElementGenerator.FromString("Wheat", font);

            res.AppendChild(XmlElementGenerator.FromString("fontFamily", font.FontFamily.Name));
            res.AppendChildren(XmlElementGenerator.FromNamePropsOf(font, "Size", "Style"));
            return(res);
        }
Exemplo n.º 6
0
        public static XmlElement ToXmlElement(this Color color)
        {
            XmlElement res = XmlElementGenerator.FromString("Wheat", color);

            res.AppendChildren(XmlElementGenerator.FromNamePropsOf(color, "A", "R", "G", "B"));
            if (color.IsNamedColor)
            {
                res.AppendChildren(XmlElementGenerator.FromNamePropsOf(color, "Name"));
            }
            return(res);
        }
Exemplo n.º 7
0
 XmlElement IXmlSavable.ToXmlElement()
 {
     return(XmlElementGenerator.FromCollection(((IXmlSavable)this).Name, this, bingdingName: null));
 }