+bool
+wxHtmlPrintout::CheckFit(const wxSize& pageArea, const wxSize& docArea) const
+{
+ if ( docArea.x > pageArea.x )
+ {
+ wxMessageDialog
+ dlg
+ (
+ NULL,
+ wxString::Format
+ (
+ _("The document \"%s\" doesn't fit on the page "
+ "horizontally and will be truncated if printed.\n"
+ "\n"
+ "Would you like to proceed with printing it nevertheless?"),
+ GetTitle()
+ ),
+ _("Printing"),
+ wxOK | wxCANCEL | wxCANCEL_DEFAULT | wxICON_QUESTION
+ );
+ dlg.SetExtendedMessage
+ (
+ _("If possible, try changing the layout parameters to "
+ "make the printout more narrow.")
+ );
+ dlg.SetOKLabel(wxID_PRINT);
+
+ if ( dlg.ShowModal() == wxID_CANCEL )
+ return false;
+ }
+
+ return true;
+}
+