{"id":398,"date":"2011-03-14T08:11:58","date_gmt":"2011-03-14T00:11:58","guid":{"rendered":"http:\/\/leybreeze.com\/blog\/?p=398"},"modified":"2011-03-28T11:23:43","modified_gmt":"2011-03-28T03:23:43","slug":"%e5%b8%b8%e8%a7%81%e5%b8%83%e5%b1%80%e5%af%b9%e8%b1%a1","status":"publish","type":"post","link":"http:\/\/leybreeze.com\/blog\/?p=398","title":{"rendered":"\u5e38\u89c1\u5e03\u5c40\u5bf9\u8c61"},"content":{"rendered":"<p>\u8fd9\u4e00\u8282\u5c06\u63cf\u8ff0\u4e00\u4e9b\u5728\u7a0b\u5e8f\u4e2d\u8f83\u4e3a\u5e38\u7528\u7684\u5e03\u5c40\u5bf9\u8c61\u7c7b\u578b\u3002\u548c\u5176\u4ed6\u5e03\u5c40\u4e00\u6837\uff0c\u5b83\u4eec\u662fViewGroup\u7684\u5b50\u7c7b\u3002\u53e6\u8bf7\u53c2\u9605\u201cHello Views\u201d\u6559\u7a0b\u4ee5\u83b7\u53d6\u4f7f\u7528Android View\u5e03\u5c40\u7684\u66f4\u591a\u6307\u5bfc\u3002<\/p>\n<h2>FrameLayout<\/h2>\n<p>FrameLayout\u662f\u6700\u4e3a\u7b80\u5355\u7684\u5e03\u5c40\u5bf9\u8c61\u7c7b\u578b\u3002\u7b80\u5355\u8bf4\u5b83\u662f\u5c4f\u5e55\u4e0a\u7684\u4e00\u5757\u7a7a\u767d\u7a7a\u95f4\uff0c\u4e4b\u540e\u53ef\u4ee5\u5728\u5176\u4e2d\u586b\u5145\u5355\u4e2a\u5bf9\u8c61\u2014\u2014\u4f8b\u5982\uff0c\u4e00\u5f20\u9700\u8981\u8bfb\u53d6\u7684\u56fe\u7247\u3002\u6240\u6709FrameLayout\u7684\u5b50\u5143\u7d20\u4f4d\u4e8e\u5c4f\u5e55\u7684\u5de6\u4e0a\u89d2\uff1b\u4e0d\u80fd\u4e3a\u5b50\u89c6\u56fe\u6307\u5b9a\u53e6\u5916\u7684\u4f4d\u7f6e\u3002\u540e\u7ee7\u7684\u5b50\u89c6\u56fe\u5c06\u7b80\u5355\u5730\u8986\u76d6\u4e4b\u524d\u7684\u89c6\u56fe\uff0c\u90e8\u5206\u6216\u662f\u5b8c\u5168\u906e\u4f4f\u5b83\u4eec\uff08\u9664\u975e\u65b0\u7684\u90a3\u4e2a\u5bf9\u8c61\u662f\u900f\u660e\u7684\uff09\u3002<\/p>\n<h2>LinearLayout<\/h2>\n<p>LinearLayout\u6839\u636e\u5728<span style=\"color: #008000;\">orientation<\/span>\u5c5e\u6027\u4e2d\u6240\u5b9a\u4e49\u7684\uff0c\u6cbf\u7740\u5355\u4e00\u65b9\u5411\u2014\u2014\u6c34\u5e73\u6216\u662f\u5782\u76f4\u2014\u2014\u6392\u5217\u5b50\u89c6\u56fe\u3002\u6240\u6709\u7684\u5b50\u89c6\u56fe\u4e00\u4e2a\u63a5\u4e00\u4e2a\u5806\u780c\uff0c\u56e0\u6b64\u4e00\u4e2a\u5782\u76f4\u5217\u8868\u4e2d\u65e0\u8bba\u5b50\u89c6\u56fe\u6709\u591a\u5bbd\uff0c\u6bcf\u4e00\u884c\u90fd\u53ea\u6709\u4e00\u4e2a\u5b50\u89c6\u56fe\u3002\u800c\u4e00\u4e2a\u6c34\u5e73\u5217\u8868\u9ad8\u5ea6\u53ea\u6709\u4e00\u884c\uff08\u6700\u9ad8\u7684\u5b50\u89c6\u56fe\u7684\u9ad8\u5ea6\u52a0\u4e0a\u95f4\u9699\uff09\u3002LinearLayout\u80fd\u663e\u793a\u6bcf\u4e00\u4e2a\u5b50\u89c6\u56fe\u4e4b\u95f4\u7684\u8fb9\u8ddd\u548c\u91cd\u529b\uff08\u53f3\u4fa7\u3001\u4e2d\u5fc3\u6216\u5de6\u4fa7\uff09\u3002<\/p>\n<p>LinearLayout\u8fd8\u652f\u6301\u4e3a\u5176\u5355\u72ec\u7684\u5b50\u5143\u7d20\u8bbe\u5b9a\u6743\u91cd\uff08weight\uff09\u3002\u8be5\u5c5e\u6027\u7ed9\u89c6\u56fe\u8bbe\u5b9a\u4e86\u201c\u91cd\u8981\u6027\u201d\u3002\u5141\u8bb8\u5176\u6269\u5c55\u586b\u5145\u7236\u89c6\u56fe\u4e2d\u7684\u4efb\u610f\u5269\u4f59\u7a7a\u95f4\u3002\u5b50\u89c6\u56fe\u53ef\u4ee5\u6307\u5b9a\u4e00\u4e2a\u6574\u578b\u6743\u91cd\u503c\uff0c\u4e4b\u540e\u89c6\u56fe\u7ec4\u4e2d\u7684\u5269\u4f59\u7a7a\u95f4\u4f1a\u6309\u5b50\u89c6\u56fe\u6240\u58f0\u660e\u7684\u6743\u91cd\u6bd4\u6765\u5206\u914d\u3002\u9ed8\u8ba4\u6743\u91cd\u662f\u96f6\u3002\u4f8b\u5982\uff0c\u5982\u679c\u6709\u4e09\u4e2a\u6587\u672c\u6846\uff0c\u5176\u4e2d\u4e24\u4e2a\u7684\u6743\u91cd\u88ab\u58f0\u660e\u4e3a1\uff0c\u53e6\u4e00\u4e2a\u6ca1\u6709\u6743\u91cd\uff080\uff09\uff0c\u90a3\u4e48\u8fd9\u4e2a\u6ca1\u6709\u6743\u91cd\u7684\u6587\u672c\u6846\u4e0d\u4f1a\u6269\u5c55\uff0c\u53ea\u4f1a\u5360\u5b83\u5185\u5bb9\u6240\u9700\u7684\u7a7a\u95f4\u3002\u53e6\u4e24\u4e2a\u4f1a\u6309\u76f8\u540c\u6bd4\u4f8b\u6269\u5c55\uff0c\u5145\u6ee1\u4e09\u4e2a\u6587\u672c\u6846\u88ab\u8ba1\u7b97\u540e\u6240\u5269\u4f59\u7684\u7a7a\u95f4\u3002\u5982\u679c\u7b2c\u4e09\u4e2a\u6587\u672c\u6846\u6743\u91cd\u4e3a2\uff08\u800c\u4e0d\u662f0\uff09\uff0c\u90a3\u5b83\u5c31\u88ab\u58f0\u660e\u4e3a\u6bd4\u5176\u4ed6\u4e24\u4e2a\u201d\u66f4\u4e3a\u91cd\u8981\u201c\uff0c\u800c\u83b7\u5f97\u603b\u5269\u4f59\u7a7a\u95f4\u7684\u4e00\u534a\uff0c\u53e6\u4e24\u4e2a\u5219\u662f\u5e73\u5206\u53e6\u4e00\u534a\u3002<\/p>\n<p>\u4e0b\u9762\u7684\u4e24\u79cd\u5f62\u5f0f\u4ee3\u8868\u4e86\u542b\u6709\u4e00\u7ec4\u5143\u7d20\u7684LinearLayout\uff1a\u4e00\u4e2a\u6309\u94ae\u3001\u4e00\u4e9b\u6807\u7b7e\u548c\u4e00\u4e9b\u6587\u672c\u6846\u3002\u6587\u672c\u6846\u7684\u5bbd\u5ea6\u8bbe\u7f6e\u4e3a<span style=\"color: #008000;\">fill_parent<\/span>\uff1b\u5176\u4ed6\u5143\u7d20\u8bbe\u7f6e\u4e3a<span style=\"color: #008000;\">wrap_content<\/span>\u3002\u91cd\u529b\uff08gravity\uff09\u9ed8\u8ba4\u662f\u5411\u5de6\uff08left\uff09\u3002\u4e24\u4e2a\u7248\u672c\u54e6\u5dee\u5f02\u5728\u4e8e\u5de6\u8fb9\u7684\u6ca1\u6709\u8bbe\u7f6e\u6743\u91cd\uff08\u9ed8\u8ba4\u4e3a\u96f6\uff09\uff0c\u53f3\u8fb9\u7684\u4e00\u4e2a\u6587\u672c\u6846\u7684\u6743\u91cd\u88ab\u8bbe\u4e3a\u4e861\u3002\u5982\u679cName\u6587\u672c\u6846\u4e5f\u88ab\u8bbe\u4e3a\u4e861\u7684\u8bdd\uff0cName\u548cComments\u6587\u672c\u6846\u5219\u4f1a\u4e00\u6837\u9ad8\u3002<\/p>\n<p style=\"text-align: center;\">&nbsp;<\/p>\n<figure id=\"attachment_414\" aria-describedby=\"caption-attachment-414\" style=\"width: 300px\" class=\"wp-caption aligncenter\"><a href=\"http:\/\/leybreeze.com\/blog\/wp-content\/uploads\/2011\/03\/linearlayout.png\"><img loading=\"lazy\" decoding=\"async\" class=\"size-medium wp-image-414 \" title=\"linearlayout\" src=\"http:\/\/leybreeze.com\/blog\/wp-content\/uploads\/2011\/03\/linearlayout-300x213.png\" alt=\"linearlayout\" width=\"300\" height=\"213\" srcset=\"http:\/\/leybreeze.com\/blog\/wp-content\/uploads\/2011\/03\/linearlayout-300x213.png 300w, http:\/\/leybreeze.com\/blog\/wp-content\/uploads\/2011\/03\/linearlayout.png 421w\" sizes=\"(max-width: 300px) 85vw, 300px\" \/><\/a><figcaption id=\"caption-attachment-414\" class=\"wp-caption-text\">linearlayout<\/figcaption><\/figure>\n<p style=\"padding-left: 30px;\"><strong>Tip<\/strong>\uff1a\u4e3a\u4e86\u5728\u5c4f\u5e55\u4e0a\u521b\u5efa\u6bd4\u4f8b\u5408\u9002\u7684\u5e03\u5c40\uff0c\u53ef\u4ee5\u521b\u5efa\u4e00\u4e2a\u5bb9\u5668\u89c6\u56fe\u7ec4\uff0c<span style=\"color: #008000;\">layout_width<\/span>\u548c<span style=\"color: #008000;\">layout_height<\/span>\u5c5e\u6027\u8bbe\u4e3a<span style=\"color: #008000;\">fill_parent<\/span>\uff1b\u8bbe\u7f6e\u5b50\u89c6\u56fe\u7684\u9ad8\u548c\u5bbd\u4e3a<span style=\"color: #008000;\">0<\/span>\uff1b\u6839\u636e\u6240\u5e0c\u671b\u7684\u5c4f\u5e55\u6bd4\u4f8b\u8bbe\u7f6e\u6bcf\u4e00\u4e2a\u5b50\u89c6\u56fe\u7684\u76f8\u5bf9\u6743\u91cd\uff08<span style=\"color: #008000;\">weight<\/span>\uff09\u3002<\/p>\n<p>\u5728\u4e00\u4e2a\u6c34\u5e73LinearLayout\u4e2d\uff0c\u9879\u76ee\u6839\u636e\u5176\u6587\u672c\u57fa\u51c6\u7ebf\u7684\u4f4d\u7f6e\u6392\u5217\uff08\u6700\u4e0a\u90e8\u6216\u6700\u5de6\u4fa7\u7684\u7b2c\u4e00\u4e2a\u5143\u7d20\u7684\u7b2c\u4e00\u6761\u7ebf\u88ab\u8ba4\u4e3a\u662f\u53c2\u8003\u7ebf\uff09\u3002\u8fd9\u6837\u5728\u6d4f\u89c8\u5143\u7d20\u65f6\u5c31\u4e0d\u5fc5\u4e0a\u4e0b\u79fb\u52a8\u89c6\u7ebf\u4ee5\u9605\u8bfb\u76f8\u90bb\u5143\u7d20\u7684\u5143\u7d20\u6587\u672c\u4e86\u3002\u53ef\u4ee5\u901a\u8fc7\u5728\u5e03\u5c40XML\u4e2d\u8bbe\u7f6e<span style=\"color: #008000;\">android:baselineAligned=&#8221;false&#8221;<\/span>\u6765\u5173\u95ed\u8fd9\u4e00\u529f\u80fd\u3002<\/p>\n<p>\u8981\u67e5\u770b\u5176\u4ed6\u7684\u8303\u4f8b\u4ee3\u7801\uff0c\u8bf7\u53c2\u9605\u201cHello LinearLayout\u201d\u6559\u7a0b\u3002<\/p>\n<h2>TableLayout<\/h2>\n<p>TableLayout\u5c06\u5176\u5b50\u89c6\u56fe\u6309\u884c\u3001\u5217\u6392\u5217\u3002TableLayout\u5bb9\u5668\u4e0d\u663e\u793a\u5176\u884c\u3001\u5217\u6216\u5355\u5143\u683c\u7684\u8fb9\u7ebf\u3002\u8868\u683c\u7684\u5217\u6570\u548c\u62e5\u6709\u5355\u5143\u683c\u6700\u591a\u7684\u90a3\u884c\u76f8\u540c\u3002\u4e00\u5f20\u8868\u683c\u53ef\u4ee5\u6709\u7a7a\u5355\u5143\u683c\uff0c\u4e0d\u8fc7\u5355\u5143\u683c\u65e0\u6cd5\u8de8\u8d8a\u5217\uff0c\u5c31\u50cfHTML\u4e2d\u4e00\u6837\u3002<\/p>\n<p>TableRow\u5bf9\u8c61\u662fTableLayout\u7684\u5b50\u89c6\u56fe\uff08\u6bcf\u4e00\u4e2aTableRow\u5b9a\u4e49\u4e86\u8868\u4e2d\u5355\u72ec\u7684\u4e00\u884c\uff09\u3002\u6bcf\u4e00\u884c\u6709\u96f6\u4e2a\u6216\u66f4\u591a\u7684\u5355\u5143\u683c\uff0c\u5176\u6bcf\u4e00\u4e2a\u53ef\u4ee5\u88ab\u5176\u4ed6\u7c7b\u578b\u7684\u89c6\u56fe\u6240\u5b9a\u4e49\u3002\u56e0\u6b64\uff0c\u4e00\u884c\u5355\u5143\u683c\u53ef\u80fd\u662f\u7531\u591a\u79cdView\u5bf9\u8c61\uff0c\u6bd4\u5982ImageView\u6216TextView\uff0c\u6784\u6210\u7684\u3002\u4e00\u4e2a\u5355\u5143\u683c\u4e5f\u53ef\u4ee5\u662f\u4e00\u4e2aViewGroup\u5bf9\u8c61\uff08\u4f8b\u5982\uff0c\u53ef\u4ee5\u628a\u53e6\u4e00\u4e2aTableLayout\u5d4c\u5957\u4e8e\u4e00\u4e2a\u5355\u5143\u683c\u5185\uff09\u3002<\/p>\n<p>\u4e0b\u9762\u7684\u8303\u4f8b\u5e03\u5c40\u6709\u4e24\u884c\uff0c\u6bcf\u884c\u6709\u4e24\u4e2a\u5355\u5143\u683c\u3002\u76f8\u5e94\u7684\u622a\u56fe\u663e\u793a\u4e86\u5176\u7ed3\u679c\uff0c\u5355\u5143\u683c\u8fb9\u754c\u4ee5\u70b9\u7ebf\u663e\u793a\uff08\u4f5c\u4e3a\u89c6\u89c9\u6548\u679c\u800c\u6dfb\u52a0\uff09\u3002<a href=\"http:\/\/leybreeze.com\/blog\/wp-content\/uploads\/2011\/03\/table_layout.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-439\" title=\"table_layout\" src=\"http:\/\/leybreeze.com\/blog\/wp-content\/uploads\/2011\/03\/table_layout.png\" alt=\"\" width=\"320\" height=\"191\" srcset=\"http:\/\/leybreeze.com\/blog\/wp-content\/uploads\/2011\/03\/table_layout.png 320w, http:\/\/leybreeze.com\/blog\/wp-content\/uploads\/2011\/03\/table_layout-300x179.png 300w\" sizes=\"(max-width: 320px) 85vw, 320px\" \/><\/a><\/p>\n<pre><span style=\"color: #000000;\">&lt;?xml version=<span style=\"color: #008000;\">\"1.0\"<\/span> encoding=<span style=\"color: #008000;\">\"utf-8\"<\/span>?&gt;<\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #000080;\">&lt;TableLayout<\/span> <span style=\"color: #800080;\">xmlns:android<\/span>=<span style=\"color: #008000;\">\"http:\/\/schemas.android.com\/apk\/res\/android\"<\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 android:layout_width<\/span>=<span style=\"color: #008000;\">\"fill_parent\"<\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 android:layout_height<\/span>=<span style=\"color: #008000;\">\"fill_parent\"<\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 android:stretchColumns<\/span>=<span style=\"color: #008000;\">\"1\"<\/span><span style=\"color: #000080;\">&gt;<\/span><\/span>\r\n<span style=\"color: #000080;\">\u00a0 \u00a0 &lt;TableRow&gt;<\/span>\r\n<span style=\"color: #000080;\">\u00a0 \u00a0 \u00a0 \u00a0 &lt;TextView<\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:text<\/span>=<span style=\"color: #008000;\">\"@string\/table_layout_4_open\"<\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:padding<\/span>=<span style=\"color: #008000;\">\"3dip\" <\/span><span style=\"color: #000080;\">\/&gt;<\/span><\/span>\r\n<span style=\"color: #000080;\">\u00a0 \u00a0 \u00a0 \u00a0 &lt;TextView<\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:text<\/span>=<span style=\"color: #008000;\">\"@string\/table_layout_4_open_shortcut\"<\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:gravity<\/span>=<span style=\"color: #008000;\">\"right\"<\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:padding<\/span>=<span style=\"color: #008000;\">\"3dip\"<\/span> <span style=\"color: #000080;\">\/&gt;<\/span><\/span>\r\n<span style=\"color: #000080;\">\u00a0 \u00a0 &lt;\/TableRow&gt;<\/span>\r\n\r\n<span style=\"color: #000080;\">\u00a0 \u00a0 &lt;TableRow&gt;<\/span>\r\n<span style=\"color: #000080;\">\u00a0 \u00a0 \u00a0 \u00a0 &lt;TextView<\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:text<\/span>=<span style=\"color: #008000;\">\"@string\/table_layout_4_save\"<\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:padding<\/span>=<span style=\"color: #008000;\">\"3dip\" <\/span><span style=\"color: #000080;\">\/&gt;<\/span><\/span>\r\n<span style=\"color: #000080;\">\u00a0 \u00a0 \u00a0 \u00a0 &lt;TextView<\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:text<\/span>=<span style=\"color: #008000;\">\"@string\/table_layout_4_save_shortcut\"<\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:gravity<\/span>=<span style=\"color: #008000;\">\"right\"<\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:padding<\/span>=<span style=\"color: #008000;\">\"3dip\"<\/span> <span style=\"color: #000080;\">\/&gt;<\/span><\/span>\r\n<span style=\"color: #000080;\">\u00a0 \u00a0 &lt;\/TableRow&gt;<\/span>\r\n<span style=\"color: #000080;\">&lt;\/TableLayout&gt;<\/span><\/pre>\n<p>\u53ef\u4ee5\u5c06\u7ad6\u680f\u9690\u85cf\u3001\u62c9\u4f38\u586b\u5145\u5c4f\u5e55\u6216\u662f\u6807\u8bb0\u4e3a\u53ef\u7f29\u5c0f\u7684\u4ee5\u5f3a\u5236\u7f29\u5c0f\u8868\u683c\u9002\u5e94\u5c4f\u5e55\u3002\u53c2\u89c1TableLayout\u53c2\u8003\u6587\u6863\u4ee5\u4e86\u89e3\u66f4\u591a\u7ec6\u8282\u3002<\/p>\n<p>\u53c2\u89c1\u201cHello TableLayout\u201d\u6559\u7a0b\u4ee5\u67e5\u770b\u8303\u4f8b\u4ee3\u7801\u3002<\/p>\n<h2>RelativeLayout<\/h2>\n<p>RelativeLayout\u5141\u8bb8\u5b50\u89c6\u56fe\u6307\u5b9a\u5b83\u4eec\u76f8\u5bf9\u4e8e\u7236\u89c6\u56fe\u7684\u4f4d\u7f6e\u6216\u5b83\u4eec\u4e4b\u95f4\u7684\u76f8\u4e92\u4f4d\u7f6e\uff08\u901a\u8fc7ID\u6765\u6307\u5b9a\uff09\u3002\u56e0\u6b64\u53ef\u4ee5\u5c06\u4e24\u4e2a\u5143\u7d20\u9760\u7740\u53f3\u4fa7\u8fb9\u7f18\u6392\u5217\uff0c\u6216\u662f\u4e8e\u5c4f\u5e55\u4e2d\u5fc3\u3001\u6216\u504f\u5de6\u4fa7\u4e0a\u4e0b\u6392\u5217\uff0c\u6216\u662f\u5176\u4ed6\u6392\u5217\u65b9\u5f0f\u3002\u5143\u7d20\u5c06\u6309\u6307\u5b9a\u7684\u65b9\u5f0f\u6392\u5217\uff0c\u56e0\u6b64\u5982\u679c\u7b2c\u4e00\u4e2a\u5143\u7d20\u4f4d\u4e8e\u5c4f\u5e55\u4e2d\u592e\uff0c\u5176\u4ed6\u548c\u8be5\u5143\u7d20\u76f8\u5173\u7684\u5143\u7d20\u4e5f\u4f1a\u76f8\u5bf9\u4e8e\u5c4f\u5e55\u4e2d\u592e\u8fdb\u884c\u6392\u5217\u3002\u540c\u65f6\uff0c\u7531\u4e8e\u6709\u8fd9\u6837\u7684\u987a\u5e8f\uff0c\u5982\u679c\u662f\u901a\u8fc7XML\u6307\u5b9a\u8fd9\u79cd\u89c6\u56fe\u7684\u8bdd\uff0c\u8981\u5f15\u7528\u7684\u5143\u7d20\uff08\u4e3a\u4e86\u80fd\u5b9a\u4f4d\u5176\u4ed6\u7684\u89c6\u56fe\u5bf9\u8c61\uff09\u5fc5\u987b\u5728\u5728\u5176\u4ed6\u89c6\u56fe\u5f15\u7528\u5176ID\u4e4b\u524d\u5c31\u88ab\u5217\u4e8eXML\u6587\u4ef6\u4e4b\u4e2d\u3002<\/p>\n<p>\u4e0b\u9762\u7684\u4f8b\u5b50\u5c55\u793a\u4e86\u4e00\u4e2aXML\u6587\u4ef6\u53ca\u5176\u5c4f\u5e55\u754c\u9762\u7684\u663e\u793a\u7ed3\u679c\u3002\u9700\u8981\u6ce8\u610f\uff0c\u5f15\u7528\u4e86\u76f8\u5bf9\u5143\u7d20\u7684\u90a3\u4e9b\u5c5e\u6027\uff08\u6bd4\u5982\uff0c<span style=\"color: #008000;\">layout_toLeft<\/span>\uff09\u662f\u901a\u8fc7\u76f8\u5bf9\u8d44\u6e90\uff08<span style=\"color: #008000;\">@id\/id<\/span>\uff09\u7684\u8bed\u6cd5\u6765\u5f15\u7528\u5176ID\u7684\u3002<\/p>\n<pre><span style=\"color: #000000;\">&lt;?xml version=<span style=\"color: #008000;\">\"1.0\"<\/span> encoding=\"<span style=\"color: #008000;\">utf-8\"<\/span>?&gt;<\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #000080;\">&lt;RelativeLayout<\/span> <span style=\"color: #800080;\">xmlns:android<\/span>=<span style=\"color: #008000;\">\"http:\/\/schemas.android.com\/apk\/res\/android\"<\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:layout_width<\/span>=<span style=\"color: #008000;\">\"fill_parent\" <\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:layout_height<\/span>=<span style=\"color: #008000;\">\"wrap_content\"<\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:background<\/span>=<span style=\"color: #008000;\">\"@drawable\/blue\"<\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:padding<\/span>=<span style=\"color: #008000;\">\"10px\"<\/span> <span style=\"color: #000080;\">&gt;<\/span><\/span>\r\n\r\n<span style=\"color: #000000;\"><span style=\"color: #000080;\">\u00a0 \u00a0 &lt;TextView<\/span> <span style=\"color: #800080;\">android:i<\/span>d=<span style=\"color: #008000;\">\"@+id\/label\" <\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:layout_width<\/span>=<span style=\"color: #008000;\">\"fill_parent\" <\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:layout_height<\/span>=<span style=\"color: #008000;\">\"wrap_content\" <\/span><\/span>\r\n<span style=\"color: #000000;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:text=<span style=\"color: #008000;\">\"Type here:\"<\/span> <span style=\"color: #000080;\">\/&gt;<\/span><\/span>\r\n\r\n<span style=\"color: #000000;\"><span style=\"color: #000080;\">\u00a0 \u00a0 &lt;EditText<\/span> <span style=\"color: #800080;\">android:id<\/span>=<span style=\"color: #008000;\">\"@+id\/entry\" <\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:layout_width<\/span>=<span style=\"color: #008000;\">\"fill_parent\" <\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:layout_height<\/span>=<span style=\"color: #008000;\">\"wrap_content\" <\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:background<\/span>=<span style=\"color: #008000;\">\"@android:drawable\/editbox_background\"<\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:layout_below<\/span>=<span style=\"color: #008000;\">\"@id\/label\" <\/span><span style=\"color: #000080;\">\/&gt;<\/span><\/span>\r\n\r\n<span style=\"color: #000000;\"><span style=\"color: #000080;\">\u00a0 \u00a0 &lt;Button<\/span> <span style=\"color: #800080;\">android:id<\/span>=<span style=\"color: #008000;\">\"@+id\/ok\" <\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:layout_width<\/span>=<span style=\"color: #008000;\">\"wrap_content\" <\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:layout_height<\/span>=<span style=\"color: #008000;\">\"wrap_content\" <\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:layout_below<\/span>=<span style=\"color: #008000;\">\"@id\/entry\"<\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:layout_alignParentRight<\/span>=<span style=\"color: #008000;\">\"true\"<\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:layout_marginLeft<\/span>=<span style=\"color: #008000;\">\"10px\"<\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:text<\/span>=<span style=\"color: #008000;\">\"OK\"<\/span> <span style=\"color: #000080;\">\/&gt;<\/span><\/span>\r\n\r\n<span style=\"color: #000000;\"><span style=\"color: #000080;\">\u00a0 \u00a0 &lt;Button<\/span> <span style=\"color: #800080;\">android:layout_width<\/span>=<span style=\"color: #008000;\">\"wrap_content\" <\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:layout_height<\/span>=<span style=\"color: #008000;\">\"wrap_content\"<\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:layout_toLeftOf<\/span>=<span style=\"color: #008000;\">\"@id\/ok\"<\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:layout_alignTop<\/span>=<span style=\"color: #008000;\">\"@id\/ok\"<\/span><\/span>\r\n<span style=\"color: #000000;\"><span style=\"color: #800080;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 android:text<\/span>=<span style=\"color: #008000;\">\"Cancel\"<\/span> <span style=\"color: #000080;\">\/&gt;<\/span><\/span><span style=\"color: #000080;\">\r\n&lt;\/RelativeLayout&gt;<\/span><\/pre>\n<p><a href=\"http:\/\/leybreeze.com\/blog\/wp-content\/uploads\/2011\/03\/designing_ui_layout_example.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-444\" title=\"designing_ui_layout_example\" src=\"http:\/\/leybreeze.com\/blog\/wp-content\/uploads\/2011\/03\/designing_ui_layout_example.png\" alt=\"\" width=\"320\" height=\"191\" srcset=\"http:\/\/leybreeze.com\/blog\/wp-content\/uploads\/2011\/03\/designing_ui_layout_example.png 320w, http:\/\/leybreeze.com\/blog\/wp-content\/uploads\/2011\/03\/designing_ui_layout_example-300x179.png 300w\" sizes=\"(max-width: 320px) 85vw, 320px\" \/><\/a><\/p>\n<p>\u8fd9\u4e9b\u5c5e\u6027\u4e2d\u7684\u4e00\u90e8\u5206\u76f4\u63a5\u88ab\u5143\u7d20\u6240\u652f\u6301\uff0c\u53e6\u4e00\u4e9b\u5219\u88ab\u5176LayoutParams\u6210\u5458\uff08RelativeLayout\u5bf9\u4e8e\u5c4f\u5e55\u4e0a\u6240\u6709\u5143\u7d20\u7684\u5b50\u7c7b\uff0c\u8fd9\u662f\u56e0\u4e3a\u6240\u6709\u5143\u7d20\u90fd\u662fRelativeLayout\u7236\u5bf9\u8c61\u7684\u5b50\u5bf9\u8c61\uff09\u6240\u652f\u6301\u3002\u6240\u5b9a\u4e49\u7684RelativeLayout\u53c2\u6570\u6709\uff1a<span style=\"color: #008000;\">width<\/span>\u3001<span style=\"color: #008000;\">height<\/span>\u3001<span style=\"color: #008000;\">below<\/span>\u3001<span style=\"color: #008000;\">alignTop<\/span>\u3001<span style=\"color: #008000;\">toLeft<\/span>\u3001<span style=\"color: #008000;\">padding[Bottom|Left|Right|Top]<\/span>\u548c<span style=\"color: #008000;\">margin[Bottom|Left|Right|Top]<\/span>\u3002\u6ce8\u610f\uff0c\u5176\u4e2d\u4e00\u4e9b\u53c2\u6570\u662f\u7528\u4e8e\u6307\u5b9a\u76f8\u5bf9\u5e03\u5c40\u4f4d\u7f6e\u2014\u2014\u5b83\u4eec\u7684\u503c\u5fc5\u987b\u662f\u5e0c\u671b\u4f5c\u4e3a\u76f8\u5bf9\u89c6\u56fe\u57fa\u51c6\u7684\u5143\u7d20\u7684ID\u3002\u4f8b\u5982\uff0c\u8bbe\u7f6e\u53c2\u6570<span style=\"color: #008000;\">toLeft=&#8221;my_botton&#8221;<\/span>\u81f3\u4e00\u4e2aTextView\u5c06\u628a\u8be5TextView\u653e\u5728ID\u4e3a<em><span style=\"color: #008000;\">my_button<\/span><\/em>\u7684\u5143\u7d20\uff08\u6bd4\u5982\u5728XML\u4e2d\u5148\u4e8eTextView\u51fa\u73b0\uff09\u7684\u5de6\u4fa7\u3002<\/p>\n<p>\u8981\u67e5\u770b\u8be5\u8303\u4f8b\u4ee3\u7801\uff0c\u8bf7\u53c2\u89c1\u201cHello RelativeLayout\u201d\u6559\u7a0b\u3002<\/p>\n<h2>\u91cd\u8981\u89c6\u56fe\u7ec4\u7684\u603b\u7ed3<\/h2>\n<p>\u8fd9\u4e9b\u5bf9\u8c61\u90fd\u6709\u5b50UI\u5143\u7d20\u3002\u4e00\u4e9b\u63d0\u4f9b\u4e86\u53ef\u89c1\u7684\u754c\u9762\u81ea\u6709\u5f62\u5f0f\uff0c\u53e6\u4e00\u4e9b\u5219\u662f\u4e0d\u53ef\u89c1\u7684\u7ed3\u6784\uff0c\u53ea\u80fd\u7528\u4e8e\u7ba1\u7406\u5176\u5b50\u89c6\u56fe\u3002<\/p>\n<table border=\"1\" width=\"100%\">\n<tbody>\n<tr>\n<th scope=\"col\">\u7c7b<\/th>\n<th scope=\"col\">\u63cf\u8ff0<\/th>\n<\/tr>\n<tr>\n<td><code><a href=\"http:\/\/developer.android.com\/reference\/android\/widget\/FrameLayout.html\">FrameLayout<\/a><\/code><\/td>\n<td>\u7528\u4e8e\u663e\u793a\u5355\u4e2a\u5bf9\u8c61\u7684\u89c6\u56fe\u6846\u67b6\u5e03\u5c40\u3002<\/td>\n<\/tr>\n<tr>\n<td><code><a href=\"http:\/\/developer.android.com\/reference\/android\/widget\/Gallery.html\">Gallery<\/a><\/code><\/td>\n<td>\u4e00\u4e2a\u53ef\u6c34\u5e73\u6eda\u52a8\u7684\u56fe\u50cf\u5217\u8868\u3002<\/td>\n<\/tr>\n<tr>\n<td><code><a href=\"http:\/\/developer.android.com\/reference\/android\/widget\/GridView.html\">GridView<\/a><\/code><\/td>\n<td>\u663e\u793am\u5217n\u884c\u53ef\u6eda\u52a8\u7684\u8868\u683c\u3002<\/td>\n<\/tr>\n<tr>\n<td><code><a href=\"http:\/\/developer.android.com\/reference\/android\/widget\/LinearLayout.html\">LinearLayout<\/a><\/code><\/td>\n<td>\u5c06\u5b50\u5143\u7d20\u6c34\u5e73\u6216\u662f\u5782\u76f4\u6392\u5217\u4e3a\u4e00\u884c\/\u5217\u7684\u5e03\u5c40\u3002\u5982\u679c\u89c6\u7a97\u957f\u5ea6\u8d85\u8fc7\u5c4f\u5e55\u957f\u5ea6\uff0c\u5c06\u4f1a\u81ea\u52a8\u521b\u5efa\u6eda\u52a8\u6761\u3002<\/td>\n<\/tr>\n<tr>\n<td><code><a href=\"http:\/\/developer.android.com\/reference\/android\/widget\/ListView.html\">ListView<\/a><\/code><\/td>\n<td>\u663e\u793a\u4e00\u5217\u6eda\u52a8\u5217\u8868\u3002<\/td>\n<\/tr>\n<tr>\n<td><code><a href=\"http:\/\/developer.android.com\/reference\/android\/widget\/RelativeLayout.html\">RelativeLayout<\/a><\/code><\/td>\n<td>\u5141\u8bb8\u6307\u5b9a\u5b50\u5bf9\u8c61\u76f8\u4e92\u4e4b\u95f4\u7684\u4f4d\u7f6e\uff08\u5982\uff1a\u5b50\u5bf9\u8c61A\u5728\u5b50\u5bf9\u8c61B\u7684\u5de6\u4fa7\uff09 \u6216\u4e0e\u7236\u5bf9\u8c61\u7684\u76f8\u5bf9\u4f4d\u7f6e\uff08\u5982\uff1a\u5728\u7236\u5bf9\u8c61\u7684\u4e0a\u90e8\uff09\u3002<\/td>\n<\/tr>\n<tr>\n<td><code><a href=\"http:\/\/developer.android.com\/reference\/android\/widget\/ScrollView.html\">ScrollView<\/a><\/code><\/td>\n<td>\u4e00\u5217\u5782\u76f4\u7684\u53ef\u6eda\u52a8\u5143\u7d20\u3002<\/td>\n<\/tr>\n<tr>\n<td><code><a href=\"http:\/\/developer.android.com\/reference\/android\/widget\/Spinner.html\">Spinner<\/a><\/code><\/td>\n<td>\u5728\u4e00\u4e2a\u5355\u884c\u6587\u672c\u6846\u4e2d\u663e\u793a\u6240\u7ed1\u5b9a\u5217\u8868\u7684\u5176\u4e2d\u4e00\u884c\u3002\u5c31\u50cf\u4e00\u4e2a\u5217\u8868\u6846\uff0c\u53ef\u4ee5\u6c34\u5e73\u6216\u662f\u5782\u76f4\u4e0b\u62c9\u3002<\/td>\n<\/tr>\n<tr>\n<td><code><a href=\"http:\/\/developer.android.com\/reference\/android\/view\/SurfaceView.html\">SurfaceView<\/a><\/code><\/td>\n<td>\u63d0\u4f9b\u6240\u6307\u5b9a\u7ed8\u56fe\u8868\u5c42\u7684\u76f4\u63a5\u8bfb\u53d6\u3002 \u5b83\u53ef\u4ee5\u6301\u6709\u4f4d\u4e8e\u5c4f\u5e55\u8868\u9762\u7684\u5b50\u5bf9\u8c61\uff0c\u4e0d\u8fc7\u5176\u5b9e\u662f\u4e3a\u5728\u5c4f\u5e55\u4e0a\u8fdb\u884c\u50cf\u7d20\u64cd\u4f5c\u800c\u975e\u4f7f\u7528\u63a7\u4ef6\u800c\u8bbe\u8ba1\u7684\u3002<\/td>\n<\/tr>\n<tr>\n<td><code><a href=\"http:\/\/developer.android.com\/reference\/android\/widget\/TabHost.html\">TabHost<\/a><\/code><\/td>\n<td>\u63d0\u4f9b\u4e86\u4e00\u4e2a\u6807\u7b7e\u9875\u9009\u62e9\u5668\uff0c\u901a\u8fc7\u76d1\u89c6\u70b9\u51fb\u884c\u4e3a\u4ee5\u5728\u6807\u7b7e\u88ab\u9009\u62e9\u65f6\u5207\u6362\u5c4f\u5e55\u5185\u5bb9\u3002<\/td>\n<\/tr>\n<tr>\n<td><code><a href=\"http:\/\/developer.android.com\/reference\/android\/widget\/TableLayout.html\">TableLayout<\/a><\/code><\/td>\n<td>\u4e00\u4e2a\u884c\u5217\u6570\u56fa\u5b9a\u7684\u8868\u683c\u5e03\u5c40\u3002\u6bcf\u4e00\u4e2a\u5355\u5143\u683c\u53ef\u4ee5\u6301\u6709\u4e00\u4e2a\u6240\u9009\u62e9\u7684\u63a7\u4ef6\u3002\u6bcf\u4e00\u884c\u4f1a\u81ea\u9002\u5e94\u6700\u5927\u7684\u5217\u6570\u3002\u5355\u5143\u683c\u7684\u8fb9\u754c\u662f\u4e0d\u53ef\u89c1\u7684\u3002<\/td>\n<\/tr>\n<tr>\n<td><code><a href=\"http:\/\/developer.android.com\/reference\/android\/widget\/ViewFlipper.html\">ViewFlipper<\/a><\/code><\/td>\n<td>\u5728\u4e00\u4e2a\u5355\u884c\u6587\u672c\u6846\u4e2d\u4e00\u6b21\u663e\u793a\u4e00\u4e2a\u9879\u76ee\u7684\u5217\u8868\u3002\u53ef\u4ee5\u8bbe\u7f6e\u5982\u540c\u5e7b\u706f\u7247\u4e00\u6837\u5728\u4e00\u5b9a\u65f6\u95f4\u95f4\u9694\u540e\u5207\u6362\u9879\u76ee\u3002<\/td>\n<\/tr>\n<tr>\n<td><code><a href=\"http:\/\/developer.android.com\/reference\/android\/widget\/ViewSwitcher.html\">ViewSwitcher<\/a><\/code><\/td>\n<td>\u548cViewFlipper\u76f8\u540c\u3002<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p><a title=\"\u7528\u6237\u754c\u9762\" href=\"http:\/\/leybreeze.com\/blog\/?p=117\">\u8fd4\u56de\u7528\u6237\u754c\u9762<\/a><\/p>\n<p>\u672c\u9875\u90e8\u5206\u5185\u5bb9\u6839\u636e<a title=\"Android Open Source Projec\" href=\"http:\/\/code.google.com\/intl\/zh-CN\/policies.html\" target=\"_blank\">Android Open Source Project<\/a>\u521b\u4f5c\u5e76\u5171\u4eab\u7684\u5185\u5bb9\u4fee\u6539\uff0c\u5e76\u5728<a title=\"\u77e5\u8bc6\u5171\u4eab \u7f72\u540d2.5\u8bb8\u53ef\u534f\u8bae\" href=\"http:\/\/creativecommons.org\/licenses\/by\/2.5\/\" target=\"_blank\">\u77e5\u8bc6\u5171\u4eab \u7f72\u540d2.5\u8bb8\u53ef\u534f\u8bae<\/a>\u4e2d\u6240\u8ff0\u6761\u6b3e\u7684\u9650\u5236\u4e0b\u4f7f\u7528\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u8fd9\u4e00\u8282\u5c06\u63cf\u8ff0\u4e00\u4e9b\u5728\u7a0b\u5e8f\u4e2d\u8f83\u4e3a\u5e38\u7528\u7684\u5e03\u5c40\u5bf9\u8c61\u7c7b\u578b\u3002\u548c\u5176\u4ed6\u5e03\u5c40\u4e00\u6837\uff0c\u5b83\u4eec\u662fViewGroup\u7684\u5b50\u7c7b\u3002\u53e6\u8bf7\u53c2\u9605\u201cHe &hellip; <a href=\"http:\/\/leybreeze.com\/blog\/?p=398\" class=\"more-link\">\u7ee7\u7eed\u9605\u8bfb<span class=\"screen-reader-text\">\u201c\u5e38\u89c1\u5e03\u5c40\u5bf9\u8c61\u201d<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[6,10],"tags":[5,44,17],"_links":{"self":[{"href":"http:\/\/leybreeze.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/398"}],"collection":[{"href":"http:\/\/leybreeze.com\/blog\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/leybreeze.com\/blog\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/leybreeze.com\/blog\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/leybreeze.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=398"}],"version-history":[{"count":10,"href":"http:\/\/leybreeze.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/398\/revisions"}],"predecessor-version":[{"id":401,"href":"http:\/\/leybreeze.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/398\/revisions\/401"}],"wp:attachment":[{"href":"http:\/\/leybreeze.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=398"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/leybreeze.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=398"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/leybreeze.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=398"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}