Aptana shortcut key entry 1: Code assist

Source: Internet
Author: User

Two days ago, I briefly introduced Aptana in "rare JavaScript (Ajax) development tool-Aptana. Everyone is very concerned about this and has raised many questions. Because Aptana has a lot of related content and it is impossible to finish it all in one article, so I want to write several small articles in several aspects with many problems. Hope to help you. I have just started using Aptana. Please include anything wrong. In addition, if you want to read more documents from Aptana, your problem should be solved soon.

Code assist in Aptana is a part of interest and an important part of Aptana that is better than other tools. Here I will introduce some more.

I. Shortcut Keys

1.
In Aptana, you can useAlt +/Activate smart prompts.

Of course, you can also replace it with any shortcut key you want. In the menu window/preferences/General/keys, find "content assist" and modify it.

Note that Ctrl + J has been occupied by another function (incremental find). If you want to use Ctrl + J, it is best to replace it together.

2.
The quick cut key for entering the selected prompt item is "enter" rather than "tab", which may be unfamiliar to many people.

 

Ii. Automatically complete brackets and quotation marks

Whether it is{},()Or[]And"", As long as you enter the first half and the second half, it will be automatically typed.
Enter quotation marks before the string, and the other quotation marks are automatically added to the end of the string, and the mouse is automatically positioned behind the quotation marks at the end.

3. function parameter prompts

You can see this picture.

 

4. ubiquitous tip

When you input DOM objects, functions, parameters, CSS, HTML, and so on, you will constantly jump out of prompts containing various types of information. I will not go through them one by one. You can enjoy them slowly.

In addition, moving the mouse to an object at any position will jump out of richer content tip, and even include sample

 

5. Support for third-party (custom) frameworks

Here is the highlight of today:

First, find the tutorial library of ASP. Net Ajax and drag it to the Code assist profiles window,

Added to the default profile by default

Create test. js and write a function.

Wow, do you see that? Everything in the ASP. NET Ajax library comes in!


The new variable is also in!


The variable is of the "strong type" type! (Allow me to borrow this word)


The newly created function is correct.

Note: Here I use the default profile, because it is "Global", it will be valid when you edit any file. A better way is to use projects for management. However, this is beyond the scope of this article.

6. automatically go to Function Definition

Let's put the cursor on tostring () and press F3 to see


Microsoftajax. JS is automatically opened and "sys $ stringbuilder $ tostring" is located ". To facilitate debugging, the beta version uses a new naming method, so that we cannot directly locate the function definition. It doesn't matter. Place the cursor in "sys $ stringbuilder $ tostring" and then click F3.


Now.

7. Use scriptdoc to customize code assist

Add some comments to our Concat function, and then look at the prompted content.

The scriptdoc annotation can also be defined in the. SDoC file with the same name as the JS file. For more information, see.

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.