Eclipse code prompt function settings (Java & C/C ++)

Source: Internet
Author: User

Turn: http://www.cnblogs.com/myitm/archive/2010/12/17/1909194.html

 

Today, I have studied the smart sensing function of myeclispse. When I first started using it, I always felt so uncomfortable → the smart sensing function was too weak! Visual studio2008 is not a class! However, after checking the information on the Internet, I found that it was not so weak. When I played with it last week, I found that I could modify the prompt time that I could perceive through the following settings:

Windows → preferences → Java → editor → content assist

We can see that the default value of autoactivation delay is 200 (unit: milliseconds). That is to say, the smart sensing prompt is displayed only after "." is played. So what if I change it to 20? Try it. After it is changed to 20, the system prompts a significant increase in speed, which can keep pace with the times ...... :)

OK. The last modified prompt time. Modify the trigger that triggers Intelligent Sensing this time. That is to say, make it a powerful sensing function like our visual studio2008, that is, input s to prompt all the functions such as the keyword starting with S. It is easy to set the value of auto activation triggers for Java, and change the original trigger "." To "." + 26 × 2 letters. Hmm? Why is it 26 × 2? Because the letters are case-sensitive, 26 in upper case and 26 in lower case. Of course 26 × 2 is the case!

The procedure is as follows:

Go to: Windows → preferences → Java → editor → content assist

Then modify the default value "." of auto activation triggers for Java to ". ABC ". Next, file → export → preferences → export to a certain file (assumed as test. and open test. EPF, search ". ABC "and then change it ". abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvw ", save.

Then file → import → preferences → test. EPF, OK, and write JavaProgram.

You can try it yourself, but it is better to check the effect first:

Input sys smart sensing:

We know that in Vs, if you enter try and then press two tabs, the try command will appear.CodeIn this case, this function can also be implemented:

Click "Press ENTER" to display the following code block:

How is it? Is it very practical? I believe it will increase your development efficiency several times.

C/C ++: Open the terminal: input: $ gcc-V to get the GCC version 4.1.3 20070929 (prerelease) (Ubuntu 4.1.2-16ubuntu2) you can easily see the current version. Start eclipse. Go to windows --> preferences --> C/C ++ and find environment. Add two variables: cplus_include_path:/usr/include/C ++/4.1.3 (My GCC version) c_include_path:/usr/include

 

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.