예제 #1
0
        /// <summary>
        /// Gets a PrintDocument to work with the standard Windows print dialogs</summary>
        /// <returns>PrintDocument to work with the standard Windows print dialogs</returns>
        public PrintDocument GetPrintDocument()
        {
            // static allocation, to remember print settings
            if (s_printDocument == null)
                s_printDocument = new FsmPrintDocument();

            s_printDocument.SetDocument(
                DomNode.Cast<EditingContext>(),
                DomNode.Cast<ViewingContext>());

            return s_printDocument;
        }
예제 #2
0
        /// <summary>
        /// Gets a PrintDocument to work with the standard Windows print dialogs</summary>
        /// <returns>PrintDocument to work with the standard Windows print dialogs</returns>
        public PrintDocument GetPrintDocument()
        {
            // static allocation, to remember print settings
            if (s_printDocument == null)
            {
                s_printDocument = new FsmPrintDocument();
            }

            s_printDocument.SetDocument(
                DomNode.Cast <EditingContext>(),
                DomNode.Cast <ViewingContext>());

            return(s_printDocument);
        }