protected void InitializeComponent_extended() { this.LastFallTime = new DateTime(); this.BackColor = Color.LimeGreen; this.TransparencyKey = Color.LimeGreen; this.Text = String.Format("Veneer {0}", ScreenIndex.ToString("D2")); }
/// <summary> /// Build a csv line describing this pup screen (to be saved in a screens.pup file) /// </summary> /// <returns></returns> public string GetCsv() { string text = ""; text += ScreenIndex.ToString() + ","; text += "\"" + Description + "\","; text += "\"" + PlayList + "\","; text += "\"" + Playfile + "\","; text += (Loopit?"1":"") + ","; text += Active + ","; text += Priority + ","; text += "\"" + CustomPos + "\""; return(text); }
/// <summary> /// get a description of this pup screen as a list item /// </summary> /// <returns></returns> public ListViewItem GetListViewItem() { return(new ListViewItem(new[] { ScreenIndex.ToString(), Description, //PlayList, //Playfile, //Loopit, Active, //Priority, CustomPos } )); }
public XmlElement GenerateXmlElement(XmlDocument doc) { var node = doc.CreateElement("Viewport"); node.SetAttribute("Index", ScreenIndex.ToString()); node.SetAttribute("Name", Name); if (!IsVisible) { node.SetAttribute("IsVisible", IsVisible.ToString()); } node.SetAttribute("TimeLength", TimeLength.ToString()); node.SetAttribute("SwitchMode", SwitchMode.ToString()); node.SetAttribute("SwitchHotKey", SwitchHotKey.ToString()); if (ElementsCaptionColor != System.Drawing.Color.White) { node.SetAttribute("ElementsCaptionColor", ElementsCaptionColor.ToArgb().ToString()); } if (ElementsCaptionScale != 1) { node.SetAttribute("ElementsCaptionScale", ElementsCaptionScale.ToString()); } foreach (var elm in Elements) { if (elm == null) { continue; } if (elm.Resource != null && elm.Resource.FullFilePath == ResourceInfo_BackgroundImage.DefaultBackgroundImageFile) { continue; } var enode = elm.GenerateXmlElement(doc); node.AppendChild(enode); } var gnode = ElemGroupCollector.GenerateXmlElement(doc); if (gnode != null) { node.AppendChild(gnode); } return(node); }