IDE editor encoding Configuration

Source: Internet
Author: User

 

During cross-platform development, the biggest headache for developers using different ides is various garbled code problems.

Common ides support UTF-8 encoding and '\ n' at the end of the line in UNIX format '.


1. Set text encoding and line feed in xcode
Xcode> preferences = text editing-Editing:
There are default text encoding and default line endings.

2. Set text encoding and line feed in eclipse

Menu> preferences = General> Workspace-configuration page
There are text file encoding and new text file line delimiter.

3. Visual Studio
No direct handling method found. The following is a compromise.
Tools-> options-> environment-> events-> Save document as Unicode when data cannot be saved in codePage save as Unicode, check

Tools> Options> text editor> General> auto-detect UTF-8 encoding without signature
Open the UTF-8-encoded file and check (Note: xcode saves the text without the encoding mark of the file header, Vs may be garbled when opening these files)

In vs, the original encoding is maintained when the UTF-8 encoded file is opened. Make sure that the new file is UTF-8:
After creating a new file, you can use the advanced save option of the file to specify the UTF-8 encoding and the end of the line.

IDE editor encoding Configuration

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.