DayOfWeekRow QML Type
1週間の曜日の名前が並んでいます。詳細...
| Import Statement: | import QtQuick.Controls |
| Inherits: |
プロパティ
- delegate : Component
詳細な説明
DayOfWeekRowは、曜日名を1行に表示します。曜日の名前は、指定されたlocale に基づいて順序付けられ、書式設定されます。

DayOfWeekRow {
locale: Qt.locale("en_US")
}DayOfWeekRowは単独のコントロールとして使用することもできますが、ほとんどの場合、MonthGrid と組み合わせて使用されます。使用方法にかかわらず、行の位置決めはユーザーに委ねられます。

ColumnLayout {
DayOfWeekRow {
locale: grid.locale
Layout.fillWidth: true
}
MonthGrid {
id: grid
month: Calendar.December
year: 2015
locale: Qt.locale("en_US")
Layout.fillWidth: true
}
}custom delegate を実装することで、DayOfWeekRow の外観を変更できます。
MonthGrid およびWeekNumberColumnも参照してください 。
プロパティのドキュメント
delegate : Component
このプロパティには、曜日ごとにデータを可視化するアイテムデリゲートが格納されます。
index プロパティに加え、各デリゲートのコンテキストでは、以下のモデルデータロールのリストが利用可能です:
| model.day: int | 曜日(Qt::DayOfWeek ) |
| model.longName: string | 曜日の名称の完全形。例:「Monday」(QLocale::LongFormat ) |
| model.shortName: string | 曜日の名称の短縮形。例:「Mon」(QLocale::ShortFormat ) |
| model.narrowName: string | スペースが限られている場合に使用する、曜日の名称の特別な表記。例:「M」(QLocale::NarrowFormat ) |
以下のスニペットは、アイテムデリゲートのデフォルトの実装を示しています。これは、カスタムデリゲートを実装する際の出発点として使用できます。
delegate: Text {
text: shortName
font: control.font
color: control.palette.text
horizontalAlignment: Text.AlignHCenter
verticalAlignment: Text.AlignVCenter
required property string shortName
}DayOfWeekRow デリゲートの所有権を取得しません。
© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.