이 페이지에서

DropArea QML Type

특정 영역에서 드래그 앤 드롭 처리를 지정하기 위함입니다. 더 보기...

Import Statement: import QtQuick
Inherits:

Item

속성

신호

자세한 설명

DropArea는 다른 항목이 그 위로 드래그될 때 이벤트를 수신하는 보이지 않는 항목입니다.

Drag 부착 속성을 사용하면 아이템이 DropArea 위로 드래그될 때 DropArea에 이를 알릴 수 있습니다.

keys 속성을 사용하면 일치하는 키가 포함되지 않은 드래그 이벤트를 필터링할 수 있습니다.

drag.source 속성은 드래그 이벤트의 소스에게 드래그 대상에 대한 드롭의 수신자로 전달됩니다.

Qt Quick 예제 - 드래그 앤 드롭도참조하십시오 .

속성 설명서

containsDrag : bool [read-only]

이 속성은 DropArea 에 현재 드래그된 항목이 포함되어 있는지 여부를 나타냅니다.

drag.source : QtObject [read-only]

이 속성은 드래그의 시작점을 나타냅니다.

drag group

drag.x : real [read-only]

drag.y : real [read-only]

이 속성들은 마지막 드래그 이벤트의 좌표를 저장합니다.

keys : stringlist

이 속성은 ` DropArea `가 허용하는 드래그 키 목록을 포함합니다.

키가 나열되어 있지 않으면 DropArea 는 모든 드래그 소스의 이벤트를 허용하며, 그렇지 않은 경우 드래그 소스에는 호환되는 키가 적어도 하나 있어야 합니다.

QtQuick::Drag::keys도 참조하십시오 .

신호 문서

dropped(DragEvent drop)

이 신호는 DropArea 의 범위 내에서 drop 이벤트가 발생했을 때 발생합니다.

참고: 이에 대응하는핸들러는 onDropped 입니다.

entered(DragEvent drag)

이 신호는 drag 가 DropArea 의 경계 내에 진입할 때 발생합니다.

참고: 해당 핸들러는 onEntered 입니다.

exited()

이 신호는 드래그가 ` DropArea`의 경계를 벗어날 때 발생합니다.

참고: 이에 대응하는핸들러는 onExited 입니다.

positionChanged(DragEvent drag)

이 신호는 drag 의 위치가 변경되었을 때 발생합니다.

참고: 해당 핸들러는 onPositionChanged 입니다.

© 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.