Comments (12)
理论上想兼容三大桌面,但实际上目前参与者中没有MacOS X开发者。关于BOM/Utf-8,真心msvc/gcc不统一
from tianchi.
「关于BOM/Utf-8,真心msvc/gcc不统一」,能解釋下嗎?編譯器層面肯定都支持帶BOM的UTF-8,主要的困難應該是Win32 API要麼ANSI要麼UTF-16 LE(微軟所謂的Unicode),但是在Qt的宇宙中UTF-8的支持應該沒問題啊。
from tianchi.
可查看qtcn.org中Qt中文处理版块的内容。
from tianchi.
看一個別人的實測結果:
http://www.cnblogs.com/zyl910/archive/2012/07/26/cfile_utf8.html
from tianchi.
那篇文章中怎么没测Qt4历史上使用最广泛的编译器之一msvc2008呢
from tianchi.
「Qt4历史上使用最广泛的编译器」請問您怎麼統計的「历史」?現在最新的VC是2008嗎?最新的Qt是4系列嗎?
其實VC2008的情況應該和VC2005類似啊,源碼可以是UTF-8 with BOM,但是運行時會強制轉換成ANSI(在簡體中文環境顯然就是GBK),其實這樣和你直接保存成GBK在運行時的效果一樣啊。反而只是break了不作這種強制轉換的VC2003,對於高版本VC和GCC,本來你就可以指定運行時編碼啊。等到VC2005/2008淡出了,就可以純用UTF-8了。
from tianchi.
兄台有什么好的方法吗,目前要万全似乎只有去除全部中文及中文注释了。不再兼容Qt4的话,肯定全用Utf-8了。
from tianchi.
註釋也有影響?
from tianchi.
源码中的中文很少量,倒是可以通过另外的方法避免,主要是jonix写的两个文件有这个问题。中文注释这是最根本的,也影响编译。
from tianchi.
我自己积累了很多Qt的库,也议过用UTF8进行编码.没有人理一点兴趣都没有了
from tianchi.
只要解决了几个编译器的兼容性问题就可以,楼上的有什么好办法吗?
from tianchi.
目前这种代码保存为GBK的方式,我从2008年到现在使用得都正常。将源代码由UTF-8改为GBK,就是因为msvc2008的问题.
from tianchi.
Related Issues (8)
- make: *** [sub-shared-make_first] 错误 3 HOT 2
- make all error HOT 2
- 是MinGW不是mingW HOT 1
- Back soon, boss Chinux...
- please add me
- hub issue
- 怎么使用 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from tianchi.