]> git.saurik.com Git - wxWidgets.git/blobdiff - src/html/htmprint.cpp
test for pen validity before calling GetStyle() on it, this asserts now if the pen...
[wxWidgets.git] / src / html / htmprint.cpp
index cc804e27d34c35bb8041c4039f19407b78b72443..0d0d2a102a6007876135730d474ff648072b91d4 100644 (file)
@@ -251,7 +251,7 @@ bool wxHtmlPrintout::OnBeginDocument(int startPage, int endPage)
 bool wxHtmlPrintout::OnPrintPage(int page)
 {
     wxDC *dc = GetDC();
-    if (dc && dc->Ok())
+    if (dc && dc->IsOk())
     {
         if (HasPage(page))
             RenderPage(dc, page);
@@ -410,7 +410,7 @@ void wxHtmlPrintout::RenderPage(wxDC *dc, int page)
 
     m_Renderer->SetDC(dc, (double)ppiPrinterY / (double)ppiScreenY);
 
-    dc->SetBackgroundMode(wxTRANSPARENT);
+    dc->SetBackgroundMode(wxBRUSHSTYLE_TRANSPARENT);
 
     m_Renderer->Render((int) (ppmm_h * m_MarginLeft),
                          (int) (ppmm_v * (m_MarginTop + (m_HeaderHeight == 0 ? 0 : m_MarginSpace)) + m_HeaderHeight), m_PageBreaks,