当前位置:网站首页>Qt Cmake 纯C 代码调用系统控制台输入scanf 及 中文输出乱码
Qt Cmake 纯C 代码调用系统控制台输入scanf 及 中文输出乱码
2022-06-25 23:12:00 【NIWODIY】
Qt Cmake 纯C 代码调用系统控制台输入scanf 及 中文输出乱码
2020-11-20 15:57:19
系统控制台输出
当用输入功能时,Qt自带控制台。
调用系统控制台的方法,点击左侧 “项目” 图标,出现构建和运行界面,选择“运行”选项,勾选 “在终端中运行(Run in terminal)”即可。
中文输出乱码
在CMakeLists.txt 中添加如下代码
#dubug -g 调试 GBK 中文
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -g -fexec-charset=GBK")

边栏推荐
- Inheritance -- holy grail mode
- mongodb
- WIN10系统C盘清理策略
- Redis的安装及启动
- ETCD数据库源码分析——集群间网络层服务端接口
- DGUS新升级:全面支持数字视频播放功能
- Preorder and middle order traversal of forest
- Learn to identify follow-up questions in dialogue Q & A
- [TSP problem] solving traveling salesman problem based on Hopfield neural network with matlab code
- Kylin
猜你喜欢

ciscn_ 2019_ en_ two

Post ordered clue binary tree

Ssl/tls, symmetric and asymmetric encryption, and tlsv1.3

1-9network configuration in VMWare

Vscode shortcut

Blob

Web學習之TypeScript

Electronic training.

Mining pit record of modified field information in Dameng database

FreeRTOS+STM32L+ESP8266+MQTT协议传输温湿度数据到腾讯云物联网平台
随机推荐
C IO stream (II) extension class_ Packer
QT excellent open source project 9: qtox
Balanced binary tree AVL
DPVS fullnat mode deployment
马斯克 VS 乔布斯,谁是21世纪最伟大的创业家
Px4 system terminal for pixhawk
Return value is object type method call equals()
Megacli common command collation
Solve STM32 operation μ Solution to sudden failure of task scheduling in c/os-ii system
STL tutorial 5-basic concepts of STL and the use of string and vector
Chapter V exercises (124, 678, 15, 19, 22) [microcomputer principles] [exercises]
关于EF翻页查询数据库
4 key points to help the product manage the project well
FPGA notes -- implementation of FPGA floating point operation
Flex & bison start
Stream data
STM32 uses SPI mode to drive TFT-LCD optimization code of hx8347 scheme
Example: use C # Net to teach you how to develop wechat official account (21) -- using wechat to pay online collection: H5 method
debezium
剑指 Offer II 096. 字符串交织