公告:凡是在
2025 年 4 月 15 日前註冊使用 Earth Engine 的非商業專案,都必須
驗證非商業用途資格,才能繼續存取 Earth Engine。
ui.Panel
透過集合功能整理內容
你可以依據偏好儲存及分類內容。
可容納其他小工具的小工具。使用面板建構巢狀小工具的複雜組合。
面板可以新增至 ui.root,但無法使用 print() 列印至控制台。
用量 | 傳回 |
---|
ui.Panel(widgets, layout, style) | ui.Panel |
引數 | 類型 | 詳細資料 |
---|
widgets | List<ui.Widget>|ui.Widget,選用 | 要新增至面板的小工具清單或單一小工具。預設為空陣列。 |
layout | String|ui.Panel.Layout,選用 | 這個面板要使用的版面配置。如果傳入字串,系統會將其視為該名稱的版面配置建構函式捷徑。預設值為「flow」。 |
style | 物件 (選用) | 允許的 CSS 樣式物件,以及要為這個小工具設定的值。請參閱 style() 說明文件。 |
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權,程式碼範例則為阿帕契 2.0 授權。詳情請參閱《Google Developers 網站政策》。Java 是 Oracle 和/或其關聯企業的註冊商標。
上次更新時間:2025-07-25 (世界標準時間)。
[null,null,["上次更新時間:2025-07-25 (世界標準時間)。"],[[["\u003cp\u003ePanels are widgets that can contain other widgets, enabling complex nested layouts within Earth Engine applications.\u003c/p\u003e\n"],["\u003cp\u003eThey are added to the \u003ccode\u003eui.root\u003c/code\u003e but cannot be printed to the console using \u003ccode\u003eprint()\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003ePanel layouts can be customized using predefined options or by specifying CSS styles.\u003c/p\u003e\n"],["\u003cp\u003eInitialization involves providing a list of widgets (or a single widget), a layout type, and optional styling.\u003c/p\u003e\n"]]],["Panels, which are widgets that can contain other widgets, are created using `ui.Panel()`. They accept an optional list of `widgets`, a `layout` (defaulting to 'flow'), and a `style` object for CSS styling. Panels can be added to `ui.root` but cannot be printed using `print()`. The `layout` argument can be a string representing a shortcut to a layout constructor. Panels facilitate the construction of complex, nested widget structures.\n"],null,["# ui.Panel\n\n\u003cbr /\u003e\n\nA widget that can hold other widgets. Use panels to construct complex combinations of nested widgets.\n\n\u003cbr /\u003e\n\nPanels can be added to ui.root but not printed to the console with print().\n\n| Usage | Returns |\n|--------------------------------------------------|----------|\n| `ui.Panel(`*widgets* `, `*layout* `, `*style*`)` | ui.Panel |\n\n| Argument | Type | Details |\n|-----------|----------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------|\n| `widgets` | List\\\u003cui.Widget\\\u003e\\|ui.Widget, optional | The list of widgets or a single widget to add to the panel. Defaults to an empty array. |\n| `layout` | String\\|ui.Panel.Layout, optional | The layout to use for this panel. If a string is passed in, it's taken as a shortcut to the layout constructor with that name. Defaults to 'flow'. |\n| `style` | Object, optional | An object of allowed CSS styles with their values to be set for this widget. See style() documentation. |"]]