richTextBox1.SelectionColor = Color.Red;
richTextBox1.SelectionFont = new Font(richTextBox1.SelectionFont, FontStyle.Bold);
richTextBox1.SelectionAlignment = HorizontalAlignment.Center;This code centers all the text in the RichTextBox. The System.Windows.Forms RichTextBox is included in the System.Windows.Forms namespace, which is part of the standard .NET Framework package.