{"id":1900,"date":"2015-01-30T21:38:15","date_gmt":"2015-01-30T13:38:15","guid":{"rendered":"http:\/\/blog.qdac.cc\/?p=1900"},"modified":"2015-01-30T22:05:40","modified_gmt":"2015-01-30T14:05:40","slug":"fmx-tpopup-%e7%bb%84%e4%bb%b6","status":"publish","type":"post","link":"https:\/\/blog.qdac.cc\/?p=1900","title":{"rendered":"[FMX] TPopup \u7ec4\u4ef6\u5e2e\u52a9\u7684\u6838\u5fc3\u7ffb\u8bd1"},"content":{"rendered":"<p><strong class=\"selflink\">TPopup<\/strong>\u00a0\u7528\u4e8e\u5728\u4e00\u4e2a\u4e34\u65f6\u5f39\u51fa\u7a97\u53e3\u4e2d\u663e\u793a\u5185\u5bb9\uff08\u5b9e\u9645\u4e0a\u53ef\u4ee5\u7528\u6765\u5f39\u51fa\u590d\u6742\u7684\u5c5e\u6027\u53ca\u7f16\u8f91\u7a97\u53e3\uff09\u3002\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u4e00\u4e2a\u00a0<strong class=\"selflink\">TPopup<\/strong>\u00a0\u662f\u6ca1\u6709\u5185\u5bb9\u7684\uff0c\u4f60\u53ef\u4ee5\u6dfb\u52a0\u4e00\u4e9b\u5bf9\u8c61\u5230\u5176\u4e2d\uff1a<\/p>\n<div id=\"globalWrapper\">\n<div id=\"column-content\">\n<div id=\"content\">\n<div id=\"bodyContent\" class=\"mw-body\">\n<div id=\"mw-content-text\" class=\"mw-content-ltr\" dir=\"ltr\" lang=\"en\">\n<ul>\n<li>\u8981\u6dfb\u52a0\u4e00\u4e2a\u63a7\u4ef6\u5230\u00a0<strong class=\"selflink\">TPopup<\/strong>\u00a0\uff0c\u8bbe\u7f6e\u5b83\u7684 Parent\u00a0\u5c5e\u6027\u6216\u8005\u521b\u5efa\u5b83\u65f6\u7528 TPopup\u505a\u4e3a\u6240\u6709\u8005\u3002<\/li>\n<li>\u8981\u8bbf\u95ee\u00a0<strong class=\"selflink\">TPopup<\/strong>\u00a0\u5b50\u5bf9\u8c61\uff0c\u4f7f\u7528\u00a0ChildrenCount \u548c Children \u5c5e\u6027\u3002<\/li>\n<\/ul>\n<p>\u8981\u5b9a\u4f4d\u4e00\u4e2a\u00a0<strong class=\"selflink\">TPopup<\/strong>\uff0c\u4f7f\u7528\u4e0b\u5217\u5c5e\u6027\uff1a<\/p>\n<ul>\n<li>PlacementRectangle<br \/>\n\u83b7\u53d6\u6216\u8bbe\u7f6e\u5143\u7d20\u76f8\u5bf9\u4e8e TPopup \u7684\u4f4d\u7f6e\u3002\u4f7f\u7528\u00a0Placement\uff0cPlacementTarget\u00a0\u548c <strong class=\"selflink\">PlacementRectangle<\/strong>\u00a0\u6765\u8bbe\u7f6e\u76ee\u6807\u539f\u70b9\u548cTPopup\u7684\u5bf9\u9f50\u70b9\u3002\u4e0b\u56fe\u662f\u4e00\u4e2a TPopup \u4f7f\u7528\u00a0<strong class=\"selflink\">PlacementRectangle <\/strong>\u7684\u4f8b\u5b50:<\/p>\n<div id=\"globalWrapper\">\n<div id=\"column-content\">\n<div id=\"content\">\n<div id=\"bodyContent\" class=\"mw-body\">\n<div id=\"mw-content-text\" class=\"mw-content-ltr\" dir=\"ltr\" lang=\"en\">\n<p><a href=\"https:\/\/blog.qdac.cc\/wp-content\/uploads\/2015\/01\/popupplacementrectangle.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-1909\" src=\"https:\/\/blog.qdac.cc\/wp-content\/uploads\/2015\/01\/popupplacementrectangle.png\" alt=\"popupplacementrectangle\" width=\"201\" height=\"125\" \/><\/a><\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/li>\n<li>PlacementTarget\n<div id=\"globalWrapper\">\n<div id=\"column-content\">\n<div id=\"content\">\n<div id=\"bodyContent\" class=\"mw-body\">\n<div id=\"mw-content-text\" class=\"mw-content-ltr\" dir=\"ltr\" lang=\"en\">\n<p>\u83b7\u53d6\u6216\u8bbe\u7f6e TPopup \u5b9a\u4f4d\u65f6\u76f8\u5bf9\u7684\u76ee\u6807\u3002<\/p>\n<p>\u5982\u679c\u00a0<strong class=\"selflink\">PlacementTarget<\/strong>\u00a0\u672a\u8bbe\u7f6e\u5e76\u4e14 TPopup \u62e5\u6709\u4e00\u4e2a\u7236\uff0cTPopup \u57fa\u4e8e\u7236\u6765\u5b9a\u4f4d\u81ea\u5df1\u3002\u5982\u679c\u00a0<strong class=\"selflink\">PlacementTarget<\/strong> \u548c Parent\u00a0\u90fd\u6ca1\u8bbe\u7f6e\uff0c\u00a0TPopup\u00a0\u4f7f\u7528\u76f8\u5bf9\u4e8e\u4e3b\u7a97\u53e3\u5b9a\u4f4d\u3002\u4f7f\u7528\u00a0Placement\uff0cPlacementTarget\u00a0\u548c <strong class=\"selflink\">PlacementRectangle<\/strong>\u00a0\u6765\u8bbe\u7f6e\u76ee\u6807\u539f\u70b9\u548cTPopup\u7684\u5bf9\u9f50\u70b9\u3002<\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/li>\n<li>HorizontalOffset\u83b7\u53d6\u6216\u8bbe\u7f6e\u5728\u76ee\u6807\u539f\u70b9\u548c TPopup \u5bf9\u9f50\u70b9\u4e4b\u95f4\u7684\u6c34\u5e73\u8ddd\u79bb\uff08\u5b9e\u9645\u4e0a\u662f Left \u5750\u6807\u76f8\u5bf9\u4e8e Placement \u7684\u504f\u79fb\u91cf\uff09\u3002\u8981\u8bbe\u7f6e\u76ee\u6807\u539f\u70b9\u548cTPopup\u7684\u5bf9\u9f50\u70b9\uff0c\u4f7f\u7528\u5c5e\u6027 Placement\uff0cPlacementTarget\u00a0\u548c <strong class=\"selflink\">PlacementRectangle<\/strong>\u00a0\u3002\n<div id=\"globalWrapper\">\n<div id=\"column-content\">\n<div id=\"content\">\n<div id=\"bodyContent\" class=\"mw-body\">\n<div id=\"mw-content-text\" class=\"mw-content-ltr\" dir=\"ltr\" lang=\"en\">\n<p>\u5982\u679c Placement \u53d6\u4ee5\u4e0b\u503c\uff0c<strong class=\"selflink\">HorizontalOffset<\/strong>\u00a0\u65e0\u6548\uff1a\u00a0<code>Absolute<\/code>\u3001 <code>Mouse<\/code>\u3001 <code>MouseCenter\u3002<\/code><\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/li>\n<li>VerticalOffset<br \/>\n\u83b7\u53d6\u6216\u8bbe\u7f6e\u5728\u76ee\u6807\u539f\u70b9\u548c TPopup \u5bf9\u9f50\u70b9\u4e4b\u95f4\u7684\u5782\u76f4\u8ddd\u79bb\uff08\u5b9e\u9645\u4e0a\u662f Top \u76f8\u5bf9\u4e8e Placement \u7684\u504f\u79fb\u91cf\uff09\u3002\u8981\u8bbe\u7f6e\u76ee\u6807\u539f\u70b9\u548cTPopup\u7684\u5bf9\u9f50\u70b9\uff0c\u4f7f\u7528\u5c5e\u6027 Placement\uff0cPlacementTarget\u00a0\u548c <strong class=\"selflink\">PlacementRectangle<\/strong>\u00a0\u3002<\/p>\n<div id=\"globalWrapper\">\n<div id=\"column-content\">\n<div id=\"content\">\n<div id=\"bodyContent\" class=\"mw-body\">\n<div id=\"mw-content-text\" class=\"mw-content-ltr\" dir=\"ltr\" lang=\"en\">\n<p>\u5982\u679c Placement \u53d6\u4ee5\u4e0b\u503c\uff0c<strong class=\"selflink\">VerticalOffset<\/strong>\u00a0\u65e0\u6548\uff1a\u00a0<code>Absolute<\/code>\u3001 <code>Mouse<\/code>\u3001 <code>MouseCenter\u3002<\/code><\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/li>\n<li>Placement\n<div id=\"globalWrapper\">\n<div id=\"column-content\">\n<div id=\"content\">\n<div id=\"bodyContent\" class=\"mw-body\">\n<div id=\"mw-content-text\" class=\"mw-content-ltr\" dir=\"ltr\" lang=\"en\">\n<p>\u83b7\u53d6\u6216\u8bbe\u7f6e TPopup\u7684\u5b9a\u4f4d\u65b9\u5f0f\u3002<\/p>\n<p>\u5b83\u4e5f\u6307\u5b9a\u4e86 TPopup \u5728\u8d85\u51fa\u5c4f\u5e55\u8fb9\u754c\u65f6\u7684\u884c\u4e3a\u3002\u9ed8\u8ba4\u503c\u4e3a\u5e95\u90e8\uff08<code>Bottom\uff09<\/code>.<\/p>\n<p><strong class=\"selflink\">Placement\u00a0<\/strong>\u7684\u6240\u6709\u503c\u8bf4\u660e\u53c2\u8003\u00a0TPlacement\u00a0\u5b9a\u4e49\uff0c\u5b9a\u4e49\u5982\u4e0b\uff1a<\/p>\n<pre class=\"lang:delphi decode:true  \">TPlacement = (Bottom, Top, Left, Right, Center, BottomCenter, TopCenter, LeftCenter, RightCenter, Absolute, Mouse, MouseCenter);<\/pre>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/li>\n<\/ul>\n<p>\u5f53\u4e00\u4e2a\u00a0<strong class=\"selflink\">TPopup<\/strong>\u00a0\u6253\u5f00\uff0c\u5982\u679c\u5b83\u7684\u7236\u91cd\u5b9a\u4f4d\uff0c\u5b83\u4e0d\u4f1a\u91cd\u5b9a\u4f4d\u3002\u5982\u679c\u4e0e\u5176\u7236\u4e00\u8d77\u62d6\u52a8\u4e00\u4e2a TPopup \uff0c\u8bbe\u7f6e\u00a0DragWithParent\u00a0\u5c5e\u6027\u4e3a\u00a0<b>True<\/b>.<\/p>\n<p><strong class=\"selflink\">TPopup<\/strong>\u00a0\u652f\u6301\u52a8\u753b\u548c\u56fe\u5f62\u6548\u679c\u3002\u8fd9\u4e9b\u52a8\u753b\u548c\u56fe\u5f62\u7279\u6548\u88ab\u7528\u4e8e\u663e\u793a\u7a97\u53e3\uff0c\u00a0\u800c\u4e0d\u662f\u6bcf\u4e00\u4e2a TPopup \u7684\u5b50\u7ec4\u4ef6\u3002\u5bf9\u4e8e\u4e0d\u900f\u660e\u6548\u679c\uff0c\u76f4\u63a5\u8bbe\u7f6e TPopup\u5b50\u7ec4\u4ef6\u6548\u679c\u3002<strong class=\"selflink\">TPopup<\/strong>\u00a0\u4e0d\u4f1a\u7ee7\u627f\u7236\u7684\u52a8\u753b\u548c\u7279\u6548\u3002<\/p>\n<p>\u5982\u679c <strong class=\"selflink\">TPopup<\/strong>\u00a0\u6ca1\u6709\u4e25\u683c\u7684\u5c3a\u5bf8\u9650\u5236\uff0c\u5b83\u7684\u5927\u5c0f\u5c06\u53d6\u51b3\u4e8e\u5185\u5bb9\u3002\u4e5f\u5c31\u662f\u8bf4\uff0c\u5982\u679c\u4e00\u4e2a\u6548\u679c\u5e94\u7528\u4e8e\u5185\u5bb9\u7684\u663e\u793a\u5c3a\u5bf8\uff0c\u90e8\u5206\u5185\u5bb9\u53ef\u80fd\u88ab\u906e\u76d6\u3002\u8981\u907f\u514d\u8fd9\u4e9b\uff0c\u660e\u786e\u8bbe\u7f6e TPopup\u7684\u5c3a\u5bf8\u6216\u901a\u8fc7\u5b83\u7684 BoundsRect\u3001Margins\u3001Padding \u5c5e\u60c5\u8ff7\u6765\u8bbe\u7f6e\u7ed1\u5b9a\u533a\u57df\u3002<\/p>\n<p>\u8981\u663e\u5f0f\u7684\u6253\u5f00\u548c\u5173\u95ed\u00a0<strong class=\"selflink\">TPopu<\/strong>\uff0c \u5206\u522b\u8bbe\u7f6e\u00a0TPopup.IsOpen\u00a0\u5c5e\u6027\u4e3a\u00a0<b>True<\/b>\u00a0\u548c\u00a0<b>False<\/b>\u3002\uff08\u6211\u4eec\u4e0d\u63a8\u8350\u4f7f\u7528 Popup \u548cClosePopup\uff09<\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>TPopup\u00a0\u7528\u4e8e\u5728\u4e00\u4e2a\u4e34\u65f6\u5f39\u51fa\u7a97\u53e3\u4e2d\u663e [&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":[8],"tags":[149,311],"class_list":["post-1900","post","type-post","status-publish","format-standard","hentry","category-delphi","tag-fmx","tag-tpopup"],"views":3715,"_links":{"self":[{"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=\/wp\/v2\/posts\/1900","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=1900"}],"version-history":[{"count":8,"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=\/wp\/v2\/posts\/1900\/revisions"}],"predecessor-version":[{"id":1917,"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=\/wp\/v2\/posts\/1900\/revisions\/1917"}],"wp:attachment":[{"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1900"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1900"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.qdac.cc\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1900"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}