Eclipse tab and space, UTF-8 settings

Source: Internet
Author: User

1. Use spaces to replace the tab in eclipse Basic Editor settings

Window-> preferences-> General-> editors-> text editors

 

2. For Java, HTML, ant, and other extension editors, you also need to set them separately.

1). For Java: sets Java code style in eclipse
Window-> preferences-> JAVA-> code style-> formatter
Add a new profile, For more detail, test it in eclipse please

2). For ant: sets build. XML in eclipse
Window-> preferences-> ant> Editor-> formatter
Uncheck [Use Tab character instead of spaces] Option.

3). For HTML:
Window-> preferences-> Web and XML-> HTML files-> HTML source
Select "indent using tabs" and set space = 4

4). For XML:
Windows> preferences> Web and XML> XML files> XML Source
Select "indent using tabs" and set space = 4

3. How to configure files such as JSP/properties to create or read using UTF-8 encoding by default?
Window-> preferences-> General-> content types

Select the specified extension, specify the encoding, and then update.

 

4. Convert the carriage return line feed format of an existing file
After all, it is not a professional editor and does not seem to have this function.

 

 

Note:

Post from: http://koda.javaeye.com/blog/127200

 

Related Article

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.