Exemplo n.º 1
0
        public static void OutputOSInfo(this System.Windows.Controls.RichTextBox output)
        {
            var osInfo = GetOSInfo();

            output.AppendIndentedLine($"OSCaption       = {osInfo.Name}");
            output.AppendIndentedLine($"OSVersion       = {osInfo.Version.ToString()}");
            output.AppendIndentedLine($"OSArchitecture  = {osInfo.Architecture}");
            output.AppendIndentedLine($"VisibleMemoryGB = {osInfo.TotalVisibleMemory.ToString("n2")}");
            output.AppendIndentedLine($"FreeMemoryGB    = {osInfo.TotalFreeMemory.ToString("n2")}");
        }
Exemplo n.º 2
0
        public static void OutputCultureInfo(this System.Windows.Controls.RichTextBox output)
        {
            var curCulture = Thread.CurrentThread.CurrentCulture;

            //output.AppendRange("").Indent();
            output.AppendIndentedLine($"Culture Name              = {curCulture.Name}");
            output.AppendIndentedLine($"Culture DisplayName       = {curCulture.DisplayName}");
            output.AppendIndentedLine($"Culture EnglishName       = {curCulture.EnglishName}");
            output.AppendIndentedLine($"Culture 2-Letter ISO Name = {curCulture.TwoLetterISOLanguageName}");
            output.AppendIndentedLine($"Culture DecimalSeparator  = {curCulture.NumberFormat.NumberDecimalSeparator}");
            output.AppendIndentedLine($"Culture GroupSeparator    = {curCulture.NumberFormat.NumberGroupSeparator}");
            output.AppendIndentedLine($"Culture CurrencySymbol    = {curCulture.NumberFormat.CurrencySymbol}");
            output.AppendIndentedLine($"Culture ShortDatePattern  = {curCulture.DateTimeFormat.ShortDatePattern}");
        }
Exemplo n.º 3
0
 public static void AppendIndentedLine(this System.Windows.Controls.RichTextBox myOutput, string text)
 {
     myOutput.AppendIndentedLine(text, "Black");
 }
 public static TextRange AppendIndentedLine(this System.Windows.Controls.RichTextBox myOutput, string text)
 {
     return(myOutput.AppendIndentedLine(text, "Black"));
 }