Python IDE-some personalized settings of Pydev

Source: Internet
Author: User

I used eric for python IDE before, but it was not very good. I also tried to use Vim to add some plug-ins for python IDE, which is not very good, it is estimated that this is the way the user sees or uses the product for the first time, causing some difficulties for the user, and it is very likely that the user will lose interest in this product. Of course, I am not saying that eric and vim are not good. On the contrary, they all have many supporters who use them to write Python, and I usually use Vim when writing C or Shell. Later, when I wrote Python, I used Eclipse and added a Pydev plug-in to write Python. It took about half a year to get started.

Pydev has just been set up in the past few days to make it more personalized and efficient. Now, it is easy to set it again next time.

1. Set the tab size: As mentioned in the previous article, let's talk about it here. Window -- preference -- Pydev -- Editor, you can see the setting of the Tab length. In addition, there is an option in the row below it, "Replace tabs with spaces when typing ?", If you select it, there will be no tab in the new source file, but it will be replaced by X spaces.

2. setting of automatic comments starting with module: window -- preference -- Pydev -- Editor-Templates. I chose to set the name to "<Empty>, and the table is "on. The value is as follows:

View Code PYTHON
1234567
'''Created on ${date} @author: Jay Ren@module: ${module}'''${cursor}

3. print settings (because I use python3, so print (): The setting is also in templates, select "print" as name, and set it: print ${space_if_py2 }$ {lparen_if_py3 }$ {cursor }$ {rparen_if_py3} and select its automatically insert.

4. Automatic Completion settings: Customize the window -- preference -- Pydev -- Editor-Code Completion settings.

After setting, a simple result is as follows:

View Code PYTHON
1234567891011
'''Created on 2011-12-7 @author: Jay Ren@module: just_for_fun'''def just_for_fun():print('just for fun')if __name__ == '__main__':just_for_fun()


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.