QT_NO_UTF8_SOURCE

Windows에서 소스 파일이 UTF-8로 처리되도록 강제하는 것을 방지합니다.

이 속성은 Qt 6.0에서 도입되었습니다.

Windows용 일부 컴파일러로 빌드할 때, Qt 라이브러리에 링크되는 타깃은 컴파일러가 해당 소스 파일을 UTF-8로 처리하도록 강제하는 플래그를 사용합니다. 이 기능은 현재 Visual Studio 및 Intel 컴파일러에서 구현되어 있습니다. 이 속성을 ` TRUE`로 설정하여 타깃별로 이 동작을 비활성화할 수 있습니다:

set_property(TARGET target_name PROPERTY QT_NO_UTF8_SOURCE TRUE)

참고: 이는 QString 와 같은 클래스의 런타임 동작을 변경하지 않습니다( const char * 의 생성자는 올바르게 인코딩된 UTF-8 입력을 필요로 합니다). 이러한 코드를 식별하는 데는 QT_NO_CAST_FROM_ASCII 및 QT_RESTRICTED_CAST_FROM_ASCII 매크로를 사용하십시오.

qt_disable_unicode_defines() 및 qt_allow_non_utf8_sources()도 참조하십시오 .

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