请教关于打印的问题
各位大哥,请问如何才能将RichTextBox里的内容分行打印出来,而且从RichTextBox的顶端开始显示?我的代码如下,但只能呈一行打印出来,并且这行处于RichTextBox的正中间。case "RichTextBox":
RichTextBox rt = (RichTextBox)c;
//ControlPaint.DrawButton(g, rt.Left, rt.Top, rt.Width, rt.Height, ButtonState.Pushed );
g.FillRectangle(new SolidBrush(rt.BackColor), rt.Left+1, rt.Top + 1, rt.Width+2, rt.Height -2);
g.DrawString(rt.Text, rt.Font, new SolidBrush(rt.ForeColor), rt.Left + 2, rt.Top +
rt.Height/2 - g.MeasureString("a", rt.Font).Height/2, new StringFormat());
break;