public PrintHelper(Image image)
 {
     this.image = image;
     printDialog.UseEXDialog    = true;
     printDocument.DocumentName = FilenameHelper.GetFilenameWithoutExtensionFromPattern(AppConfig.GetInstance().Output_File_FilenamePattern);
     printDocument.PrintPage   += GetImageForPrint;
     printDialog.Document       = printDocument;
 }
Esempio n. 2
0
 public PrintHelper(Image image, ICaptureDetails captureDetails)
 {
     this.image = image;
     printDialog.UseEXDialog    = true;
     printDocument.DocumentName = FilenameHelper.GetFilenameWithoutExtensionFromPattern(conf.OutputFileFilenamePattern, captureDetails);
     printDocument.PrintPage   += DrawImageForPrint;
     printDialog.Document       = printDocument;
 }
Esempio n. 3
0
 public PrintHelper(ISurface surface, ICaptureDetails captureDetails)
 {
     _surface                    = surface;
     _captureDetails             = captureDetails;
     _printDialog.UseEXDialog    = true;
     _printDocument.DocumentName = FilenameHelper.GetFilenameWithoutExtensionFromPattern(CoreConfig.OutputFileFilenamePattern, captureDetails);
     _printDocument.PrintPage   += DrawImageForPrint;
     _printDialog.Document       = _printDocument;
 }
Esempio n. 4
0
        public PrintHelper(
            ICoreConfiguration coreConfiguration,
            IGreenshotLanguage greenshotLanguage,
            Func <Owned <PrintOptionsDialog> > printOptionsDialogFactory,
            ISurface surface,
            ICaptureDetails captureDetails)
        {
            _coreConfig                = coreConfiguration;
            _greenshotLanguage         = greenshotLanguage;
            _printOptionsDialogFactory = printOptionsDialogFactory;

            _surface                    = surface;
            _captureDetails             = captureDetails;
            _printDialog.UseEXDialog    = true;
            _printDocument.DocumentName = FilenameHelper.GetFilenameWithoutExtensionFromPattern(coreConfiguration.OutputFileFilenamePattern, captureDetails);
            _printDocument.PrintPage   += DrawImageForPrint;
            _printDialog.Document       = _printDocument;
        }