xcgui.h 165 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040
  1. /**************************************************************************\
  2. *
  3. * Copyright (c) 炫彩界面库. All Rights Reserved.
  4. *
  5. * 炫彩界面库 - 官方网站 : http://www.xcgui.com
  6. *
  7. \**************************************************************************/
  8. //v1.5.3
  9. #include <docobj.h> //当DLL文件使用该头文件时,需取消注释
  10. #include <exdispid.h>
  11. #ifndef XCGUI_HEADER_FILE_
  12. #define XCGUI_HEADER_FILE_
  13. // 用户自定义消息范围 WM_USER - 0x7000
  14. // 炫彩内部自定义消息范围 0x7001 - 0x7FFF
  15. #define XC_API
  16. //接口类型
  17. /// @defgroup groupObjectType 接口句柄类型
  18. /// @ingroup macroDefine
  19. /// @{
  20. //窗口:
  21. #define XC_WINDOW 1 ///<窗口
  22. #define XC_MODALWINDOW 2 ///<模态窗口
  23. #define XC_FRAMEWND 3 ///<框架窗口
  24. #define XC_FLOATWND 4 ///<浮动窗口
  25. //元素 :
  26. #define XC_ELE 20 ///<元素
  27. #define XC_BUTTON 21 ///<按钮
  28. #define XC_RADIO 22 ///<单选按钮
  29. #define XC_CHECK 23 ///<复选按钮元素
  30. #define XC_EDIT 24 ///<编辑框元素
  31. #define XC_RICHEDIT 25 ///<富文本编辑框
  32. #define XC_COMBOBOX 26 ///<下拉组合框元素
  33. #define XC_SCROLLBAR 27 ///<滚动条元素
  34. #define XC_SCROLLVIEW 28 ///<滚动视图元素
  35. #define XC_LIST 29 ///<列表元素
  36. #define XC_LISTBOX 30 ///<列表框元素
  37. #define XC_TREE 31 ///<树元素
  38. #define XC_MENUBAR 32 ///<菜单条
  39. #define XC_PROPERTYPAGE 33 ///<属性页
  40. #define XC_SLIDERBAR 34 ///<滑动条
  41. #define XC_PROGRESSBAR 35 ///<进度条
  42. #define XC_TOOLBAR 36 ///<工具条
  43. #define XC_STATIC 37 ///<静态文本元素
  44. #define XC_GROUPBOX 38 ///<组框
  45. #define XC_PICTURE 39 ///<图片元素
  46. #define XC_MONTHCAL 40 ///<月历元素
  47. #define XC_DATETIME 41 ///<时间元素
  48. #define XC_PROPERTYGRID 42 ///<属性网格
  49. #define XC_CHOOSECOLOR 43 ///<颜色选择元素
  50. #define XC_OUTLOOK 44 ///<测试内容
  51. #define XC_TEXTLINK 45 ///<链接文本
  52. #define XC_TABBAR 46 ///<TabBar
  53. #define XC_GIF 47 ///<GIF动画
  54. #define XC_EDITFILE 48 ///<文件选择编辑框
  55. #define XC_LISTVIEW 49 ///<列表视图,大图标
  56. #define XC_PANE 50 ///<布局窗格
  57. #define XC_DRAGBAR 51 ///<布局窗格拖动分割条
  58. #define XC_SCROLLVIEW_VIEW 52 ///<滚动视图元素的视
  59. #define XC_MENUBAR_BUTTON 60 ///<菜单条上的按钮
  60. #define XC_TOOLBAR_BUTTON 61 ///<工具条上按钮
  61. #define XC_PROPERTYPAGE_LABEL 62 ///<属性页标签按钮
  62. #define XC_ARRAY 70 ///<数组操作
  63. #define XC_STRING 71 ///<字符串操作
  64. #define XC_IMAGELIST 72 ///<图片列表
  65. #define XC_MENU 73 ///<弹出菜单
  66. #define XC_IMAGE 74 ///<图片操作
  67. #define XC_HDRAW 75 ///<绘图操作
  68. #define XC_FONT 76 ///<炫彩字体
  69. #define XC_PIER 102 ///<窗格停靠码头
  70. #define XC_PANE_CELL 103
  71. ///@}
  72. //特殊按钮:
  73. #define XC_BUTTON_MIN 201 //最小化窗口按钮
  74. #define XC_BUTTON_MAX 202 //最大化窗口按钮
  75. #define XC_BUTTON_CLOSE 203 //关闭窗口按钮
  76. //#define XC_BUTTON_HSCROLLBAR_SLIDER 104 //水平滚动条,滑块按钮
  77. //#define XC_BUTTON_VSCROLLBAR_SLIDER 105 //垂直滚动条,滑块按钮
  78. //#define XC_BUTTON_HSCROLLBAR_LEFT 106 //水平滚动条,左滚动按钮
  79. //#define XC_BUTTON_HSCROLLBAR_RIGHT 107 //水平滚动条,右滚动按钮
  80. //#define XC_BUTTON_VSCROLLBAR_TOP 108 //垂直滚动条,上滚动按钮
  81. //#define XC_BUTTON_VSCROLLBAR_BOTTOM 109 //垂直滚动条,下滚动按钮
  82. #define XC_BUTTON_SLIDERBAR_SLIDER 210 //滑动条,滑块按钮
  83. //#define XC_BUTTON_COMBOBOX_POP 111 //组合框下拉列表弹出按钮
  84. //#define XC_BUTTON_PROPERTYPAGE_LEFT 112 //属性页,左滚动按钮
  85. //#define XC_BUTTON_PROPERTYPAGE_RIGHT 113 //属性页,右滚动按钮
  86. //#define XC_BUTTON_PROPERTYPAGE_LABEL 114 //属性页,标签按钮
  87. //#define XC_BUTTON_DATETIME_POP 115 //日期时间元素,弹出选择卡片按钮
  88. ///输入输出///////////////////
  89. #define in_
  90. #define out_
  91. #define in_out_
  92. #ifdef _DEBUG
  93. #define DECLARE_HANDLEX(name) struct name##__ { int unused; }; typedef struct name##__ *name
  94. #else
  95. #define DECLARE_HANDLEX(name) typedef void* name
  96. #endif
  97. //接口句柄类型
  98. /// @defgroup groupHandle 句柄列表
  99. /// @ingroup macroDefine
  100. /// @{
  101. typedef void* HXCGUI; ///<资源句柄
  102. DECLARE_HANDLEX(HWINDOW); ///<窗口资源句柄
  103. DECLARE_HANDLEX(HELE); ///<元素资源句柄
  104. DECLARE_HANDLEX(HMENUX); ///<菜单资源句柄
  105. DECLARE_HANDLEX(HSTRING); ///<字符串资源句柄
  106. DECLARE_HANDLEX(HDRAW); ///<图形绘制资源句柄
  107. DECLARE_HANDLEX(HARRAY); ///<数组资源句柄
  108. DECLARE_HANDLEX(HIMAGE); ///<图片资源句柄
  109. DECLARE_HANDLEX(HXMLRES); ///<XML资源句柄
  110. DECLARE_HANDLEX(HARRAY_ITERATOR); ///<数组迭代器
  111. DECLARE_HANDLEX(HFONTX); ///<炫彩字体句柄
  112. DECLARE_HANDLEX(HPANE_GROUP); ///<窗格组句柄
  113. ///@}
  114. /// @defgroup groupImageDrawType 图片绘制类型
  115. /// @ingroup macroDefine
  116. /// @{
  117. #define XC_IMAGE_DEFAULT 0 ///<默认
  118. #define XC_IMAGE_STRETCH 1 ///<拉伸
  119. #define XC_IMAGE_ADAPTIVE 2 ///<自适应
  120. #define XC_IMAGE_TILE 3 ///<平铺
  121. ///@}
  122. //状态--------------------------------------
  123. /// @defgroup groupButtonState 按钮状态
  124. /// @ingroup macroDefine
  125. /// @{
  126. #define STATE_LEAVE 0 ///<离开
  127. #define STATE_DOWN 1 ///<按下
  128. #define STATE_STAY 2 ///<停留
  129. #define STATE_SELECT 3 ///<选择,保留
  130. ///@}
  131. //窗口样式----------------------------
  132. /// @defgroup groupWindowStyle 炫彩窗口样式
  133. /// @ingroup macroDefine
  134. /// @{
  135. #define XC_SY_MINIMIZE 0x00000001 ///<最小化窗口按钮
  136. #define XC_SY_MAXIMIZE 0x00000002 ///<最大化窗口按钮
  137. #define XC_SY_CLOSE 0x00000004 ///<关闭窗口按钮
  138. #define XC_SY_CAPTION 0x00000008 ///<标题栏
  139. #define XC_SY_BORDER 0x00000010 ///<边框
  140. #define XC_SY_ROUND 0x00000020 ///<圆角窗口
  141. #define XC_SY_CENTER 0x00000040 ///<窗口居中
  142. #define XC_SY_DRAG_BORDER 0x00000080 ///<拖动窗口边框
  143. #define XC_SY_DRAG_WINDOW 0x00000100 ///<拖动窗口
  144. #define XC_SY_DRAW_CAPTION_ICON 0x00000200 ///<绘制窗口标题栏图标
  145. #define XC_SY_DRAW_CAPTION_TITLE 0x00000400 ///<绘制窗口标题栏文本
  146. ///窗口默认样式 1791
  147. #define XC_SY_DEFAULT (XC_SY_MINIMIZE | \
  148. XC_SY_MAXIMIZE | \
  149. XC_SY_CLOSE | \
  150. XC_SY_CAPTION | \
  151. XC_SY_BORDER | \
  152. XC_SY_ROUND | \
  153. XC_SY_CENTER | \
  154. XC_SY_DRAG_BORDER | \
  155. XC_SY_DRAW_CAPTION_ICON | \
  156. XC_SY_DRAW_CAPTION_TITLE)
  157. ///模态窗口
  158. #define XC_SY_MODAL_WINDOW (XC_SY_CLOSE | \
  159. XC_SY_CAPTION | \
  160. XC_SY_BORDER | \
  161. XC_SY_ROUND | \
  162. XC_SY_DRAW_CAPTION_ICON | \
  163. XC_SY_DRAW_CAPTION_TITLE)
  164. ///@}
  165. //透明窗口
  166. /// @defgroup groupWindowTransparent 炫彩窗口透明标识
  167. /// @ingroup macroDefine
  168. /// @{
  169. #define XC_WIND_TRANSPARENT_NO 0 ///<默认窗口,不透明
  170. #define XC_WIND_TRANSPARENT_SHAPED 1 ///<透明窗口,带透明通道,异型.
  171. #define XC_WIND_TRANSPARENT_SHADOW 2 ///<阴影窗口,带透明通道,边框阴影,窗口透明或半透明.
  172. #define XC_WIND_TRANSPARENT_SIMPLE 4 ///<透明窗口,不带透明通道,指定半透明度,指定透明色.
  173. #define XC_WIND_TRANSPARENT_WIN7 8 ///<WIN7玻璃窗口,需要WIN7开启特效,当前未启用.
  174. ///@}
  175. //弹出消息框类型
  176. /// @defgroup groupMessageBox 弹出消息框
  177. /// @ingroup macroDefine
  178. /// @{
  179. #define XMB_OK 1 ///<确定按钮
  180. #define XMB_CANCEL 2 ///<取消按钮
  181. ///@}
  182. //增加元素------------------------------------------------
  183. /// @defgroup groupAddElement 添加元素
  184. /// @ingroup macroDefine
  185. /// @{
  186. #define XC_ADDELE_END 0 ///<增加到末尾
  187. #define XC_ADDELE_FRIST 1 ///<增加到第一位置
  188. #define XC_ADDELE_BEFORE 2 ///<增加到指定元素前面
  189. #define XC_ADDELE_AFTER 3 ///<增加到指定元素后面
  190. #define XC_ADDELE_INDEX 4 ///<增加到指定位置索引
  191. ///@}
  192. //设置元素Z序-----------------------
  193. /// @defgroup groupSetZOrder 元素Z序
  194. /// @ingroup macroDefine
  195. /// @{
  196. #define XC_ZORDER_TOP 0 ///<最上面
  197. #define XC_ZORDER_BOTTOM 1 ///<最下面
  198. #define XC_ZORDER_BEFORE 2 ///<指定元素在目标元素下面
  199. #define XC_ZORDER_AFTER 3 ///<指定元素在目标元素上面
  200. #define XC_ZORDER_INDEX 4 ///<指定索引位置
  201. ///@}
  202. //按钮图标对齐方式
  203. /// @defgroup groupIconAlign 按钮图标对齐方式
  204. /// @ingroup macroDefine
  205. /// @{
  206. #define XC_ICON_ALIGN_LEFT 0 ///<图标在左边
  207. #define XC_ICON_ALIGN_TOP 1 ///<图标在顶部
  208. #define XC_ICON_ALIGN_RIGHT 2 ///<图标在右边
  209. #define XC_ICON_ALIGN_BOTTOM 3 ///<图标在底部
  210. ///@}
  211. //滚动条
  212. /// @defgroup groupScrollBar 滚动条
  213. /// @ingroup macroDefine
  214. /// @{
  215. #define SY_HSCROLL TRUE ///<水平滚动条
  216. #define SY_VSCROLL FALSE ///<垂直滚动条
  217. ///@}
  218. //树元素
  219. /// @defgroup groupTree 列表树元素
  220. /// @ingroup macroDefine
  221. /// @{
  222. #define XTREE_INSERT_BEGIN -2 ///<插入当前层开始
  223. #define XTREE_INSERT_LAST -1 ///<插入当前层末尾
  224. #define XTREE_ROOT 0 ///<根节点
  225. ///@}
  226. //基于二叉树的多叉树根节点ID
  227. #define XMTREE_ROOT -1 //根节点ID
  228. //弹出菜单根节点ID
  229. #define XMENU_ROOT XMTREE_ROOT //根节点ID
  230. /// @defgroup groupMenu 弹出菜单
  231. /// @ingroup macroDefine
  232. /// @{
  233. //弹出菜单项标识
  234. ///@name 弹出菜单项标识
  235. ///@{
  236. #define XM_SELECT 1 ///<选择
  237. #define XM_DISABLED 2 ///<禁用
  238. #define XM_CHECK 4 ///<勾选
  239. #define XM_POPUP 8 ///<弹出
  240. #define XM_SEPARATOR 16 ///<分隔栏 ID号任意,ID号被忽略
  241. ///@}
  242. //弹出菜单方向
  243. ///@name 弹出菜单方向
  244. ///@{
  245. #define XM_LEFT_TOP 0 ///<左上角
  246. #define XM_LEFT_BOTTOM 1 ///<左下角
  247. #define XM_RIGHT_TOP 2 ///<右上角
  248. #define XM_RIGHT_BOTTOM 3 ///<右下角
  249. #define XM_CENTER_LEFT 4 ///<左居中
  250. #define XM_CENTER_TOP 5 ///<上居中
  251. #define XM_CENTER_RIGHT 6 ///<右居中
  252. #define XM_CENTER_BOTTOM 7 ///<下居中
  253. ///@}
  254. //菜单ID--------------------------------------
  255. ///@name 菜单ID
  256. ///@{
  257. #define IDM_CLIP 1000000000 ///<剪切
  258. #define IDM_COPY 1000000001 ///<复制
  259. #define IDM_PASTE 1000000002 ///<粘贴
  260. #define IDM_DELETE 1000000003 ///<删除
  261. #define IDM_SELECTALL 1000000004 ///<全选
  262. #define IDM_DELETEALL 1000000005 ///<清空
  263. ///@}
  264. //窗格菜单
  265. ///@name 窗格菜单
  266. ///@{
  267. #define IDM_LOCK 1000000006 ///<锁定
  268. #define IDM_DOCK 1000000007 ///<停靠
  269. #define IDM_FLOAT 1000000008 ///<浮动
  270. #define IDM_HIDE 1000000009 ///<隐藏
  271. ///@}
  272. ///@}
  273. //属性网格元素,项类型
  274. /// @defgroup groupPropertyGrid 属性网格元素
  275. /// @ingroup macroDefine
  276. /// @{
  277. ///@name 项类型
  278. ///@{
  279. #define PGRID_STRING 0 ///<默认,字符串类型
  280. #define PGRID_EDIT 1 ///<编辑框
  281. #define PGRID_COMBOBOX 2 ///<组合框
  282. #define PGRID_CHOOSECOLOR 3 ///<颜色选择元素
  283. #define PGRID_EDIT_FILE 4 ///<文件选择编辑框
  284. ///@}
  285. ///@}
  286. enum align_type_
  287. {
  288. align_any=1,
  289. align_left,
  290. align_top,
  291. align_right,
  292. align_bottom,
  293. align_group_member, //组成员
  294. };
  295. //窗格状态
  296. enum pane_state_
  297. {
  298. pane_state_any=0,
  299. pane_state_lock,
  300. pane_state_dock,
  301. pane_state_float,
  302. pane_state_hide,
  303. };
  304. //窗口消息
  305. /**
  306. @addtogroup wndMSG
  307. <hr>
  308. <h2>Windows 标准消息</h2>
  309. - @ref WM_PAINT 窗口绘制消息
  310. - @ref WM_CLOSE 窗口关闭消息.
  311. - @ref WM_DESTROY 窗口销毁消息.
  312. - @ref WM_NCDESTROY 窗口非客户区销毁消息.
  313. - @ref WM_MOUSEMOVE 窗口鼠标移动消息.
  314. - @ref WM_LBUTTONDOWN 窗口鼠标左键按下消息
  315. - @ref WM_LBUTTONUP 窗口鼠标左键弹起消息.
  316. - @ref WM_RBUTTONDOWN 窗口鼠标右键按下消息.
  317. - @ref WM_RBUTTONUP 窗口鼠标右键弹起消息.
  318. - @ref WM_MOUSEWHEEL 窗口鼠标滚轮滚动消息.
  319. - @ref WM_EXITSIZEMOVE 窗口退出移动或调整大小模式循环改,详情参加MSDN.
  320. - @ref WM_MOUSELEAVE 窗口鼠标离开消息.
  321. - @ref WM_SIZE 窗口大小改变消息.
  322. - @ref WM_TIMER 窗口定时器消息.
  323. - @ref WM_SETFOCUS 窗口获得焦点.
  324. - @ref WM_KILLFOCUS 窗口失去焦点.
  325. - @ref WM_KEYDOWN 窗口键盘按键消息.
  326. - @ref WM_CAPTURECHANGED 窗口鼠标捕获改变消息.
  327. - @ref other 其他Windows系统消息,包含你自定义的Windows消息.
  328. <hr>
  329. @anchor WM_PAINT WM_PAINT 窗口绘制消息
  330. @code BOOL CALLBACK WndDrawWindow(HWINDOW hWindow,HDRAW hDraw); @endcode
  331. @param hWindow 窗口句柄.
  332. @param hDraw 图形绘制句柄.
  333. @return 默认返回FALSE,如果终止消息传递返回TRUE.
  334. <hr>
  335. @anchor WM_CLOSE WM_CLOSE 窗口关闭消息.
  336. @code BOOL CALLBACK WndClose(HWINDOW hWindow); @endcode
  337. @param hWindow 窗口句柄.
  338. @return 默认返回FALSE,如果终止消息传递返回TRUE.
  339. <hr>
  340. @anchor WM_DESTROY WM_DESTROY 窗口销毁消息.
  341. @code BOOL CALLBACK WndDestroy(HWINDOW hWindow); @endcode
  342. @param hWindow 窗口句柄.
  343. @return 默认返回FALSE,如果终止消息传递返回TRUE.
  344. <hr>
  345. @anchor WM_NCDESTROY WM_NCDESTROY 窗口非客户区销毁消息.
  346. @code BOOL CALLBACK WndNCDestroy(HWINDOW hWindow); @endcode
  347. @param hWindow 窗口句柄.
  348. @return 默认返回FALSE,如果终止消息传递返回TRUE.
  349. <hr>
  350. @anchor WM_MOUSEMOVE WM_MOUSEMOVE 窗口鼠标移动消息.
  351. @code BOOL CALLBACK WndMouseMove(HWINDOW hWindow,UINT flags,POINT *pPt); @endcode
  352. @param hWindow 窗口句柄.
  353. @param flags 请参见MSDN WM_MOUSEMOVE wParam参数.
  354. @param pPt 鼠标坐标点.
  355. @return 默认返回FALSE,如果终止消息传递返回TRUE.
  356. <hr>
  357. @anchor WM_LBUTTONDOWN WM_LBUTTONDOWN 窗口鼠标左键按下消息
  358. @code BOOL CALLBACK WndLButtonDown(HWINDOW hWindow,UINT flags,POINT *pPt); @endcode
  359. @param hWindow 窗口句柄.
  360. @param flags 请参见MSDN WM_LBUTTONDOWN.
  361. @param pPt 鼠标坐标点.
  362. @return 默认返回FALSE,如果终止消息传递返回TRUE.
  363. <hr>
  364. @anchor WM_LBUTTONUP WM_LBUTTONUP 窗口鼠标左键弹起消息.
  365. @code BOOL CALLBACK WndLButtonUp(HWINDOW hWindow,UINT flags,POINT *pPt); @endcode
  366. @param hWindow 窗口句柄.
  367. @param flags 请参见MSDN WM_LBUTTONUP.
  368. @param pPt 鼠标坐标点.
  369. @return 默认返回FALSE,如果终止消息传递返回TRUE.
  370. <hr>
  371. @anchor WM_RBUTTONDOWN WM_RBUTTONDOWN 窗口鼠标右键按下消息.
  372. @code BOOL CALLBACK WndRButtonDown(HWINDOW hWindow,UINT flags,POINT *pPt); @endcode
  373. @param hWindow 窗口句柄.
  374. @param flags 请参见MSDN WM_RBUTTONDOWN.
  375. @param pPt 鼠标坐标点.
  376. @return 默认返回FALSE,如果终止消息传递返回TRUE.
  377. <hr>
  378. @anchor WM_RBUTTONUP WM_RBUTTONUP 窗口鼠标右键弹起消息.
  379. @code BOOL CALLBACK WndRButtonUp(HWINDOW hWindow,UINT flags,POINT *pPt); @endcode
  380. @param hWindow 窗口句柄.
  381. @param flags 请参见MSDN WM_RBUTTONUP.
  382. @param pPt 鼠标坐标点.
  383. @return 默认返回FALSE,如果终止消息传递返回TRUE.
  384. <hr>
  385. @anchor WM_MOUSEWHEEL WM_MOUSEWHEEL 窗口鼠标滚轮滚动消息.
  386. @code BOOL CALLBACK WndMouseWheel(HWINDOW hWindow,UINT flags,POINT *pPt); @endcode
  387. @param hWindow 窗口句柄.
  388. @param flags 请参见MSDN WM_MOUSEWHEEL消息wParam参数.
  389. @param pPt 鼠标坐标点.
  390. @return 默认返回FALSE,如果终止消息传递返回TRUE.
  391. <hr>
  392. @anchor WM_EXITSIZEMOVE WM_EXITSIZEMOVE 窗口退出移动或调整大小模式循环改,详情参加MSDN.
  393. @code BOOL CALLBACK WndExitSizeMove(HWINDOW hWindow); @endcode
  394. @param hWindow 窗口句柄.
  395. @return 默认返回FALSE,如果终止消息传递返回TRUE.
  396. <hr>
  397. @anchor WM_MOUSELEAVE WM_MOUSELEAVE 窗口鼠标离开消息.
  398. @code BOOL CALLBACK WndMouseLeave(HWINDOW hWindow); @endcode
  399. @param hWindow 窗口句柄.
  400. @return 默认返回FALSE,如果终止消息传递返回TRUE.
  401. <hr>
  402. @anchor WM_SIZE WM_SIZE 窗口大小改变消息.
  403. @code BOOL CALLBACK WndSize(HWINDOW hWindow,UINT flags,SIZE *pSize); @endcode
  404. @param hWindow 窗口句柄.
  405. @param flags 请参见MSDN WM_SIZE消息wParam参数.
  406. @param pSize 窗口大小.
  407. @return 默认返回FALSE,如果终止消息传递返回TRUE.
  408. <hr>
  409. @anchor WM_TIMER WM_TIMER 窗口定时器消息.
  410. @code BOOL CALLBACK WndTimer(HWINDOW hWindow,UINT_PTR nIDEvent,UINT uElapse); @endcode
  411. @param hWindow 窗口句柄.
  412. @param nIDEnent 定时器标示符.
  413. @param uElapse 指定所经过的系统启动以来的毫秒数,这是由GetTickCount函数的返回值.
  414. @return 默认返回FALSE,如果终止消息传递返回TRUE.
  415. <hr>
  416. @anchor WM_SETFOCUS WM_SETFOCUS 窗口获得焦点.
  417. @code BOOL CALLBACK WndSetFocus(HWINDOW hWindow); @endcode
  418. @param hWindow 窗口句柄.
  419. @return 默认返回FALSE,如果终止消息传递返回TRUE.
  420. <hr>
  421. @anchor WM_KILLFOCUS WM_KILLFOCUS 窗口失去焦点.
  422. @code BOOL CALLBACK WndKillFocus(HWINDOW hWindow); @endcode
  423. @param hWindow 窗口句柄.
  424. @return 默认返回FALSE,如果终止消息传递返回TRUE.
  425. <hr>
  426. @anchor WM_KEYDOWN WM_KEYDOWN 窗口键盘按键消息.
  427. @code BOOL CALLBACK WndKeyDown(HWINDOW hWindow,WPARAM wParam,LPARAM lParam); @endcode
  428. @param hWindow 窗口句柄.
  429. @return 默认返回FALSE,如果终止消息传递返回TRUE.
  430. @note wParam,lParam:请参见MSDN WM_KEYDOWN.
  431. <hr>
  432. @anchor WM_CAPTURECHANGED WM_CAPTURECHANGED 窗口鼠标捕获改变消息.
  433. @code BOOL CALLBACK WndCaptureChanged(HWINDOW hWindow,HWND hWnd); @endcode
  434. @param hWindow 窗口句柄.
  435. @param hWnd 获得鼠标捕获的窗口句柄.
  436. @return 默认返回FALSE,如果终止消息传递返回TRUE.
  437. <hr>
  438. @anchor other 其他Windows系统消息,包含你自定义的Windows消息.
  439. @code BOOL CALLBACK WndOther(HWINDOW hWindow,WPARAM wParam,LPARAM lParam); @endcode
  440. @param hWindow 窗口句柄.
  441. @param wParam 消息参数.
  442. @param lParam 消息参数.
  443. @return 默认返回FALSE,如果终止消息传递返回TRUE.
  444. @note 参数信息请参见MSDN.
  445. @{
  446. */
  447. ///@brief 鼠标单击窗口
  448. ///@code BOOL CALLBACK WndMouseClick(HWINDOW hWindow,POINT *pPt); @endcode
  449. #define XWM_MOUSECLICK 0x7000+1 //wParam:x坐标, lParam:y坐标
  450. ///@brief 鼠标双击窗口
  451. ///@code BOOL CALLBACK WndMouseDBClick(HWINDOW hWindow,POINT *pPt) @endcode
  452. ///@param hWindow 窗口句柄
  453. ///@param pPt 鼠标位置
  454. #define XWM_MOUSEDBCLICK 0x7000+2 //wParam:x坐标, lParam:y坐标
  455. ///@brief 重绘元素
  456. ///@code BOOL CALLBACK WndRedrawEle(HWINDOW hWindow,HELE hEle,RECT *pRect); @endcode
  457. #define XWM_REDRAW_ELE 0x7000+3 //重绘元素 wParam:元素句柄, lParam:*
  458. ///@brief 菜单选择
  459. ///@code BOOL CALLBACK WndMenuSelect(HWINDOW hWindow,int id); @endcode
  460. #define XWM_MENUSELECT 0x7000+4 //菜单选择 wParam:菜单项ID, lParam:0
  461. ///@brief 菜单退出
  462. ///@code BOOL CALLBACK WndMenuExit(HWINDOW hWindow); @endcode
  463. #define XWM_MENUEXIT 0x7000+5 //菜单退出 wParam:0, lParam:0
  464. ///@brief 窗口字体改变
  465. ///@code BOOL CALLBACK WndSetFont(HWINDOW hWindow); @endcode
  466. #define XWM_SETFONT 0x7000+6 //窗口字体改变
  467. //炫彩定时器
  468. ///@code BOOL CALLBACK WndTimer2(HWINDOW hWindow,int timerID,int userData); @endcode
  469. #define XWM_TIMER 0x7000+8 //wParam:, lParam:
  470. #define XWM_DRAW_T 0x7000+9 //窗口绘制,内部使用, wParam:0, lParam:0
  471. ///@}
  472. //窗口非客户区消息-逻辑上的非客户区
  473. /// @addtogroup wndNCMSG
  474. /// 窗口非客户区消息-逻辑上的非客户区
  475. /// @{
  476. /// @brief 窗口非客户区绘制消息
  477. /// @code BOOL CALLBACK WndNCDrawWindow(HWINDOW hWindow,HDRAW hDraw); @endcode
  478. /// @param hWindow 窗口句柄
  479. /// @param hDraw 图形绘制句柄.
  480. /// @return 默认返回FALSE,如果终止消息传递返回TRUE.
  481. #define XWM_NCPAINT 0 //wParam:HDC lParam:0
  482. /// @brief 窗口绘制完成消息,在显示之前
  483. /// @code BOOL CALLBACK WndNCEndDrawWindow(HWINDOW hWindow,HDRAW hDraw); @endcode
  484. /// @param hWindow 窗口句柄
  485. /// @param hDraw 图形绘制句柄.
  486. /// @return 默认返回FALSE,如果终止消息传递返回TRUE.
  487. #define XWM_NCENDPAINT 1 //wParam:HDC lParam:0 窗口绘制完成后调用,便于特效合成
  488. /// @brief 窗口非客户区鼠标移动消息.
  489. /// @code BOOL CALLBACK WndNCMouseMove(HWINDOW hWindow,UINT flags,POINT *pPt); @endcode
  490. /// @param hWindow 窗口句柄
  491. /// @param flags 请参见msdn WM_MOUSEMOVE.
  492. /// @param pPt 鼠标坐标点.
  493. /// @return 默认返回FALSE,如果终止消息传递返回TRUE.
  494. #define XWM_NCMOUSEMOVE 2 //wParam:对应系统wParam lParam:坐标点
  495. /// @brief 窗口非客户区鼠标左键按下消息.
  496. /// @code BOOL CALLBACK WndNCLButtonDown(HWINDOW hWindow,UINT flags,POINT *pPt); @endcode
  497. /// @param hWindow 窗口句柄
  498. /// @param flags 请参见msdn WM_LBUTTONDOWN.
  499. /// @param pPt 鼠标坐标点.
  500. /// @return 默认返回FALSE,如果终止消息传递返回TRUE.
  501. #define XWM_NCLBUTTONDOWN 3 //wParam:对应系统wParam lParam:坐标点
  502. /// @brief 窗口非客户区鼠标左键弹起消息.
  503. /// @code BOOL CALLBACK WndNCLButtonUp(HWINDOW hWindow,UINT flags,POINT *pPt); @endcode
  504. /// @param hWindow 窗口句柄
  505. /// @param flags 请参见msdn MSDN WM_LBUTTONUP.
  506. /// @param pPt 鼠标坐标点.
  507. /// @return 默认返回FALSE,如果终止消息传递返回TRUE.
  508. #define XWM_NCLBUTTONUP 4 //wParam:对应系统wParam lParam:坐标点
  509. /// @brief 窗口非客户区鼠标右键按下消息.
  510. /// @code BOOL CALLBACK WndNCRButtonDown(HWINDOW hWindow,UINT flags,POINT *pPt); @endcode
  511. /// @param hWindow 窗口句柄
  512. /// @param flags 请参见msdn MSDN WM_RBUTTONDOWN.
  513. /// @param pPt 鼠标坐标点.
  514. /// @return 默认返回FALSE,如果终止消息传递返回TRUE.
  515. #define XWM_NCRBUTTONDOWN 5 //wParam:对应系统wParam lParam:坐标点
  516. /// @brief 窗口非客户区鼠标右键弹起消息.
  517. /// @code BOOL CALLBACK WndNCRButtonUp(HWINDOW hWindow,UINT flags,POINT *pPt); @endcode
  518. /// @param hWindow 窗口句柄
  519. /// @param flags 请参见msdn MSDN WM_RBUTTONUP.
  520. /// @param pPt 鼠标坐标点.
  521. /// @return 默认返回FALSE,如果终止消息传递返回TRUE.
  522. #define XWM_NCRBUTTONUP 6 //wParam:对应系统wParam lParam:坐标点
  523. /// @brief 窗口非客户区鼠标左键点击消息.
  524. /// @code BOOL CALLBACK WndNCMouseClick(HWINDOW hWindow,POINT *pPt); @endcode
  525. /// @param hWindow 窗口句柄
  526. /// @param pPt 鼠标坐标点.
  527. /// @return 默认返回FALSE,如果终止消息传递返回TRUE.
  528. #define XWM_NCMOUSECLICK 7 //wParam:坐标点 lParam:0 鼠标单击 非客户区
  529. /// @brief 窗口非客户区鼠标左键双击消息.
  530. /// @code BOOL CALLBACK WndNCMouseDBClick(HWINDOW hWindow,POINT *pPt); @endcode
  531. /// @param hWindow 窗口句柄
  532. /// @param pPt 鼠标坐标点.
  533. /// @return 默认返回FALSE,如果终止消息传递返回TRUE.
  534. #define XWM_NCMOUSEDBCLICK 8 //wParam:坐标点 lParam:0 鼠标双击窗口 非客户区
  535. ///@}
  536. //元素消息
  537. /// @addtogroup eleMSG
  538. /// @{
  539. /// @brief 元素绘制消息.
  540. /// @code BOOL CALLBACK EleDraw(HELE hEle,HDRAW hDraw); @endcode
  541. /// @param hEle 元素句柄.
  542. /// @param hDraw 图形绘制句柄.
  543. /// @return 默认返回FALSE,如果终止消息传递返回TRUE.
  544. #define XM_PAINT 100 //wParam:hDraw,lParam:0
  545. /// @brief 元素鼠标左键点击消息.
  546. /// @code BOOL CALLBACK EleMouseClick(HELE hEle,POINT *pPt); @endcode
  547. /// @param hEle 元素句柄.
  548. /// @param pPt 鼠标坐标点.
  549. /// @return 默认返回FALSE,如果终止消息传递返回TRUE.
  550. #define XM_MOUSECLICK 101 //鼠标单击 wParam:POINT坐标,lParam:0
  551. /// @brief 元素鼠标左键双击消息.
  552. /// @code BOOL CALLBACK EleMouseDBClick(HELE hEle,POINT *pPt); @endcode
  553. /// @param hEle 元素句柄.
  554. /// @param pPt 鼠标坐标点.
  555. /// @return 默认返回FALSE,如果终止消息传递返回TRUE.
  556. #define XM_MOUSEDBCLICK 102 //鼠标双击 wParam:POINT坐标,lParam:0
  557. /// @brief 元素鼠标移动消息.
  558. /// @code BOOL CALLBACK EleMouseMove(HELE hEle,UINT flags,POINT *pPt); @endcode
  559. /// @param hEle 元素句柄.
  560. /// @param flags 请参见MSDN WM_MOUSEMOVE.
  561. /// @param pPt 鼠标坐标点.
  562. /// @return 默认返回FALSE,如果终止消息传递返回TRUE.
  563. #define XM_MOUSEMOVE 103 //鼠标移动 wParam:标识, lParam:POINT坐标
  564. /// @brief 元素鼠标左键按下消息.
  565. /// @code BOOL CALLBACK EleLButtonDown(HELE hEle,UINT flags,POINT *pPt); @endcode
  566. /// @param hEle 元素句柄.
  567. /// @param flags 请参见MSDN WM_LBUTTONDOWN.
  568. /// @param pPt 鼠标坐标点.
  569. /// @return 默认返回FALSE,如果终止消息传递返回TRUE.
  570. #define XM_LBUTTONDOWN 104 //wParam:标识, lParam:POINT坐标
  571. /// @brief 元素鼠标左键弹起消息.
  572. /// @code BOOL CALLBACK EleLButtonUp(HELE hEle,UINT flags,POINT *pPt); @endcode
  573. /// @param hEle 元素句柄.
  574. /// @param flags 请参见MSDN WM_LBUTTONUP.
  575. /// @param pPt 鼠标坐标点.
  576. /// @return 默认返回FALSE,如果终止消息传递返回TRUE.
  577. #define XM_LBUTTONUP 105 //wParam:标识, lParam:POINT坐标
  578. /// @brief 元素鼠标右键按下消息.
  579. /// @code BOOL CALLBACK EleRButtonDown(HELE hEle,UINT flags,POINT *pPt); @endcode
  580. /// @param hEle 元素句柄.
  581. /// @param flags 请参见MSDN WM_RBUTTONDOWN.
  582. /// @param pPt 鼠标坐标点.
  583. /// @return 默认返回FALSE,如果终止消息传递返回TRUE.
  584. #define XM_RBUTTONDOWN 106 //wParam:标识, lParam:POINT坐标
  585. /// @brief 元素鼠标右键弹起消息.
  586. /// @code BOOL CALLBACK EleRButtonUp(HELE hEle,UINT flags,POINT *pPt); @endcode
  587. /// @param hEle 元素句柄.
  588. /// @param flags 请参见MSDN WM_RBUTTONUP.
  589. /// @param pPt 鼠标坐标点.
  590. /// @return 默认返回FALSE,如果终止消息传递返回TRUE.
  591. #define XM_RBUTTONUP 107 //wParam:标识, lParam:POINT坐标
  592. //炫彩定时器
  593. // BOOL (CALLBACK *pFunEleTimerEx)(HELE hEle,UINT timerID,int userData); //定时器消息 XWM_TIMER
  594. #define XM_TIMER 108
  595. ///@}
  596. //元素事件
  597. /// @addtogroup eleEvents
  598. /// @{
  599. /// @brief 元素销毁事件.
  600. /// @code void CALLBACK EventDestroy(HELE hEle); @endcode
  601. /// @param hEle 元素句柄.
  602. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  603. #define XE_DESTROY -1 //元素销毁 特殊事件
  604. /// @brief 按钮元素点击事件.
  605. /// @code BOOL CALLBACK EventBtnClick(HELE hEle,HELE hEventEle); @endcode
  606. /// @param hEle 当前处理事件的元素句柄.
  607. /// @param hEventEle 触发事件的元素句柄.
  608. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  609. #define XE_BNCLICK 0 //按钮点击事件,没有时间间隔 wParam:0, lParam:0
  610. /// @brief 元素鼠标停留事件.
  611. /// @code BOOL CALLBACK EventMouseStay(HELE hEle,HELE hEventEle); @endcode
  612. /// @param hEle 当前处理事件的元素句柄.
  613. /// @param hEventEle 触发事件的元素句柄.
  614. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  615. #define XE_MOUSESTAY 1 //鼠标停留 wParam:0,lParam:0
  616. /// @brief 元素鼠标离开事件.
  617. /// @code BOOL CALLBACK EventMouseLeave(HELE hEle,HELE hEventEle); @endcode
  618. /// @param hEle 当前处理事件的元素句柄.
  619. /// @param hEventEle 触发事件的元素句柄.
  620. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  621. #define XE_MOUSELEAVE 2 //鼠标离开 wParam:0,lParam:0
  622. /// @brief 元素鼠标滚轮滚动事件.
  623. /// @code BOOL CALLBACK EventMouseWheel(HELE hEle,HELE hEventEle,UINT flags,POINT *pPt); @endcode
  624. /// @param hEle 当前处理事件的元素句柄.
  625. /// @param hEventEle 触发事件的元素句柄.
  626. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  627. #define XE_MOUSEWHEEL 3 //鼠标滚轮 wParam:标识,lParam:POINT坐标
  628. /// @brief 元素获得焦点事件.
  629. /// @code BOOL CALLBACK EventSetFocus(HELE hEle,HELE hEventEle); @endcode
  630. /// @param hEle 当前处理事件的元素句柄.
  631. /// @param hEventEle 触发事件的元素句柄.
  632. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  633. #define XE_SETFOCUS 4 //获得焦点 wParam:0,lParam:0
  634. /// @brief 元素失去焦点事件.
  635. /// @code BOOL CALLBACK EventKillFocus(HELE hEle,HELE hEventEle); @endcode
  636. /// @param hEle 当前处理事件的元素句柄.
  637. /// @param hEventEle 触发事件的元素句柄.
  638. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  639. #define XE_KILLFOCUS 5 //失去焦点 wParam:0,lParam:0
  640. /// @brief 元素按键事件.
  641. /// @code BOOL CALLBACK EventKeyDown(HELE hEle,HELE hEventEle,WPARAM wParam,LPARAM lParam); @endcode
  642. /// @param hEle 当前处理事件的元素句柄.
  643. /// @param hEventEle 触发事件的元素句柄.
  644. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  645. /// @note wParam,lParam:请参见MSDN WM_KEYDOWN.
  646. #define XE_KEYDOWN 6 //wParam和lParam参数与标准消息相同
  647. /// @brief 通过TranslateMessage函数翻译的字符事件.
  648. /// @code BOOL CALLBACK EventChar(HELE hEle,HELE hEventEle,WPARAM wParam,LPARAM lParam); @endcode
  649. /// @param hEle 当前处理事件的元素句柄.
  650. /// @param hEventEle 触发事件的元素句柄.
  651. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  652. /// @note wParam,lParam:请参见MSDN WM_KEYDOWN.
  653. #define XE_CHAR 7 //wParam和lParam参见MSDN
  654. /// @brief 水平滚动条元素滚动事件,滚动条触发.
  655. /// @code BOOL CALLBACK EventHScroll(HELE hEle,HELE hEventEle,int pos); @endcode
  656. /// @param hEle 当前处理事件的元素句柄.
  657. /// @param hEventEle 触发事件的元素句柄.
  658. /// @param pos 当前滚动点.
  659. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  660. #define XE_HSCROLL 8 //水平滚动条滚动事件 wParam:滚动点,lParam:0 (滚动条触发)
  661. /// @brief 垂直滚动条元素滚动事件,滚动条触发.
  662. /// @code BOOL CALLBACK EventVScroll(HELE hEle,HELE hEventEle,int pos); @endcode
  663. /// @param hEle 当前处理事件的元素句柄.
  664. /// @param hEventEle 触发事件的元素句柄.
  665. /// @param pos 当前滚动点.
  666. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  667. #define XE_VSCROLL 9 //垂直滚动条滚动事件 wParam:滚动点,lParam:0 (滚动条触发)
  668. /// @brief 滚动视图元素水平滚动事件,滚动视图触发.
  669. /// @code BOOL CALLBACK EventHScrollView(HELE hEle,HELE hEventEle,int pos); @endcode
  670. /// @param hEle 当前处理事件的元素句柄.
  671. /// @param hEventEle 触发事件的元素句柄.
  672. /// @param pos 当前滚动点.
  673. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  674. #define XE_HSCROLLVIEW 10 //滚动视图 滚动事件 wParam:滚动点,lParam:0 (滚动视图触发,表明滚动视图已滚动完成)
  675. /// @brief 滚动视图元素垂直滚动事件,滚动视图触发.
  676. /// @code BOOL CALLBACK EventVScrollView(HELE hEle,HELE hEventEle,int pos); @endcode
  677. /// @param hEle 当前处理事件的元素句柄.
  678. /// @param hEventEle 触发事件的元素句柄.
  679. /// @param pos 当前滚动点.
  680. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  681. #define XE_VSCROLLVIEW 11 //滚动视图 滚动事件 wParam:滚动点,lParam:0 (滚动视图触发,表明滚动视图已滚动完成)
  682. /// @brief 元素设置鼠标捕获事件.
  683. /// @code BOOL CALLBACK EventSetCapture(HELE hEle,HELE hEventEle); @endcode
  684. /// @param hEle 当前处理事件的元素句柄.
  685. /// @param hEventEle 触发事件的元素句柄.
  686. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  687. #define XE_SETCAPTURE 12 //设置鼠标捕获 wParam:0,lParam:0
  688. /// @brief 元素失去鼠标捕获事件.
  689. /// @code BOOL CALLBACK EventKillCapture(HELE hEle,HELE hEventEle); @endcode
  690. /// @param hEle 当前处理事件的元素句柄.
  691. /// @param hEventEle 触发事件的元素句柄.
  692. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  693. #define XE_KILLCAPTURE 13 //失去鼠标捕获 wParam:0,lParam:0
  694. /// @brief 弹出菜单项选择事件.
  695. /// @code BOOL CALLBACK EventMenuSelect(HELE hEle,HELE hEventEle,int id); @endcode
  696. /// @param hEle 当前处理事件的元素句柄.
  697. /// @param hEventEle 触发事件的元素句柄.
  698. /// @param id 菜单项id.
  699. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  700. #define XE_MENUSELECT 14 //菜单项选择 wParam:菜单ID,lParam:0
  701. /// @brief 弹出菜单退出事件.
  702. /// @code BOOL CALLBACK EventMenuExit(HELE hEle,HELE hEventEle); @endcode
  703. /// @param hEle 当前处理事件的元素句柄.
  704. /// @param hEventEle 触发事件的元素句柄.
  705. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  706. #define XE_MENUEXIT 15 //菜单退出
  707. /// @brief 元素大小改变事件.
  708. /// @code BOOL CALLBACK EventSize(HELE hEle,HELE hEventEle); @endcode
  709. /// @param hEle 当前处理事件的元素句柄.
  710. /// @param hEventEle 触发事件的元素句柄.
  711. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  712. #define XE_SIZE 16 //元素大小位置改变,wParam:0,lParam:0
  713. /// @brief 元素字体改变事件.
  714. /// @code BOOL CALLBACK EventSetFont(HELE hEle,HELE hEventEle); @endcode
  715. /// @param hEle 当前处理事件的元素句柄.
  716. /// @param hEventEle 触发事件的元素句柄.
  717. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  718. #define XE_SETFONT 17 //元素字体改变事件,wParam:0,lParam:0
  719. /// @brief 元素显示或隐藏事件.
  720. /// @code BOOL CALLBACK EventShow(HELE hEle,HELE hEventEle,BOOL bShow); @endcode
  721. /// @param hEle 当前处理事件的元素句柄.
  722. /// @param hEventEle 触发事件的元素句柄.
  723. /// @param bShow 如果元素显示TRUE,隐藏FALSE.
  724. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  725. #define XE_SHOW 18 //wParam:TRUE或FALSE, lParam:0
  726. /// @brief 列表元素,项选择事件.
  727. /// @code BOOL CALLBACK EventListSelect(HELE hEle,HELE hEventEle,int index); @endcode
  728. /// @param hEle 当前处理事件的元素句柄.
  729. /// @param hEventEle 触发事件的元素句柄.
  730. /// @param index 选择项索引,如果是-1没有选择项.
  731. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  732. #define XE_LIST_SELECT 50 //列表项选择, wParam:项index,如果是-1没有选择项, lParam:0
  733. /// @brief 列表元素,列表头项点击事件.
  734. /// @code BOOL CALLBACK EventListHeaderClick(HELE hEle,HELE hEventEle,int id); @endcode
  735. /// @param hEle 当前处理事件的元素句柄.
  736. /// @param hEventEle 触发事件的元素句柄.
  737. /// @param index 项索引.
  738. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  739. #define XE_LIST_HEADER_CLICK 51 //列表头项点击,wParam:项index, lParam:0
  740. /// @brief 列表元素,列表头项宽度改变事件.
  741. /// @code BOOL CALLBACK EventListHeaderChange(HELE hEle,HELE hEventEle,int index,int width); @endcode
  742. /// @param hEle 当前处理事件的元素句柄.
  743. /// @param hEventEle 触发事件的元素句柄.
  744. /// @param index 列表头项索引.
  745. /// @param width 项宽度.
  746. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  747. #define XE_LIST_HEADER_CHANGE 52 //列表头项宽度改变,wParam:项index, lParam:项宽度
  748. /// @brief 树元素,项选择事件.
  749. /// @code BOOL CALLBACK EventTreeSelect(HELE hEle,HELE hEventEle,int id); @endcode
  750. /// @param hEle 当前处理事件的元素句柄.
  751. /// @param hEventEle 触发事件的元素句柄.
  752. /// @param id 选择项id,如果是-1没有选择项.
  753. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  754. #define XE_TREE_SELECT 53 //树项选择, wParam:选择项id,如果是-1没有选择项, lParam:0
  755. /// @brief 树元素,项展开或收缩事件.
  756. /// @code BOOL CALLBACK EventTreeExpand(HELE hEle,HELE hEventEle,int id,BOOL bExpand); @endcode
  757. /// @param hEle 当前处理事件的元素句柄.
  758. /// @param hEventEle 触发事件的元素句柄.
  759. /// @param id 树项id.
  760. /// @param bExpand TRUE展开,FALSE收缩.
  761. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  762. #define XE_TREE_EXPAND 54 //树项展开或收缩, wParam:项id; lParam:展开TRUE,收缩FALSE
  763. /// @brief 组合框元素,组合框弹出下拉列表项选择事件.
  764. /// @code BOOL CALLBACK EventComboBoxSelect(HELE hEle,HELE hEventEle,int index); @endcode
  765. /// @param hEle 当前处理事件的元素句柄.
  766. /// @param hEventEle 触发事件的元素句柄.
  767. /// @param index 选中项索引,如果-1没有选中项
  768. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  769. #define XE_COMBOBOX_SELECT 55 //下拉组合框选择事件,wParam:选择项索引,如果-1没有选择项, lParam:0
  770. /// @brief 组合框元素,组合框下拉列表弹出事件.
  771. /// @code BOOL CALLBACK EventComboBoxPopupList(HELE hEle,HELE hEventEle,HWINDOW hWindow,HELE hListBox); @endcode
  772. /// @param hEle 当前处理事件的元素句柄.
  773. /// @param hEventEle 触发事件的元素句柄.
  774. /// @param hWindow 弹出窗口句柄.
  775. /// @param hListBox 下拉列表句柄.
  776. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  777. #define XE_COMBOBOX_POPUP_LIST 56 //组合框下拉列表弹出事件,wParam:弹出窗口句柄, lParam:listBox句柄
  778. /// @brief 组合框元素,组合框弹出下拉列表退出事件.
  779. /// @code BOOL CALLBACK EventComboBoxExitList(HELE hEle,HELE hEventEle); @endcode
  780. /// @param hEle 当前处理事件的元素句柄.
  781. /// @param hEventEle 触发事件的元素句柄.
  782. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  783. #define XE_COMBOBOX_EXIT_LIST 57 //组合框弹出下拉列表关闭事件,wParam:0, lParam:0
  784. /// @brief 属性页元素,标签项选择事件.
  785. /// @code BOOL CALLBACK EventPPageSelect(HELE hEle,HELE hEventEle,int index); @endcode
  786. /// @param hEle 当前处理事件的元素句柄.
  787. /// @param hEventEle 触发事件的元素句柄.
  788. /// @param index 选择标签索引,如果-1没有选择标签.
  789. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  790. #define XE_PPAGE_SELECT 58 //属性页标签选择,wParam:标签索引,如果-1没有选择标签, lParam:0
  791. /// @brief TabBar元素,标签项选择事件.
  792. /// @code BOOL CALLBACK EventTabBarSelect(HELE hEle,HELE hEventEle,int index); @endcode
  793. /// @param hEle 当前处理事件的元素句柄.
  794. /// @param hEventEle 触发事件的元素句柄.
  795. /// @param index 选择标签索引,如果-1没有选择标签.
  796. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  797. #define XE_TABBAR_SELECT 58 //TabBar标签选择,wParam:标签索引,如果-1没有选择标签, lParam:0
  798. /// @brief 滑动条元素,滑块位置改变事件.
  799. /// @code BOOL CALLBACK EventSliderChange(HELE hEle,HELE hEventEle,int pos); @endcode
  800. /// @param hEle 当前处理事件的元素句柄.
  801. /// @param hEventEle 触发事件的元素句柄.
  802. /// @param pos 滑块当前滑动位置点.
  803. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  804. #define XE_SLIDER_CHANGE 59 //滑动条位置改变,wParam:滑块当前滑动位置点, lParam:0
  805. //wParam:TRUE日期发生改变; FALSE:日期未改变,与先前日期一样,
  806. //lParam:在月历的第一视图,通过鼠标点击日期号(1-31)选择,为TRUE; 否则在月选择视图,或年选择视图都是FALSE;
  807. /// @brief 月历元素,日期改变事件.
  808. /// @code BOOL CALLBACK EventMonthChange(HELE hEle,HELE hEventEle,BOOL bChange,BOOL bDownDayNum); @endcode
  809. /// @param hEle 当前处理事件的元素句柄.
  810. /// @param hEventEle 触发事件的元素句柄.
  811. /// @param bChange TRUE日期发生改变; FALSE日期未改变,与先前日期一样.
  812. /// @param bDownDayNum 在月历的第一视图,通过鼠标点击日期号(1-31)选择,为TRUE; 否则在月选择视图,或年选择视图都是FALSE;
  813. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  814. #define XE_MONTHCAL_CHANGE 60 //月历元素,日期改变事件,
  815. /// @brief 日期编辑框元素,日期改变事件,日期格式为:年-月-日.
  816. /// @code BOOL CALLBACK EventDateTimeChange(HELE hEle,HELE hEventEle); @endcode
  817. /// @param hEle 当前处理事件的元素句柄.
  818. /// @param hEventEle 触发事件的元素句柄.
  819. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  820. #define XE_DATETIME_CHANGE 61 //日期元素,日期改变事件,wParam:0,lParam:0
  821. /// @brief 日期编辑框元素,弹出日期选择窗口事件.
  822. /// @code BOOL CALLBACK EventDateTimePopupMonthCal(HELE hEle,HELE hEventEle); @endcode
  823. /// @param hEle 当前处理事件的元素句柄.
  824. /// @param hEventEle 触发事件的元素句柄.
  825. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  826. #define XE_DATETIME_POPUP_MONTHCAL 62 //日期元素 弹出日期选择窗口事件,wParam:0,lParam:0
  827. /// @brief 日期编辑框元素,弹出日期选择窗口退出事件.
  828. /// @code BOOL CALLBACK EventDateTimeExitMonthCal(HELE hEle,HELE hEventEle); @endcode
  829. /// @param hEle 当前处理事件的元素句柄.
  830. /// @param hEventEle 触发事件的元素句柄.
  831. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  832. #define XE_DATETIME_EXIT_MONTHCAL 63 //日期元素 弹出日期选择窗口退出事件,wParam:0,lParam:0
  833. /// @brief 列表框元素,项选择事件.
  834. /// @code BOOL CALLBACK EventListBoxSelect(HELE hEle,HELE hEventEle,int index); @endcode
  835. /// @param hEle 当前处理事件的元素句柄.
  836. /// @param hEventEle 触发事件的元素句柄.
  837. /// @param index 选择项的索引,如果是-1没有选择任何项.
  838. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  839. #define XE_LISTBOX_SELECT 64 //列表框元素项选择,wParam:选择项索引,如果是-1没有选择项; lParam:0
  840. /// @brief 属性网格元素,项选择改变事件.
  841. /// @code BOOL CALLBACK EventPGridSelChange(HELE hEle,HELE hEventEle,int prevID,int id); @endcode
  842. /// @param hEle 当前处理事件的元素句柄.
  843. /// @param hEventEle 触发事件的元素句柄.
  844. /// @param prevID 先前选择项id,如果是-1没有选择项.
  845. /// @param id 当前选择项id,如果是-1没有选择项.
  846. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  847. #define XE_PGRID_SELCHANGE 65 //属性网格 项选择改变, wParam:先前选择项id,如果是-1没有选择项; lParam:当前选择项id,如果是-1没有选择项
  848. /// @brief 属性网格元素,项值改变事件.
  849. /// @code BOOL CALLBACK EventPGridValueChange(HELE hEle,HELE hEventEle,int id); @endcode
  850. /// @param hEle 当前处理事件的元素句柄.
  851. /// @param hEventEle 触发事件的元素句柄.
  852. /// @param id 项ID.
  853. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  854. #define XE_PGRID_VALUECHANGE 66 //属性网格 项值改变事件, wParam:值改变的项id; lPara:0
  855. /// @brief 列表视图元素,项选择事件.
  856. /// @code BOOL CALLBACK EventListViewSelect(HELE hEle,HELE hEventEle,int groupIndex,int itemIndex); @endcode
  857. /// @param hEle 当前处理事件的元素句柄.
  858. /// @param hEventEle 触发事件的元素句柄.
  859. /// @param id 项ID.
  860. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  861. #define XE_LISTVIEW_SELECT 67 //列表视图元素,项选择事件, wParam:组索引,如果-1没有选择组, lParam:项索引,如果-1没有选择项
  862. /// @brief 列表视图元素,组展开收缩事件
  863. /// @code BOOL CALLBACK EventListViewExpand(HELE hEle,HELE hEventEle,int groupIndex,BOOL bExpand); @endcode
  864. /// @param hEle 当前处理事件的元素句柄.
  865. /// @param hEventEle 触发事件的元素句柄.
  866. /// @param id 组ID.
  867. /// @param bExpand TRUE展开,FALSE收缩.
  868. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  869. #define XE_LISTVIEW_EXPAND 68 //列表视图元素,组展开收缩事件, wParam:组索引; lParam:展开TRUE,收缩FALSE
  870. /// @brief 列表视图元素,用户拖动项插入事件
  871. /// @code BOOL CALLBACK EventListViewDragInsert(HELE hEle,HELE hEventEle,listView_dragInsert_ *pInfo); @endcode
  872. /// @param hEle 当前处理事件的元素句柄.
  873. /// @param hEventEle 触发事件的元素句柄.
  874. /// @param pInfo 信息结构体.
  875. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  876. #define XE_LISTVIEW_DRAG_INSERT 69 //wParam:listView_dragInsert_*; lParam:0
  877. /// @brief 窗格锁定事件
  878. /// @code BOOL CALLBACK EventPaneLock(HELE hEle,HELE hEventEle); @endcode
  879. /// @param hEle 当前处理事件的元素句柄.
  880. /// @param hEventEle 触发事件的元素句柄.
  881. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  882. #define XE_PANE_LOACK 70 //wParam:0; lParam:0
  883. /// @brief 窗格停靠到码头事件
  884. /// @code BOOL CALLBACK EventPaneDock(HELE hEle,HELE hEventEle); @endcode
  885. /// @param hEle 当前处理事件的元素句柄.
  886. /// @param hEventEle 触发事件的元素句柄.
  887. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  888. #define XE_PANE_DOCK 80 //wParam:0; lParam:0
  889. /// @brief 窗格浮动事件
  890. /// @code BOOL CALLBACK EventPaneFloat(HELE hEle,HELE hEventEle); @endcode
  891. /// @param hEle 当前处理事件的元素句柄.
  892. /// @param hEventEle 触发事件的元素句柄.
  893. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  894. #define XE_PANE_FLOAT 81 //wParam:0; lParam:0
  895. /// @brief 编辑框内容改变事件
  896. /// @code BOOL CALLBACK EventEditChange(HELE hEle,HELE hEventEle); @endcode
  897. /// @param hEle 当前处理事件的元素句柄.
  898. /// @param hEventEle 触发事件的元素句柄.
  899. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  900. #define XE_EDIT_CHANGE 82 //wParam:0; lParam:0
  901. /// @brief 下拉组合框元素,选择项正在改变.
  902. /// @code BOOL CALLBACK EventComboBoxSelecting(HELE hEle,HELE hEventEle,int index,BOOL *pBOOL); @endcode
  903. /// @param hEle 当前处理事件的元素句柄.
  904. /// @param hEventEle 触发事件的元素句柄.
  905. /// @param index 选择项的索引,如果是-1没有选择任何项.
  906. /// @param pBOOL 是否终止改变,TRUE终止.
  907. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  908. #define XE_COMBOBOX_SELECT_ING 83 //wParam:index; lParam:pBOOL
  909. /// @brief 列表框元素,项选择正在改变.
  910. /// @code BOOL CALLBACK EventListBoxSelecting(HELE hEle,HELE hEventEle,int index,BOOL *pBOOL); @endcode
  911. /// @param hEle 当前处理事件的元素句柄.
  912. /// @param hEventEle 触发事件的元素句柄.
  913. /// @param index 选择项的索引,如果是-1没有选择任何项.
  914. /// @param pBOOL 是否终止改变,TRUE终止.
  915. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  916. #define XE_LISTBOX_SELECT_ING 84 //列表框元素项选择,wParam:选择项索引,如果是-1没有选择项; lParam:pBOOL
  917. /// @brief 树元素,项选择正在改变.
  918. /// @code BOOL CALLBACK EventTreeSelecting(HELE hEle,HELE hEventEle,int id,BOOL *pBOOL); @endcode
  919. /// @param hEle 当前处理事件的元素句柄.
  920. /// @param hEventEle 触发事件的元素句柄.
  921. /// @param id 选择项id,如果是-1没有选择项.
  922. /// @param pBOOL 是否终止改变,TRUE终止.
  923. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  924. #define XE_TREE_SELECT_ING 85 //树项选择, wParam:选择项id,如果是-1没有选择项, lParam:pBOOL
  925. ///@}
  926. #ifdef _DEBUG
  927. #define XTRACE xtrace
  928. #define XTRACEW xtracew
  929. #define XERROR XTRACE
  930. #define XERRORW XTRACEW
  931. #else
  932. #define XTRACE
  933. #define XTRACEW
  934. #define XERROR
  935. #define XERRORW
  936. #endif
  937. #ifndef GET_X_LPARAM
  938. #define GET_X_LPARAM(lp) ((int)(short)LOWORD(lp))
  939. #endif
  940. #ifndef GET_Y_LPARAM
  941. #define GET_Y_LPARAM(lp) ((int)(short)HIWORD(lp))
  942. #endif
  943. ///////////////////IE begin///////////////////////////////////////////////////
  944. //////////////////////////////////////////////////////////////////////////////
  945. //IE事件:
  946. ///@defgroup IE_Event IE事件
  947. ///@details 注册IE事件,DWebBrowserEvents2接口事件,注册API: XWeb_RegEvent().
  948. ///@ingroup msgAndEvents
  949. ///@{
  950. /// @brief 在导航操作之前.
  951. /// @code BOOL CALLBACK IE_BeforeNavigate2(HXCGUI hWebBrowser,in_ IDispatch *pDisp,in_ wchar_t *pUrl,in_ int Flags,in_ wchar_t *pTargetFrameName,in_ wchar_t *pPostData,in_ wchar_t *pHeaders,in_out_ VARIANT_BOOL *bCancel); @endcode
  952. /// @param hWebBrowser 浏览器控件句柄.
  953. /// @param pDisp 请参见MSDN.
  954. /// @param pUrl 请参见MSDN.
  955. /// @param Flags 请参见MSDN.
  956. /// @param pTargetFrameName 请参见MSDN.
  957. /// @param pPostData 请参见MSDN.
  958. /// @param pHeaders 请参见MSDN.
  959. /// @param bCancel TRUE取消导航操作,或FALSE允许进行导航操作。
  960. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  961. #define IE_BEFORENAVIGATE2 DISPID_BEFORENAVIGATE2 //BeforeNavigate2
  962. /// @brief 请求操作,客户区窗口大小转换到宿主窗口大小.
  963. /// @code BOOL CALLBACK IE_ClientToHostWindow(HXCGUI hWebBrowser,in_out_ long *pCx,in_out_ long *pCy); @endcode
  964. /// @param hWebBrowser 浏览器控件句柄.
  965. /// @param pCx 接收和指定的客户端窗口的宽度.
  966. /// @param pCy 接收和指定的客户端窗口的高度.
  967. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  968. #define IE_CLIENTTOHOSTWINDOW DISPID_CLIENTTOHOSTWINDOW //ClientToHostWindow
  969. /// @brief 启用状态的命令更改.
  970. /// @code BOOL CALLBACK IE_CommandStateChange(HXCGUI hWebBrowser,in_ long command,in_ VARIANT_BOOL enable); @endcode
  971. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  972. #define IE_COMMANDSTATECHANGE DISPID_COMMANDSTATECHANGE //CommandStateChange
  973. /// @brief 一个文档完全加载和初始化.
  974. /// @code BOOL CALLBACK IE_DocumentComplete(HXCGUI hWebBrowser,in_ IDispatch *pDisp,in_ wchar_t *pUrl); @endcode
  975. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  976. #define IE_DOCUMENTCOMPLETE DISPID_DOCUMENTCOMPLETE //DocumentComplete
  977. /// @brief 开始导航操作.
  978. /// @code BOOL CALLBACK IE_DownloadBegin(HXCGUI hWebBrowser); @endcode
  979. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  980. #define IE_DOWNLOADBEGIN DISPID_DOWNLOADBEGIN //DownloadBegin
  981. /// @brief 导航操作完成时,停止或失败.
  982. /// @code BOOL CALLBACK IE_DownloadComplete(HXCGUI hWebBrowser); @endcode
  983. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  984. #define IE_DOWNLOADCOMPLETE DISPID_DOWNLOADCOMPLETE //DownloadComplete
  985. /// @brief 下载文件是即将发生.
  986. /// @code BOOL CALLBACK IE_FileDownload(HXCGUI hWebBrowser,in_ VARIANT_BOOL ActiveDocument,in_out_ VARIANT_BOOL *Cancel); @endcode
  987. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  988. #define IE_FILEDOWNLOAD DISPID_FILEDOWNLOAD //FileDownload
  989. /// @brief 导航到一个链接,一个窗口元素或一个框架元素完成.
  990. /// @code BOOL CALLBACK IE_NavigateComplete2(HXCGUI hWebBrowser,in_ IDispatch *pDisp,in_ wchar_t *pUrl); @endcode
  991. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  992. #define IE_NAVIGATECOMPLETE2 DISPID_NAVIGATECOMPLETE2 //NavigateComplete2
  993. /// @brief 在导航过程中发生错误时触发.
  994. /// @code BOOL CALLBACK IE_NavigateError(HXCGUI hWebBrowser,in_ IDispatch *pDisp,in_ wchar_t *pUrl,in_ wchar_t *pTargetFrameName,in_ int statusCode,in_out_ VARIANT_BOOL *bCancel); @endcode
  995. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  996. #define IE_NAVIGATEERROR DISPID_NAVIGATEERROR //NavigateError
  997. // IE_NEWPROCESS DISPID_NEWPROCESS //NewProcess 找不到
  998. /// @brief 创建一个新的窗口时触发.
  999. /// @code BOOL CALLBACK IE_NewWindow2(HXCGUI hWebBrowser,in_out_ IDispatch **pDisp,in_out_ VARIANT_BOOL *bCancel); @endcode
  1000. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1001. #define IE_NEWWINDOW2 DISPID_NEWWINDOW2 //NewWindow2
  1002. /// @brief 创建一个新窗口时触发.
  1003. /// @code BOOL (CALLBACK *pFunIE_NewWindow3)(HXCGUI hWebBrowser,in_out_ IDispatch **pDisp,in_out_ VARIANT_BOOL *bCancel,in_ DWORD dwFlags,in_ wchar_t *pUrlContext,in_ wchar_t *pUrl); @endcode
  1004. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1005. #define IE_NEWWINDOW3 DISPID_NEWWINDOW3 //NewWindow3
  1006. /// @brief IWebBrowser2::FullScreen属性被改变时触发.
  1007. /// @code BOOL CALLBACK IE_OnFullScreen(HXCGUI hWebBrowser,in_ VARIANT_BOOL bFullScreen); @endcode
  1008. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1009. #define IE_ONFULLSCREEN DISPID_ONFULLSCREEN //OnFullScreen
  1010. /// @brief IWebBrowser2::MenuBar属性被改变时触发.
  1011. /// @code BOOL CALLBACK IE_OnMenuBar(HXCGUI hWebBrowser,in_ VARIANT_BOOL bMenuBar); @endcode
  1012. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1013. #define IE_ONMENUBAR DISPID_ONMENUBAR //OnMenuBar
  1014. /// @brief Internet Explorer的应用程序退出之前触发.
  1015. /// @code BOOL CALLBACK IE_OnQuit(HXCGUI hWebBrowser); @endcode
  1016. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1017. #define IE_ONQUIT DISPID_ONQUIT //OnQuit
  1018. /// @brief IWebBrowser2::StatusBar属性被改变时触发.
  1019. /// @code BOOL CALLBACK IE_OnStatusBar(HXCGUI hWebBrowser,in_ VARIANT_BOOL bStatusBar); @endcode
  1020. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1021. #define IE_ONSTATUSBAR DISPID_ONSTATUSBAR //OnStatusBar
  1022. /// @brief IWebBrowser2::TheaterMode属性被改变时触发.
  1023. /// @code BOOL CALLBACK IE_OnTheaterMode(HXCGUI hWebBrowser,in_ VARIANT_BOOL bTheaterMode); @endcode
  1024. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1025. #define IE_ONTHEATERMODE DISPID_ONTHEATERMODE //OnTheaterMode
  1026. /// @brief IWebBrowser2::ToolBar属性被改变时触发.
  1027. /// @code BOOL CALLBACK IE_OnToolBar(HXCGUI hWebBrowser,in_ VARIANT_BOOL bToolBar); @endcode
  1028. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1029. #define IE_ONTOOLBAR DISPID_ONTOOLBAR //OnToolBar
  1030. /// @brief IWebBrowser2::Visible属性被改变时触发.
  1031. /// @code BOOL CALLBACK IE_OnVisible(HXCGUI hWebBrowser,in_ VARIANT_BOOL bVisible); @endcode
  1032. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1033. #define IE_ONVISIBLE DISPID_ONVISIBLE //OnVisible
  1034. /// @brief 打印模板实例化时触发.
  1035. /// @code BOOL CALLBACK IE_PrintTemplateInstantiation(HXCGUI hWebBrowser,in_ IDispatch *pDisp); @endcode
  1036. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1037. #define IE_PRINTTEMPLATEINSTANTIATION DISPID_PRINTTEMPLATEINSTANTIATION //PrintTemplateInstantiation
  1038. /// @brief 打印模板被销毁时触发.
  1039. /// @code BOOL CALLBACK IE_PrintTemplateTeardown(HXCGUI hWebBrowser,in_ IDispatch *pDisp); @endcode
  1040. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1041. #define IE_PRINTTEMPLATETEARDOWN DISPID_PRINTTEMPLATETEARDOWN // PrintTemplateTeardown
  1042. /// @brief 当一个受影响的私有事件,或用户导航已经受影响的远程URL时发生.
  1043. /// @code BOOL CALLBACK IE_PrivacyImpactedStateChange(HXCGUI hWebBrowser,in_ VARIANT_BOOL bPrivacyImpacted); @endcode
  1044. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1045. #define IE_PRIVACYIMPACTEDSTATECHANGE DISPID_PRIVACYIMPACTEDSTATECHANGE //PrivacyImpactedStateChange
  1046. /// @brief 更新对象时触发的下载操作的进度.
  1047. /// @code BOOL CALLBACK IE_ProgressChangee(HXCGUI hWebBrowser,in_ long Progress,in_ long ProgressMax); @endcode
  1048. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1049. #define IE_PROGRESSCHANGE DISPID_PROGRESSCHANGE //ProgressChange
  1050. /// @brief IWebBrowser2::PutProperty对象的方法改变属性值时触发.
  1051. /// @code BOOL CALLBACK IE_PropertyChange(HXCGUI hWebBrowser,in_ wchar_t *pProperty); @endcode
  1052. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1053. #define IE_PROPERTYCHANGE DISPID_PROPERTYCHANGE //PropertyChange
  1054. // IE_REDIRECTXDOMAINBLOCKED DISPID_REDIRECTXDOMAINBLOCKED // RedirectXDomainBlocked 找不到
  1055. /// @brief 触发表明当前网页仿冒过滤分析微软的进度和状态。.
  1056. /// @code BOOL CALLBACK IE_SetPhishingFilterStatus(HXCGUI hWebBrowser,in_ long phishingFilterStatus); @endcode
  1057. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1058. #define IE_SETPHISHINGFILTERSTATUS DISPID_SETPHISHINGFILTERSTATUS //SetPhishingFilterStatus
  1059. /// @brief 在加密级别的变化时触发.
  1060. /// @code BOOL CALLBACK IE_SetSecureLockIcon(HXCGUI hWebBrowser,in_ signed int SecureLockIcon); @endcode
  1061. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1062. #define IE_SETSECURELOCKICON DISPID_SETSECURELOCKICON //SetSecureLockIcon
  1063. /// @brief 改变对象的状态栏文本时触发.
  1064. /// @code BOOL CALLBACK IE_StatusTextChange(HXCGUI hWebBrowser,in_ wchar_t *pText); @endcode
  1065. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1066. #define IE_STATUSTEXTCHANGE DISPID_STATUSTEXTCHANGE //StatusTextChange
  1067. // IE_THIRDPARTYURLBLOCKED DISPID_THIRDPARTYURLBLOCKED //ThirdPartyUrlBlocked 找不到
  1068. /// @brief 对象的文档的标题变为可用或改变时触发.
  1069. /// @code BOOL CALLBACK IE_TitleChange(HXCGUI hWebBrowser,in_ wchar_t *pText); @endcode
  1070. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1071. #define IE_TITLECHANGE DISPID_TITLECHANGE //TitleChange
  1072. //UpdatePageStatus IE没有实现
  1073. /// @brief 该对象的窗口被关闭脚本时触发.
  1074. /// @code BOOL CALLBACK IE_WindowClosing(HXCGUI hWebBrowser,in_ VARIANT_BOOL IsChildWindow,in_out_ VARIANT_BOOL *bCancel); @endcode
  1075. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1076. #define IE_WINDOWCLOSING DISPID_WINDOWCLOSING //WindowClosing
  1077. /// @brief 当对象改变其高度的触发.
  1078. /// @code BOOL CALLBACK IE_WindowSetHeight(HXCGUI hWebBrowser,in_ long height); @endcode
  1079. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1080. #define IE_WINDOWSETHEIGHT DISPID_WINDOWSETHEIGHT //WindowSetHeight
  1081. /// @brief 当对象改变其左侧位置时触发.
  1082. /// @code BOOL CALLBACK IE_WindowSetLeft(HXCGUI hWebBrowser,in_ long left); @endcode
  1083. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1084. #define IE_WINDOWSETLEFT DISPID_WINDOWSETLEFT //WindowSetLeft
  1085. /// @brief 发生指示宿主窗口是否应该允许调整对象.
  1086. /// @code BOOL CALLBACK IE_WindowSetResizable(HXCGUI hWebBrowser,in_ VARIANT_BOOL bResizable); @endcode
  1087. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1088. #define IE_WINDOWSETRESIZABLE DISPID_WINDOWSETRESIZABLE //WindowSetResizable
  1089. /// @brief 当对象改变其顶部位置的触发.
  1090. /// @code BOOL CALLBACK IE_WindowSetTop(HXCGUI hWebBrowser,in_ long top); @endcode
  1091. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1092. #define IE_WINDOWSETTOP DISPID_WINDOWSETTOP //WindowSetTop
  1093. /// @brief 当对象改变其宽度的触发.
  1094. /// @code BOOL CALLBACK IE_WindowSetWidth(HXCGUI hWebBrowser,in_ long width); @endcode
  1095. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1096. #define IE_WINDOWSETWIDTH DISPID_WINDOWSETWIDTH //WindowSetWidth
  1097. /// @brief 当窗口内容的可见性状态,如浏览器窗口或选项卡,更改时触发.
  1098. /// @code BOOL CALLBACK IE_WindowStateChanged(HXCGUI hWebBrowser,in_ DWORD dwFlags,in_ DWORD dwValidFlagsMask); @endcode
  1099. /// @return 默认返回FALSE,如果终止事件传递返回TRUE.
  1100. #define IE_WINDOWSTATECHANGED DISPID_WINDOWSTATECHANGED //WindowStateChanged
  1101. ///@}
  1102. //定义IE外部函数类型
  1103. typedef BOOL (CALLBACK *pFunIE_External0)(HXCGUI hWebBrowser,HSTRING hResultVal);
  1104. typedef BOOL (CALLBACK *pFunIE_External1)(HXCGUI hWebBrowser,HSTRING hResultVal,wchar_t *pParam1);
  1105. typedef BOOL (CALLBACK *pFunIE_External2)(HXCGUI hWebBrowser,HSTRING hResultVal,wchar_t *pParam1,wchar_t *pParam2);
  1106. typedef BOOL (CALLBACK *pFunIE_External3)(HXCGUI hWebBrowser,HSTRING hResultVal,wchar_t *pParam1,wchar_t *pParam2,wchar_t *pParam3);
  1107. typedef BOOL (CALLBACK *pFunIE_External4)(HXCGUI hWebBrowser,HSTRING hResultVal,wchar_t *pParam1,wchar_t *pParam2,wchar_t *pParam3,wchar_t *pParam4);
  1108. typedef BOOL (CALLBACK *pFunIE_External5)(HXCGUI hWebBrowser,HSTRING hResultVal,wchar_t *pParam1,wchar_t *pParam2,wchar_t *pParam3,wchar_t *pParam4,wchar_t *pParam5);
  1109. typedef BOOL (CALLBACK *pFunIE_External6)(HXCGUI hWebBrowser,HSTRING hResultVal,wchar_t *pParam1,wchar_t *pParam2,wchar_t *pParam3,wchar_t *pParam4,wchar_t *pParam5,wchar_t *pParam6);
  1110. typedef BOOL (CALLBACK *pFunIE_External7)(HXCGUI hWebBrowser,HSTRING hResultVal,wchar_t *pParam1,wchar_t *pParam2,wchar_t *pParam3,wchar_t *pParam4,wchar_t *pParam5,wchar_t *pParam6,wchar_t *pParam7);
  1111. typedef BOOL (CALLBACK *pFunIE_External8)(HXCGUI hWebBrowser,HSTRING hResultVal,wchar_t *pParam1,wchar_t *pParam2,wchar_t *pParam3,wchar_t *pParam4,wchar_t *pParam5,wchar_t *pParam6,wchar_t *pParam7,wchar_t *pParam8);
  1112. //定义IE事件回调函数类型
  1113. typedef BOOL (CALLBACK *pFunIE_BeforeNavigate2)(HXCGUI hWebBrowser,in_ IDispatch *pDisp,in_ wchar_t *pUrl,in_ int Flags,in_ wchar_t *pTargetFrameName,in_ wchar_t *pPostData,in_ wchar_t *pHeaders,in_out_ VARIANT_BOOL *bCancel);
  1114. typedef BOOL (CALLBACK *pFunIE_ClientToHostWindow)(HXCGUI hWebBrowser,in_out_ long *pCx,in_out_ long *pCy);
  1115. typedef BOOL (CALLBACK *pFunIE_CommandStateChange)(HXCGUI hWebBrowser,in_ long command,in_ VARIANT_BOOL enable);
  1116. typedef BOOL (CALLBACK *pFunIE_DocumentComplete)(HXCGUI hWebBrowser,in_ IDispatch *pDisp,in_ wchar_t *pUrl);
  1117. typedef BOOL (CALLBACK *pFunIE_DownloadBegin)(HXCGUI hWebBrowser);
  1118. typedef BOOL (CALLBACK *pFunIE_DownloadComplete)(HXCGUI hWebBrowser);
  1119. typedef BOOL (CALLBACK *pFunIE_FileDownload)(HXCGUI hWebBrowser,in_ VARIANT_BOOL ActiveDocument,in_out_ VARIANT_BOOL *Cancel);
  1120. typedef BOOL (CALLBACK *pFunIE_NavigateComplete2)(HXCGUI hWebBrowser,in_ IDispatch *pDisp,in_ wchar_t *pUrl);
  1121. typedef BOOL (CALLBACK *pFunIE_NavigateError)(HXCGUI hWebBrowser,in_ IDispatch *pDisp,in_ wchar_t *pUrl,in_ wchar_t *pTargetFrameName,in_ int statusCode,in_out_ VARIANT_BOOL *bCancel);
  1122. typedef BOOL (CALLBACK *pFunIE_NewWindow2)(HXCGUI hWebBrowser,in_out_ IDispatch **pDisp,in_out_ VARIANT_BOOL *bCancel);
  1123. typedef BOOL (CALLBACK *pFunIE_NewWindow3)(HXCGUI hWebBrowser,in_out_ IDispatch **pDisp,in_out_ VARIANT_BOOL *bCancel,in_ DWORD dwFlags,in_ wchar_t *pUrlContext,in_ wchar_t *pUrl);
  1124. typedef BOOL (CALLBACK *pFunIE_OnFullScreen)(HXCGUI hWebBrowser,in_ VARIANT_BOOL bFullScreen);
  1125. typedef BOOL (CALLBACK *pFunIE_OnMenuBar)(HXCGUI hWebBrowser,in_ VARIANT_BOOL bMenuBar);
  1126. typedef BOOL (CALLBACK *pFunIE_OnQuit)(HXCGUI hWebBrowser);
  1127. typedef BOOL (CALLBACK *pFunIE_OnStatusBar)(HXCGUI hWebBrowser,in_ VARIANT_BOOL bStatusBar);
  1128. typedef BOOL (CALLBACK *pFunIE_OnTheaterMode)(HXCGUI hWebBrowser,in_ VARIANT_BOOL bTheaterMode);
  1129. typedef BOOL (CALLBACK *pFunIE_OnToolBar)(HXCGUI hWebBrowser,in_ VARIANT_BOOL bToolBar);
  1130. typedef BOOL (CALLBACK *pFunIE_OnVisible)(HXCGUI hWebBrowser,in_ VARIANT_BOOL bVisible);
  1131. typedef BOOL (CALLBACK *pFunIE_PrintTemplateInstantiation)(HXCGUI hWebBrowser,in_ IDispatch *pDisp);
  1132. typedef BOOL (CALLBACK *pFunIE_PrintTemplateTeardown)(HXCGUI hWebBrowser,in_ IDispatch *pDisp);
  1133. typedef BOOL (CALLBACK *pFunIE_PrivacyImpactedStateChange)(HXCGUI hWebBrowser,in_ VARIANT_BOOL bPrivacyImpacted);
  1134. typedef BOOL (CALLBACK *pFunIE_ProgressChangee)(HXCGUI hWebBrowser,in_ long Progress,in_ long ProgressMax);
  1135. typedef BOOL (CALLBACK *pFunIE_PropertyChange)(HXCGUI hWebBrowser,in_ wchar_t *pProperty);
  1136. typedef BOOL (CALLBACK *pFunIE_SetPhishingFilterStatus)(HXCGUI hWebBrowser,in_ long phishingFilterStatus);
  1137. typedef BOOL (CALLBACK *pFunIE_SetSecureLockIcon)(HXCGUI hWebBrowser,in_ signed int SecureLockIcon);
  1138. typedef BOOL (CALLBACK *pFunIE_StatusTextChange)(HXCGUI hWebBrowser,in_ wchar_t *pText);
  1139. typedef BOOL (CALLBACK *pFunIE_TitleChange)(HXCGUI hWebBrowser,in_ wchar_t *pText);
  1140. typedef BOOL (CALLBACK *pFunIE_WindowClosing)(HXCGUI hWebBrowser,in_ VARIANT_BOOL IsChildWindow,in_out_ VARIANT_BOOL *bCancel);
  1141. typedef BOOL (CALLBACK *pFunIE_WindowSetHeight)(HXCGUI hWebBrowser,in_ long height);
  1142. typedef BOOL (CALLBACK *pFunIE_WindowSetLeft)(HXCGUI hWebBrowser,in_ long left);
  1143. typedef BOOL (CALLBACK *pFunIE_WindowSetResizable)(HXCGUI hWebBrowser,in_ VARIANT_BOOL bResizable);
  1144. typedef BOOL (CALLBACK *pFunIE_WindowSetTop)(HXCGUI hWebBrowser,in_ long top);
  1145. typedef BOOL (CALLBACK *pFunIE_WindowSetWidth)(HXCGUI hWebBrowser,in_ long width);
  1146. typedef BOOL (CALLBACK *pFunIE_WindowStateChanged)(HXCGUI hWebBrowser,in_ DWORD dwFlags,in_ DWORD dwValidFlagsMask);
  1147. ////////////////IE end///////////////////////////////////////////////////////////
  1148. /////////////////////////////////////////////////////////////////////////////////
  1149. //窗口消息处理过程
  1150. typedef BOOL (CALLBACK *pFunWndMsgProc)(HWINDOW hWindow,UINT message, WPARAM wParam, LPARAM lParam);
  1151. //元素消息处理过程
  1152. typedef BOOL (CALLBACK *pFunEleMsgProc)(HELE hEle,UINT eleMessage,WPARAM wParam,LPARAM lParam);
  1153. //元素事件处理过程
  1154. typedef BOOL (CALLBACK *pFunEleEventProc)(HELE hEle,int type,WPARAM wParam,LPARAM lParam);
  1155. //绘制滚动视图
  1156. typedef BOOL (CALLBACK *pFunDrawScrollView)(HELE hEle,HDRAW hDraw);
  1157. //////////////////////////////////////////////////////////
  1158. //树元素自绘
  1159. ///@addtogroup groupTree
  1160. ///@{
  1161. ///列表树元素,项自绘结构
  1162. struct tree_drewItem_
  1163. {
  1164. HDRAW hDraw; ///<图形绘制句柄
  1165. int id; ///<项ID
  1166. int imageId; ///<图标ID
  1167. int state; ///<状态
  1168. BOOL bExpand; ///<是否展开结点
  1169. wchar_t *pText; ///<文本内容
  1170. RECT rcButton; ///<按钮坐标
  1171. RECT rcImage; ///<图片坐标
  1172. RECT rcText; ///<文本坐标
  1173. };
  1174. ///@}
  1175. ///@defgroup groupList_draw 列表元素自绘
  1176. ///@ingroup macroDefine
  1177. ///@{
  1178. ///列表元素,项自绘结构
  1179. struct list_drawItem_
  1180. {
  1181. HDRAW hDraw; ///<图形绘制句柄
  1182. int index; ///<项索引
  1183. int subIndex; ///<子项索引
  1184. int imageId; ///<图标ID
  1185. int state; ///<状态
  1186. RECT rect; ///<项坐标
  1187. RECT rcCheck; ///<复选框坐标,对subIndex索引为0的有效
  1188. wchar_t *pText; ///<文本内容
  1189. };
  1190. ///列表元素,列表头项自绘结构
  1191. struct listHeader_drawItem_
  1192. {
  1193. HDRAW hDraw; ///<图形绘制句柄
  1194. int index; ///<项索引
  1195. int imageId; ///<图标ID
  1196. int state; ///<状态 如果值为-1,那么为绘制背景
  1197. RECT rect; ///<项坐标
  1198. wchar_t *pText; ///<文本内容
  1199. };
  1200. ///@}
  1201. ///@defgroup groupListBox_draw 列表框元素自绘
  1202. ///@ingroup macroDefine
  1203. ///@{
  1204. ///列表框元素,项自绘结构
  1205. struct listBox_drawItem_
  1206. {
  1207. HDRAW hDraw; ///<图形绘制句柄
  1208. int index; ///<索引
  1209. int imageId; ///<图标ID
  1210. int state; ///<状态
  1211. RECT rcItem; ///<项坐标
  1212. RECT rcCheck; ///<复选框坐标,当复选框启用时有效
  1213. wchar_t *pText; ///<文本内容
  1214. };
  1215. ///@}
  1216. ///@defgroup itemBindEle 项绑定元素信息结构
  1217. ///@ingroup macroDefine
  1218. ///@{
  1219. ///项绑定元素信息结构.
  1220. struct itemBindEle_
  1221. {
  1222. HELE hEle; ///<绑定的元素,如果绑定到列表元素,那么它的父应该为列表元素.
  1223. int left; ///<相对于项.
  1224. int top; ///<相对于项.
  1225. int width; ///<宽度.
  1226. int height; ///<高度.
  1227. };
  1228. ///@}
  1229. ///@defgroup groupListView_draw 列表视图元素自绘
  1230. ///@ingroup macroDefine
  1231. ///@{
  1232. ///列表视图元素,项自绘结构
  1233. struct listView_drawItem_ //绘制项
  1234. {
  1235. HDRAW hDraw; ///<图形绘制句柄
  1236. int groupIndex; //组索引
  1237. int itemIndex; //项索引
  1238. int imageID; ///<图片ID
  1239. wchar_t *pText; ///<文本
  1240. int state; ///<状态,是否选择
  1241. HIMAGE hImage_stay; //项停留图片
  1242. HIMAGE hImage_select; //项选择图标
  1243. RECT rcIcon; ///<图标坐标
  1244. RECT rcIconDraw; ///<图标实际绘制区域
  1245. RECT rcText; ///<文字坐标
  1246. RECT rect; ///<整个区域,包含边框
  1247. int userData; ///<用户数据
  1248. };
  1249. ///列表视图元素,组自绘结构
  1250. struct listView_drawGroup_ //绘制组
  1251. {
  1252. HDRAW hDraw; ///<图形绘制句柄
  1253. BOOL bExpand; ///<是否展开
  1254. wchar_t *pText; ///<文本
  1255. RECT rcText; ///<文本坐标
  1256. RECT rcButton; ///<展开按钮坐标
  1257. RECT rect; ///<组区域坐标
  1258. int userData; ///<用户数据
  1259. };
  1260. ///列表视图元素,用户拖动项插入
  1261. struct listView_dragInsert_
  1262. {
  1263. int groupIndex; ///<拖动项 - 组索引
  1264. int itemIndex; ///<拖动项 - 项索引
  1265. int groupIndex_insert; ///<插入位置 - 组索引
  1266. int itemIndex_insert; ///<插入位置 - 项索引
  1267. int groupIndex_new; //插入后位置 组索引
  1268. int itemIndex_new; //插入后位置 项索引
  1269. };
  1270. ///@}
  1271. ///@defgroup groupMenu_draw 菜单自绘
  1272. ///@ingroup macroDefine
  1273. ///@{
  1274. ///菜单项自绘结构
  1275. struct menu_drawItem_
  1276. {
  1277. HWINDOW hWindow; ///<当前弹出菜单项的窗口句柄
  1278. HDRAW hDraw; ///<图形绘制句柄
  1279. int id; ///<ID
  1280. int state; ///<状态
  1281. RECT rcItem; ///<坐标
  1282. HIMAGE hImage; ///<图片
  1283. wchar_t *pText; ///<文本
  1284. };
  1285. ///菜单窗口背景自绘结构
  1286. struct menu_drawBG_
  1287. {
  1288. HWINDOW hWindow; ///<当前弹出菜单项的窗口句柄
  1289. HDRAW hDraw; ///<图形绘制句柄
  1290. int parentItemId; ///<子菜单对应的父项菜单ID,-1没有父项
  1291. HIMAGE hImage; ///<图片
  1292. };
  1293. ///@}
  1294. //列表项自绘
  1295. typedef void (CALLBACK *pFunList_DrawItem)(HELE hEle,list_drawItem_ *pDrawItem);
  1296. //列表头项自绘
  1297. typedef void (CALLBACK *pFunListHeader_DrawItem)(HELE hEle,listHeader_drawItem_ *pDrawItem);
  1298. //列表框项自绘
  1299. typedef void (CALLBACK *pFunListBox_DrawItem)(HELE hEle,listBox_drawItem_ *pDrawItem);
  1300. //树项自绘
  1301. typedef void (CALLBACK *pFunTree_DrawItem)(HELE hEle,tree_drewItem_ *pDrawItem);
  1302. //列表视图项自绘
  1303. typedef void (CALLBACK *pFunListView_DrawItem)(HELE hEle,listView_drawItem_ *pDrawItem);
  1304. //列表视图组自绘
  1305. typedef void (CALLBACK *pFunListView_DrawGroup)(HELE hEle,listView_drawGroup_ *pDrawGroup);
  1306. //菜单项自绘
  1307. typedef void (CALLBACK *pFunMenu_DrawItem)(HMENUX hMenu,menu_drawItem_ *pDrawItem);
  1308. //菜单背景自绘
  1309. typedef void (CALLBACK *pFunMenu_DrawBG)(HMENUX hMenu,menu_drawBG_ *pDrawBG);
  1310. //菜单项更新UI
  1311. typedef void (CALLBACK *pFunMenu_UpdateUI)(HMENUX hMenu,int id);
  1312. //////////////////////////////////////////////////////////////////////////////////
  1313. //下面部分通常不需要改动//////////////////////////////////////////////////////////
  1314. #define XCGUI_PLUS // C++类支持版 , C plus plus
  1315. #ifdef XCGUI_PLUS //C++类支持,对类成员函数注册的支持
  1316. struct eventOrMsg_ //元素消息事件回调信息,C++类支持
  1317. {
  1318. union
  1319. {
  1320. HELE hEle;
  1321. HWINDOW hWindow;
  1322. HMENUX hMenu;
  1323. };
  1324. union
  1325. {
  1326. HELE hEventEle;
  1327. int xint;
  1328. };
  1329. WPARAM wParam;
  1330. LPARAM lParam;
  1331. void *pClass_fun; //类成员函数指针
  1332. };
  1333. //格式 xc_fun_返回类型_参数类型表...
  1334. //b:BOOL, e:HELE, w:HWINDOW, x:HXCGUI, hwnd:HWND, hdraw:HDRAW, i:int, p:void*, pt:POINT*, size:SIZE*, v:void
  1335. //pb:BOOL*;
  1336. //menu:HMENUX.
  1337. enum xcgui_fun_type //函数类型
  1338. {
  1339. xc_fun_b_e_e,
  1340. xc_fun_b_e_e_b,
  1341. xc_fun_b_e_e_b_b,
  1342. xc_fun_b_e_e_w_e,
  1343. xc_fun_b_e_e_pb,
  1344. xc_fun_b_e_e_i,
  1345. xc_fun_b_e_e_i_pt,
  1346. xc_fun_b_e_e_i_b,
  1347. xc_fun_b_e_e_i_pb,
  1348. xc_fun_b_e_e_i_i,
  1349. xc_fun_b_e_i_i,
  1350. xc_fun_b_e_i_i_i,
  1351. xc_fun_b_e_e_listView_dragInsert,
  1352. xc_fun_v_e, //元素销毁
  1353. xc_fun_b_e_pt,
  1354. xc_fun_b_e_hdraw,
  1355. xc_fun_b_e_i_pt,
  1356. xc_fun_b_w,
  1357. xc_fun_b_w_e,
  1358. xc_fun_b_w_pt,
  1359. xc_fun_b_w_i,
  1360. xc_fun_b_w_i_pt,
  1361. xc_fun_b_w_i_size,
  1362. xc_fun_b_w_i_i,
  1363. xc_fun_b_w_hdraw,
  1364. xc_fun_b_w_hwnd,
  1365. xc_fun_v_e_list_item,
  1366. xc_fun_v_e_list_header,
  1367. xc_fun_v_e_tree,
  1368. xc_fun_v_e_listBox,
  1369. xc_fun_v_e_listView_item,
  1370. xc_fun_v_e_listView_group,
  1371. xc_fun_v_x_menu_item,
  1372. xc_fun_v_x_menu_bg,
  1373. xc_fun_v_x_menu_i,
  1374. };
  1375. //事件回调类型
  1376. typedef BOOL (CALLBACK *pFunClassEventMsg)(eventOrMsg_ *pEvent,xcgui_fun_type funType);
  1377. //{
  1378. //以下API内部使用
  1379. extern XC_API void* WINAPI XC_Malloc(int size);
  1380. extern XC_API void WINAPI XEle_RegisterMessageEx(HELE hEle,int message,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info);
  1381. extern XC_API void WINAPI XEle_RegisterEventEx(HELE hEle,int type,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info);
  1382. extern XC_API void WINAPI XEle_RegisterMsgProcEx(HELE hEle,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //注册元素消息处理过程
  1383. extern XC_API void WINAPI XEle_RegisterEventProcEx(HELE hEle,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //注册事件拦截过滤函数
  1384. extern XC_API void WINAPI XWnd_RegisterMessageEx(HWINDOW hWindow,int message,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //注册消息回调函数
  1385. extern XC_API void WINAPI XWnd_RegisterNCMessageEx(HWINDOW hWindow,int message,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //注册非客户区消息
  1386. extern XC_API void WINAPI XWnd_RegisterMsgProcEx(HWINDOW hWindow,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //注册窗口消息处理过程
  1387. extern XC_API void WINAPI XSView_SetDrawScrollViewEx(HELE hEle,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info);
  1388. extern XC_API void WINAPI XList_SetUserDrawItemEx(HELE hEle,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //设置用户自绘列表项
  1389. extern XC_API void WINAPI XList_SetUserDrawItemHeaderEx(HELE hEle,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //设置用户自绘列表头项
  1390. extern XC_API void WINAPI XTree_SetUserDrawItemEx(HELE hEle,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //设置用户自绘项
  1391. extern XC_API void WINAPI XListBox_SetUserDrawItemEx(HELE hEle,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //设置用户自绘列表框项
  1392. extern XC_API void WINAPI XListView_SetUserDrawItemEx(HELE hEle,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //设置用户自绘项
  1393. extern XC_API void WINAPI XListView_SetUserDrawGroupEx(HELE hEle,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //设置用户自绘组
  1394. extern XC_API void WINAPI XMenu_SetUserDrawItemEx(HMENUX hMenu,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //设置用户自绘菜单项
  1395. extern XC_API void WINAPI XMenu_SetUserDrawBGEx(HMENUX hMenu,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //设置用户自绘菜背景
  1396. extern XC_API void WINAPI XMenu_SetUserUpdateUIEx(HMENUX hMenu,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info);
  1397. //}
  1398. class CXEventMsg
  1399. {
  1400. public:
  1401. virtual void CXEventMsg__(void){} //此函数不可删除
  1402. //注册元素事件
  1403. #define XCGUI_RegEleEvent(hEle,type,memberFunction) \
  1404. RegisterAll(hEle,type,reinterpret_cast<void (CXEventMsg::*)(void)>(memberFunction),ele_event)
  1405. //注册元素消息
  1406. #define XCGUI_RegEleMessage(hEle,type,memberFunction) \
  1407. RegisterAll(hEle,type,reinterpret_cast<void (CXEventMsg::*)(void)>(memberFunction),ele_msg)
  1408. //注册元素消息处理过程
  1409. #define XCGUI_RegEleMsgProc(hEle,type,memberFunction) \
  1410. RegisterAll(hEle,type,reinterpret_cast<void (CXEventMsg::*)(void)>(memberFunction),ele_msg_proc)
  1411. //注册元素事件处理过程
  1412. #define XCGUI_RegEleEventProc(hEle,type,memberFunction) \
  1413. RegisterAll(hEle,type,reinterpret_cast<void (CXEventMsg::*)(void)>(memberFunction),ele_event_proc)
  1414. //注册窗口消息
  1415. #define XCGUI_RegWndMessage(hWindow,type,memberFunction) \
  1416. RegisterAll(hWindow,type,reinterpret_cast<void (CXEventMsg::*)(void)>(memberFunction),wnd_msg)
  1417. //注册窗口逻辑非客户区消息
  1418. #define XCGUI_RegWndNCMessage(hWindow,type,memberFunction) \
  1419. RegisterAll(hWindow,type,reinterpret_cast<void (CXEventMsg::*)(void)>(memberFunction),wnd_msg_nc)
  1420. //注册窗口消息处理过程
  1421. #define XCGUI_RegWndMsgProc(hWindow,memberFunction) \
  1422. RegisterAll(hWindow,0,reinterpret_cast<void (CXEventMsg::*)(void)>(memberFunction),wnd_msg_proc)
  1423. //注册滚动视图绘制
  1424. #define XCGUI_SView_SetDrawScrollView(hEle,memberFunction) \
  1425. RegisterAll(hEle,0,reinterpret_cast<void (CXEventMsg::*)(void)>(memberFunction),ele_scrollView_draw)
  1426. //注册列表项绘制
  1427. #define XCGUI_List_SetUserDrawItem(hEle,memberFunction) \
  1428. RegisterAll(hEle,0,reinterpret_cast<void (CXEventMsg::*)(void)>(memberFunction),ele_list_drawItem)
  1429. //列表头项绘制
  1430. #define XCGUI_List_SetUserDrawItemHeader(hEle,memberFunction) \
  1431. RegisterAll(hEle,0,reinterpret_cast<void (CXEventMsg::*)(void)>(memberFunction),ele_list_drawItemHeader)
  1432. //树项绘制
  1433. #define XCGUI_Tree_SetUserDrawItem(hEle,memberFunction) \
  1434. RegisterAll(hEle,0,reinterpret_cast<void (CXEventMsg::*)(void)>(memberFunction),ele_tree_drawItem)
  1435. //列表框项绘制
  1436. #define XCGUI_ListBox_SetUserDrawItem(hEle,memberFunction) \
  1437. RegisterAll(hEle,0,reinterpret_cast<void (CXEventMsg::*)(void)>(memberFunction),ele_listBox_drawItem)
  1438. //列表视图项绘制
  1439. #define XCGUI_ListView_SetUserDrawItem(hEle,memberFunction) \
  1440. RegisterAll(hEle,0,reinterpret_cast<void (CXEventMsg::*)(void)>(memberFunction),ele_listView_drawItem)
  1441. //列表视图组绘制
  1442. #define XCGUI_ListView_SetUserDrawGroup(hEle,memberFunction) \
  1443. RegisterAll(hEle,0,reinterpret_cast<void (CXEventMsg::*)(void)>(memberFunction),ele_listView_drawGroup)
  1444. //菜单项自绘
  1445. #define XCGUI_Menu_SetUserDrawItem(hMenu,memberFunction) \
  1446. RegisterAll(hMenu,0,reinterpret_cast<void (CXEventMsg::*)(void)>(memberFunction),ele_menu_drawItem)
  1447. //菜单背景自绘
  1448. #define XCGUI_Menu_SetUserDrawBG(hMenu,memberFunction) \
  1449. RegisterAll(hMenu,0,reinterpret_cast<void (CXEventMsg::*)(void)>(memberFunction),ele_menu_drawBG)
  1450. //更新菜单项
  1451. #define XCGUI_Menu_SetUserUpdateUI(hMenu,memberFunction) \
  1452. RegisterAll(hMenu,0,reinterpret_cast<void (CXEventMsg::*)(void)>(memberFunction),ele_menu_updateUI)
  1453. union xcgui_functions //函数指针
  1454. {
  1455. void (CXEventMsg::*fun_v_v)(void);
  1456. BOOL (CXEventMsg::*fun_b_e_e_i_i)(HELE,HELE,int,int);
  1457. BOOL (CXEventMsg::*fun_b_e_e_i)(HELE,HELE,int);
  1458. BOOL (CXEventMsg::*fun_b_e_e)(HELE,HELE);
  1459. BOOL (CXEventMsg::*fun_b_e_e_pb)(HELE,HELE,BOOL*);
  1460. BOOL (CXEventMsg::*fun_b_e_e_i_pb)(HELE,HELE,int,BOOL*);
  1461. BOOL (CXEventMsg::*fun_b_e_e_b)(HELE,HELE,BOOL);
  1462. BOOL (CXEventMsg::*fun_b_e_e_i_p)(HELE,HELE,int,POINT*);
  1463. BOOL (CXEventMsg::*fun_b_e_e_i_b)(HELE,HELE,int,BOOL);
  1464. BOOL (CXEventMsg::*fun_b_e_e_b_b)(HELE,HELE,BOOL,BOOL);
  1465. BOOL (CXEventMsg::*fun_b_e_i_i_i)(HELE,int,int,int);
  1466. BOOL (CXEventMsg::*fun_b_e_i_i)(HELE,int,int);
  1467. BOOL (CXEventMsg::*fun_b_e_e_w_e)(HELE,HELE,HWINDOW,HELE);
  1468. BOOL (CXEventMsg::*fun_b_e_e_listViewDragInsert)(HELE,HELE,listView_dragInsert_*);
  1469. void (CXEventMsg::*fun_v_e)(HELE);
  1470. BOOL (CXEventMsg::*fun_b_e_i_p)(HELE,int,POINT*);
  1471. BOOL (CXEventMsg::*fun_b_e_p)(HELE,POINT*);
  1472. BOOL (CXEventMsg::*fun_b_e_hdraw)(HELE,HDRAW);
  1473. BOOL (CXEventMsg::*fun_b_w_hdraw)(HWINDOW,HDRAW);
  1474. BOOL (CXEventMsg::*fun_b_w)(HWINDOW);
  1475. BOOL (CXEventMsg::*fun_b_w_i_p)(HWINDOW,int,POINT*);
  1476. BOOL (CXEventMsg::*fun_b_w_i_size)(HWINDOW,int,SIZE*);
  1477. BOOL (CXEventMsg::*fun_b_w_i_i)(HWINDOW,int,int);
  1478. BOOL (CXEventMsg::*fun_b_w_p)(HWINDOW,POINT*);
  1479. BOOL (CXEventMsg::*fun_b_w_e)(HWINDOW,HELE);
  1480. BOOL (CXEventMsg::*fun_b_w_hwnd)(HWINDOW,HWND);
  1481. BOOL (CXEventMsg::*fun_b_w_i)(HWINDOW,int);
  1482. void (CXEventMsg::*fun_v_e_list)(HELE,list_drawItem_*);
  1483. void (CXEventMsg::*fun_v_e_listHeader)(HELE,listHeader_drawItem_*);
  1484. void (CXEventMsg::*fun_v_e_tree)(HELE,tree_drewItem_*);
  1485. void (CXEventMsg::*fun_v_e_listBox)(HELE,listBox_drawItem_*);
  1486. void (CXEventMsg::*fun_v_e_listView)(HELE,listView_drawItem_*);
  1487. void (CXEventMsg::*fun_v_e_listViewGroup)(HELE,listView_drawGroup_*);
  1488. void (CXEventMsg::*fun_v_x_menu_drawItem)(HMENUX,menu_drawItem_*);
  1489. void (CXEventMsg::*fun_v_x_menu_drawBG)(HMENUX,menu_drawBG_*);
  1490. void (CXEventMsg::*fun_v_x_menu_updateUI)(HMENUX,int);
  1491. };
  1492. enum xcgui_reg_type //注册类型
  1493. {
  1494. ele_event, //元素事件
  1495. ele_msg, //元素消息
  1496. ele_msg_proc, //元素消息处理过程
  1497. ele_event_proc, //元素事件处理过程
  1498. wnd_msg, //窗口消息
  1499. wnd_msg_nc, //窗口逻辑非客户区消息
  1500. wnd_msg_proc, //窗口消息处理过程
  1501. //---------------
  1502. ele_scrollView_draw, //滚动视图自绘
  1503. ele_list_drawItem, //列表项自绘
  1504. ele_list_drawItemHeader, //列表头项自绘
  1505. ele_tree_drawItem, //树项自绘
  1506. ele_listBox_drawItem, //列表框项自绘
  1507. ele_listView_drawItem, //列表视图项绘制
  1508. ele_listView_drawGroup, //列表视图组绘制
  1509. ele_menu_drawItem, //绘制菜单项
  1510. ele_menu_drawBG, //绘制菜单背景
  1511. ele_menu_updateUI, //菜单项更新UI
  1512. };
  1513. struct xcgui_info_
  1514. {
  1515. CXEventMsg *theThis;
  1516. xcgui_functions funs;
  1517. };
  1518. void RegisterAll(HXCGUI hXCGUI,int type,void (CXEventMsg::*fun)(void),int T) //注册消息事件
  1519. {
  1520. xcgui_info_ *pInfo=(xcgui_info_*)XC_Malloc(sizeof(xcgui_info_));
  1521. pInfo->theThis=this;
  1522. pInfo->funs.fun_v_v=fun;
  1523. switch(T)
  1524. {
  1525. case ele_event: //注册元素事件
  1526. XEle_RegisterEventEx((HELE)hXCGUI,type,CXEventMsg::OnEventAndMsg,pInfo);
  1527. break;
  1528. case ele_msg: //元素消息
  1529. XEle_RegisterMessageEx((HELE)hXCGUI,type,CXEventMsg::OnEventAndMsg,pInfo);
  1530. break;
  1531. case ele_msg_proc: //元素消息处理过程
  1532. XEle_RegisterMsgProcEx((HELE)hXCGUI,CXEventMsg::OnEventAndMsg,pInfo);
  1533. break;
  1534. case ele_event_proc: //元素事件处理过程
  1535. XEle_RegisterEventProcEx((HELE)hXCGUI,CXEventMsg::OnEventAndMsg,pInfo);
  1536. break;
  1537. case wnd_msg: //注册窗口消息
  1538. XWnd_RegisterMessageEx((HWINDOW)hXCGUI,type,CXEventMsg::OnEventAndMsg,pInfo);
  1539. break;
  1540. case wnd_msg_nc: //注册窗口逻辑上非客户区消息
  1541. XWnd_RegisterNCMessageEx((HWINDOW)hXCGUI,type,CXEventMsg::OnEventAndMsg,pInfo);
  1542. break;
  1543. case wnd_msg_proc:
  1544. XWnd_RegisterMsgProcEx((HWINDOW)hXCGUI,CXEventMsg::OnEventAndMsg,pInfo);
  1545. break;
  1546. case ele_scrollView_draw: //滚动视图绘制
  1547. XSView_SetDrawScrollViewEx((HELE)hXCGUI,CXEventMsg::OnEventAndMsg,pInfo);
  1548. break;
  1549. case ele_list_drawItem: //列表项自绘
  1550. XList_SetUserDrawItemEx((HELE)hXCGUI,CXEventMsg::OnEventAndMsg,pInfo);
  1551. break;
  1552. case ele_list_drawItemHeader: //列表头项绘制
  1553. XList_SetUserDrawItemHeaderEx((HELE)hXCGUI,CXEventMsg::OnEventAndMsg,pInfo);
  1554. break;
  1555. case ele_tree_drawItem: //树项自绘
  1556. XTree_SetUserDrawItemEx((HELE)hXCGUI,CXEventMsg::OnEventAndMsg,pInfo);
  1557. break;
  1558. case ele_listBox_drawItem://列表框项自绘
  1559. XListBox_SetUserDrawItemEx((HELE)hXCGUI,CXEventMsg::OnEventAndMsg,pInfo);
  1560. break;
  1561. case ele_listView_drawItem: //列表视图项自绘
  1562. XListView_SetUserDrawItemEx((HELE)hXCGUI,CXEventMsg::OnEventAndMsg,pInfo);
  1563. break;
  1564. case ele_listView_drawGroup: //列表视图组自绘
  1565. XListView_SetUserDrawGroupEx((HELE)hXCGUI,CXEventMsg::OnEventAndMsg,pInfo);
  1566. break;
  1567. case ele_menu_drawItem: //菜单项自绘
  1568. XMenu_SetUserDrawItemEx((HMENUX)hXCGUI,CXEventMsg::OnEventAndMsg,pInfo);
  1569. break;
  1570. case ele_menu_drawBG:
  1571. XMenu_SetUserDrawBGEx((HMENUX)hXCGUI,CXEventMsg::OnEventAndMsg,pInfo);
  1572. break;
  1573. case ele_menu_updateUI:
  1574. XMenu_SetUserUpdateUIEx((HMENUX)hXCGUI,CXEventMsg::OnEventAndMsg,pInfo);
  1575. break;
  1576. };
  1577. }
  1578. static BOOL CALLBACK OnEventAndMsg(eventOrMsg_ *pEvent,xcgui_fun_type funType)//事件回调
  1579. {
  1580. xcgui_info_ *info=(xcgui_info_*)pEvent->pClass_fun;
  1581. BOOL bResult=FALSE;
  1582. switch(funType)
  1583. {
  1584. //////////////////////////////////////////////////
  1585. case xc_fun_b_e_e_i_i:
  1586. bResult=(info->theThis->*info->funs.fun_b_e_e_i_i)(pEvent->hEle,pEvent->hEventEle,pEvent->wParam,pEvent->lParam);
  1587. break;
  1588. case xc_fun_b_e_e_i:
  1589. bResult=(info->theThis->*info->funs.fun_b_e_e_i)(pEvent->hEle,pEvent->hEventEle,pEvent->wParam);
  1590. break;
  1591. case xc_fun_b_e_e:
  1592. bResult=(info->theThis->*info->funs.fun_b_e_e)(pEvent->hEle,pEvent->hEventEle);
  1593. break;
  1594. case xc_fun_b_e_e_pb:
  1595. bResult=(info->theThis->*info->funs.fun_b_e_e_pb)(pEvent->hEle,pEvent->hEventEle,(BOOL*)&pEvent->wParam);
  1596. break;
  1597. case xc_fun_b_e_e_i_pb:
  1598. bResult=(info->theThis->*info->funs.fun_b_e_e_i_pb)(pEvent->hEle,pEvent->hEventEle,pEvent->wParam,(BOOL*)pEvent->lParam);
  1599. break;
  1600. case xc_fun_b_e_e_b:
  1601. bResult=(info->theThis->*info->funs.fun_b_e_e_b)(pEvent->hEle,pEvent->hEventEle,(BOOL)pEvent->wParam);
  1602. break;
  1603. case xc_fun_b_e_e_i_pt:
  1604. bResult=(info->theThis->*info->funs.fun_b_e_e_i_p)(pEvent->hEle,pEvent->hEventEle,pEvent->wParam,(POINT*)pEvent->lParam);
  1605. break;
  1606. case xc_fun_b_e_e_i_b:
  1607. bResult=(info->theThis->*info->funs.fun_b_e_e_i_b)(pEvent->hEle,pEvent->hEventEle,pEvent->wParam,pEvent->lParam?TRUE:FALSE);
  1608. break;
  1609. case xc_fun_b_e_e_b_b:
  1610. bResult=(info->theThis->*info->funs.fun_b_e_e_b_b)(pEvent->hEle,pEvent->hEventEle,pEvent->wParam?TRUE:FALSE,pEvent->lParam?TRUE:FALSE);
  1611. break;
  1612. case xc_fun_b_e_e_w_e:
  1613. bResult=(info->theThis->*info->funs.fun_b_e_e_w_e)(pEvent->hEle,pEvent->hEventEle,(HWINDOW)pEvent->wParam,(HELE)pEvent->lParam);
  1614. break;
  1615. case xc_fun_b_e_e_listView_dragInsert:
  1616. bResult=(info->theThis->*info->funs.fun_b_e_e_listViewDragInsert)(pEvent->hEle,pEvent->hEventEle,(listView_dragInsert_*)pEvent->wParam);
  1617. break;
  1618. /////////////////////////////////////////////////////////
  1619. case xc_fun_v_e:
  1620. (info->theThis->*info->funs.fun_v_e)(pEvent->hEle);
  1621. break;
  1622. case xc_fun_b_e_i_i_i:
  1623. bResult=(info->theThis->*info->funs.fun_b_e_i_i_i)(pEvent->hEle,pEvent->xint,pEvent->wParam,pEvent->lParam);
  1624. break;
  1625. case xc_fun_b_e_i_i:
  1626. bResult=(info->theThis->*info->funs.fun_b_e_i_i)(pEvent->hEle,pEvent->wParam,pEvent->lParam);
  1627. break;
  1628. case xc_fun_b_e_i_pt:
  1629. bResult=(info->theThis->*info->funs.fun_b_e_i_p)(pEvent->hEle,pEvent->wParam,(POINT*)pEvent->lParam);
  1630. break;
  1631. case xc_fun_b_e_pt:
  1632. bResult=(info->theThis->*info->funs.fun_b_e_p)(pEvent->hEle,(POINT*)pEvent->wParam);
  1633. break;
  1634. case xc_fun_b_e_hdraw:
  1635. bResult=(info->theThis->*info->funs.fun_b_e_hdraw)(pEvent->hEle,(HDRAW)pEvent->wParam);
  1636. break;
  1637. case xc_fun_b_w_hdraw:
  1638. bResult=(info->theThis->*info->funs.fun_b_w_hdraw)(pEvent->hWindow,(HDRAW)pEvent->wParam);
  1639. break;
  1640. case xc_fun_b_w:
  1641. bResult=(info->theThis->*info->funs.fun_b_w)(pEvent->hWindow);
  1642. break;
  1643. case xc_fun_b_w_i_pt:
  1644. bResult=(info->theThis->*info->funs.fun_b_w_i_p)(pEvent->hWindow,pEvent->wParam,(POINT*)pEvent->lParam);
  1645. break;
  1646. case xc_fun_b_w_i_size:
  1647. bResult=(info->theThis->*info->funs.fun_b_w_i_size)(pEvent->hWindow,pEvent->wParam,(SIZE*)pEvent->lParam);
  1648. break;
  1649. case xc_fun_b_w_i_i:
  1650. bResult=(info->theThis->*info->funs.fun_b_w_i_i)(pEvent->hWindow,pEvent->wParam,pEvent->lParam);
  1651. break;
  1652. case xc_fun_b_w_pt:
  1653. bResult=(info->theThis->*info->funs.fun_b_w_p)(pEvent->hWindow,(POINT*)pEvent->wParam);
  1654. break;
  1655. case xc_fun_b_w_e:
  1656. bResult=(info->theThis->*info->funs.fun_b_w_e)(pEvent->hWindow,(HELE)pEvent->wParam);
  1657. break;
  1658. case xc_fun_b_w_hwnd:
  1659. bResult=(info->theThis->*info->funs.fun_b_w_hwnd)(pEvent->hWindow,(HWND)pEvent->wParam);
  1660. break;
  1661. case xc_fun_b_w_i:
  1662. bResult=(info->theThis->*info->funs.fun_b_w_i)(pEvent->hWindow,pEvent->wParam);
  1663. break;
  1664. //////////////////////////////////////////////////////
  1665. case xc_fun_v_e_list_item:
  1666. (info->theThis->*info->funs.fun_v_e_list)(pEvent->hEle,(list_drawItem_*)pEvent->wParam);
  1667. break;
  1668. case xc_fun_v_e_list_header:
  1669. (info->theThis->*info->funs.fun_v_e_listHeader)(pEvent->hEle,(listHeader_drawItem_*)pEvent->wParam);
  1670. break;
  1671. case xc_fun_v_e_tree:
  1672. (info->theThis->*info->funs.fun_v_e_tree)(pEvent->hEle,(tree_drewItem_*)pEvent->wParam);
  1673. break;
  1674. case xc_fun_v_e_listBox:
  1675. (info->theThis->*info->funs.fun_v_e_listBox)(pEvent->hEle,(listBox_drawItem_*)pEvent->wParam);
  1676. break;
  1677. case xc_fun_v_e_listView_item:
  1678. (info->theThis->*info->funs.fun_v_e_listView)(pEvent->hEle,(listView_drawItem_*)pEvent->wParam);
  1679. break;
  1680. case xc_fun_v_e_listView_group:
  1681. (info->theThis->*info->funs.fun_v_e_listViewGroup)(pEvent->hEle,(listView_drawGroup_*)pEvent->wParam);
  1682. break;
  1683. case xc_fun_v_x_menu_item:
  1684. (info->theThis->*info->funs.fun_v_x_menu_drawItem)(pEvent->hMenu,(menu_drawItem_*)pEvent->wParam);
  1685. break;
  1686. case xc_fun_v_x_menu_bg:
  1687. (info->theThis->*info->funs.fun_v_x_menu_drawBG)(pEvent->hMenu,(menu_drawBG_*)pEvent->wParam);
  1688. break;
  1689. case xc_fun_v_x_menu_i:
  1690. (info->theThis->*info->funs.fun_v_x_menu_updateUI)(pEvent->hMenu,pEvent->wParam);
  1691. break;
  1692. }
  1693. return bResult;
  1694. }
  1695. };
  1696. #endif //XCGUI_PLUS
  1697. //这里添加导出API函数////////////////////////////////////////////////////////
  1698. XC_API HWINDOW WINAPI XC_LoadXML_Window(wchar_t *pFileName,HXMLRES hXmlRes=NULL,HWND hWndParent=NULL);
  1699. XC_API HWINDOW WINAPI XC_LoadXML_WindowRes(int resID,wchar_t *pType,HXMLRES hXmlRes=NULL,HWND hWndParent=NULL);
  1700. XC_API BOOL WINAPI XC_LoadXML_Page(HXCGUI hParent,wchar_t *pFileName,HXMLRES hXmlRes=NULL);
  1701. XC_API BOOL WINAPI XC_LoadXML_PageRes(HXCGUI hParent,int resID,wchar_t *pType,HXMLRES hXmlRes=NULL);
  1702. XC_API BOOL WINAPI XC_LoadXML_Style(HWINDOW hWindow,wchar_t *pFileName,HXMLRES hXmlRes=NULL);
  1703. XC_API BOOL WINAPI XC_LoadXML_StyleRes(HWINDOW hWindow,int resID,wchar_t *pType,HXMLRES hXmlRes=NULL); //从资源加载
  1704. XC_API HXMLRES WINAPI XXmlRes_Load(wchar_t *pFileName);
  1705. XC_API HXMLRES WINAPI XXmlRes_LoadRes(int resID,wchar_t *pType);//从VC资源文件中加载
  1706. XC_API void WINAPI XXmlRes_Destroy(HXMLRES hXmlRes);
  1707. XC_API int WINAPI XXmlRes_FindId(HXMLRES hXmlRes,wchar_t *pName);
  1708. XC_API void WINAPI XXmlRes_FindImage(HXMLRES hXmlRes,wchar_t *pName,out_ wchar_t *pOut,int outLen);
  1709. XC_API void WINAPI XXmlRes_FindString(HXMLRES hXmlRes,wchar_t *pName,out_ wchar_t *pOut,int outLen);
  1710. XC_API HIMAGE WINAPI XXmlRes_FildHIMAGE(HXMLRES hXmlRes,wchar_t *pName);
  1711. XC_API HARRAY WINAPI XArray_Create(); //创建
  1712. XC_API void WINAPI XArray_Destroy(HARRAY hArray); //销毁
  1713. XC_API int WINAPI XArray_Add(HARRAY hArray,void *pElement);//增加元素到末尾
  1714. XC_API void WINAPI XArray_AddFirst(HARRAY hArray,void *pElement); //增加到开头
  1715. XC_API BOOL WINAPI XArray_insert(HARRAY hArray,void *pElement,int index); //插入到指定位置
  1716. XC_API void WINAPI XArray_DeleteIndex(HARRAY hArray,int index);
  1717. XC_API void WINAPI XArray_Delete(HARRAY hArray,void *pElement);
  1718. XC_API void WINAPI XArray_DeleteEnd(HARRAY hArray,int index); //删除末尾内容
  1719. XC_API void WINAPI XArray_DeleteRange(HARRAY hArray,int begin,int end);
  1720. XC_API void WINAPI XArray_DeleteAll(HARRAY hArray);
  1721. XC_API void WINAPI XArray_SetAt(HARRAY hArray,int index,void *pElement);
  1722. XC_API void* WINAPI XArray_GetAt(HARRAY hArray,int index);
  1723. XC_API int WINAPI XArray_GetCount(HARRAY hArray);
  1724. XC_API HARRAY_ITERATOR WINAPI XArrayIterator_Create(HARRAY hArray,BOOL bType=TRUE); //创建迭代器
  1725. XC_API void* WINAPI XArrayIterator_GetAt(HARRAY_ITERATOR hArray_Iterator);
  1726. XC_API void WINAPI XArrayIterator_Destroy(HARRAY_ITERATOR hArray_Iterator);
  1727. XC_API HELE WINAPI XBtn_Create(int x, int y, int cx, int cy,wchar_t *pTitle=NULL,HXCGUI hParent=NULL); //创建按钮
  1728. XC_API wchar_t * WINAPI XBtn_GetText(HELE hEle); //获取文本
  1729. XC_API void WINAPI XBtn_SetText(HELE hEle,wchar_t *pText);
  1730. XC_API void WINAPI XBtn_SetCheck(HELE hEle,BOOL bCheck);
  1731. XC_API BOOL WINAPI XBtn_IsCheck(HELE hEle); //按钮是否被选中
  1732. XC_API int WINAPI XBtn_GetState(HELE hEle);
  1733. XC_API void WINAPI XBtn_SetImageLeave(HELE hEle,HIMAGE hImage=NULL); //鼠标离开时图片
  1734. XC_API void WINAPI XBtn_SetImageStay(HELE hEle,HIMAGE hImage=NULL); //鼠标停留时图片
  1735. XC_API void WINAPI XBtn_SetImageDown(HELE hEle,HIMAGE hImage=NULL); //鼠标按下时图片
  1736. XC_API void WINAPI XBtn_SetImageCheck(HELE hEle,HIMAGE hImage=NULL); //选中时图片
  1737. XC_API void WINAPI XBtn_SetImageDisable(HELE hEle,HIMAGE hImage=NULL); //按钮禁用状态图片
  1738. XC_API void WINAPI XBtn_SetTextAlign(HELE hEle,int flag); //设置文本对齐
  1739. XC_API void WINAPI XBtn_SetIcon(HELE hEle,HIMAGE hImage); //设置图标
  1740. XC_API void WINAPI XBtn_SetIconAlign(HELE hEle,int align);
  1741. XC_API void WINAPI XBtn_EnableCursorHand(HELE hEle,BOOL bEnable); //鼠标停留,光标变为手型
  1742. XC_API void WINAPI XBtn_EnableAnimation(HELE hEle,BOOL bEnable,BOOL bLoopPlay=FALSE);
  1743. XC_API void WINAPI XBtn_AddAnimationFrame(HELE hEle,HIMAGE hImage,UINT uElapse);
  1744. XC_API void WINAPI XBtn_SetOffset(HELE hEle,int x,int y); //设置内容坐标偏移量
  1745. XC_API HELE WINAPI XCheck_Create(int x, int y, int cx, int cy,wchar_t *pTitle=NULL,HXCGUI hParent=NULL);
  1746. XC_API void WINAPI XCheck_SetImageLeave_UnCheck(HELE hEle,HIMAGE hImage); //鼠标离开时图片 未选择
  1747. XC_API void WINAPI XCheck_SetImageStay_UnCheck(HELE hEle,HIMAGE hImage); //鼠标停留时图片 未选择
  1748. XC_API void WINAPI XCheck_SetImageDown_UnCheck(HELE hEle,HIMAGE hImage); //鼠标按下时图片 未选择
  1749. XC_API void WINAPI XCheck_SetImageDisable_UnCheck(HELE hEle,HIMAGE hImage); //按钮禁用状态图片 未选择
  1750. XC_API void WINAPI XCheck_SetImageLeave_Check(HELE hEle,HIMAGE hImage); //鼠标离开时图片 选择
  1751. XC_API void WINAPI XCheck_SetImageStay_Check(HELE hEle,HIMAGE hImage); //鼠标停留时图片 选择
  1752. XC_API void WINAPI XCheck_SetImageDown_Check(HELE hEle,HIMAGE hImage); //鼠标按下时图片 选择
  1753. XC_API void WINAPI XCheck_SetImageDisable_Check(HELE hEle,HIMAGE hImage); //按钮禁用状态图片 选择
  1754. XC_API HELE WINAPI XCHColor_Create(int x, int y, int cx, int cy,HXCGUI hParent=NULL);
  1755. XC_API COLORREF WINAPI XCHColor_GetColor(HELE hEle); //获取颜色RGB值
  1756. XC_API void WINAPI XCHColor_SetColor(HELE hEle,COLORREF color);//设置颜色
  1757. XC_API HELE WINAPI XComboBox_Create(int x, int y, int cx, int cy,HXCGUI hParent=NULL);
  1758. XC_API BOOL WINAPI XComboBox_AddString(HELE hEle,wchar_t *pText,int data=0); //增加一个字符串到组合框
  1759. XC_API void WINAPI XComboBox_DeleteItem(HELE hEle,int index);//删除项
  1760. XC_API void WINAPI XComboBox_DeleteItemAll(HELE hEle); //删除所有项
  1761. XC_API void WINAPI XComboBox_EnableEdit(HELE hEle,BOOL bEdit); //启动编辑内容
  1762. XC_API void WINAPI XComboBox_SetSelectItem(HELE hEle,int index); //设置选择项
  1763. XC_API void WINAPI XComboBox_SetText(HELE hEle,wchar_t *pText); //设置编辑框内容
  1764. XC_API void WINAPI XComboBox_SetItemHeight(HELE hEle,int height); //设置下拉列表项高
  1765. XC_API void WINAPI XComboBox_SetListHeight(HELE hEle,int height); //设置下拉列表高度
  1766. XC_API void WINAPI XComboBox_SetButtonWidth(HELE hEle,int width); //设置下拉按钮宽度
  1767. XC_API void WINAPI XComboBox_SetItemData(HELE hEle,int index,int data);
  1768. XC_API int WINAPI XComboBox_GetButtonWidth(HELE hEle); //获取下拉按钮宽度
  1769. XC_API void WINAPI XComboBox_GetText(HELE hEle,wchar_t *pOut,int len); //获取编辑框文本
  1770. XC_API int WINAPI XComboBox_GetItemHeight(HELE hEle); //获取项高
  1771. XC_API int WINAPI XComboBox_GetListHeight(HELE hEle); //获取下拉列表高度
  1772. XC_API wchar_t* WINAPI XComboBox_GetItemText(HELE hEle,int index); //获取下拉列表文本
  1773. XC_API int WINAPI XComboBox_GetSelectItem(HELE hEle); //获取当前选择项索引
  1774. XC_API int WINAPI XComboBox_GetItemData(HELE hEle,int index);
  1775. XC_API int WINAPI XComboBox_GetItemCount(HELE hEle); //获取项数量
  1776. XC_API void WINAPI XComboBox_SetImageLeave(HELE hEle,HIMAGE hImage=NULL); //鼠标离开
  1777. XC_API void WINAPI XComboBox_SetImageStay(HELE hEle,HIMAGE hImage=NULL); //鼠标停留
  1778. XC_API void WINAPI XComboBox_SetImageDown(HELE hEle,HIMAGE hImage=NULL); //鼠标按下
  1779. XC_API void WINAPI XDraw_FillSolidRect(HDC hdc,RECT *pRect,COLORREF clr);
  1780. XC_API BOOL WINAPI XDraw_GradientFill2(HDC hdc,COLORREF color1,COLORREF color2,RECT *pRect,int mode);
  1781. XC_API BOOL WINAPI XDraw_GradientFill4(HDC hdc,COLORREF color1,COLORREF color2,COLORREF colo3,COLORREF color4,RECT *pRect,int mode);
  1782. XC_API void WINAPI XDraw_Check(HDC hdc,int x,int y,COLORREF color,BOOL bCheck);
  1783. XC_API void WINAPI XDraw_HImage(HDC hdc,HIMAGE hImage,int x,int y);
  1784. XC_API void WINAPI XDraw_HImageStretch(HDC hdc,HIMAGE hImage,int x,int y,int width,int height);
  1785. XC_API void WINAPI XDraw_HImageSuper(HDC hdc,HIMAGE hImage,RECT *pRect);
  1786. XC_API void WINAPI XDraw_HImageEx(HDC hdc,HIMAGE hImage,int x,int y,int width,int height,int srcX,int srcY);
  1787. XC_API void WINAPI XDraw_HImageExTile(HDC hdc,HIMAGE hImage,RECT *pRect,int flag=0);
  1788. XC_API void WINAPI XDraw_HImageAdaptive(HDC hdc,HIMAGE hImage,RECT *pRect);
  1789. XC_API HDRAW WINAPI XDraw_Create_(HDC hdc); //创建
  1790. XC_API void WINAPI XDraw_Destroy_(HDRAW hDraw); //销毁
  1791. XC_API void WINAPI XDraw_SetOffset_(HDRAW hDraw,int x,int y); //设置坐标偏移量
  1792. XC_API void WINAPI XDraw_RestoreGDIOBJ_(HDRAW hDraw); //还原状态,释放用户绑定的GDI对象
  1793. XC_API HDC WINAPI XDraw_GetHDC_(HDRAW hDraw);
  1794. XC_API void WINAPI XDraw_GetOffset_(HDRAW hDraw,out_ int *pX,out_ int *pY); //获取坐标偏移量
  1795. XC_API COLORREF WINAPI XDraw_SetTextColor_(HDRAW hDraw,COLORREF crColor);
  1796. XC_API HBRUSH WINAPI XDraw_CreateSolidBrush_(HDRAW hDraw,COLORREF crColor);
  1797. XC_API HPEN WINAPI XDraw_CreatePen_(HDRAW hDraw,int fnPenStyle,int nWidth,COLORREF crColor);
  1798. XC_API HRGN WINAPI XDraw_CreateRoundRectRgn_(HDRAW hDraw,int nLeftRect,int nTopRect,int nRightRect,int nBottomRect,int nWidthEllipse,int nHeightEllipse);
  1799. XC_API HRGN WINAPI XDraw_CreatePolygonRgn_(HDRAW hDraw,POINT *pPt,int cPoints,int fnPolyFillMode);
  1800. XC_API HGDIOBJ WINAPI XDraw_SelectObject_(HDRAW hDraw,HGDIOBJ hObj);
  1801. XC_API int WINAPI XDraw_SelectClipRgn_(HDRAW hDraw,HRGN hRgn);
  1802. XC_API BOOL WINAPI XDraw_DeleteObject_(HDRAW hDraw,HGDIOBJ hObj);
  1803. XC_API int WINAPI XDraw_FillRect_(HDRAW hDraw,RECT *pRect,HBRUSH hbr);
  1804. XC_API BOOL WINAPI XDraw_FillRgn_(HDRAW hDraw,HRGN hrgn,HBRUSH hbr);
  1805. XC_API void WINAPI XDraw_FillSolidRect_(HDRAW hDraw,RECT *pRect,COLORREF clr);
  1806. XC_API BOOL WINAPI XDraw_GradientFill2_(HDRAW hDraw,COLORREF color1,COLORREF color2, RECT *pRect,int mode);
  1807. XC_API BOOL WINAPI XDraw_GradientFill4_(HDRAW hDraw,COLORREF color1,COLORREF color2,COLORREF color3,COLORREF color4,RECT *pRect,int mode);
  1808. XC_API BOOL WINAPI XDraw_FrameRgn_(HDRAW hDraw,HRGN hrgn,HBRUSH hbr,int nWidth,int nHeight);
  1809. XC_API int WINAPI XDraw_FrameRect_(HDRAW hDraw,RECT *pRect,HBRUSH hbr);
  1810. XC_API BOOL WINAPI XDraw_FocusRect_(HDRAW hDraw,RECT *pRect);
  1811. XC_API BOOL WINAPI XDraw_Rectangle_(HDRAW hDraw,int nLeftRect,int nTopRect,int nRightRect,int nBottomRect);
  1812. XC_API BOOL WINAPI XDraw_MoveToEx_(HDRAW hDraw,int X,int Y,LPPOINT lpPoint=NULL);
  1813. XC_API BOOL WINAPI XDraw_LineTo_(HDRAW hDraw,int nXEnd,int nYEnd);
  1814. XC_API void WINAPI XDraw_Check_(HDRAW hDraw,int x,int y,COLORREF color,BOOL bCheck);
  1815. XC_API void WINAPI XDraw_Dottedline_(HDRAW hDraw,int x,int y,int length,COLORREF color,BOOL bHorizontal=TRUE); //绘制虚线
  1816. XC_API COLORREF WINAPI XDraw_SetPixel_(HDRAW hDraw,int X,int Y,COLORREF crColor);
  1817. XC_API BOOL WINAPI XDraw_DrawIconEx_(HDRAW hDraw,int xLeft,int yTop,HICON hIcon,int cxWidth,int cyWidth,UINT istepIfAniCur,HBRUSH hbrFlickerFreeDraw, UINT diFlags);
  1818. XC_API BOOL WINAPI XDraw_BitBlt_(HDRAW hDrawDest,int nXDest,int nYDest,int nWidth,int nHeight,HDC hdcSrc,int nXSrc,int nYSrc,DWORD dwRop);
  1819. XC_API BOOL WINAPI XDraw_BitBlt2_(HDRAW hDrawDest,int nXDest,int nYDest,int nWidth,int nHeight,HDRAW hDrawSrc,int nXSrc,int nYSrc,DWORD dwRop);
  1820. XC_API void WINAPI XDraw_TriangularArrow(HDRAW hDraw,HBRUSH hBrush,int align,int x,int y,int width,int height);
  1821. XC_API void WINAPI XDraw_HImage_(HDRAW hDraw,HIMAGE hImage,int x,int y);
  1822. XC_API void WINAPI XDraw_HImage2_(HDRAW hDraw,HIMAGE hImage,int x,int y,int width,int height);
  1823. XC_API void WINAPI XDraw_HImageStretch_(HDRAW hDraw,HIMAGE hImage,int x,int y,int width,int height);
  1824. XC_API void WINAPI XDraw_HImageAdaptive_(HDRAW hDraw,HIMAGE hImage,RECT *pRect);
  1825. XC_API void WINAPI XDraw_HImageExTile_(HDRAW hDraw,HIMAGE hImage,RECT *pRect,int flag=0);
  1826. XC_API void WINAPI XDraw_HImageSuper_(HDRAW hDraw,HIMAGE hImage,RECT *pRect);
  1827. XC_API void WINAPI XDraw_HImageSuper2_(HDRAW hDraw,HIMAGE hImage,RECT *pRcDest,RECT *pSrcRect);
  1828. XC_API int WINAPI XDraw_DrawText_(HDRAW hDraw,wchar_t * lpString,int nCount,RECT* lpRect,UINT uFormat);
  1829. XC_API BOOL WINAPI XDraw_TextOut_(HDRAW hDraw,int nXStart,int nYStart,wchar_t * lpString,int cbString);
  1830. XC_API HELE WINAPI XEdit_Create(int x, int y, int cx, int cy,HXCGUI hParent=NULL);
  1831. XC_API void WINAPI XEdit_EnableMultiLine(HELE hEle,BOOL b); //启用多行输入
  1832. XC_API void WINAPI XEdit_EnablePassBox(HELE hEle,BOOL bPass); //启用密码框
  1833. XC_API void WINAPI XEdit_EnableNumber(HELE hEle,BOOL bNumber); //只能输入数字
  1834. XC_API void WINAPI XEdit_EnablePopupMenu(HELE hEle,BOOL bEnable); //启用鼠标右键菜单
  1835. XC_API void WINAPI XEdit_InsertText(HELE hEle,wchar_t *pText,int row=-1,int column=-1); //插入文本,row=-1末尾行,column=-1末尾列;
  1836. XC_API void WINAPI XEdit_DeleteSelectText(HELE hEle); //删除选择文本,当只读属性时,也可以删除文本
  1837. XC_API void WINAPI XEdit_SetText(HELE hEle,wchar_t *pText); //设置文本
  1838. XC_API void WINAPI XEdit_SetInt(HELE hEle,int value); //设置整形内容
  1839. XC_API void WINAPI XEdit_SetReadOnly(HELE hEle,BOOL bRead); //设置只读文本
  1840. XC_API void WINAPI XEdit_SetTextSpacingLeft(HELE hEle,int spacing); //设置字体左对齐间隔
  1841. XC_API void WINAPI XEdit_SetTextSpacingTop(HELE hEle,int spacing); //设置字体上对齐间隔
  1842. XC_API void WINAPI XEdit_SetPos(HELE hEle,int line,int column); //设置插入符位置
  1843. XC_API void WINAPI XEdit_SetCaretWidth(HELE hEle,int width); //设置编辑框插入符宽度
  1844. XC_API void WINAPI XEdit_SetBackspace(HELE hEle); //退格
  1845. XC_API void WINAPI XEdit_SetSelectTextBkColor(HELE hEle,COLORREF color);//设置选择文本背景颜色
  1846. XC_API void WINAPI XEdit_GetSelectText(HELE hEle,wchar_t *pOut,int len); //获取选择内容
  1847. XC_API int WINAPI XEdit_GetTextLength(HELE hEle); //获取内容长度
  1848. XC_API void WINAPI XEdit_GetText(HELE hEle,wchar_t *pOut,int len); //获取文本
  1849. XC_API int WINAPI XEdit_GetInt(HELE hEle); //获取整形内容
  1850. XC_API int WINAPI XEdit_GetRowCount(HELE hEle); //获取总行数
  1851. XC_API int WINAPI XEdit_GetColumnCount(HELE hEle,int row); //获取指定行字符数,row=-1末尾行;
  1852. XC_API int WINAPI XEdit_GetCurrentRow(HELE hEle); //获取插入符位置当前行
  1853. XC_API int WINAPI XEdit_GetCurrentColumn(HELE hEle); //获取插入符位置当前列
  1854. XC_API BOOL WINAPI XEdit_IsEmpty(HELE hEle); //判断内容是否为空
  1855. XC_API void WINAPI XEdit_DeleteAll(HELE hEle); //清空 删除所有文本
  1856. XC_API void WINAPI XEdit_Menu_Cut(HELE hEle); //剪切 删除选择的文本,并将文本拷贝到剪切板中
  1857. XC_API void WINAPI XEdit_Menu_Copy(HELE hEle); //复制 复制选择的文本到剪切板中
  1858. XC_API void WINAPI XEdit_Menu_Paste(HELE hEle); //粘贴 将剪切板中的文本插入当前光标位置
  1859. XC_API void WINAPI XEdit_Menu_Clear(HELE hEle); //删除 删除选择的文本,当只读属性时无法删除文本
  1860. XC_API void WINAPI XEdit_Menu_SelectAll(HELE hEle); //全选 选择所有文本
  1861. XC_API void WINAPI XEdit_Menu_DeleteAll(HELE hEle); //清空 删除所有文本
  1862. XC_API void WINAPI XEdit_SetImageLeave(HELE hEle,HIMAGE hImage=NULL); //鼠标离开
  1863. XC_API void WINAPI XEdit_SetImageStay(HELE hEle,HIMAGE hImage=NULL); //鼠标停留
  1864. XC_API HELE WINAPI XEditFile_Create(int x, int y, int cx, int cy,HXCGUI hParent=NULL);
  1865. XC_API void WINAPI XEditFile_SetOpenFileType(HELE hEle,wchar_t *pType); //设置打开文件类型
  1866. XC_API void WINAPI XEditFile_SetDefaultFile(HELE hEle,wchar_t *pFile); //设置默认目录文件
  1867. XC_API void WINAPI XEditFile_SetRelativeDir(HELE hEle,wchar_t *pDir); //TODO:设置相对路径
  1868. XC_API void WINAPI XEle_RegisterEventEx(HELE hEle,int type,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info);
  1869. XC_API void WINAPI XEle_RegisterMessageEx(HELE hEle,int message,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //注册消息
  1870. XC_API void WINAPI XEle_RegisterMsgProcEx(HELE hEle,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //注册元素消息处理过程
  1871. XC_API void WINAPI XEle_RegisterEventProcEx(HELE hEle,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //注册事件拦截过滤函数
  1872. XC_API HELE WINAPI XEle_Create(int x, int y, int cx, int cy,HXCGUI hParent=NULL); //创建
  1873. XC_API BOOL WINAPI XEle_Destroy(HELE hEle); //销毁
  1874. XC_API void WINAPI XEle_RegisterMessage(HELE hEle,int message,void *pFun);
  1875. XC_API void WINAPI XEle_RegisterEvent(HELE hEle,int type,void *pFun);
  1876. XC_API void WINAPI XEle_RegisterMsgProc(HELE hEle,pFunEleMsgProc pFun); //注册元素消息处理过程
  1877. XC_API void WINAPI XEle_RegisterEventProc(HELE hEle,pFunEleEventProc pFun); //注册元素事件处理过程
  1878. XC_API void WINAPI XEle_SetBkTransparent(HELE hEle,BOOL bTran); //设置元素背景透明
  1879. XC_API void WINAPI XEle_SetFocus(HELE hEle,BOOL bFocus); //设置焦点
  1880. XC_API void WINAPI XEle_SetId(HELE hEle,int id);
  1881. XC_API void WINAPI XEle_SetFont(HELE hEle,HFONTX hFontX);
  1882. XC_API HFONTX WINAPI XEle_GetFont(HELE hEle); //获取字体
  1883. XC_API BOOL WINAPI XEle_SetZOrder(HELE hEle,HELE hDestEle=NULL,int flag=XC_ZORDER_TOP,int index=NULL);
  1884. XC_API void WINAPI XEle_SetBkColor(HELE hEle,COLORREF color); //设置背景颜色
  1885. XC_API COLORREF WINAPI XEle_GetBkColor(HELE hEle); //获取背景颜色
  1886. XC_API void WINAPI XEle_SetBorderColor(HELE hEle,COLORREF color); //设置边框颜色
  1887. XC_API void WINAPI XEle_SetToolTips(HELE hEle,wchar_t *pText); //设置工具提示内容
  1888. XC_API void WINAPI XEle_SetCapture(HELE hEle); //设置元素鼠标捕获
  1889. XC_API wchar_t* WINAPI XEle_GetTooltips(HELE hEle); //获取工具提示内容
  1890. XC_API HELE WINAPI XEle_GetParentEle(HELE hEle); //获取父元素句柄
  1891. XC_API int WINAPI XEle_GetChildCout(HELE hEle); //获取子元素数量
  1892. XC_API HELE WINAPI XEle_GetChildByIndex(HELE hEle,int index); //获取指定子元素
  1893. XC_API HWND WINAPI XEle_GetHWnd(HELE hEle); //获取窗口句柄
  1894. XC_API HWINDOW WINAPI XEle_GetHWindow(HELE hEle); //获取窗口资源句柄
  1895. XC_API int WINAPI XEle_GetUserData(HELE hEle); //获取用户数据
  1896. XC_API int WINAPI XEle_GetId(HELE hEle);
  1897. XC_API void WINAPI XEle_ReleaseCapture(HELE hEle); //释放元素鼠标捕获
  1898. XC_API void WINAPI XEle_EnableEle(HELE hEle,BOOL bEnable); //元素是否有效
  1899. XC_API void WINAPI XEle_EnableFocus(HELE hEle,BOOL bFocus); //开启焦点
  1900. XC_API void WINAPI XEle_EnableDrawFocus(HELE hEle,BOOL bFocus); //是否绘制焦点
  1901. XC_API void WINAPI XEle_EnableToolTips(HELE hEle,BOOL bTips); //启用工具提示
  1902. XC_API void WINAPI XEle_EnableBorder(HELE hEle,BOOL bEnable); //绘制边框
  1903. XC_API void WINAPI XEle_EnableTransparentChannel(HELE hEle,BOOL bEnable);
  1904. XC_API BOOL WINAPI XEle_AddEle(HELE hEle,HELE hNewEle,int flag=XC_ADDELE_END,HELE hDestEle=0,int index=0); //添加元素
  1905. XC_API void WINAPI XEle_RemoveEle(HELE hEle); //移除元素,但不销毁
  1906. XC_API void WINAPI XEle_RedrawEle(HELE hEle,BOOL bImmediately=FALSE); //重绘元素
  1907. XC_API void WINAPI XEle_RedrawRect(HELE hEle,RECT *pRect); //元素重绘指定区域
  1908. XC_API void WINAPI XEle_ShowEle(HELE hEle,BOOL bShow);
  1909. XC_API BOOL WINAPI XEle_IsBkTransparent(HELE hEle); //元素背景是否透明
  1910. XC_API BOOL WINAPI XEle_IsFocus(HELE hEle); //元素是否拥有焦点
  1911. XC_API BOOL WINAPI XEle_IsShowEle(HELE hEle); //元素是否显示
  1912. XC_API BOOL WINAPI XEle_IsHitChildEle(HELE hEle,POINT *pPt); //判断是否点击在子元素上
  1913. XC_API BOOL WINAPI XEle_IsChildEle(HELE hEle,HELE hChild); //判断指定元素是否为子元素
  1914. XC_API void WINAPI XEle_SetUserData(HELE hEle,int data); //设置用户数据
  1915. XC_API UINT WINAPI XEle_SetTimerEx(HELE hEle,UINT nIDEvent,UINT uElapse,int userData=0);
  1916. XC_API BOOL WINAPI XEle_KillTimerEx(HELE hEle,UINT nIDEvent);
  1917. XC_API void WINAPI XEle_SetRect(HELE hEle,in_ RECT *pRect,BOOL bRedraw=FALSE);
  1918. XC_API void WINAPI XEle_GetClientRect(HELE hEle,out_ RECT *pRect); //元素客户区坐标 xy(0,0) ,如果元素有边框,包含边框区域
  1919. XC_API void WINAPI XEle_GetRect(HELE hEle,out_ RECT *pRect); //基于父元素坐标
  1920. XC_API void WINAPI XEle_GetWndClientRect(HELE hEle,out_ RECT *pRect); //元素基于窗口客户区坐标(不包含非客户区)
  1921. XC_API void WINAPI XEle_GetNCWndRect(HELE hEle,out_ RECT *pRect); //基于窗口非客户区坐标(包含非客户区)
  1922. XC_API void WINAPI XEle_PointToParent(HELE hEle,in_out_ POINT *pPt);
  1923. XC_API void WINAPI XEle_PointToWndClient(HELE hEle,in_out_ POINT *pPt); //元素坐标点转换到窗口客户区坐标点(不包含非客户区)
  1924. XC_API void WINAPI XEle_PointToNCWnd(HELE hEle,in_out_ POINT *pPt);
  1925. XC_API void WINAPI XEle_PointNCWndToEle(HELE hEle,in_out_ POINT *pPt);
  1926. XC_API void WINAPI XEle_PointWndClientToEle(HELE hEle,in_out_ POINT *pPt);
  1927. XC_API void WINAPI XEle_RectToWndClient(HELE hEle,in_out_ RECT *pRect);
  1928. XC_API void WINAPI XEle_RectToNCWnd(HELE hEle,in_out_ RECT *pRect);
  1929. XC_API void WINAPI XEle_SetTextColor(HELE hEle,COLORREF color); //设置文本颜色
  1930. XC_API COLORREF WINAPI XEle_GetTextColor(HELE hEle); //获取文本颜色
  1931. XC_API void WINAPI XEle_EnableMouseThrough(HELE hEle,BOOL bEnable); //启用鼠标穿透元素
  1932. XC_API void WINAPI XEle_SetAlpha(HELE hEle,int alpha); //设置元素透明度 0-255
  1933. XC_API HXCGUI WINAPI XFlash_Create(HWINDOW hWindow);
  1934. XC_API void WINAPI XFlash_OpenFlashFile(HXCGUI hFlash,wchar_t *pFlashFile);
  1935. XC_API void* WINAPI XFlash_GetControl(HXCGUI hFlash);//获取控件接口
  1936. XC_API void WINAPI XFlash_Destroy(HXCGUI hFlash);
  1937. XC_API HFONTX WINAPI XFont_Create(int size);//创建字体
  1938. XC_API HFONTX WINAPI XFont_Create2(wchar_t *pName=L"宋体",int size=12,BOOL bBold=FALSE,BOOL bItalic=FALSE,BOOL bUnderline=FALSE,BOOL bStrikeOut=FALSE);
  1939. XC_API HFONTX WINAPI XFont_CreateEx(LOGFONTW *pFontInfo);
  1940. XC_API void WINAPI XFont_Destroy(HFONTX hFontX); //销毁字体
  1941. XC_API HFONT WINAPI XFont_GetHFONT(HFONTX hFontX);
  1942. XC_API HWINDOW WINAPI XFrameWnd_CreateWindow(int x,int y,int cx,int cy,wchar_t *pTitle,HWND hWndParent=NULL,int XCStyle=XC_SY_DEFAULT);
  1943. XC_API BOOL WINAPI XFrameWnd_AddPane(HWINDOW hWindow,HELE hPaneDest,HELE hPaneNew,align_type_ align=align_any,int scale=50);
  1944. XC_API HPANE_GROUP WINAPI XFrameWnd_MergePane(HWINDOW hWindow,HELE hPaneDest,HELE hPaneNew,int proportion=50);
  1945. XC_API BOOL WINAPI XFrameWnd_MergePaneToGroup(HWINDOW hWindow,HPANE_GROUP hGroup,HELE hPaneNew,int proportion=50); //窗格合并到组
  1946. XC_API void WINAPI XFrameWnd_AdjustLayout(HWINDOW hWindow,BOOL bFixedSize=FALSE);
  1947. XC_API void WINAPI XFrameWnd_GetLayoutAreaRect(HWINDOW hWindow,out_ RECT *pRect); //获取客户区布局区域坐标
  1948. XC_API HELE WINAPI XFrameWnd_GetActivatePane(HWINDOW hWindow);//获取框架窗口内激活的窗格,不包含浮动窗格
  1949. XC_API HELE WINAPI XGif_Create(int x, int y, int cx, int cy,HXCGUI hParent=NULL);
  1950. XC_API void WINAPI XGif_SetImage(HELE hEle,wchar_t *pImageName);
  1951. XC_API void WINAPI XGif_SetImageRes(HELE hEle,int id,wchar_t *pType);
  1952. XC_API void WINAPI XGif_SetImageZip(HELE hEle,wchar_t *pZipFileName,wchar_t *pImageName,wchar_t *pPassword=NULL);
  1953. XC_API HELE WINAPI XGBox_Create(int x, int y, int cx, int cy,wchar_t *pTitle,HXCGUI hParent=NULL); //创建
  1954. XC_API wchar_t* WINAPI XGBox_GetText(HELE hEle);
  1955. XC_API void WINAPI XGBox_SetText(HELE hEle,wchar_t *pText);
  1956. XC_API HIMAGE WINAPI XImage_LoadFile(wchar_t *pImageName,BOOL bStretch=FALSE);//从文件中加载图片
  1957. XC_API HIMAGE WINAPI XImage_LoadRes(int id,wchar_t *pType,BOOL bStretch=FALSE);//从资源中加载图片
  1958. XC_API HIMAGE WINAPI XImage_LoadZip(wchar_t *pZipFileName,wchar_t *pImageName,wchar_t *pPassword=NULL,BOOL bStretch=FALSE);//从ZIP中加载图片
  1959. XC_API HIMAGE WINAPI XImage_LoadFileAdaptive(wchar_t *pImageName,int x1,int x2,int y1,int y2);//从文件中加载图片
  1960. XC_API HIMAGE WINAPI XImage_LoadResAdaptive(int id,wchar_t *pType,int x1,int x2,int y1,int y2);//从资源中加载图片
  1961. XC_API HIMAGE WINAPI XImage_LoadZipAdaptive(wchar_t *pZipFileName,wchar_t *pImageName,wchar_t *pPassword,int x1,int x2,int y1,int y2);//从ZIP中加载图片
  1962. XC_API HIMAGE WINAPI XImage_LoadFileRect(wchar_t *pImageName,int x,int y,int cx,int cy);
  1963. XC_API HIMAGE WINAPI XImage_LoadFileFromExtractIcon(wchar_t *pImageName);
  1964. XC_API HIMAGE WINAPI XImage_LoadFileFromHICON(HICON hIcon);
  1965. XC_API HIMAGE WINAPI XImage_LoadFileFromHBITMAP(HBITMAP hBitmap);
  1966. XC_API BOOL WINAPI XImage_IsStretch(HIMAGE hImage); //是否拉伸图片
  1967. XC_API BOOL WINAPI XImage_IsAdaptive(HIMAGE hImage); //是否为自适应图片
  1968. XC_API BOOL WINAPI XImage_IsTile(HIMAGE hImage); //是否为平铺图片
  1969. XC_API BOOL WINAPI XImage_SetDrawType(HIMAGE hImage,int type);//设置图片绘制类型
  1970. XC_API BOOL WINAPI XImage_SetDrawTypeAdaptive(HIMAGE hImage,int x1,int x2,int y1,int y2);//设置图片自适应
  1971. XC_API void WINAPI XImage_SetTranColor(HIMAGE hImage,COLORREF color); //设置透明色
  1972. XC_API void WINAPI XImage_SetTranColorEx(HIMAGE hImage,COLORREF color,byte tranColor); //设置透明色
  1973. XC_API void WINAPI XImage_EnableTranColor(HIMAGE hImage,BOOL bEnable); //启用透明色
  1974. XC_API void WINAPI XImage_EnableAutoDestroy(HIMAGE hImage,BOOL bEnable); //启用或关闭自动销毁,当与UI元素关联时有效
  1975. XC_API int WINAPI XImage_GetDrawType(HIMAGE hImage);
  1976. XC_API int WINAPI XImage_GetWidth(HIMAGE hImage);
  1977. XC_API int WINAPI XImage_GetHeight(HIMAGE hImage);
  1978. XC_API void WINAPI XImage_Destroy(HIMAGE hImage);
  1979. XC_API HXCGUI WINAPI XImageList_Create(int cx,int cy);
  1980. XC_API void WINAPI XImageList_Destroy(HXCGUI hImageList); //销毁
  1981. XC_API void WINAPI XImageList_AddImage(HXCGUI hImageList,HIMAGE hImage); //添加图片
  1982. XC_API int WINAPI XImageList_GetWidth(HXCGUI hImageList); //获取图片宽度
  1983. XC_API int WINAPI XImageList_GetHeight(HXCGUI hImageList); //获取图片高度
  1984. XC_API int WINAPI XImageList_GetCount(HXCGUI hImageList); //获取图片数量
  1985. XC_API HIMAGE WINAPI XImageList_GetImage(HXCGUI hImageList,int index); //获取图片
  1986. XC_API void WINAPI XImageList_DeleteIndex(HXCGUI hImageList,int index); //删除指定图片
  1987. XC_API void WINAPI XImageList_DeleteAll(HXCGUI hImageList); //删除全部图片
  1988. XC_API void WINAPI XImageList_DrawImage(HXCGUI hImageList,HDRAW hDraw,int index, int x, int y);
  1989. XC_API void WINAPI XImageList_DrawImage2(HXCGUI hImageList,HDRAW hDraw,int index, RECT *pRect);
  1990. XC_API void WINAPI XImageList_EnableFixedSize(HXCGUI hImageList,BOOL bEnable); //绘制固定大小 Fixed-size
  1991. XC_API BOOL WINAPI XImageList_IsFixedSize(HXCGUI hImageList);
  1992. XC_API void WINAPI XList_SetUserDrawItemEx(HELE hEle,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //设置用户自绘列表项
  1993. XC_API void WINAPI XList_SetUserDrawItemHeaderEx(HELE hEle,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //设置用户自绘列表头项
  1994. XC_API HELE WINAPI XList_Create(int x,int y,int cx,int cy,HXCGUI hParent=NULL);
  1995. XC_API int WINAPI XList_AddColumn(HELE hEle,int width,wchar_t *pText,int imageId=-1); //增加列
  1996. XC_API int WINAPI XList_AddItem(HELE hEle,wchar_t *pText, int imageId=-1); //增加项
  1997. XC_API BOOL WINAPI XList_InsertColumn(HELE hEle,int index,int width,wchar_t *pText,int imageId=-1); //插入列
  1998. XC_API BOOL WINAPI XList_InsertItem(HELE hEle,int index,wchar_t *pText,int imageId=-1); //插入项
  1999. XC_API BOOL WINAPI XList_SetItemText(HELE hEle,int item,int subItem,wchar_t *pText,int imageId=-1); //设置子项
  2000. XC_API BOOL WINAPI XList_SetColumnWidth(HELE hEle,int index, int width); //设置列宽
  2001. XC_API BOOL WINAPI XList_SetItemImage(HELE hEle,int item,int subItem,int imageId); //设置子项图片
  2002. XC_API void WINAPI XList_SetImageList(HELE hEle,HXCGUI hImageList); //设置图片列表
  2003. XC_API void WINAPI XList_SetItemHeight(HELE hEle,int height); //设置项高度
  2004. XC_API void WINAPI XList_SetHeaderHeight(HELE hEle,int height); //设置列表头高度
  2005. XC_API BOOL WINAPI XList_SetSelectItem(HELE hEle,int index); //设置选择项
  2006. XC_API void WINAPI XList_SetSelectItemAll(HELE hEle); //全选
  2007. XC_API void WINAPI XList_SetSpacingLeft(HELE hEle,int spacing); //设置内容左间距
  2008. XC_API void WINAPI XList_SetSpacingRight(HELE hEle,int spacing); //设置内容右间距
  2009. XC_API void WINAPI XList_SetItemData(HELE hEle,int index,int data); //设置用户数据
  2010. XC_API BOOL WINAPI XList_SetItemBindEle(HELE hEle,int item,int subItem,itemBindEle_ *pInfo); //绑定元素
  2011. XC_API void WINAPI XList_SetColumnMinWidth(HELE hEle,int index,int minWidth); //设置列最小宽度
  2012. XC_API int WINAPI XList_GetHeaderHeight(HELE hEle); //获取列表头高度
  2013. XC_API wchar_t* WINAPI XList_GetHeaderItemText(HELE hEle,int index); //获取列表头项文本
  2014. XC_API int WINAPI XList_GetColumnWidth(HELE hEle,int index); //获取列宽
  2015. XC_API int WINAPI XList_GetSpacingLeft(HELE hEle); //获取内容左间距
  2016. XC_API int WINAPI XList_GetSpacingRight(HELE hEle); //获取内容右间距
  2017. XC_API HXCGUI WINAPI XList_GetImageList(HELE hEle); //获取图片列表
  2018. XC_API wchar_t* WINAPI XList_GetItemText(HELE hEle,int index, int subItem); //获取项文本
  2019. XC_API int WINAPI XList_GetItemImage(HELE hEle,int item,int subItem); //获取子项图片
  2020. XC_API int WINAPI XList_GetItemHeight(HELE hEle); //获取项高
  2021. XC_API int WINAPI XList_GetItemData(HELE hEle,int index); //设置用户数据
  2022. XC_API int WINAPI XList_GetSelectCount(HELE hEle); //获取选择项数量
  2023. XC_API int WINAPI XList_GetSelectItem(HELE hEle); //获取选择项
  2024. XC_API int WINAPI XList_GetSelectAllItem(HELE hEle,out_ int *pArray, int arrayLength); //获取所有选择项
  2025. XC_API int WINAPI XList_GetItemCount(HELE hEle); //获取项数量
  2026. XC_API BOOL WINAPI XList_GetHeaderItemRect(HELE hEle,int item,out_ RECT *pRect); //获取列表头项坐标
  2027. XC_API BOOL WINAPI XList_GetSubItemRect(HELE hEle,int item,int sub,out_ RECT *pRect);//获取子项坐标
  2028. XC_API BOOL WINAPI XList_GetItemCheckRect(HELE hEle,int item,out_ RECT *pRect); //获取复选按钮坐标
  2029. XC_API int WINAPI XList_GetItemBindEleCount(HELE hEle,int item,int subItem);
  2030. XC_API BOOL WINAPI XList_GetItemBindEleInfo(HELE hEle,int item,int subItem,out_ itemBindEle_ *pInfo,int index);//获取绑定项信息
  2031. XC_API void WINAPI XList_CancelSelectAll(HELE hEle); //取消选择所有项
  2032. XC_API void WINAPI XList_CancelSelect(HELE hEle,int index); //取消选择指定项
  2033. XC_API BOOL WINAPI XList_DeleteItem(HELE hEle,int index); //删除项
  2034. XC_API BOOL WINAPI XList_DeleteColumn(HELE hEle,int index); //删除列
  2035. XC_API void WINAPI XList_DeleteAllItems(HELE hEle); //删除所有项
  2036. XC_API void WINAPI XList_DeleteAllColumns(HELE hEle); //删除所有列
  2037. XC_API void WINAPI XList_EnableGrid(HELE hEle,BOOL bGrid); //启用网格样式
  2038. XC_API int WINAPI XList_HitTest(HELE hEle,POINT *pPt); //测试鼠标点在哪个项上,-1没有在任何项上
  2039. XC_API BOOL WINAPI XList_HitTestEx(HELE hEle,POINT *pPt,out_ int *item,out_ int *sub); //测试鼠标点在哪个项上及子项,-1没有在任何项上
  2040. XC_API void WINAPI XList_ShowHeader(HELE hEle,BOOL bShow);//显示隐藏列表头
  2041. XC_API void WINAPI XList_SetUserDrawItem(HELE hEle,pFunList_DrawItem pFunDrawItem); //设置用户自绘列表项
  2042. XC_API void WINAPI XList_SetUserDrawItemHeader(HELE hEle,pFunListHeader_DrawItem pFunDrawItem); //设置用户自绘列表头项
  2043. XC_API void WINAPI XList_EnableCheckBox(HELE hEle,BOOL bEnable); //启用复选框
  2044. XC_API void WINAPI XList_EnableMultilineSelect(HELE hEle,BOOL bEnable); //启用关闭多行选择 XEdit_EnableMultiLine
  2045. XC_API void WINAPI XLsit_EnableLineHighlight(HELE hEle,BOOL bEnable); //启用或关闭行高亮显示
  2046. XC_API BOOL WINAPI XList_IsItemCheck(HELE hEle,int index); //判断项的复选框是否勾选
  2047. XC_API void WINAPI XList_SetItemCheck(HELE hEle,int index, BOOL bCheck); //设置项的复选框
  2048. XC_API void WINAPI XListBox_SetUserDrawItemEx(HELE hEle,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //设置用户自绘列表框项
  2049. XC_API HELE WINAPI XListBox_Create(int x, int y, int cx, int cy,HXCGUI hParent=NULL);
  2050. XC_API int WINAPI XListBox_AddString(HELE hEle,wchar_t *pText,int imageId=-1); //增加一个字符串到列表
  2051. XC_API BOOL WINAPI XListBox_InsertString(HELE hEle,int index,wchar_t *pText,int imageId=-1); //插入项
  2052. XC_API void WINAPI XListBox_EnableCheckBox(HELE hEle,BOOL bEnable); //启用复选框
  2053. XC_API void WINAPI XLsitBox_EnableLineHighlight(HELE hEle,BOOL bEnable); //启用或关闭行高亮显示
  2054. XC_API wchar_t* WINAPI XListBox_GetItemText(HELE hEle,int index); //获取指定行文本
  2055. XC_API int WINAPI XListBox_GetItemHeight(HELE hEle); //获取行高
  2056. XC_API int WINAPI XListBox_GetSelectItem(HELE hEle); //获取选择行
  2057. XC_API int WINAPI XListBox_GetItemImage(HELE hEle,int index); //获取项图标ID
  2058. XC_API int WINAPI XListBox_GetItemCount(HELE hEle); //获取项数量
  2059. XC_API HXCGUI WINAPI XListBox_GetImageList(HELE hEle); //获取图片列表
  2060. XC_API BOOL WINAPI XListBox_GetItemRect(HELE hEle,in_ int index,out_ RECT *pRect); //获取项坐标...
  2061. XC_API int WINAPI XListBox_HitTest(HELE hEle,POINT *pPt); //测试鼠标点在哪个项上,-1没有在任何项上
  2062. XC_API int WINAPI XListBox_GetItemData(HELE hEle,int index); //获取项绑定数据
  2063. XC_API void WINAPI XListBox_SetItemText(HELE hEle,int index, wchar_t *pText); //设置指定行文本
  2064. XC_API void WINAPI XListBox_SetSelectItem(HELE hEle,int index); //设置选择行
  2065. XC_API void WINAPI XListBox_SetItemHeight(HELE hEle,int height); //设置行高
  2066. XC_API void WINAPI XListBox_SetImageList(HELE hEle,HXCGUI hImageList); //设置图标列表
  2067. XC_API void WINAPI XListBox_SetItemImage(HELE hEle,int index,int imageId); //设置项图标ID
  2068. XC_API void WINAPI XListBox_SetItemCheck(HELE hEle,int index, BOOL bCheck); //设置项的复选框
  2069. XC_API BOOL WINAPI XListBox_SetItemBindEle(HELE hEle,int index,itemBindEle_ *pInfo); //绑定元素
  2070. XC_API void WINAPI XListBox_SetItemData(HELE hEle,int index,int data); //设置项绑定数据
  2071. XC_API void WINAPI XListBox_SetSelectItemColor(HELE hEle,COLORREF color); //设置选择项颜色
  2072. XC_API void WINAPI XListBox_SetItemMouseStayColor(HELE hEle,COLORREF color);//设置鼠标停留高亮项颜色
  2073. XC_API void WINAPI XListBox_DeleteItem(HELE hEle,int index); //删除行
  2074. XC_API void WINAPI XListBox_DeleteAll(HELE hEle); //删除所有行
  2075. XC_API BOOL WINAPI XListBox_IsItemCheck(HELE hEle,int index); //判断项的复选框是否勾选
  2076. XC_API void WINAPI XListBox_Adjust(HELE hEle);
  2077. XC_API void WINAPI XListBox_SetUserDrawItem(HELE hEle,pFunListBox_DrawItem pFunDrawItem); //设置用户自绘列表框项
  2078. XC_API void WINAPI XListView_SetUserDrawItemEx(HELE hEle,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //设置用户自绘项
  2079. XC_API void WINAPI XListView_SetUserDrawGroupEx(HELE hEle,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //设置用户自绘组
  2080. XC_API HELE WINAPI XListView_Create(int x, int y, int cx, int cy,HXCGUI hParent=NULL);
  2081. XC_API int WINAPI XListView_AddItem(HELE hEle,wchar_t *pName,int imageID=-1,int groupIndex=-1); //增加项
  2082. XC_API int WINAPI XListView_AddGroup(HELE hEle,wchar_t *pName,BOOL bExpand=TRUE); //增加组
  2083. XC_API int WINAPI XListView_InsertItem(HELE hEle,int groupIndex,int itemIndex,wchar_t *pName,int imageID=-1); //插入项
  2084. XC_API int WINAPI XListView_InsertGroup(HELE hEle,int groupIndex,wchar_t *pName,BOOL bExpand=TRUE); //插入组
  2085. XC_API void WINAPI XListView_SetImageList(HELE hEle,HXCGUI hImageList);
  2086. XC_API BOOL WINAPI XListView_SetItemData(HELE hEle,int groupIndex, int itemIndex,int data); //设置项绑定数据
  2087. XC_API BOOL WINAPI XListView_SetGroupData(HELE hEle,int groupIndex,int data); //设置组绑定数据
  2088. XC_API BOOL WINAPI XListView_SetSelectItem(HELE hEle,int goupIndex,int itemIndex,BOOL bSelect);//设置选择项
  2089. XC_API BOOL WINAPI XListView_SetItemText(HELE hEle,int groupIndex,int itemIndex,wchar_t *pText);//设置项文本
  2090. XC_API BOOL WINAPI XListView_SetGroupText(HELE hEle,int groupIndex,wchar_t *pText);//设置组文本
  2091. XC_API BOOL WINAPI XListView_SetItemIcon(HELE hEle,int groupIndex,int itemIndex,int imageID);//设置项图标ID
  2092. XC_API void WINAPI XListView_SetIconSize(HELE hEle,int cx,int cy); //设置图标区域大小,并不是图标的大小.
  2093. XC_API void WINAPI XListView_SetItemBorderSpacing(HELE hEle,int left,int top,int right,int bottom); //设置项边间隔
  2094. XC_API void WINAPI XListView_SetColumnSpacing(HELE hEle,int width); //设置项列间隔
  2095. XC_API void WINAPI XListView_SetRowSpacing(HELE hEle,int height); //设置项行间隔
  2096. XC_API void WINAPI XListView_SetItemIconTextSpacing(HELE hEle,int height); //设置图标与文本间隔
  2097. XC_API void WINAPI XListView_SetViewLeftAlign(HELE hEle,int size); //设置视图左对齐
  2098. XC_API void WINAPI XListView_SetViewTopAlign(HELE hEle,int size); //设置视图上对齐
  2099. XC_API void WINAPI XListView_SetGroupHeight(HELE hEle,int height); //设置组高度
  2100. XC_API void WINAPI XListView_GetIconSize(HELE hEle,out_ SIZE *pSize); //获取图标区域大小,并不是图标的大小.
  2101. XC_API int WINAPI XListView_GetItemBorderLeft(HELE hEle); //获取项边间隔
  2102. XC_API int WINAPI XListView_GetItemBorderTop(HELE hEle);
  2103. XC_API int WINAPI XListView_GetItemBorderRight(HELE hEle);
  2104. XC_API int WINAPI XListView_GetItemBorderBottom(HELE hEle);
  2105. XC_API int WINAPI XListView_GetColumnSpacing(HELE hEle); //获取项列间隔
  2106. XC_API int WINAPI XListView_GetRowSpacing(HELE hEle); //获取项行间隔
  2107. XC_API int WINAPI XListView_GetItemIconTextSpacing(HELE hEle); //获取图标与文本间隔
  2108. XC_API int WINAPI XListView_GetViewLeftAlign(HELE hEle); //获取视图左对齐
  2109. XC_API int WINAPI XListView_GetViewTopAlign(HELE hEle); //获取视图上对齐
  2110. XC_API int WINAPI XListView_GetGroupHeight(HELE hEle); //获取组高度
  2111. XC_API void WINAPI XListView_GetSelectItem(HELE hEle,out_ int *pGroupIndex,out_ int *pItemIndex); //获取选择项
  2112. XC_API int WINAPI XListView_GetSelectCount(HELE hEle); //获取选择项数量
  2113. XC_API int WINAPI XListView_GetSelectAllItem(HELE hEle,int *pArrayGroupIndex,int *pArrayItemIndex,int arrayLength); //获取所有选择项
  2114. XC_API int WINAPI XListView_GetGroupCount(HELE hEle); //获取组数量
  2115. XC_API int WINAPI XListView_GetGroupMemberCount(HELE hEle,int groupIndex); //获取组成员数量
  2116. XC_API int WINAPI XListView_GetUngroupMemberCount(HELE hEle);//获取未分组项数量
  2117. XC_API HXCGUI WINAPI XListView_GetImageList(HELE hEle); //获取图片列表
  2118. XC_API BOOL WINAPI XListView_GetItemRect(HELE hEle,int groupIndex,int itemIndex,out_ RECT *pRect); //获取项坐标
  2119. XC_API BOOL WINAPI XListView_GetItemIconRect(HELE hEle,int groupIndex,int itemIndex,out_ RECT *pRect);//获取项图标坐标
  2120. XC_API BOOL WINAPI XListView_GetItemTextRect(HELE hEle,int groupIndex,int itemIndex,out_ RECT *pRect); //获取项文本坐标
  2121. XC_API wchar_t* WINAPI XListView_GetItemText(HELE hEle,int groupIndex,int itemIndex);//获取项文本
  2122. XC_API int WINAPI XListView_GetItemIcon(HELE hEle,int groupIndex,int itemIndex);//获取项图标ID
  2123. XC_API wchar_t* WINAPI XListView_GetGroupText(HELE hEle,int groupIndex);//获取组文本
  2124. XC_API BOOL WINAPI XListView_GetGroupRect(HELE hEle,int groupIndex,out_ RECT *pRect);//获取组坐标
  2125. XC_API int WINAPI XListView_GetItemData(HELE hEle,int groupIndex,int itemIndex); //获取项绑定数据
  2126. XC_API int WINAPI XListView_GetGroupData(HELE hEle,int groupIndex); //获取组绑定数据
  2127. XC_API BOOL WINAPI XListView_DeleteItem(HELE hEle,int groupIndex,int itemIndex); //删除项
  2128. XC_API BOOL WINAPI XListView_DeleteGroup(HELE hEle,int groupIndex); //删除组
  2129. XC_API void WINAPI XListView_DeleteAllGroups(HELE hEle); //删除所有组
  2130. XC_API void WINAPI XListView_DeleteAll(HELE hEle); //删除所有,清空数据
  2131. XC_API int WINAPI XListView_IsItemSelect(HELE hEle,int groupIndex,int itemIndex);//检查项是否被选择
  2132. XC_API BOOL WINAPI XListView_HitTest(HELE hEle,POINT *pPt,out_ int *pGroupIndex,out_ int *pItemIndex);//测试用户点击,组,项
  2133. XC_API int WINAPI XListView_IsGroupExpand(HELE hEle,int groupIndex);//判断组是否展开
  2134. XC_API BOOL WINAPI XListView_SetGroupExpand(HELE hEle,int groupIndex,BOOL bExpand); //展开指定组
  2135. XC_API void WINAPI XListView_EnableMultiSelect(HELE hEle,BOOL bEnable); //启用关闭多项选择
  2136. XC_API void WINAPI XListView_EnableExpandButton(HELE hEle,BOOL bEnable); //启用/关闭展开按钮
  2137. XC_API void WINAPI XListView_EnableDragItem(HELE hEle,BOOL bEnable); //启用或关闭拖动项功能
  2138. XC_API void WINAPI XListView_CancelSelectItem(HELE hEle,int groupIndex,int itemIndex); //取消选择指定项
  2139. XC_API void WINAPI XListView_CancelSelectAll(HELE hEle); //取消选择所有项
  2140. XC_API void WINAPI XListView_SetUserDrawItem(HELE hEle,pFunListView_DrawItem pFunDrawItem); //设置用户自绘项
  2141. XC_API void WINAPI XListView_SetUserDrawGroup(HELE hEle,pFunListView_DrawGroup pFunDrawGroup); //设置用户自绘组
  2142. XC_API void WINAPI XListView_SetItemImageSelect(HELE hEle,int groupIndex,int itemIndex,HIMAGE hImage);
  2143. XC_API void WINAPI XListView_SetItemImageStay(HELE hEle,int groupIndex,int itemIndex,HIMAGE hImage);
  2144. XC_API void WINAPI XListView_Adjust(HELE hEle); //调整布局
  2145. XC_API void WINAPI XMenu_SetUserDrawItemEx(HMENUX hMenu,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //设置用户自绘菜单项
  2146. XC_API void WINAPI XMenu_SetUserDrawBGEx(HMENUX hMenu,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //设置用户自绘菜背景
  2147. XC_API void WINAPI XMenu_SetUserUpdateUIEx(HMENUX hMenu,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info);
  2148. XC_API HMENUX WINAPI XMenu_Create();
  2149. XC_API void WINAPI XMenu_AddItem(HMENUX hMenu,int id,wchar_t *pText,int parentId=XMENU_ROOT,int uFlags=0); //添加菜单项
  2150. XC_API void WINAPI XMenu_AddItemImage(HMENUX hMenu,int id,wchar_t *pText,int parentId,int uFlags,HIMAGE hImage);
  2151. XC_API void WINAPI XMenu_InsertItem(HMENUX hMenu,int id,wchar_t *pText,int uFlags,int insertID);
  2152. XC_API void WINAPI XMenu_InsertItemImage(HMENUX hMenu,int id,wchar_t *pText,int uFlags,int insertID,HIMAGE hImage);
  2153. XC_API void WINAPI XMenu_DeleteItem(HMENUX hMenu,int id);
  2154. XC_API void WINAPI XMenu_SetAutoDestroy(HMENUX hMenu,BOOL bAuto); //是否自动销毁对象,默认弹出菜单关闭后自动销毁
  2155. XC_API void WINAPI XMenu_SetItemHeight(HMENUX hMenu,int height); //设置菜单项高度
  2156. XC_API BOOL WINAPI XMenu_SetBGImage(HMENUX hMenu,HIMAGE hImage);//设置菜单背景图片
  2157. XC_API BOOL WINAPI XMenu_SetItemImage(HMENUX hMenu,int id,HIMAGE hImage); //设置项图标
  2158. XC_API BOOL WINAPI XMenu_SetItemText(HMENUX hMenu,int id,wchar_t *pText); //设置项文本
  2159. XC_API void WINAPI XMenu_SetItemFlags(HMENUX hMenu,int id,int uFlags); //设置项属性
  2160. XC_API void WINAPI XMenu_SetItemCheck(HMENUX hMenu,int id,BOOL bCheck);
  2161. XC_API BOOL WINAPI XMenu_IsItemCheck(HMENUX hMenu,int id);
  2162. XC_API int WINAPI XMenu_GetItemFlags(HMENUX hMenu,int id); //获取项属性
  2163. XC_API int WINAPI XMenu_GetItemHeight(HMENUX hMenu); //获取菜单项高度
  2164. XC_API int WINAPI XMenu_GetItemCount(HMENUX hMenu); //获取菜单项数量,包含子菜单项
  2165. XC_API wchar_t* WINAPI XMenu_GetItemText(HMENUX hMenu,int id); //获取菜单项文本
  2166. XC_API int WINAPI XMenu_GetItemLeftWidth(HMENUX hMenu); //获取左侧宽度
  2167. XC_API int WINAPI XMenu_GetItemLeftText(HMENUX hMenu); //获取菜单项文本左间隔
  2168. XC_API BOOL WINAPI XMenu_Popup(HMENUX hMenu,HWND hParentWnd,int x,int y,HELE hParentEle=NULL,int uFlags=NULL); //弹出菜单
  2169. XC_API void WINAPI XMenu_Destroy(HMENUX hMenu);
  2170. XC_API void WINAPI XMenu_CloseMenu(HMENUX hMenu);
  2171. XC_API void WINAPI XMenu_SetUserDrawItem(HMENUX hMenu,pFunMenu_DrawItem pFunDrawItem); //设置用户自绘项
  2172. XC_API void WINAPI XMenu_SetUserDrawBG(HMENUX hMenu,pFunMenu_DrawBG pFunDrawBG); //设置用户自绘菜单背景
  2173. XC_API void WINAPI XMenu_SetUserUpdateUI(HMENUX hMenu,pFunMenu_UpdateUI pUpdateUI);
  2174. XC_API HELE WINAPI XMenuBar_Create(int x, int y, int cx, int cy,HXCGUI hParent=NULL); //创建按钮
  2175. XC_API int WINAPI XMenuBar_AddButton(HELE hEle,wchar_t *pText); //增加弹出菜单按钮
  2176. XC_API int WINAPI XMenuBar_InsertButton(HELE hEle,wchar_t *pText,int index); //插入弹出菜单按钮
  2177. XC_API void WINAPI XMenuBar_AddMenuItem(HELE hEle,int index,int id,wchar_t *pText,int parentId=XMENU_ROOT,int uFlags=0);
  2178. XC_API void WINAPI XMenuBar_AddMenuItemImage(HELE hEle,int index,int id,wchar_t *pText,int parentId,int uFlags,HIMAGE hImage); //增加菜单项
  2179. XC_API void WINAPI XMenuBar_InsertMenuItem(HELE hEle,int index,int id,wchar_t *pText,int uFlags,int insertID); //插入菜单项,插入到ID为insertID菜单项前面位置
  2180. XC_API void WINAPI XMenuBar_InsertMenuItemImage(HELE hEle,int index,int id,wchar_t *pText,int uFlags,int insertID,HIMAGE hImage); //增加菜单项
  2181. XC_API void WINAPI XMenuBar_DeleteMenuItem(HELE hEle,int index,int id); //删除菜单项
  2182. XC_API void WINAPI XMenuBar_SetButtonHeight(HELE hEle,int height); //设置弹出菜单按钮高度
  2183. XC_API HELE WINAPI XMenuBar_GetButton(HELE hEle,int index); //获取弹出菜单按钮句柄
  2184. XC_API HMENUX WINAPI XMenuBar_GetMenu(HELE hEle,int index); //获取菜单句柄
  2185. XC_API void WINAPI XMenuBar_DeleteButton(HELE hEle,int index); //删除菜单项并且销毁,同时该按钮下的弹出菜单也被销毁
  2186. XC_API void WINAPI XMenuBar_SetImage(HELE hEle,HIMAGE hImage=NULL);
  2187. XC_API HWINDOW WINAPI XModalWnd_CreateWindow(int width,int height,wchar_t *pTitle,HWND hWndParent,int XCStyle=XC_SY_MODAL_WINDOW);//基于父窗口坐标
  2188. XC_API int WINAPI XModalWnd_DoModal(HWINDOW hWindow); //启动模态窗口
  2189. XC_API void WINAPI XModalWnd_DoOk(HWINDOW hWindow); //确定
  2190. XC_API void WINAPI XModalWnd_DoCancel(HWINDOW hWindow); //取消
  2191. XC_API int WINAPI XMessageBox(HXCGUI hXCGUI, wchar_t *pText, wchar_t *pCaption=L"炫彩界面库-提示框",int type=XMB_OK);
  2192. XC_API HELE WINAPI XMonthCal_Create(int x, int y,int cx,int cy,HXCGUI hParent=NULL);
  2193. XC_API void WINAPI XMonthCal_SetSpacingLeft(HELE hEle,int left); //左对齐间距
  2194. XC_API void WINAPI XMonthCal_SetSpacingTop(HELE hEle,int top); //上对齐间距
  2195. XC_API void WINAPI XMonthCal_SetDate(HELE hEle,int year,int month,int day); //设置时间
  2196. XC_API int WINAPI XMonthCal_GetYear(HELE hEle);
  2197. XC_API int WINAPI XMonthCal_GetMonth(HELE hEle);
  2198. XC_API int WINAPI XMonthCal_GetDay(HELE hEle);
  2199. XC_API HELE WINAPI XDateTime_Create(int x, int y,int cx,int cy,HXCGUI hParent=NULL);
  2200. XC_API void WINAPI XDateTime_SetDate(HELE hEle,int year,int month,int day); //设置时间
  2201. XC_API int WINAPI XDateTime_GetYear(HELE hEle);
  2202. XC_API int WINAPI XDateTime_GetMonth(HELE hEle);
  2203. XC_API int WINAPI XDateTime_GetDay(HELE hEle);
  2204. XC_API HELE WINAPI XDateTime_GetButton(HELE hEle); //获取下拉按钮
  2205. XC_API void WINAPI XDateTime_SetImage(HELE hEle,HIMAGE hImage);
  2206. XC_API HELE WINAPI XOutlook_Create(int x, int y, int cx, int cy,HXCGUI hParent=NULL);
  2207. XC_API void WINAPI XOutlook_AddView(HELE hEle,HELE hView,wchar_t *pTitle);
  2208. XC_API void WINAPI XOutlook_Adjust(HELE hEle);
  2209. XC_API void WINAPI XOutlook_Expand(HELE hEle,int index); //展开指定项
  2210. XC_API int WINAPI XOutlook_GetExpand(HELE hEle); //获取当前展开的项索引
  2211. XC_API HELE WINAPI XPane_Create(wchar_t *pTitle=NULL,HWINDOW hFrameWnd=NULL); //创建按钮
  2212. XC_API wchar_t* WINAPI XPane_GetTitle(HELE hEle);
  2213. XC_API void WINAPI XPane_Hide(HELE hEle); //隐藏窗格
  2214. XC_API void WINAPI XPane_Dock(HELE hEle); //停靠窗格,自动隐藏
  2215. XC_API void WINAPI XPane_Lock(HELE hEle); //锁定窗格
  2216. XC_API void WINAPI XPane_popup(HELE hEle); //弹出窗格,当在码头上
  2217. XC_API void WINAPI XPane_Show(HELE hEle); //隐藏-显示浮动窗格
  2218. XC_API HPANE_GROUP WINAPI XPane_GetGroup(HELE hEle); //获取窗格所属组,如果没有组返回空
  2219. XC_API BOOL WINAPI XPane_Destroy(HELE hEle); //销毁窗格
  2220. XC_API pane_state_ WINAPI XPane_GetState(HELE hEle); //获取状态
  2221. XC_API void WINAPI XPane_DragPane(HELE hEle,POINT *pPtDown); //拖动窗格
  2222. XC_API void WINAPI XPane_DragGroup(HELE hEle,POINT *pPtDown);//拖动窗格组
  2223. XC_API void WINAPI XPane_FloatPane(HELE hEle); //浮动窗格
  2224. XC_API void WINAPI XPane_SetView(HELE hEle,HELE hView);
  2225. XC_API void WINAPI XPane_SetToolBar(HELE hEle,HELE hToolBar); //设置工具条
  2226. XC_API void WINAPI XPane_SetMenuBar(HELE hEle,HELE hMenuBar); //设置菜单条
  2227. XC_API void WINAPI XPane_SetSpacing(HELE hEle,int left, int top, int right, int bottom);
  2228. XC_API void WINAPI XPane_SetFixedSize(HELE hEle,BOOL bFixedSize); //设置窗格固定大小,如果为FALSE非固定大小
  2229. XC_API void WINAPI XPane_SetTitle(HELE hEle,wchar_t *pTitle);
  2230. XC_API void WINAPI XPane_SetActivate(HELE hEle,BOOL bActivate); //激活窗格
  2231. XC_API BOOL WINAPI XPane_IsActivate(HELE hEle); //判断窗格是否激活,当窗格在框架内有效
  2232. XC_API void WINAPI XPane_SetCaptionHeight(HELE hEle,int height);//设置标题栏高度
  2233. XC_API int WINAPI XPane_GetCaptionHeight(HELE hEle);//获取标题栏高度
  2234. XC_API HELE WINAPI XPane_GetButtonClose(HELE hEle); //获取关闭按钮
  2235. XC_API HELE WINAPI XPane_GetButtonLock(HELE hEle); //获取锁定按钮
  2236. XC_API HELE WINAPI XPane_GetButtonMenu(HELE hEle); //获取菜单按钮
  2237. XC_API void WINAPI XFloatWnd_EnableLock(HWINDOW hWindow,BOOL bEnable); //启用关闭锁定功能,当关闭锁定功能后,用户拖动浮动窗格不能锁定到框架窗口中
  2238. XC_API HELE WINAPI XPic_Create(int x, int y, int cx, int cy,HXCGUI hParent=NULL);
  2239. XC_API void WINAPI XPic_SetImage(HELE hEle,HIMAGE hImage); //设置图片
  2240. XC_API HELE WINAPI XProgBar_Create(int x, int y, int cx, int cy,BOOL bHorizon,HXCGUI hParent=NULL);
  2241. XC_API void WINAPI XProgBar_SetRange(HELE hEle,int range); //设置范围
  2242. XC_API void WINAPI XProgBar_SetPos(HELE hEle,int pos); //设置当前位置
  2243. XC_API int WINAPI XProgBar_GetRange(HELE hEle);
  2244. XC_API int WINAPI XProgBar_GetPos(HELE hEle);
  2245. XC_API void WINAPI XProgBar_SetHorizon(HELE hEle,BOOL bHorizon); //水平显示或垂直
  2246. XC_API void WINAPI XProgBar_EnablePercent(HELE hEle,BOOL bPercent); //显示百分比
  2247. XC_API void WINAPI XProgBar_SetImage(HELE hEle,HIMAGE hImage); //背景
  2248. XC_API void WINAPI XProgBar_SetImage2(HELE hEle,HIMAGE hImage); //显示当前进度图片
  2249. XC_API HELE WINAPI XPGrid_Create(int x, int y, int cx, int cy,HXCGUI hParent=NULL);
  2250. XC_API int WINAPI XPGrid_AddGroup(HELE hEle,wchar_t *pName,BOOL bExpand=TRUE); //添加分组
  2251. XC_API int WINAPI XPGrid_AddItem(HELE hEle,wchar_t *pName,int type,int groupID=-1); //添加项
  2252. XC_API int WINAPI XPGrid_AddItemString(HELE hEle,wchar_t *pName,wchar_t *pValue,int groupID=-1); //添加项
  2253. XC_API HELE WINAPI XPGrid_GetItemHEle(HELE hEle,int itemID);
  2254. XC_API BOOL WINAPI XPGrid_SetItemString(HELE hEle,int itemID,wchar_t *pText);
  2255. XC_API BOOL WINAPI XPGrid_SetItemColor(HELE hEle,int itemID,COLORREF color);
  2256. XC_API void WINAPI XPGrid_GetItemValue(HELE hEle,int itemID,wchar_t *pOut,int len);
  2257. XC_API void WINAPI XPGrid_DeleteItem(HELE hEle,int itemID); //删除项
  2258. XC_API void WINAPI XPGrid_DeleteGroup(HELE hEle,int groupID); //删除组
  2259. XC_API void WINAPI XPGrid_DeleteAll(HELE hEle); //删除所有
  2260. XC_API void WINAPI XPGrid_SetSpacePoint(HELE hEle,int point);//设置分隔线基于X坐标位置
  2261. XC_API int WINAPI XPGrid_GetSelectItem(HELE hEle); //获取当前选择项
  2262. XC_API void WINAPI XPGrid_Adjust(HELE hEle); //调整布局
  2263. XC_API HELE WINAPI XPPage_Create(int x, int y, int cx, int cy,HXCGUI hParent=NULL);
  2264. XC_API int WINAPI XPPage_AddLabel(HELE hEle,wchar_t *pName,HELE hPage=NULL); //添加一个标签
  2265. XC_API int WINAPI XPPage_InsertLabel(HELE hEle,int index,wchar_t *pName,HELE hPage=NULL);
  2266. XC_API void WINAPI XPPage_Adjust(HELE hEle);
  2267. XC_API BOOL WINAPI XPPage_SetBindEle(HELE hEle,int index,HELE hPage); //绑定视图元素到标签
  2268. XC_API void WINAPI XPPage_SetLabelHeight(HELE hEle,int height); //设置标签高度
  2269. XC_API void WINAPI XPPage_SetLabelWidth(HELE hEle,int index,int width); //设置标签宽度
  2270. XC_API void WINAPI XPPage_SetSelect(HELE hEle,int index,BOOL reDraw=TRUE); //设置选择标签
  2271. XC_API void WINAPI XPPage_SetLabelText(HELE hEle,int index,wchar_t *pText); //设置标签文本
  2272. XC_API void WINAPI XPPage_SetLabelSpacing(HELE hEle,int spacing);//设置标签间距, 0没有间距
  2273. XC_API void WINAPI XPPage_SetUp(HELE hEle); //左滚动
  2274. XC_API void WINAPI XPPage_SetDown(HELE hEle); //右滚动
  2275. XC_API int WINAPI XPPage_GetSelect(HELE hEle); //获取选择的标签
  2276. XC_API int WINAPI XPPage_GetLabelHeight(HELE hEle); //获取标签高度
  2277. XC_API int WINAPI XPPage_GetLabelWidth(HELE hEle,int index); //获取标签宽度
  2278. XC_API int WINAPI XPPage_GetLabelCount(HELE hEle); //获取标签项数量
  2279. XC_API wchar_t * WINAPI XPPage_GetLabelText(HELE hEle,int index); //获取文本
  2280. XC_API HELE WINAPI XPPage_GetLabel(HELE hEle,int index);//获取标签按钮Button
  2281. XC_API HELE WINAPI XPPage_GetLabelPage(HELE hEle,int index);//获取标签对应的页
  2282. XC_API int WINAPI XPPage_GetPageIndex(HELE hEle,HELE hPage); //检索绑定页对应标签索引
  2283. XC_API int WINAPI XPPage_GetLabelIndex(HELE hEle,HELE hLabel); //获取属性页标签按钮元素位置索引值
  2284. XC_API int WINAPI XPPage_GetLabelSpacing(HELE hEle);//获取标签间距, 0没有间距
  2285. XC_API void WINAPI XPPage_DeleteLabel(HELE hEle,int index,BOOL deletePage=FALSE); //删除
  2286. XC_API void WINAPI XPPage_DeleteLabelAll(HELE hEle,BOOL deletePage=FALSE); //删除所有TAB
  2287. XC_API void WINAPI XPPage_EnableScrollButton(HELE hEle,BOOL bEnable); //是否显示滚动按钮
  2288. XC_API HELE WINAPI XRadio_Create(int x, int y, int cx, int cy,wchar_t *pTitle=NULL,HXCGUI hParent=NULL); //创建按钮
  2289. XC_API void WINAPI XRadio_SetImageLeave_UnCheck(HELE hEle,HIMAGE hImage=NULL); //鼠标离开时图片 未选择
  2290. XC_API void WINAPI XRadio_SetImageStay_UnCheck(HELE hEle,HIMAGE hImage=NULL); //鼠标停留时图片 未选择
  2291. XC_API void WINAPI XRadio_SetImageDown_UnCheck(HELE hEle,HIMAGE hImage=NULL); //鼠标按下时图片 未选择
  2292. XC_API void WINAPI XRadio_SetImageDisable_UnCheck(HELE hEle,HIMAGE hImage=NULL); //按钮禁用状态图片 未选择
  2293. XC_API void WINAPI XRadio_SetImageLeave_Check(HELE hEle,HIMAGE hImage=NULL); //鼠标离开时图片 选择
  2294. XC_API void WINAPI XRadio_SetImageStay_Check(HELE hEle,HIMAGE hImage=NULL); //鼠标停留时图片 选择
  2295. XC_API void WINAPI XRadio_SetImageDown_Check(HELE hEle,HIMAGE hImage=NULL); //鼠标按下时图片 选择
  2296. XC_API void WINAPI XRadio_SetImageDisable_Check(HELE hEle,HIMAGE hImage=NULL); //按钮禁用状态图片 选择
  2297. XC_API void WINAPI XRadio_SetGroupID(HELE hEle,int groupID); //设置组ID
  2298. XC_API int WINAPI XRadio_GetGroupID(HELE hEle); //获取组ID
  2299. XC_API void WINAPI XRadio_EnableButtonStyle(HELE hEle,BOOL bStyle); //启用按钮样式
  2300. XC_API void WINAPI XRadio_SetBindEle(HELE hEle,HELE bindEle);
  2301. XC_API HELE WINAPI XRichEdit_Create(int x, int y, int cx, int cy,HXCGUI hParent=NULL);
  2302. XC_API BOOL WINAPI XRichEdit_InsertText(HELE hEle,wchar_t *pText,int row,int column); //插入文本内容
  2303. XC_API BOOL WINAPI XRichEdit_InsertTextEx(HELE hEle,wchar_t *pText,int row,int column,LOGFONTW *pFont,BOOL bColor=FALSE,COLORREF color=0);
  2304. XC_API BOOL WINAPI XRichEdit_InsertData(HELE hEle,void *pData,int row,int column);
  2305. XC_API BOOL WINAPI XRichEdit_InsertImage(HELE hEle,HIMAGE hImage,wchar_t *pImagePath,int row,int column); //插入图片,到当前位置
  2306. XC_API BOOL WINAPI XRichEdit_InsertImageGif(HELE hEle,wchar_t *pImageName,int row,int column);//插入GIF图片,到当前位置
  2307. XC_API void WINAPI XRichEdit_SetText(HELE hEle,wchar_t *pText); //设置文本内容,会清空之前的内容
  2308. XC_API BOOL WINAPI XRichEdit_SetPos(HELE hEle,int row,int column); //设置插入符位置
  2309. XC_API BOOL WINAPI XRichEdit_SetItemFontEx(HELE hEle,int beginRow,int beginColumn,int endRow,int endColumn,LOGFONTW *pFont);
  2310. XC_API BOOL WINAPI XRichEdit_SetItemColorEx(HELE hEle,int beginRow,int beginColumn,int endRow,int endColumn,COLORREF color);
  2311. XC_API void WINAPI XRichEdit_SetRowHeight(HELE hEle,int height); //设置默认行高
  2312. XC_API void WINAPI XRichEdit_SetReadOnly(HELE hEle,BOOL bRead); //设置只读内容
  2313. XC_API int WINAPI XRichEdit_GetItemCount(HELE hEle); //获取内容数量,包括图片
  2314. XC_API void WINAPI XRichEdit_GetText(HELE hEle,HSTRING hString); //获取文本内容
  2315. XC_API void WINAPI XRichEdit_GetHTMLFormat(HELE hEle,HSTRING hString); //获取HTML格式内容
  2316. XC_API void* WINAPI XRichEdit_GetData(HELE hEle);
  2317. XC_API void WINAPI XRichEdit_GetCurrentPos(HELE hEle,out_ int *pRow,out_ int *pColumn);//获取插入符位置,当前行和列
  2318. XC_API BOOL WINAPI XRichEdit_GetSelectPos(HELE hEle,out_ int *pBeginRow,out_ int *pBeginColumn,out_ int *pEndRow,out_ int *pEndColumn);//获取选择内容位置
  2319. XC_API int WINAPI XRichEdit_GetSelectText(HELE hEle,wchar_t *pOut,int len);//获取选择内容
  2320. XC_API int WINAPI XRichEdit_GetRowCount(HELE hEle); //获取总行数
  2321. XC_API int WINAPI XRichEdit_GetRowItemCount(HELE hEle,int row); //获取指定行内容数量
  2322. XC_API void WINAPI XRichEdit_GetVisibleRow(HELE hEle,out_ int *pBeginRow,out_ int *pEndRow); //获取可视行范围
  2323. XC_API int WINAPI XRichEdit_GetRowHeight(HELE hEle); //获取默认行高
  2324. XC_API int WINAPI XRichEdit_GetFontCount(HELE hEle); //获取字体数量
  2325. XC_API BOOL WINAPI XRichEdit_IsEmpty(HELE hEle); //判断内容是否为空
  2326. XC_API BOOL WINAPI XRichEdit_CancelSelect(HELE hEle); //取消选择
  2327. XC_API void WINAPI XRichEdit_SelectAll(HELE hEle); //全选 选择所有文本
  2328. XC_API void WINAPI XRichEdit_ClearFontTable(HELE hEle); //清理字体表,清理未使用的字体
  2329. XC_API BOOL WINAPI XRichEdit_DeleteEx(HELE hEle,int beginRow,int beginColumn,int endRow,int endColumn); //删除指定内容
  2330. XC_API BOOL WINAPI XRichEdit_DeleteSelect(HELE hEle); //删除选择内容
  2331. XC_API void WINAPI XRichEdit_DeleteAll(HELE hEle); //清空内容
  2332. XC_API BOOL WINAPI XRichEdit_Menu_Cut(HELE hEle); //剪切 删除选择的文本,并将文本拷贝到剪切板中
  2333. XC_API BOOL WINAPI XRichEdit_Menu_Copy(HELE hEle); //复制 复制选择的文本到剪切板中
  2334. XC_API BOOL WINAPI XRichEdit_Menu_Paste(HELE hEle); //粘贴 将剪切板中的文本插入当前光标位置
  2335. XC_API void WINAPI XRichEdit_Adjust(HELE hEle,int startIndex=0); //调整
  2336. XC_API HELE WINAPI XSBar_Create(int x, int y, int cx, int cy,BOOL bHorizon,HXCGUI hParent=NULL);
  2337. XC_API BOOL WINAPI XSBar_ScrollUp(HELE hEle); //向左滚动
  2338. XC_API BOOL WINAPI XSBar_ScrollDown(HELE hEle); //向右滚动
  2339. XC_API BOOL WINAPI XSBar_ScrollTop(HELE hEle); //滚动到顶部
  2340. XC_API BOOL WINAPI XSBar_ScrollBottom(HELE hEle); //滚动到底部
  2341. XC_API BOOL WINAPI XSBar_ScrollPos(HELE hEle,int pos); //滚动到指定点
  2342. XC_API void WINAPI XSBar_SetScrollRange(HELE hEle,int range);
  2343. XC_API void WINAPI XSBar_SetSliderLength(HELE hEle,int length); //设置滑块长度
  2344. XC_API void WINAPI XSBar_SetHorizon(HELE hEle,BOOL bHorizon); //水平显示或垂直
  2345. XC_API int WINAPI XSBar_GetScrollPos(HELE hEle); //获取当前滚动点
  2346. XC_API int WINAPI XSBar_GetButtonLength(HELE hEle); //按钮长度
  2347. XC_API int WINAPI XSBar_GetSliderLength(HELE hEle); //滑块长度
  2348. XC_API int WINAPI XSBar_GetScrollRange(HELE hEle); //获取滚动范围
  2349. XC_API void WINAPI XSBar_EnableScrollButton2(HELE hEle,BOOL bEnable); //是否显示上下滚动按钮
  2350. XC_API void WINAPI XSBar_Adjust(HELE hEle); //调整滚动条
  2351. XC_API void WINAPI XSBar_SetImage(HELE hEle,HIMAGE hImage); //设置背景图片
  2352. XC_API void WINAPI XSBar_SetImageLeaveUp(HELE hEle,HIMAGE hImage);
  2353. XC_API void WINAPI XSBar_SetImageStayUp(HELE hEle,HIMAGE hImage);
  2354. XC_API void WINAPI XSBar_SetImageDownUp(HELE hEle,HIMAGE hImage);
  2355. XC_API void WINAPI XSBar_SetImageLeaveDown(HELE hEle,HIMAGE hImage);
  2356. XC_API void WINAPI XSBar_SetImageStayDown(HELE hEle,HIMAGE hImage);
  2357. XC_API void WINAPI XSBar_SetImageDownDown(HELE hEle,HIMAGE hImage);
  2358. XC_API void WINAPI XSBar_SetImageLeaveSlider(HELE hEle,HIMAGE hImage);
  2359. XC_API void WINAPI XSBar_SetImageStaySlider(HELE hEle,HIMAGE hImage);
  2360. XC_API void WINAPI XSBar_SetImageDownSlider(HELE hEle,HIMAGE hImage);
  2361. XC_API void WINAPI XSView_SetDrawScrollViewEx(HELE hEle,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info);
  2362. XC_API HELE WINAPI XSView_Create(int x, int y, int cx, int cy,HXCGUI hParent=NULL);
  2363. XC_API void WINAPI XSView_SetDrawScrollView(HELE hEle,pFunDrawScrollView pFun);
  2364. XC_API HELE WINAPI XSView_GetView(HELE hEle); //获取视元素
  2365. XC_API BOOL WINAPI XSView_AddEle(HELE hEle,HELE hNewEle); //添加元素到滚动视图
  2366. XC_API int WINAPI XSView_GetHViewPos(HELE hEle); //获取视口原点X坐标
  2367. XC_API int WINAPI XSView_GetVViewPos(HELE hEle); //获取视口原点Y坐标
  2368. XC_API int WINAPI XSView_GetSpacingLeft(HELE hEle);
  2369. XC_API int WINAPI XSView_GetSpacingTop(HELE hEle);
  2370. XC_API int WINAPI XSView_GetSpacingRight(HELE hEle);
  2371. XC_API int WINAPI XSView_GetSpacingBottom(HELE hEle);
  2372. XC_API int WINAPI XSView_GetScrollBarWidth(HELE hEle); //获取滚动条宽度
  2373. XC_API int WINAPI XSView_GetViewWidth(HELE hEle); //获取视口宽度(不含边框间隔及滚动条)
  2374. XC_API int WINAPI XSView_GetViewHeight(HELE hEle); //获取视口高度(不含边框间隔及滚动条)
  2375. XC_API int WINAPI XSView_GetHSizeTotalAccurate(HELE hEle); //获取内容总宽度,精确的(不含边框间隔及滚动条),当内容大小小于视口大小时,返回的是视口大小
  2376. XC_API int WINAPI XSView_GetVSizeTotalAccurate(HELE hEle); //获取内容总高度,精确的(不含边框间隔及滚动条),当内容大小小于视口大小时,返回的是视口大小
  2377. XC_API void WINAPI XSView_GetViewRect(HELE hEle,out_ RECT *pRect); //获取视口坐标(不含边框间隔),left为视口左间隔大小,top为视口上间隔大小,非(0,0).
  2378. XC_API void WINAPI XSView_GetSize(HELE hEle,SIZE *pSize); //获取设置的内容大小
  2379. XC_API HELE WINAPI XSView_GetHScrollBar(HELE hEle); //获取水平滚动条
  2380. XC_API HELE WINAPI XSView_GetVScrollBar(HELE hEle); //获取垂直滚动条
  2381. XC_API void WINAPI XSView_SetSize(HELE hEle,int cx, int cy); //设置视图内容总大小(不包含边框间隔)
  2382. XC_API void WINAPI XSView_SetSpacing(HELE hEle,int left, int top, int right, int bottom);
  2383. XC_API void WINAPI XSView_SetScrollSize(HELE hEle,int line,int column); //设置滚动行和列大小
  2384. XC_API void WINAPI XSView_SetImage(HELE hEle,HIMAGE hImage);//设置贴图
  2385. XC_API void WINAPI XSView_EnableHScroll(HELE hEle,BOOL bEnable); //启用水平滚动条
  2386. XC_API void WINAPI XSView_EnableVScroll(HELE hEle,BOOL bEnable); //启用垂直滚动条
  2387. XC_API BOOL WINAPI XSView_IsHScrollBarVisible(HELE hEle); //水平滚动条当前是否可见
  2388. XC_API BOOL WINAPI XSView_IsVScrollBarVisible(HELE hEle); //垂直滚动条当前是否可见
  2389. XC_API void WINAPI XSView_Adjust(HELE hEle);
  2390. XC_API BOOL WINAPI XSView_ScrollHPos(HELE hEle,int pos); //滚动到指定点
  2391. XC_API BOOL WINAPI XSView_ScrollVPos(HELE hEle,int pos); //滚动到指定点
  2392. XC_API BOOL WINAPI XSView_ScrollHPosX(HELE hEle,int posX); //滚动到指定坐标
  2393. XC_API BOOL WINAPI XSView_ScrollVPosY(HELE hEle,int posY); //滚动到指定坐标
  2394. XC_API BOOL WINAPI XSView_ScrollLeftLine(HELE hEle); //向左滚动
  2395. XC_API BOOL WINAPI XSView_ScrollRightLine(HELE hEle); //向右滚动
  2396. XC_API BOOL WINAPI XSView_ScrollTopLine(HELE hEle); //向上滚动
  2397. XC_API BOOL WINAPI XSView_ScrollDownLine(HELE hEle); //向下滚动
  2398. XC_API BOOL WINAPI XSView_ScrollLeft(HELE hEle); //水平滚动到左侧
  2399. XC_API BOOL WINAPI XSView_ScrollRight(HELE hEle); //水平滚动到右侧
  2400. XC_API BOOL WINAPI XSView_ScrollTop(HELE hEle); //滚动到顶部
  2401. XC_API BOOL WINAPI XSView_ScrollBottom(HELE hEle); //滚动到底部
  2402. XC_API HELE WINAPI XSliderBar_Create(int x, int y, int cx, int cy,BOOL bHorizon,HXCGUI hParent=NULL);
  2403. XC_API void WINAPI XSliderBar_SetRange(HELE hEle,int range); //设置滑动范围
  2404. XC_API void WINAPI XSliderBar_SetPos(HELE hEle,int pos); //设置滑块位置
  2405. XC_API int WINAPI XSliderBar_GetPos(HELE hEle); //获取滑块位置
  2406. XC_API HELE WINAPI XSliderBar_GetButton(HELE hEle); //获取滑块指针
  2407. XC_API int WINAPI XSliderBar_GetButtonWidth(HELE hEle); //获取滑块宽度
  2408. XC_API void WINAPI XSliderBar_SetHorizon(HELE hEle,BOOL bHorizon); //水平显示或垂直
  2409. XC_API void WINAPI XSliderBar_SetButtonWidth(HELE hEle,int width); //设置滑块宽度
  2410. XC_API void WINAPI XSliderBar_SetImage(HELE hEle,HIMAGE hImage); //背景
  2411. XC_API void WINAPI XSliderBar_SetImage2(HELE hEle,HIMAGE hImage); //显示当前进度图片
  2412. XC_API HELE WINAPI XStatic_Create(int x, int y, int cx, int cy,wchar_t *pTitle=NULL,HXCGUI hParent=NULL);
  2413. XC_API void WINAPI XStatic_SetText(HELE hEle,wchar_t *pText);
  2414. XC_API wchar_t* WINAPI XStatic_GetText(HELE hEle);
  2415. XC_API void WINAPI XStatic_AdjustSize(HELE hEle); //根据文本内容,调整元素大小
  2416. XC_API void WINAPI XStatic_SetTextAlign(HELE hEle,int flag); //设置文本对齐
  2417. XC_API HSTRING WINAPI XStr_Create(wchar_t *pString=NULL);
  2418. XC_API void WINAPI XStr_Destroy(HSTRING hStr);
  2419. XC_API void WINAPI XStr_InsertChar(HSTRING hStr,int index,wchar_t ch); //插入
  2420. XC_API void WINAPI XStr_InsertString(HSTRING hStr,int index,wchar_t *pStr);
  2421. XC_API void WINAPI XStr_SetString(HSTRING hStr, wchar_t *pStr); //设置文本
  2422. XC_API void WINAPI XStr_AddString(HSTRING hStr, wchar_t *pStr); //添加文本到末尾
  2423. XC_API void WINAPI XStr_AddStringLength(HSTRING hStr, wchar_t *pStr, int strLen); //添加文本到末尾
  2424. XC_API void WINAPI XStr_SetLength(HSTRING hStr,int length); //设置字符串长度,多余的字符去掉
  2425. XC_API void WINAPI XStr_Replace(HSTRING hStr,wchar_t *pStrOld,wchar_t *pStrNew); //字符串替换 Replace
  2426. XC_API wchar_t* WINAPI XStr_GetBuffer(HSTRING hStr);
  2427. XC_API int WINAPI XStr_GetLength(HSTRING hStr);
  2428. XC_API wchar_t* WINAPI XStr_Find(HSTRING hStr,wchar_t ch, int strart=0); //查找字符
  2429. XC_API void WINAPI XStr_SetAt(HSTRING hStr,int index, wchar_t ch);//设置指定位置的一个字符
  2430. XC_API wchar_t WINAPI XStr_GetAt(HSTRING hStr,int index); //获取指定位置的一个字符
  2431. XC_API void WINAPI XStr_Empty(HSTRING hStr); //清空
  2432. XC_API BOOL WINAPI XStr_IsEmpty(HSTRING hStr); //判断是否为空
  2433. XC_API void WINAPI XStr_Delete(HSTRING hStr,wchar_t ch); //删除ch,全部ch删除
  2434. XC_API void WINAPI XStr_DeleteLength(HSTRING hStr,int index, int count=1); //从index位置删除count个字符
  2435. XC_API void WINAPI XStr_DeleteFront(HSTRING hStr, int index); //删除指定位置之后的字符串
  2436. XC_API void WINAPI XStr_DeleteBack(HSTRING hStr, int index); //删除指定位置之前的字符串
  2437. XC_API HELE WINAPI XTabBar_Create(int x, int y, int cx, int cy,HXCGUI hParent=NULL);
  2438. XC_API int WINAPI XTabBar_AddLabel(HELE hEle,wchar_t *pName,HELE hPage=NULL); //添加一个标签
  2439. XC_API int WINAPI XTabBar_InsertLabel(HELE hEle,int index,wchar_t *pName,HELE hPage=NULL);
  2440. XC_API void WINAPI XTabBar_DeleteLabel(HELE hEle,int index,BOOL deletePage=FALSE); //删除
  2441. XC_API void WINAPI XTabBar_DeleteLabelAll(HELE hEle,BOOL deletePage=FALSE); //删除所有TAB
  2442. XC_API HELE WINAPI XTabBar_GetLabel(HELE hEle,int index);//获取标签按钮Button
  2443. XC_API HELE WINAPI XTabBar_GetLabelPage(HELE hEle,int index); //获取标签对应的页
  2444. XC_API int WINAPI XTabBar_GetPageIndex(HELE hEle,HELE hPage); //检索绑定页对应标签索引
  2445. XC_API int WINAPI XTabBar_GetSelect(HELE hEle); //获取选择的标签
  2446. XC_API int WINAPI XTabBar_GetLabelSpacing(HELE hEle); //获取标签间距, 0没有间距
  2447. XC_API int WINAPI XTabBar_GetLabelCount(HELE hEle); //获取标签项数量
  2448. XC_API void WINAPI XTabBar_SetLabelSpacing(HELE hEle,int spacing);//设置标签间距, 0没有间距
  2449. XC_API BOOL WINAPI XTabBar_SetBindEle(HELE hEle,int index,HELE hPage); //绑定视图元素到标签
  2450. XC_API void WINAPI XTabBar_SetSelect(HELE hEle,int index,BOOL reDraw=TRUE); //设置选择标签
  2451. XC_API void WINAPI XTabBar_SetAlign(HELE hEle,align_type_ align);
  2452. XC_API void WINAPI XTabBar_SetUp(HELE hEle); //左滚动
  2453. XC_API void WINAPI XTabBar_SetDown(HELE hEle); //右滚动
  2454. XC_API void WINAPI XTabBar_EnableTile(HELE hEle,BOOL bTile); //平铺标签,每个标签显示相同大小
  2455. XC_API HELE WINAPI XTextLink_Create(int x, int y, int cx, int cy,wchar_t *pTitle=NULL,HXCGUI hParent=NULL);
  2456. XC_API void WINAPI XTextLink_SetStayColor(HELE hEle,COLORREF color); //设置鼠标停留时文本颜色
  2457. XC_API COLORREF WINAPI XTextLink_GetStayColor(HELE hEle); //获取鼠标停留时文本颜色
  2458. XC_API void WINAPI XTextLink_AdjustSize(HELE hEle); //根据文本内容,调整元素大小
  2459. XC_API void WINAPI XTextLink_ShowUnderline(HELE hEle,BOOL bLeave,BOOL bStay); //显示下划线
  2460. XC_API HELE WINAPI XToolBarBtn_Create(int cx,int cy,wchar_t *pTitle);
  2461. XC_API void WINAPI XToolBarBtn_Adjust(HELE hEle); //调整到合适大小, 在添加到工具条上之后才可调用,因为需要知道工具条大小后才能做调整
  2462. XC_API HELE WINAPI XToolBar_Create(int x, int y, int cx, int cy,HXCGUI hParent=NULL);
  2463. XC_API int WINAPI XToolBar_InsertEle(HELE hEle,HELE hNewEle,int index=-1); //添加元素到工具条, -1插入到末尾
  2464. XC_API int WINAPI XToolBar_InsertSeparator(HELE hEle,int index=-1); //添加分隔符, -1插入到末尾
  2465. XC_API HELE WINAPI XToolBar_GetHEle(HELE hEle,int index); //获取工具条上元素句柄
  2466. XC_API HELE WINAPI XToolBar_GetButtonLeft(HELE hEle); //获取工具条左滚动按钮Button
  2467. XC_API HELE WINAPI XToolBar_GetButtonRight(HELE hEle); //获取工具条右滚动按钮Button
  2468. XC_API void WINAPI XToolBar_DeleteEle(HELE hEle,int index); //移除工具条上元素并销毁
  2469. XC_API void WINAPI XToolBar_Adjust(HELE hEle); //调整布局
  2470. XC_API void WINAPI XToolBar_SetImage(HELE hEle,HIMAGE hImage);
  2471. XC_API void WINAPI XTree_SetUserDrawItemEx(HELE hEle,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //设置用户自绘项
  2472. XC_API HELE WINAPI XTree_Create(int x, int y, int cx, int cy,HXCGUI hParent=NULL);
  2473. XC_API int WINAPI XTree_InsertItem(HELE hEle,wchar_t *pText, int parentId=XTREE_ROOT,int imageId=-1, int selectImageId=-1,int insertAfter=XTREE_INSERT_LAST,BOOL bExpand=TRUE); //插入项
  2474. XC_API void WINAPI XTree_EnableButton(HELE hEle,BOOL bEnable); //显示按钮
  2475. XC_API void WINAPI XTree_EnableLine(HELE hEle,BOOL bEnable); //显示连接虚线
  2476. XC_API void WINAPI XTree_EnableRootLine(HELE hEle,BOOL bEnable); //启用连接根部的线
  2477. XC_API BOOL WINAPI XTree_IsButton(HELE hEle);
  2478. XC_API BOOL WINAPI XTree_IsLine(HELE hEle);
  2479. XC_API BOOL WINAPI XTree_IsRootLine(HELE hEle);
  2480. XC_API BOOL WINAPI XTree_IsExpand(HELE hEle,int id); //判断指定项是否展开
  2481. XC_API void WINAPI XTree_SetSpacingLeft(HELE hEle,int left); //设置左间隔
  2482. XC_API void WINAPI XTree_SetSpacingTop(HELE hEle,int top); //设置上间隔
  2483. XC_API void WINAPI XTree_SetImageList(HELE hEle,HXCGUI hImageList); //设置图片列表
  2484. XC_API void WINAPI XTree_SetItemData(HELE hEle,int id, int data); //设置用户数据
  2485. XC_API void WINAPI XTree_SetExpandButtonSize(HELE hEle,int size); //设置展开按钮大小
  2486. XC_API void WINAPI XTree_SetIndentation(HELE hEle,int width); //设置子项缩进宽度
  2487. XC_API void WINAPI XTree_SetSelectItem(HELE hEle,int id); //设置选择项
  2488. XC_API void WINAPI XTree_SetItemText(HELE hEle,int id, wchar_t *pText);//设置项文本
  2489. XC_API void WINAPI XTree_SetItemImage(HELE hEle,int id, int imageId); //设置项图片
  2490. XC_API void WINAPI XTree_SetItemHeight(HELE hEle,int height); //设置项高度
  2491. XC_API BOOL WINAPI XTree_SetItemBindEle(HELE hEle,int id,itemBindEle_ *pInfo); //绑定元素
  2492. XC_API int WINAPI XTree_GetItemData(HELE hEle,int id); //获取用户数据
  2493. XC_API int WINAPI XTree_GetItemHeight(HELE hEle); //获取项高度
  2494. XC_API int WINAPI XTree_GetSelectItem(HELE hEle); //获取当前选择的项
  2495. XC_API int WINAPI XTree_GetParentItem(HELE hEle,int id); //获取指定项的父项
  2496. XC_API int WINAPI XTree_GetChildItem(HELE hEle,int id); //获取指定项的子项
  2497. XC_API int WINAPI XTree_GetNextSiblingItem(HELE hEle,int id); //获取指定项的下一个兄弟项
  2498. XC_API int WINAPI XTree_GetPrevSiblingItem(HELE hEle,int id); //获取指定项的上一个兄弟项
  2499. XC_API int WINAPI XTree_GetFirstItem(HELE hEle); //获取第一个节点
  2500. XC_API int WINAPI XTree_GetItemDepth(HELE hEle,int id);//获取节点深度
  2501. XC_API int WINAPI XTree_GetItemImage(HELE hEle,int id); //获取项图片
  2502. XC_API wchar_t* WINAPI XTree_GetItemText(HELE hEle,int id); //获取项文本
  2503. XC_API HXCGUI WINAPI XTree_GetImageList(HELE hEle); //获取图片列表
  2504. XC_API void WINAPI XTree_Expand(HELE hEle,int id, BOOL bExpand); //展开收缩指定项
  2505. XC_API void WINAPI XTree_DeleteItem(HELE hEle,int id); //删除一个项
  2506. XC_API void WINAPI XTree_DeleteAllItems(HELE hEle); //清空树
  2507. XC_API int WINAPI XTree_HitTest(HELE hEle,POINT *pPt); //测试点击位置,返回项ID
  2508. XC_API void WINAPI XTree_SetUserDrawItem(HELE hEle,pFunTree_DrawItem pFunDrawItem); //设置用户自绘项
  2509. XC_API void WINAPI XTree_EnableCheckBox(HELE hEle, BOOL bEnable);//启用复选框
  2510. XC_API BOOL WINAPI XTree_IsItemCheck(HELE hEle,int id); //判断项的复选框是否勾选
  2511. XC_API void WINAPI XTree_SetItemCheck(HELE hEle,int id, BOOL bCheck); //设置项的复选框
  2512. XC_API HXCGUI WINAPI XWeb_Create(HWINDOW hWindow,int x,int y,int cx,int cy);
  2513. XC_API BOOL WINAPI XWeb_OpenURL(HXCGUI hWebBrowser,wchar_t *pUrl);
  2514. XC_API void WINAPI XWeb_Show(HXCGUI hWebBrowser,BOOL bShow); //显示隐藏
  2515. XC_API HWND WINAPI XWeb_GetHWnd(HXCGUI hWebBrowser); //获取浏览器控件容器(CAxWindow)HWND句柄
  2516. XC_API void* WINAPI XWeb_GetControl(HXCGUI hWebBrowser); //获取控件接口IWebBrowser2*
  2517. XC_API void* WINAPI XWeb_GetCAxWindow(HXCGUI hWebBrowser); //获取容器对象指针CAxWindow*
  2518. XC_API void WINAPI XWeb_Destroy(HXCGUI hWebBrowser);
  2519. XC_API BOOL WINAPI XWeb_GetClientRect(HXCGUI hWebBrowser,out_ RECT *pRect); //获取坐标
  2520. XC_API BOOL WINAPI XWeb_SetRect(HXCGUI hWebBrowser,in_ RECT *pRect); //设置坐标
  2521. XC_API BOOL WINAPI XWeb_ExeJavascript(HXCGUI hWebBrowser,wchar_t *pFun,wchar_t* pParam[],int paramCount);
  2522. XC_API void WINAPI XWeb_RegEvent(HXCGUI hWebBrowser,int type,void *pFun);
  2523. XC_API void WINAPI XWeb_RegExternalFunction0(HXCGUI hWebBrowser,wchar_t *pFunName,pFunIE_External0 pFun); //注册Js外部函数
  2524. XC_API void WINAPI XWeb_RegExternalFunction1(HXCGUI hWebBrowser,wchar_t *pFunName,pFunIE_External1 pFun); //注册Js外部函数
  2525. XC_API void WINAPI XWeb_RegExternalFunction2(HXCGUI hWebBrowser,wchar_t *pFunName,pFunIE_External2 pFun); //注册Js外部函数
  2526. XC_API void WINAPI XWeb_RegExternalFunction3(HXCGUI hWebBrowser,wchar_t *pFunName,pFunIE_External3 pFun); //注册Js外部函数
  2527. XC_API void WINAPI XWeb_RegExternalFunction4(HXCGUI hWebBrowser,wchar_t *pFunName,pFunIE_External4 pFun); //注册Js外部函数
  2528. XC_API void WINAPI XWeb_RegExternalFunction5(HXCGUI hWebBrowser,wchar_t *pFunName,pFunIE_External5 pFun); //注册Js外部函数
  2529. XC_API void WINAPI XWeb_RegExternalFunction6(HXCGUI hWebBrowser,wchar_t *pFunName,pFunIE_External6 pFun); //注册Js外部函数
  2530. XC_API void WINAPI XWeb_RegExternalFunction7(HXCGUI hWebBrowser,wchar_t *pFunName,pFunIE_External7 pFun); //注册Js外部函数
  2531. XC_API void WINAPI XWeb_RegExternalFunction8(HXCGUI hWebBrowser,wchar_t *pFunName,pFunIE_External8 pFun); //注册Js外部函数
  2532. XC_API HRESULT WINAPI XWeb_get_AddressBar(HXCGUI hWebBrowser,out_ BOOL *pbValue);
  2533. XC_API HRESULT WINAPI XWeb_put_AddressBar(HXCGUI hWebBrowser,BOOL bValue);
  2534. XC_API HRESULT WINAPI XWeb_get_Application(HXCGUI hWebBrowser,IDispatch **ppDisp);
  2535. XC_API HRESULT WINAPI XWeb_get_Busy(HXCGUI hWebBrowser,out_ BOOL *pbBool);
  2536. XC_API HRESULT WINAPI XWeb_ClientToWindow(HXCGUI hWebBrowser,in_out_ int *pcx,in_out_ int *pcy);
  2537. XC_API HRESULT WINAPI XWeb_get_Container(HXCGUI hWebBrowser,IDispatch **ppDisp);
  2538. XC_API HRESULT WINAPI XWeb_get_Document(HXCGUI hWebBrowser,IDispatch **ppDisp);
  2539. XC_API HRESULT WINAPI XWeb_ExecWB(HXCGUI hWebBrowser,in_ OLECMDID cmdID,in_ OLECMDEXECOPT cmdexecopt,in_ VARIANT *pvaIn,in_out_ VARIANT *pvaOut);
  2540. XC_API HRESULT WINAPI XWeb_get_FullName(HXCGUI hWebBrowser,out_ wchar_t *pOut,in_ int outLen);
  2541. XC_API HRESULT WINAPI XWeb_get_FullScreen(HXCGUI hWebBrowser,BOOL *pbFullScreen);
  2542. XC_API HRESULT WINAPI XWeb_put_FullScreen(HXCGUI hWebBrowser,BOOL bFullScreen);
  2543. XC_API HRESULT WINAPI XWeb_GetProperty(HXCGUI hWebBrowser,in_ wchar_t *pProperty,out_ VARIANT *pvtValue);
  2544. XC_API HRESULT WINAPI XWeb_GoBack(HXCGUI hWebBrowser);
  2545. XC_API HRESULT WINAPI XWeb_GoForward(HXCGUI hWebBrowser);
  2546. XC_API HRESULT WINAPI XWeb_GoHome(HXCGUI hWebBrowser);
  2547. XC_API HRESULT WINAPI XWeb_GoSearch(HXCGUI hWebBrowser);
  2548. XC_API HRESULT WINAPI XWeb_get_Height(HXCGUI hWebBrowser,out_ long *pl);
  2549. XC_API HRESULT WINAPI XWeb_put_Height(HXCGUI hWebBrowser,in_ long height);
  2550. XC_API HRESULT WINAPI XWeb_get_HWND(HXCGUI hWebBrowser,out_ long *pHWND);
  2551. XC_API HRESULT WINAPI XWeb_get_Left(HXCGUI hWebBrowser,out_ long *pl);
  2552. XC_API HRESULT WINAPI XWeb_put_Left(HXCGUI hWebBrowser,in_ long left);
  2553. XC_API HRESULT WINAPI XWeb_get_LocationName(HXCGUI hWebBrowser,out_ wchar_t *pLocationName,in_ int outLen);
  2554. XC_API HRESULT WINAPI XWeb_get_LocationURL(HXCGUI hWebBrowser,out_ wchar_t *pLocationURL,in_ int outLen);
  2555. XC_API HRESULT WINAPI XWeb_get_MenuBar(HXCGUI hWebBrowser,out_ BOOL *pbValue);
  2556. XC_API HRESULT WINAPI XWeb_put_MenuBar(HXCGUI hWebBrowser,in_ BOOL bValue);
  2557. XC_API HRESULT WINAPI XWeb_get_Name(HXCGUI hWebBrowser,out_ wchar_t *pName,in_ int outLen);
  2558. XC_API HRESULT WINAPI XWeb_Navigate(HXCGUI hWebBrowser,in_ wchar_t *pUrl,in_ VARIANT *Flags,in_ VARIANT *TargetFrameName,in_ VARIANT *PostData,in_ VARIANT *Headers);
  2559. XC_API HRESULT WINAPI XWeb_Navigate2(HXCGUI hWebBrowser,in_ VARIANT *URL,in_ VARIANT *Flags,in_ VARIANT *TargetFrameName,in_ VARIANT *PostData,in_ VARIANT *Headers);
  2560. XC_API HRESULT WINAPI XWeb_get_Offline(HXCGUI hWebBrowser,out_ BOOL *pbOffline);
  2561. XC_API HRESULT WINAPI XWeb_put_Offline(HXCGUI hWebBrowser,in_ BOOL bOffline);
  2562. XC_API HRESULT WINAPI XWeb_get_Parent(HXCGUI hWebBrowser,IDispatch **ppDisp);
  2563. XC_API HRESULT WINAPI XWeb_get_Path(HXCGUI hWebBrowser,out_ wchar_t *pPath,in_ int outLen);
  2564. XC_API HRESULT WINAPI XWeb_PutProperty(HXCGUI hWebBrowser,in_ wchar_t *pProperty,in_ VARIANT vtValue);
  2565. XC_API HRESULT WINAPI XWeb_QueryStatusWB(HXCGUI hWebBrowser,in_ OLECMDID cmdID,out_ OLECMDF *pcmdf);
  2566. XC_API HRESULT WINAPI XWeb_Quit(HXCGUI hWebBrowser);
  2567. XC_API HRESULT WINAPI XWeb_get_ReadyState(HXCGUI hWebBrowser,out_ READYSTATE *plReadyState);
  2568. XC_API HRESULT WINAPI XWeb_Refresh(HXCGUI hWebBrowser);
  2569. XC_API HRESULT WINAPI XWeb_Refresh2(HXCGUI hWebBrowser,in_ int level);
  2570. XC_API HRESULT WINAPI XWeb_get_RegisterAsBrowser(HXCGUI hWebBrowser,out_ BOOL *pbRegister);
  2571. XC_API HRESULT WINAPI XWeb_put_RegisterAsBrowser(HXCGUI hWebBrowser,in_ BOOL bRegister);
  2572. XC_API HRESULT WINAPI XWeb_get_RegisterAsDropTarget(HXCGUI hWebBrowser,out_ BOOL *pbRegister);
  2573. XC_API HRESULT WINAPI XWeb_put_RegisterAsDropTarget(HXCGUI hWebBrowser,in_ BOOL bRegister);
  2574. XC_API HRESULT WINAPI XWeb_get_Resizable(HXCGUI hWebBrowser,out_ BOOL *pbValue);
  2575. XC_API HRESULT WINAPI XWeb_put_Resizable(HXCGUI hWebBrowser,in_ BOOL bValue);
  2576. XC_API HRESULT WINAPI XWeb_ShowBrowserBar(HXCGUI hWebBrowser,in_ VARIANT *pvaClsid,in_ BOOL bShow);
  2577. XC_API HRESULT WINAPI XWeb_get_Silent(HXCGUI hWebBrowser,out_ BOOL *pbSilent);
  2578. XC_API HRESULT WINAPI XWeb_put_Silent(HXCGUI hWebBrowser,in_ BOOL bSilent);
  2579. XC_API HRESULT WINAPI XWeb_get_StatusBar(HXCGUI hWebBrowser,out_ BOOL *pbBool);
  2580. XC_API HRESULT WINAPI XWeb_put_StatusBar(HXCGUI hWebBrowser,in_ BOOL bValue);
  2581. XC_API HRESULT WINAPI XWeb_get_StatusText(HXCGUI hWebBrowser,out_ wchar_t *pOut,in_ int outLen);
  2582. XC_API HRESULT WINAPI XWeb_put_StatusText(HXCGUI hWebBrowser,in_ wchar_t *pStatusText);
  2583. XC_API HRESULT WINAPI XWeb_Stop(HXCGUI hWebBrowser);
  2584. XC_API HRESULT WINAPI XWeb_get_TheaterMode(HXCGUI hWebBrowser,out_ BOOL *pbRegister);
  2585. XC_API HRESULT WINAPI XWeb_put_TheaterMode(HXCGUI hWebBrowser,in_ BOOL bRegister);
  2586. XC_API HRESULT WINAPI XWeb_get_ToolBar(HXCGUI hWebBrowser,out_ int *pValue);
  2587. XC_API HRESULT WINAPI XWeb_put_ToolBar(HXCGUI hWebBrowser,in_ int value);
  2588. XC_API HRESULT WINAPI XWeb_get_Top(HXCGUI hWebBrowser,out_ long *pl);
  2589. XC_API HRESULT WINAPI XWeb_put_Top(HXCGUI hWebBrowser,in_ long top);
  2590. XC_API HRESULT WINAPI XWeb_get_TopLevelContainer(HXCGUI hWebBrowser,out_ BOOL *pbBool);
  2591. XC_API HRESULT WINAPI XWeb_get_Type(HXCGUI hWebBrowser,out_ wchar_t *pOut,in_ int outLen);
  2592. XC_API HRESULT WINAPI XWeb_get_Visible(HXCGUI hWebBrowser,out_ BOOL *pBool);
  2593. XC_API HRESULT WINAPI XWeb_put_Visible(HXCGUI hWebBrowser,in_ BOOL bValue);
  2594. XC_API HRESULT WINAPI XWeb_get_Width(HXCGUI hWebBrowser,out_ long *pl);
  2595. XC_API HRESULT WINAPI XWeb_put_Width(HXCGUI hWebBrowser,in_ long width);
  2596. XC_API void WINAPI XWnd_RegisterMessageEx(HWINDOW hWindow,int message,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //注册消息回调函数
  2597. XC_API void WINAPI XWnd_RegisterNCMessageEx(HWINDOW hWindow,int message,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //注册非客户区消息
  2598. XC_API void WINAPI XWnd_RegisterMsgProcEx(HWINDOW hWindow,pFunClassEventMsg pCallBackFun,void *pClass_Fun_Info); //注册窗口消息处理过程
  2599. XC_API HWINDOW WINAPI XWnd_CreateWindow(int x,int y,int cx,int cy,wchar_t *pTitle,HWND hWndParent=NULL,int XCStyle=XC_SY_DEFAULT);
  2600. XC_API HWINDOW WINAPI XWnd_CreateWindowEx(DWORD dwExStyle, wchar_t* lpClassName,wchar_t* lpWindowName,DWORD dwStyle, int x,int y,int cx,int cy,HWND hWndParent,int XCStyle=XC_SY_DEFAULT);
  2601. XC_API void WINAPI XWnd_RegisterMessage(HWINDOW hWindow,int message,void *pFun); //注册消息回调函数
  2602. XC_API void WINAPI XWnd_RegisterNCMessage(HWINDOW hWindow,int message,void *pFun); //注册非客户区消息
  2603. XC_API void WINAPI XWnd_RegisterMsgProc(HWINDOW hWindow,pFunWndMsgProc pFun); //注册窗口消息处理过程
  2604. XC_API void WINAPI XWnd_GetDrawRect(HWINDOW hWindow,out_ RECT *pRect);//获取当前绘制区域(包含非客户区)
  2605. XC_API HELE WINAPI XWnd_GetFocusEle(HWINDOW hWindow); //获取拥有焦点的元素
  2606. XC_API HWND WINAPI XWnd_GetHWnd(HWINDOW hWindow); //获取窗口句柄
  2607. XC_API HELE WINAPI XWnd_GetEle(HWINDOW hWindow,int eleID); //通过ID获取元素句柄
  2608. XC_API HICON WINAPI XWnd_GetIcon(HWINDOW hWindow,BOOL bBigIcon);//获取窗口图标
  2609. XC_API int WINAPI XWnd_GetWindowText(HWINDOW hWindow,wchar_t *pOut,int len);
  2610. XC_API BOOL WINAPI XWnd_SetWindowText(HWINDOW hWindow,wchar_t *pText);
  2611. XC_API void WINAPI XWnd_SetFont(HWINDOW hWindow,HFONTX hFontX);
  2612. XC_API DWORD WINAPI XWnd_SetIcon(HWINDOW hWindow,HICON hIcon,BOOL bBigIcon);
  2613. XC_API DWORD WINAPI XWnd_SetIcon2(HWINDOW hWindow,wchar_t *pFileName,BOOL bBigIcon);
  2614. XC_API void WINAPI XWnd_SetIconSize(HWINDOW hWindow,int width,int height); //设置标题栏图标显示大小
  2615. XC_API void WINAPI XWnd_SetFontCaptionText(HWINDOW hWindow,HFONTX hFontX);//设置标题栏字体
  2616. XC_API void WINAPI XWnd_SetColorCaptionText(HWINDOW hWindow,COLORREF color);//设置标题栏文字颜色
  2617. XC_API UINT WINAPI XWnd_SetTimer(HWINDOW hWindow,UINT nIDEvent,UINT uElapse); //设置定时器
  2618. XC_API BOOL WINAPI XWnd_KillTimer(HWINDOW hWindow,UINT nIDEvent);
  2619. XC_API UINT WINAPI XWnd_SetTimerEx(HWINDOW hWindow,UINT nIDEvent,UINT uElapse,int userData=0);
  2620. XC_API BOOL WINAPI XWnd_KillTimerEx(HWINDOW hWindow,UINT nIDEvent);
  2621. XC_API void WINAPI XWnd_SetMinWidth(HWINDOW hWindow,int width); //设置窗口最小宽度
  2622. XC_API void WINAPI XWnd_SetMinHeight(HWINDOW hWindow,int height); //设置窗口最小高度
  2623. XC_API void WINAPI XWnd_SetRoundSize(HWINDOW hWindow,int size); //设置窗口圆角大小,对圆角窗口有效
  2624. XC_API void WINAPI XWnd_AddEle(HWINDOW hWindow,HELE hEle);
  2625. XC_API void WINAPI XWnd_AddEleNC(HWINDOW hWindow,HELE hEle); //添加到非客户区
  2626. XC_API void WINAPI XWnd_AddMenuBar(HWINDOW hWindow,HELE hEle); //添加工具条
  2627. XC_API void WINAPI XWnd_AddToolBar(HWINDOW hWindow,HELE hEle); //添加工具条
  2628. XC_API void WINAPI XWnd_Adjust(HWINDOW hWindow); //调整窗口布局
  2629. XC_API void WINAPI XWnd_MaximizeWnd(HWINDOW hWindow,BOOL bMax); //最大化 还原窗口
  2630. XC_API BOOL WINAPI XWnd_IsMaximizeWnd(HWINDOW hWindow); //窗口是否最大化
  2631. XC_API void WINAPI XWnd_RedrawWndRect(HWINDOW hWindow,RECT *pRect,BOOL bImmediately=FALSE); //重绘窗口指定区域
  2632. XC_API void WINAPI XWnd_RedrawWnd(HWINDOW hWindow,BOOL bImmediately=FALSE); //重绘窗口
  2633. XC_API void WINAPI XWnd_RedrawEleRectNC(HWINDOW hWindow,HELE hEle,RECT *pRect);
  2634. XC_API void WINAPI XWnd_EnableDragBorder(HWINDOW hWindow,BOOL bDrag); //使用拖动边框
  2635. XC_API void WINAPI XWnd_EnableDragWindow(HWINDOW hWindow,BOOL bDrag); //拖动窗口
  2636. XC_API HELE WINAPI XWnd_GetButtonMin(HWINDOW hWindow); //最小化按钮
  2637. XC_API HELE WINAPI XWnd_GetButtonMax(HWINDOW hWindow); //最大化按钮
  2638. XC_API HELE WINAPI XWnd_GetButtonClose(HWINDOW hWindow); //关闭按钮
  2639. XC_API void WINAPI XWnd_EnableMinButton(HWINDOW hWindow,BOOL bEnable,BOOL bRedraw=FALSE); //启用最小化按钮
  2640. XC_API void WINAPI XWnd_EnableMaxButton(HWINDOW hWindow,BOOL bEnable,BOOL bRedraw=FALSE); //启用最大化按钮
  2641. XC_API void WINAPI XWnd_EnableCloseButton(HWINDOW hWindow,BOOL bEnable,BOOL bRedraw=FALSE); //启用关闭按钮
  2642. XC_API void WINAPI XWnd_EnableRound(HWINDOW hWindow,BOOL bEnable,BOOL bRedraw=FALSE); //圆角功能的启用与关闭
  2643. XC_API int WINAPI XWnd_GetChildEleCount(HWINDOW hWindow);
  2644. XC_API int WINAPI XWnd_GetChildEleCountNC(HWINDOW hWindow);
  2645. XC_API HELE WINAPI XWnd_GetChildEleByIndex(HWINDOW hWindow,int index);
  2646. XC_API HELE WINAPI XWnd_GetChildEleByIndexNC(HWINDOW hWindow,int index);
  2647. XC_API void WINAPI XWnd_SetTransparentFlag(HWINDOW hWindow,int flag); //设置透明窗口
  2648. XC_API void WINAPI XWnd_SetTransparentAlpha(HWINDOW hWindow,BYTE alpha); //设置窗口透明度
  2649. XC_API void WINAPI XWnd_SetTransparentColor(HWINDOW hWindow,COLORREF color); //设置窗口透明色
  2650. XC_API void WINAPI XWnd_SetImage(HWINDOW hWindow,HIMAGE hImage=NULL); //客户区图片
  2651. XC_API void WINAPI XWnd_SetImageNC(HWINDOW hWindow,HIMAGE hImage=NULL); //非客户区窗口图片
  2652. XC_API void WINAPI XWnd_SetImageCaption(HWINDOW hWindow,HIMAGE hImage=NULL); //标题栏图片
  2653. XC_API void WINAPI XWnd_SetImageBorderLeft(HWINDOW hWindow,HIMAGE hImage=NULL); //边框图片
  2654. XC_API void WINAPI XWnd_SetImageBorderRight(HWINDOW hWindow,HIMAGE hImage=NULL); //边框图片
  2655. XC_API void WINAPI XWnd_SetImageBorderBottom(HWINDOW hWindow,HIMAGE hImage=NULL); //边框图片
  2656. XC_API void WINAPI XWnd_SetBkColor(HWINDOW hWindow,COLORREF color); //设置背景颜色
  2657. XC_API void WINAPI XWnd_EnableBorderStrokeInner(HWINDOW hWindow,BOOL bStroke); //启用绘制描边 内
  2658. XC_API void WINAPI XWnd_EnableBorderStrokeOuter(HWINDOW hWindow,BOOL bStroke); //启用绘制描边 外
  2659. XC_API void WINAPI XWnd_SetBorderStrokeInnerColor(HWINDOW hWindow,COLORREF color1,COLORREF color2); //设置描边颜色 内
  2660. XC_API void WINAPI XWnd_SetBorderStrokeOuterColor(HWINDOW hWindow,COLORREF color1,COLORREF color2); //设置描边颜色 外
  2661. XC_API void WINAPI XWnd_CloseWindow(HWINDOW hWindow); //关闭窗口
  2662. XC_API void WINAPI XWnd_CreateCaret(HWINDOW hWindow,HELE hEle, int width, int height);//创建插入符
  2663. XC_API void WINAPI XWnd_SetCaretSize(HWINDOW hWindow,int width, int height); //设置插入符大小
  2664. XC_API void WINAPI XWnd_SetCaretPos(HWINDOW hWindow,int x,int y); //设置插入符位置
  2665. XC_API void WINAPI XWnd_SetCaretPosEx(HWINDOW hWindow,int x,int y,int width,int height); //设置插入符位置
  2666. XC_API void WINAPI XWnd_SetCaretColor(HWINDOW hWindow,COLORREF color); //设置插入符颜色
  2667. XC_API void WINAPI XWnd_ShowCaret(HWINDOW hWindow,BOOL bShow); //显示插入符
  2668. XC_API void WINAPI XWnd_DestroyCaret(HWINDOW hWindow); //销毁插入符
  2669. XC_API BOOL WINAPI XWnd_GetClientRect(HWINDOW hWindow,out_ RECT *pRect); //获取客户区坐标(左上角0,0)
  2670. XC_API void WINAPI XWnd_GetNCClientRect(HWINDOW hWindow,out_ RECT *pRect); //非客户区坐标,整个窗口坐标(左上角0,0)
  2671. XC_API int WINAPI XWnd_GetClientLeft(HWINDOW hWindow); //客户区左间距
  2672. XC_API int WINAPI XWnd_GetClientTop(HWINDOW hWindow); //客户区上间距
  2673. XC_API int WINAPI XWnd_GetClientRight(HWINDOW hWindow); //客户区右间距
  2674. XC_API int WINAPI XWnd_GetClientBottom(HWINDOW hWindow); //客户区下间距
  2675. XC_API int WINAPI XWnd_GetCaptionHeight(HWINDOW hWindow); //获取标题栏高度
  2676. XC_API void WINAPI XWnd_SetBorderSize(HWINDOW hWindow,int left,int top,int right,int bottom); //设置窗口边框大小
  2677. XC_API void WINAPI XWnd_SetCaptionHeight(HWINDOW hWindow,int captionHeight); //设置标题栏高度
  2678. XC_API void WINAPI XWnd_WindowToClientRect(HWINDOW hWindow,in_out_ RECT *pRect); //窗口非客户区坐标转换到客户区坐标
  2679. XC_API void WINAPI XWnd_WindowToClientPt(HWINDOW hWindow,in_out_ POINT *pPt); //窗口非客户区点转换到客户区坐标点
  2680. XC_API void WINAPI XWnd_SetUserData(HWINDOW hWindow,int data);
  2681. XC_API int WINAPI XWnd_GetUserData(HWINDOW hWindow);
  2682. XC_API BOOL WINAPI XWnd_ShowWindow(HWINDOW hWindow,int nCmdShow);
  2683. XC_API BOOL WINAPI XWnd_SetWindowPos(HWINDOW hWindow,HWND hWndInsertAfter,int x,int y,int cx,int cy,UINT uFlags);
  2684. XC_API BOOL WINAPI XWnd_SetWindowRect(HWINDOW hWindow,in_ RECT *pRect);
  2685. XC_API BOOL WINAPI XWnd_SetWindowSize(HWINDOW hWindow,int width,int height);
  2686. XC_API BOOL WINAPI XWnd_GetWindowRect(HWINDOW hWindow,out_ RECT *pRect);
  2687. XC_API BOOL WINAPI XWnd_IsWindowVisible(HWINDOW hWindow);
  2688. XC_API int WINAPI XC_GetObjectType(HXCGUI hXCGUI); //获取资源类型
  2689. XC_API BOOL WINAPI XC_IsHELE(HELE hEle); //检查句柄
  2690. XC_API BOOL WINAPI XC_IsHWINDOW(HWINDOW hWindow); //检查句柄
  2691. XC_API BOOL WINAPI XC_IsSViewExtend(HELE hEle); //判断元素是否从滚动视图元素扩展的新元素,包含滚动视图元素
  2692. XC_API BOOL WINAPI XC_IsEditExtend(HELE hEle); //判断该元素是否从指定元素扩展而来
  2693. XC_API int WINAPI XC_UnicodeToAnsi(wchar_t *pIn,int inLen,char *pOut,int outLen);
  2694. XC_API int WINAPI XC_AnsiToUnicode(char *pIn,int inLen,wchar_t *pOut,int outLen);
  2695. XC_API int WINAPI XC_HexToDec(wchar_t *pHex);
  2696. XC_API void WINAPI XC_SetResourcesModule(HMODULE hModule); //设置资源模块句柄
  2697. XC_API BOOL WINAPI XC_RectInRect(RECT *pRect1,RECT *pRect2);
  2698. XC_API void WINAPI XC_CombineRect(RECT *pDest,RECT *pSrc1,RECT *pSrc2);
  2699. XC_API HMODULE WINAPI XC_GetModuleHandle(wchar_t *pModuleName);
  2700. XC_API HMODULE WINAPI XC_GetModuleHandle2();
  2701. XC_API HANDLE WINAPI XC_LoadImage(HINSTANCE hinst,wchar_t * lpszName,UINT uType,int cxDesired,int cyDesired,UINT fuLoad);
  2702. XC_API HFONT WINAPI XC_CreateFont(wchar_t *pName=L"宋体",int size=12,BOOL bBold=FALSE,BOOL bItalic=FALSE,BOOL bUnderline=FALSE,BOOL bStrikeOut=FALSE);
  2703. XC_API void WINAPI XC_InitFont(LOGFONTW *pFont,wchar_t *pName,int size,BOOL bBold=FALSE,BOOL bItalic=FALSE,BOOL bUnderline=FALSE,BOOL bStrikeOut=FALSE);
  2704. XC_API void* WINAPI XC_Malloc(int size);
  2705. XC_API void WINAPI XC_Free(void *p);
  2706. XC_API BOOL WINAPI XML_Register(int type,void *pFun); //注册回调函数
  2707. XC_API BOOL WINAPI XC_RegisterWndClass(wchar_t *pClassName,HICON hIcon=NULL); //注册窗口类
  2708. XC_API BOOL WINAPI XInitXCGUI(wchar_t *pText=NULL);
  2709. XC_API void WINAPI XRunXCGUI();
  2710. XC_API void WINAPI XExitProcess(); //退出进程(相当析构函数)
  2711. XC_API void WINAPI xtrace(char *pszFormat, ...);
  2712. XC_API void WINAPI xtracew(wchar_t *pszFormat, ...);
  2713. #endif //XCGUI_HEADER_FILE_