QTP0001
'/qt/qml/'은 Qml 모듈의 기본 리소스 접두사입니다.
이 정책은 Qt 6.5에서 도입되었습니다. 이 정책은 qt_add_qml_module() 이 리소스 시스템 내 QML 리소스를 저장하는 위치를 변경합니다.
이 정책을 활성화하면 QML 모듈이 기본 임포트 경로 아래에 배치되며, QQmlEngine::addImportPath 를 수동으로 호출하지 않아도 해당 유형을 찾을 수 있습니다.
이 정책의 ` OLD ` 동작은, ` qt_add_qml_module() `의 ` RESOURCE_PREFIX ` 인수가 기본적으로 ` "/"`로 설정된다는 것입니다.
이 정책의 NEW 동작은 qt_add_qml_module() 에 대한 RESOURCE_PREFIX 인수가 기본적으로 "/qt/qml/" 로 설정된다는 것입니다. 이 새로운 동작을 통해 모듈이 QML 임포트 경로에 포함되며, 별도의 설정 없이도 찾을 수 있게 됩니다.
qt_add_qml_module 명령에 RESOURCE_PREFIX, NO_RESOURCE_TARGET_PATH 중 어떤 인수도 전달하지 않으면 Qt 6.5에서 경고가 표시됩니다. qt_policy() 명령을 사용하여 정책을 명시적으로 OLD 또는 NEW 로 설정하면 이 경고를 억제할 수 있습니다.
참고: 정책의` OLD `동작은 더 이상 권장되지 않으며, 향후 제거될 수 있습니다.
qt_policy(), qt_standard_project_setup(), qt_cmake_policies 및 qt_add_qml_module()도 참조하십시오 .
© 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.