{"id":2423,"date":"2015-05-11T13:41:32","date_gmt":"2015-05-11T05:41:32","guid":{"rendered":"http:\/\/blog.qdac.cc\/?p=2423"},"modified":"2015-05-11T14:37:27","modified_gmt":"2015-05-11T06:37:27","slug":"vclfmx-%e5%8f%8c%e5%89%91%e5%90%88%e5%a3%81%e7%bc%96%e7%a8%8b","status":"publish","type":"post","link":"https:\/\/blog.qdac.cc\/?p=2423","title":{"rendered":"VCL+FMX \u53cc\u5251\u5408\u58c1\u7f16\u7a0b"},"content":{"rendered":"<p>\u3010\u7279\u522b\u611f\u8c22\u3011\u732b\u53d4\u6350\u52a9SSD\u786c\u76d8<\/p>\n<p>VCL \u662f\u7ecf\u5178\uff0cFMX \u662f\u65b0\u751f\uff0c\u65b0\u751f\u4e8b\u7269\u603b\u4f1a\u5e26\u6765\u4e00\u4e9b\u597d\u73a9\u65b0\u5947\u7684\u4e1c\u897f\u3002\u820d\u5f03\u7ecf\u5178\u662f\u6d6a\u8d39\uff0c\u4e0d\u4e86\u89e3\u65b0\u751f\u4e8b\u7269\u662f\u7b49\u6b7b\uff0c\u90a3\u4e48\u6211\u4eec\u6765\u4e00\u4e2a\u4e8c\u5408\u4e00\u53cc\u5251\u5408\u58c1\u53c8\u5982\u4f55\u5462\uff1f<\/p>\n<p>\u8981\u53cc\u5251\u5408\u58c1\uff0c\u5c31\u5f97\u6295\u4e9b\u673a\uff0c\u53d6\u4e9b\u5de7\u3002\u7531\u4e8e Delphi \/ C++ Builder \u4e0d\u652f\u6301\u76f4\u63a5\u521b\u5efa\u4e00\u4e2a VCL+FMX \u7684\u5408\u4f53\u5e94\u7528\uff0c\u6240\u4ee5\u6211\u4eec\u8981\u5206\u522b\u521b\u5efa\u4e00\u4e2a VCL \u548c FMX \u7684\u5e94\u7528\u7a0b\u5e8f\uff0c\u5176\u4e2d\u4e00\u4e2a\u6211\u4eec\u505a\u4e3a\u4e3b\u7a97\u53e3\u3002<\/p>\n<p>\u597d\u4e86\uff0c \u6211\u4eec\u5148\u521b\u5efa\u4e00\u4e2a\u65b0\u7684 VCL \u5de5\u7a0b\uff0c\u547d\u540d\u4e3a vclprj\uff0c\u7136\u540e\u5728\u5176\u4e0a\u653e\u7f6e\u4e00\u4e2a\u6309\u94ae\uff0c\u6548\u679c\u5982\u4e0b\uff1a<\/p>\n<p><a href=\"https:\/\/blog.qdac.cc\/wp-content\/uploads\/2015\/05\/vclmain.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2424\" src=\"https:\/\/blog.qdac.cc\/wp-content\/uploads\/2015\/05\/vclmain.jpg\" alt=\"vclmain\" width=\"669\" height=\"383\" srcset=\"https:\/\/blog.qdac.cc\/wp-content\/uploads\/2015\/05\/vclmain.jpg 669w, https:\/\/blog.qdac.cc\/wp-content\/uploads\/2015\/05\/vclmain-300x172.jpg 300w\" sizes=\"auto, (max-width: 669px) 100vw, 669px\" \/><\/a><\/p>\n<p>\u63a5\u4e0b\u6765\uff0c\u6211\u4eec\u518d\u6dfb\u52a0\u4e2a\u7a7a\u767d\u7684 FMX \u5de5\u7a0b\uff0c\u547d\u540d\u4e3a fmxprj\uff0c\u7136\u540e\uff0c\u6211\u4eec\u5728\u65b0\u6253\u5f00\u7684 FMX \u7a97\u4f53\u4e0a\u968f\u4fbf\u653e\u70b9\u5565\uff0c\u8fd9\u91cc\u6211\u653e\u4e86\u4e00\u4e2a TLabel\uff0c\u7136\u540e\u65cb\u8f6c\u4e8645\u00b0\uff0c\u7136\u540e\u968f\u4fbf\u6dfb\u52a0\u4e86\u4e00\u4e2aTFloatAnimation\u3002\u6548\u679c\u5982\u4e0b\uff08\u8fd9\u4e2a\u7a97\u4f53\u540d\u5b57\u4e3a Form4\uff09\uff1a<\/p>\n<p><a href=\"https:\/\/blog.qdac.cc\/wp-content\/uploads\/2015\/05\/fmxmain.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2425\" src=\"https:\/\/blog.qdac.cc\/wp-content\/uploads\/2015\/05\/fmxmain.jpg\" alt=\"fmxmain\" width=\"658\" height=\"475\" srcset=\"https:\/\/blog.qdac.cc\/wp-content\/uploads\/2015\/05\/fmxmain.jpg 658w, https:\/\/blog.qdac.cc\/wp-content\/uploads\/2015\/05\/fmxmain-300x217.jpg 300w\" sizes=\"auto, (max-width: 658px) 100vw, 658px\" \/><\/a><\/p>\n<p>\u597d\u4e86\uff0c\u6211\u4eec\u5207\u56de vclprj\uff0c\u7136\u540e\u53cc\u51fb\u6309\u94ae\uff0c\u7136\u540e\u5728\u00a0implementation \u90e8\u5206\u5199\u5165 uses FMX\u7a97\u4f53\u6240\u5728\u5355\u5143\uff0c\u6211\u7684\u662f unit4.pas\uff0c\u6240\u4ee5\u5c31\u662f uses unit4;<\/p>\n<p>\u63a5\u4e0b\u6765\u5c31\u8c61\u6b63\u5e38\u7684\u7f16\u7801\u4e00\u6837\uff0c\u76f4\u63a5\u521b\u5efa\u7a97\u4f53\u5e76\u663e\u793a\u51fa\u6765\u5c31\u597d\u4e86\u3002<\/p>\n<pre class=\"lang:delphi decode:true \">var\r\n  FmxAppWnd:HWND=0;\r\nprocedure HideFMXAppWnd;\r\nbegin\r\nif FmxAppWnd=0 then\r\n  FmxAppWnd:=Winapi.Windows.FindWindow('TFMAppClass',nil);\r\nif (FmxAppWnd&lt;&gt;0) and (Winapi.Windows.IsWindowVisible(FmxAppWnd)) then\r\n  ShowWindow(FmxAppWnd,SW_HIDE);\r\nend;\r\n\r\nprocedure TForm3.Button1Click(Sender: TObject);\r\nvar\r\n  F:TForm4;\r\nbegin\r\nF:=TForm4.Create(nil);\r\nHideFMXAppWnd;\r\nF.ShowModal;\r\nF.DisposeOf;\r\nend;<\/pre>\n<p>\u597d\u4e86\uff0c\u73b0\u5728\u6211\u4eec\u7f16\u8bd1\u8fd0\u884c vclprj\uff0c\u70b9\u51fb\u6309\u94ae\u770b\u770b\uff1a<\/p>\n<p><a href=\"https:\/\/blog.qdac.cc\/wp-content\/uploads\/2015\/05\/vclfmx.gif\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2426\" src=\"https:\/\/blog.qdac.cc\/wp-content\/uploads\/2015\/05\/vclfmx.gif\" alt=\"vclfmx\" width=\"828\" height=\"589\" \/><\/a><\/p>\n<p>\u600e\u4e48\u6837\uff0c\u6548\u679c\u8fd8\u662f\u86ee\u70ab\u7684\u5427\u3002<\/p>\n<p>\u3010\u8865\u5145\u3011\u4e0d\u5f97\u95f2\u53d1\u73b0\u4e00\u4e2a\u7ec4\u4ef6\u53ef\u4ee5\u76f4\u63a5\u5c06 FMX \u7684\u7a97\u4f53\u5957\u5230 VCL \u7a97\u4f53\u4e0a\uff0c\u5177\u4f53\u6548\u679c\u8bf7\u81ea\u884c\u6d4b\u8bd5\uff0c\u4ffa\u6ca1\u5b9e\u9a8c\uff1a<a href=\"http:\/\/parnassus.co\/tfiremonkeycontainer-a-vcl-control-for-mixing-vcl-and-fmx\/\" target=\"_blank\">TFireMonkeyContainer \u2013 a VCL control for mixing VCL and FMX<\/a>\uff0c\u5b83\u7684\u6e90\u7801\u6211\u5df2\u7ecf\u4e0b\u8f7d\u5206\u4eab\u7ed9\u5927\u5bb6\uff1a<a href=\"http:\/\/pan.baidu.com\/s\/1nt7lhPZ\" target=\"_blank\">\u767e\u5ea6\u7f51\u76d8<\/a><\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u3010\u7279\u522b\u611f\u8c22\u3011\u732b\u53d4\u6350\u52a9SSD\u786c\u76d8 VCL  [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","ast-disable-related-posts":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"footnotes":""},"categories":[69,8,21],"tags":[],"class_list":["post-2423","post","type-post","status-publish","format-standard","hentry","category-c-builder","category-delphi","category-misc"],"views":6215,"_links":{"self":[{"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=\/wp\/v2\/posts\/2423","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=2423"}],"version-history":[{"count":4,"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=\/wp\/v2\/posts\/2423\/revisions"}],"predecessor-version":[{"id":2430,"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=\/wp\/v2\/posts\/2423\/revisions\/2430"}],"wp:attachment":[{"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=2423"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=2423"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=2423"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}