Exemple #1
0
        public void Set(ModInfoHolder Mod, DescType WindowType, string Title, string Message, string WindowTitle = null)
        {
            this.Mod = Mod;
            LocalModInfoArea.Visible  = false;
            ServerModInfoArea.Visible = false;
            UpdateInfoArea.Visible    = false;
            switch (WindowType)
            {
            case DescType.LocalModInfo: LocalModInfoArea.Visible = true; break;

            case DescType.ServerModInfo: ServerModInfoArea.Visible = true; break;

            case DescType.UpdateInfo: UpdateInfoArea.Visible = true; break;
            }
            labelTitle.Markup    = "<b>" + Title + "</b>";
            labelTextView.Text   = "";
            labelTextView.Markup = MarkdownConvert.ToPangoString(Message);
            if (string.IsNullOrWhiteSpace(labelTextView.Text))
            {
                labelTextView.Text = Message;
            }
            if (string.IsNullOrWhiteSpace(WindowTitle))
            {
                this.Title = "TTMM - " + Title;
            }
            else
            {
                this.Title = "TTMM - " + WindowTitle;
            }
        }
Exemple #2
0
 protected void OnChanged(object sender, EventArgs e)
 {
     labelTextView.Markup = MarkdownConvert.ToPangoString(entry3.Text.Replace("\\n", "\n"));
 }