RadioDelegate QML Type
켜거나 끌 수 있는 라디오 표시기가 있는 전용 아이템 델리게이트입니다. 더 보기...
Import Statement: | import QtQuick.Controls |
Inherits: |
상세 설명
라디오 델리게이트는 켜거나(체크) 끌 수 있는(체크 해제) 항목 델리게이트를 표시합니다. 라디오 델리게이트는 일반적으로 옵션 세트에서 하나의 옵션을 선택하는 데 사용됩니다.
라디오 델리게이트는 ItemDelegate 에서 API를 상속받으며, 이는 AbstractButton 에서 상속받습니다. 예를 들어 text 를 설정하고 AbstractButton API를 사용하여 clicks 에 반응할 수 있습니다. 라디오 델리게이트의 상태는 checked 프로퍼티로 설정할 수 있습니다.
라디오 델리게이트는 기본적으로 auto-exclusive 입니다. 동일한 상위 항목에 속하는 라디오 델리게이트 중 한 번에 하나의 델리게이트만 체크할 수 있으며, 다른 델리게이트를 체크하면 이전에 체크한 델리게이트는 자동으로 체크가 해제됩니다. 공통 부모를 공유하지 않는 라디오 델리게이트의 경우 ButtonGroup 을 사용하여 독점성을 관리할 수 있습니다.
RadioButton 는 일반적으로 보기에서 사용되지 않고 옵션이 몇 개만 있고 각 버튼을 고유하게 식별할 수 있어야 하는 경우가 많다는 점을 제외하면 RadioDelegate와 유사합니다.
ButtonGroup { id: buttonGroup } ListView { model: ["Option 1", "Option 2", "Option 3"] delegate: RadioDelegate { text: modelData checked: index == 0 ButtonGroup.group: buttonGroup } }
라디오 델리게이트 사용자 지정하기, 델리게이트 컨트롤 및 RadioButton 를참조하세요 .
© 2025 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.