Changes to actually print checkbox's and radiobuttons under Windows.

No longer need special offset's during printing. nsFormControlFrame now detects
when to gfx render the widgets.
This commit is contained in:
kmcclusk@netscape.com
1998-12-10 17:29:13 +00:00
parent c532221809
commit 5e8394aee9
4 changed files with 34 additions and 21 deletions

View File

@@ -230,11 +230,23 @@ nsFormControlFrame::Reflow(nsIPresContext& aPresContext,
//XXX:PRINTING Temporary to force GFX rendered widgets to appear on the display. This
//Will be used to debug GFX rendered widgets for printing. This should be removed when
//Printing is completely working.
PRBool renderToScreen = PR_FALSE;
if (PR_TRUE == renderToScreen) {
PRBool renderToScreen = PR_FALSE;
nsIDeviceContext* dx = nsnull;
dx = aPresContext.GetDeviceContext();
PRBool supportsWidgets = PR_FALSE;
if (nsnull != dx) {
PRBool native = PR_FALSE;
dx->SupportsNativeWidgets(supportsWidgets);
NS_RELEASE(dx);
}
if ((PR_TRUE == renderToScreen) || (PR_FALSE == supportsWidgets)) {
return(ReflowWithNoWidget(aPresContext, aDesiredSize, aReflowState, aStatus));
}
GetDesiredSize(&aPresContext, aReflowState, aDesiredSize, mWidgetSize);
if (!mDidInit) {