Eclipse Edit Page Space Placeholder exception problem

Source: Internet
Author: User

Recent projects, by colleagues spit Groove code style too casual, are not aligned.

I confidently opened their code in Eclipse, which appears as follows:

650) this.width=650; "title=" image "style=" border-right-width:0px;background-image:none;border-bottom-width:0px; padding-top:0px;padding-left:0px;margin:0px;padding-right:0px;border-top-width:0px; "border=" 0 "alt=" image "src=" Http://img1.51cto.com/attachment/201409/24/4828774_1411549123Aeq3.png "width=" 244 "height=" 156 "/>

At this time, the colleague silently opened the code with the UE, shown as follows:

650) this.width=650; "title=" image "style=" border-right-width:0px;background-image:none;border-bottom-width:0px; padding-top:0px;padding-left:0px;margin:0px;padding-right:0px;border-top-width:0px; "border=" 0 "alt=" image "src=" Http://img1.51cto.com/attachment/201409/24/4828774_14115491238Fjz.png "width=" 244 "height="/>

The same code, in different editors, shows that the difference is so great.

Then open with notepad++, consistent with the UE display.

Obviously the problem is on the eclipse display.

Search on the Internet, there is no related problems.

After careful comparison of the two displays, it is found that the Eclipse hollow lattice display width is slightly smaller than the average character, causing multiple spaces to be joined together, there is a problem with alignment.

After a few hours of repeated searches, we finally found the problem.

In eclipse, I used the font of the XXFarEastFont-Arial font, which has a slightly smaller space than the other characters and has a problem with alignment.

Although the font of the Chinese language is better than other fonts, but for the cleanliness of the code, I had to reluctantly abandon it.

When you select a young circle font, Eclipse appears as follows:

650) this.width=650; "title=" image "style=" border-right-width:0px;background-image:none;border-bottom-width:0px; padding-top:0px;padding-left:0px;margin:0px;padding-right:0px;border-top-width:0px; "border=" 0 "alt=" image "src=" Http://img1.51cto.com/attachment/201409/24/4828774_1411549124Kp8x.png "width=" 244 "height=" 94 "/>

It's finally showing normal.

This question is hereby recorded for later inspection.

This article is from the "Lifelong Learning" blog, please be sure to keep this source http://anfernee.blog.51cto.com/4828774/1557830

Eclipse Edit Page Space Placeholder exception problem

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.