「App:Library:LVGL:docs:Widgets:Container (lv cont)」の版間の差分
19行目: | 19行目: | ||
|- | |- | ||
|The containers has only a main style called <code style="color: #bb0000;">LV_CONT_PART_MAIN</code> and it can use all the typicaly bacground properties and padding for layout auto sizing. | |The containers has only a main style called <code style="color: #bb0000;">LV_CONT_PART_MAIN</code> and it can use all the typicaly bacground properties and padding for layout auto sizing. | ||
− | | | + | |コンテナには、<code style="color: #bb0000;">LV_CONT_PART_MAIN</code>と呼ばれるメインスタイルのみがあり、レイアウトオートサイジングにはすべての典型的なバクグラウンドプロパティとパディングを使用できます。 |
|} | |} | ||
:[[App:Library:LVGL:docs:Widgets|戻る : Previous]] | :[[App:Library:LVGL:docs:Widgets|戻る : Previous]] | ||
30行目: | 30行目: | ||
!自動翻訳 | !自動翻訳 | ||
|- | |- | ||
− | | | + | |You can apply a layout on the containers to automatically order their children. |
− | |||
− | |||
− | You can apply a layout on the containers to automatically order their children. | ||
The layout spacing comes from the style's <code style="color: #bb0000;">pad</code> properties. The possible layout options: | The layout spacing comes from the style's <code style="color: #bb0000;">pad</code> properties. The possible layout options: | ||
− | * LV_LAYOUT_OFF - Do not align the children. | + | * '''LV_LAYOUT_OFF''' - Do not align the children. |
− | * LV_LAYOUT_CENTER - Align children to the center in column and keep <code style="color: #bb0000;">pad_inner</code> space between them. | + | * '''LV_LAYOUT_CENTER''' - Align children to the center in column and keep <code style="color: #bb0000;">pad_inner</code> space between them. |
− | * LV_LAYOUT_COLUMN_LEFT - Align children in a left-justified column. Keep <code style="color: #bb0000;">pad_left</code> space on the left, <code style="color: #bb0000;">pad_top</code> space on the top and <code style="color: #bb0000;">pad_inner</code> space between the children. | + | * '''LV_LAYOUT_COLUMN_LEFT''' - Align children in a left-justified column. Keep <code style="color: #bb0000;">pad_left</code> space on the left, <code style="color: #bb0000;">pad_top</code> space on the top and <code style="color: #bb0000;">pad_inner</code> space between the children. |
− | * LV_LAYOUT_COLUMN_MID - Align children in centered column. Keep <code style="color: #bb0000;">pad_top</code> space on the top and <code style="color: #bb0000;">pad_inner</code> space between the children. | + | * '''LV_LAYOUT_COLUMN_MID''' - Align children in centered column. Keep <code style="color: #bb0000;">pad_top</code> space on the top and <code style="color: #bb0000;">pad_inner</code> space between the children. |
− | * LV_LAYOUT_COLUMN_RIGHT - Align children in a right-justified column. Keep <code style="color: #bb0000;">pad_right</code> space on the right, <code style="color: #bb0000;">pad_top</code> space on the top and <code style="color: #bb0000;">pad_inner</code> space between the children. | + | * '''LV_LAYOUT_COLUMN_RIGHT''' - Align children in a right-justified column. Keep <code style="color: #bb0000;">pad_right</code> space on the right, <code style="color: #bb0000;">pad_top</code> space on the top and <code style="color: #bb0000;">pad_inner</code> space between the children. |
− | * LV_LAYOUT_ROW_TOP - Align children in a top justified row. Keep <code style="color: #bb0000;">pad_left</code> space on the left, <code style="color: #bb0000;">pad_top</code> space on the top and <code style="color: #bb0000;">pad_inner</code> space between the children. | + | * '''LV_LAYOUT_ROW_TOP''' - Align children in a top justified row. Keep <code style="color: #bb0000;">pad_left</code> space on the left, <code style="color: #bb0000;">pad_top</code> space on the top and <code style="color: #bb0000;">pad_inner</code> space between the children. |
− | * LV_LAYOUT_ROW_MID - Align children in centered row. Keep <code style="color: #bb0000;">pad_left</code> space on the left and <code style="color: #bb0000;">pad_inner</code> space between the children | + | * '''LV_LAYOUT_ROW_MID''' - Align children in centered row. Keep <code style="color: #bb0000;">pad_left</code> space on the left and <code style="color: #bb0000;">pad_inner</code> space between the children. |
− | |||
− | |||
− | |||
− | |||
− | |||
|コンテナにレイアウトを適用して、子供を自動的に注文できます。 | |コンテナにレイアウトを適用して、子供を自動的に注文できます。 | ||
− | + | レイアウト間隔は、スタイルの<code style="color: #bb0000;">pad</code>プロパティに由来します。可能なレイアウトオプション: | |
− | * | + | * '''LV_LAYOUT_OFF'''-子供を調整しないでください。 |
− | * | + | * '''LV_LAYOUT_CENTER'''-子供を列の中央に並べ、それらの間に<code style="color: #bb0000;">pad_inner</code>スペースを保持します。 |
− | * | + | * '''LV_LAYOUT_COLUMN_LEFT'''-左正当化された列に子供を調整します。左側に<code style="color: #bb0000;">pad_left</code>スペース、上部の<code style="color: #bb0000;">pad_top</code>スペース、子供の間の<code style="color: #bb0000;">pad_inner</code>スペースを保持します。 |
− | * | + | * '''LV_LAYOUT_COLUMN_MID'''-中央の列に子供を整列させます。上部に<code style="color: #bb0000;">pad_top</code>スペースを保ち、子供の間の<code style="color: #bb0000;">pad_inner</code>スペースを保持します。 |
− | * | + | * '''LV_LAYOUT_COLUMN_RIGHT'''-右正当化された列に子供を調整します。右側に<code style="color: #bb0000;">pad_right</code>スペース、上部の<code style="color: #bb0000;">pad_top</code>スペース、子供の間の<code style="color: #bb0000;">pad_inner</code>スペースを保持します。 |
− | * | + | * '''LV_LAYOUT_ROW_TOP'''-子どもを一番正当な列に合わせます。左側に<code style="color: #bb0000;">pad_left</code>スペース、上部の<code style="color: #bb0000;">pad_top</code>スペース、子供の間の<code style="color: #bb0000;">pad_inner</code>スペースを保持します。 |
− | * | + | * '''LV_LAYOUT_ROW_MID'''-中央の列に子供を調整します。左側に<code style="color: #bb0000;">pad_left</code>スペースを保持し、子供の間の<code style="color: #bb0000;">pad_inner</code>スペースを保持します。 |
− | * | + | |- |
− | * | + | | |
− | * | + | |
− | * | + | |
− | * | + | * '''LV_LAYOUT_ROW_BOTTOM''' - Align children in a bottom justified row. Keep <code style="color: #bb0000;">pad_left</code> space on the left, <code style="color: #bb0000;">pad_bottom</code> space on the bottom and <code style="color: #bb0000;">pad_inner</code> space between the children. |
+ | * '''LV_LAYOUT_PRETTY_TOP''' - Put as many objects as possible in a row (with at least <code style="color: #bb0000;">pad_inner</code> space and <code style="color: #bb0000;">pad_left/right</code> space on the sides). Divide the space in each line equally between the children. If here are children with different height in a row align their top edge. | ||
+ | * '''LV_LAYOUT_PRETTY_MID''' - Same as <code style="color: #bb0000;">LV_LAYOUT_PRETTY_TOP</code> but if here are children with different height in a row align their middle line. | ||
+ | * '''LV_LAYOUT_PRETTY_BOTTOM''' - Same as <code style="color: #bb0000;">LV_LAYOUT_PRETTY_TOP</code> but if here are children with different height in a row align their bottom line. | ||
+ | * '''LV_LAYOUT_GRID''' - Similar to <code style="color: #bb0000;">LV_LAYOUT_PRETTY</code> but not divide horizontal space equally just let <code style="color: #bb0000;">pad_left/right</code> on the edges and <code style="color: #bb0000;">pad_inner</code> space between the elements. | ||
+ | | | ||
+ | * | ||
+ | * '''LV_LAYOUT_ROW_BOTTOM'''-下部の正当な列に子供を並べます。左側に<code style="color: #bb0000;">pad_left</code>スペース、底部に<code style="color: #bb0000;">pad_bottom</code>スペース、子供の間の<code style="color: #bb0000;">pad_inner</code>スペースを保持します。 | ||
+ | * '''LV_LAYOUT_PRETTY_TOP'''-できるだけ多くのオブジェクトを連続して配置します(少なくとも<code style="color: #bb0000;">pad_inner</code>スペースと側面にPAD_LEFT/右スペースがあります)。各ラインのスペースを子供の間で均等に分割します。ここに連続して身長が異なる子供が最上端を合わせている場合。 | ||
+ | * '''LV_LAYOUT_PRETTY_MID'''- <code style="color: #bb0000;">LV_LAYOUT_PRETTY_TOP</code>と同じですが、ここに連続してさまざまな高さの子供が中央の線を合わせます。 | ||
+ | * '''LV_LAYOUT_PRETTY_BOTTOM'''- <code style="color: #bb0000;">LV_LAYOUT_PRETTY_TOP</code>と同じですが、ここに連続してさまざまな高さの子供が最終的な線に合わせてください。 | ||
+ | * '''LV_LAYOUT_GRID''' - <code style="color: #bb0000;">LV_LAYOUT_PRETTY</code>と似ていますが、水平方向のスペースを均等に分割せず、エッジに <code style="color: #bb0000;">pad_left/right</code> を、要素間に <code style="color: #bb0000;">pad_inner</code> スペースを設定します。 | ||
|} | |} | ||
:[[App:Library:LVGL:docs:Widgets|戻る : Previous]] | :[[App:Library:LVGL:docs:Widgets|戻る : Previous]] |
2022年8月31日 (水) 16:09時点における版
https://docs.lvgl.io/latest/en/html/widgets/cont.html
Container (lv_cont)
Overview
英文 | 自動翻訳 |
---|---|
The containers are essentially a basic object with layout and automatic sizing features. | コンテナは、基本的にレイアウトと自動サイジング機能を備えた基本オブジェクトです。 |
Parts and Styles
英文 | 自動翻訳 |
---|---|
The containers has only a main style called LV_CONT_PART_MAIN and it can use all the typicaly bacground properties and padding for layout auto sizing.
|
コンテナには、LV_CONT_PART_MAIN と呼ばれるメインスタイルのみがあり、レイアウトオートサイジングにはすべての典型的なバクグラウンドプロパティとパディングを使用できます。
|
Usage
Layout
英文 | 自動翻訳 |
---|---|
You can apply a layout on the containers to automatically order their children.
The layout spacing comes from the style's
|
コンテナにレイアウトを適用して、子供を自動的に注文できます。
レイアウト間隔は、スタイルの
|
|
|
Autofit
英文 | 自動翻訳 |
---|---|
Container have an autofit feature which can automatically change the size of the container according to its children and/or its parent.
The following options exist:
To use different auto fit horizontally and vertically, use |
コンテナには、子や親に応じてコンテナのサイズを自動的に変更できるオートフィット機能があります。
次のオプションが存在します:
さまざまな自動適合を水平および垂直に使用するには、lv_cont_set_fit2(cont、hor_fit_type、ver_fit_type)を使用します。 4つの方向すべてで異なるオートフィットを使用するには、lv_cont_set_fit4(cont、left_fit_type、right_fit_type、top_fit_type、botond_fit_type)を使用します。 |
Events
英文 | 自動翻訳 |
---|---|
Only the Generic events are sent by the object type.
|
オブジェクトタイプでは、Generic eventsのみが送信されます。
|
Keys
英文 | 自動翻訳 |
---|---|
No Keys are processed by the object type.
|
オブジェクトタイプで処理されるキーはありません。
|