[英]WPF Printing large custom control
I'm sorry if this is a duplicate, but I couldn't find anything relating to it. 很抱歉,如果这是重复的,但是我找不到任何与此相关的信息。
I'm trying to create an XpsDocument from a custom control that I have. 我正在尝试从我拥有的自定义控件创建XpsDocument。 The custom control already defines properties for a header and a footer, along with the body.
自定义控件已经定义了页眉和页脚以及主体的属性。
The idea is to be able to use that same control (or derivatives of it) as an input to some custom DocumentPaginator that will create a printer-ready version of that "report", with the header and the footer put on every page, and the controls, inside the body, showing in full (I don't want to create a bitmap of the whole control, then scale it and cut it where the page ends). 想法是能够使用相同的控件(或其派生控件)作为某些自定义DocumentPaginator的输入,该自定义DocumentPaginator将创建该“报告”的打印机就绪版本,并在每页上放置页眉和页脚,并且控件在主体内部完整显示(我不想创建整个控件的位图,然后对其进行缩放并在页面结束处进行剪切)。
Any ideas on how I can split the contents of a user control into pages? 关于如何将用户控件的内容拆分为页面的任何想法? Or suggestions on a different way to achieve the printing of the control onto pages?
还是关于以其他方式将控件打印到页面上的建议?
Thanks a lot in advance 提前谢谢
Check of VisualDOcumentPaginator; 检查VisualDOcumentPaginator; http://www.codeproject.com/Articles/164033/WPF-Visual-Print-Component
http://www.codeproject.com/Articles/164033/WPF-Visual-Print-Component
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.