VB °æ (¾«»ªÇø)
·¢ÐÅÈË: bloom (©À©Á©Â©Ã©Ä©Æ©Ç¨), ÐÅÇø: VB
±ê Ìâ: GetDCEx(É豸³¡¾°)(תÔØ)
·¢ÐÅÕ¾: ¹þ¹¤´ó×϶¡Ïã (2000Äê09ÔÂ07ÈÕ18:37:39 ÐÇÆÚËÄ), תÐÅ
¡¾ ÒÔÏÂÎÄ×ÖתÔØ×Ô cnTemp ÌÖÂÛÇø ¡¿
¡¾ ÔÎÄÓÉ catchy Ëù·¢±í ¡¿
·¢ÐÅÈË: yucheng (ÎÞ»°¿É˵), ÐÅÇø: VisualBasic
·¢ÐÅÕ¾: BBS ˮľÇ廪վ (Sun Apr 2 23:58:07 2000) WWW-POST
GetDCEx
VBÉùÃ÷
Declare Function GetDCEx Lib "user32" Alias "GetDCEx" (ByVal hwnd As Long,
ByVal hrgnclip As Long, ByVal fdwOptions As Long) As Long
˵Ã÷
Ϊָ¶¨´°¿Ú»ñÈ¡É豸³¡¾°¡£Ïà±ÈGetDC£¬±¾º¯ÊýÌṩÁ˸ü¶àµÄÑ¡Ïî
·µ»ØÖµ
Long£¬Ö´Ðгɹ¦ÎªÖ¸¶¨´°¿ÚÉ豸³¡¾°¾ä±ú¡£³ö´íÔòΪ0
²ÎÊý±í
²ÎÊý ÀàÐͼ°ËµÃ÷
hwnd Long£¬´°¿Ú¾ä±ú
hrgnclip Long£¬´°¿Ú¼ô²ÃÇø
fdwOptions Long£¬±êÖ¾×Ö¡£¸ù¾ÝÏÂÁг£ÊýÉèÖø÷λ£º
DCX_CACHE ²»¹Ü´°¿ÚÀàµÄÑùʽ£¬´Ówindows»º´æ»ñÈ¡É豸³¡¾°
DCX_CLIPCHILREN ËùÓпɼûµÄ×Ó´°¿ÚÇø¶¼Òª´ÓDCµÄ¼ô²ÃÇøÖÐÅųý
DCX_CLIPSIBLINGS ´°¿ÚhWndÉϵÄËùÓпɼûÐֵܴ°¿Ú¶¼Òª´ÓDCµÄ¼ô²ÃÇøÖÐÅųý
DCX_EXCLUDERGN ´ÓDC¼ô²ÃÇøÖÐÅųýÓÉhrgnclipÖ¸¶¨µÄÇøÓò
DCX_EXCLUDEUPDATE ´ÓÉ豸³¡¾°¼ô²ÃÇøÖÐÅųýË¢ÐÂÇøÓò
DCX_INTERSECTRGN ÓÉhrgnclipÖ¸¶¨µÄÇøÓòÓëÉ豸³¡¾°¼ô²ÃÇøÏཻ
DCX_INTERSECTUPDATE Ö¸¶¨ÇøÓòÓëÉ豸³¡¾°Ë¢ÐÂÇøÓòÏཻ
DCX_LOCKWINDOWUPDATE ¸Ã±ê־ΪÔÊÐíÏò´°¿Ú»æͼ£¬¼´Ê¹ËüÓÉÓÚLockWindowUpdateµÄµ÷ÓÃ
±»Ëøס
DCX_NORESETATTRS É豸³¡¾°Êͷź󲻱»ÖØÖÃΪĬÈÏ״̬
DCX_PARENTCLIP ·ÅÆúCS_PARENTDCÀàÑùʽÉèÖá£DCµÄÆðµãÉèΪhWnd´°¿ÚµÄ×óÉϽÇ
DCX_WINDOW A device context is returned for the entire window rectangle
rather than just the client area of the window
DCX_VALIDATE Combine with DCX_INTERSECTUPDATE, validates the clipping region
×¢½â
Èô´°¿ÚËùÊôÀà¾ßÓÐCS_OWNDC£¬ CS_CLASSDC »ò CS_PARENTDCÑùʽ£¬Ôò»ñÈ¡µÄÉ豸³¡¾°Êô´°
¿Ú»òÀàרÓС£Õâʱ£¬É豸³¡¾°×´Ì¬²»ÄÜ´Ó³õÖµÐ޸ġ£vbµÄ´°ÌåºÍ¿Ø¼þͨ³£ÊÇÕâÖÖÇé¿ö¡£·ñ
Ôò£¬ÖÃDCX_CACHEλÒÔ´ÓͨÓÃwindows»º³åÇø»Ö¸´É豸³¡¾°¡£Èô²»ÖøÃ룬Ôòº¯Êý·µ»Ø0¡£
DCµÄ״̬λĬÈÏÉèÖᣴӻº´æ»ñÈ¡µÄÉ豸³¡¾°ÓùýºóÒªÓÃReleaseDCº¯ÊýÊÍ·ÅÒÔ·Àֹϵͳ
ËÀËø£¬ÒòΪwindowsÖ»ÓÐ5¸ö»º´æDC¿ÉÓÃ
ÆäËûÇé¿ö²Î¼ûGetDCº¯Êý×¢½â
--
--
¡î À´Ô´:£®¹þ¹¤´ó×϶¡Ïã bbs.hit.edu.cn£®[FROM: casi.bbs@smth.org]
--
¡ù תÔØ:£®¹þ¹¤´ó×϶¡Ïã bbs.hit.edu.cn£®[FROM: 202.118.247.254]
Powered by KBS BBS 2.0 (http://dev.kcn.cn)
Ò³ÃæÖ´ÐÐʱ¼ä£º2.965ºÁÃë