예제 #1
0
        public void RunPageLayout(NSObject sender)
        {
            // Define objects
            var dlg = new NSPageLayout();

            // Display dialog
            dlg.BeginSheet(PrintInfo, Window, () => {
                // Handle layout change
            });
        }
예제 #2
0
        void ShowLayout(NSObject sender)
        {
            var dlg = new NSPageLayout();

            // Display the print dialog as dialog box
            if (ShowPrintAsSheet)
            {
                dlg.BeginSheet(new NSPrintInfo(), this);
            }
            else
            {
                if (dlg.RunModal() == 1)
                {
                    var alert = new NSAlert()
                    {
                        AlertStyle      = NSAlertStyle.Critical,
                        InformativeText = "We need to print the document here...",
                        MessageText     = "Print Document",
                    };
                    alert.RunModal();
                }
            }
        }
예제 #3
0
		void ShowLayout (NSObject sender) {
			var dlg = new NSPageLayout();

			// Display the print dialog as dialog box
			if (ShowPrintAsSheet) {
				dlg.BeginSheet (new NSPrintInfo (), this);
			} else {
				if (dlg.RunModal () == 1) {
					var alert = new NSAlert () {
						AlertStyle = NSAlertStyle.Critical,
						InformativeText = "We need to print the document here...",
						MessageText = "Print Document",
					};
					alert.RunModal ();
				}
			}
		}
		public void RunPageLayout (NSObject sender) {

			// Define objects
			var dlg = new NSPageLayout ();

			// Display dialog
			dlg.BeginSheet(PrintInfo, Window, () => {
				// Handle layout change
			});

		}