对话方块(七十三)

2010-12-30 21:13:56 · 作者: · 浏览: 41354
endMessage (hwndEdit, WM_SETFONT, (WPARAM) hFontNew, 0) ;
DeleteObject (hFont) ;
hFont = hFontNew ;
GetClientRect (hwndEdit, &rect) ;
InvalidateRect (hwndEdit, &rect, TRUE) ;
}

void PopFontDeinitialize (void)
{
DeleteObject (hFont) ;
}
 POPPRNT0.C
/*------------------------------------------------------------------------
POPPRNT0.C -- Popup Editor Printing Functions (dummy version)
--------------------------------------------------------------------------*/

#include <windows.h>
BOOL PopPrntPrintFile ( HINSTANCE hInst, HWND hwnd, HWND hwndEdit,
PTSTR pstrTitleName)
{
return FALSE ;
}
 POPPAD.RC (摘录)
//Microsoft Developer Studio generated resource script.
#include "resource.h"
#include "afxres.h"

/////////////////////////////////////////////////////////////////////////////
// Dialog
ABOUTBOX DIALOG DISCARDABLE 32, 32, 180, 100
STYLE DS_MODALFRAME | WS_POPUP
FONT 8, "MS Sans Serif"
BEGIN
DEFPUSHBUTTON "OK",IDOK,66,80,50,14
ICON "POPPAD",IDC_STATIC,7,7,20,20
CTEXT "PopPad",IDC_STATIC,40,12,100,8
CTEXT "Popup Editor for Windows",IDC_