Parameter Info

This week I am going to write about editor improvements, which are available in the development builds. I hope that I will have time to introduce a new feature every day. The feature freeze for NetBeans 7.0 Milestone 1 was already reached and these improvements will be also available in this M1. If you will try the development builds and run into a problem, enter new issue into Issuezilla  (category php, subcomponent editor).

The first new feature, which I want to introduce is parameter info. When you use a function and you don't remember the parameters you can use CTLR+P shortcut to show the parameters in a small popup window as it is displayed on the picture.

As you can see the parameter is bold that corresponds to the cursor position.

Also if a function has parameters with a default value, then the default value is displayed for the parameter. 



Comments:

Great

I have a question:

Can Netbeans PHP show up DocBlock for each parameter in case the methods or functions are documented like this:

/\*\*
\*
\* @param string $name User name
\* @param int $ttl The maximum time that user name can be stored in memory
\*/
public function persistIdentity($username, $ttl) {

}

I am in a process to evaluate Netbeans IDE as alternative to Eclipse PDT which is used as the main PHP IDE in our company.

Netbeans PHP feature sets are quite impressive to me

Posted by pcdinh on December 08, 2008 at 10:45 AM CET #

Are NB 7 snapshots the only way to get updates for the PHP plugin? NB 6.5 Beta 2 was great for PHP but NB 6.5 is almost useless with big performance regressions.

Posted by Richard Hyde on December 08, 2008 at 06:06 PM CET #

Hello,

I also think that this functionality should support phpdoc.

Maybe it should just show window, which you see when you use content asist for functions? I mean window which describes function and its parameters.
This window could be show over parameters popup.

Posted by Michal on December 09, 2008 at 01:04 AM CET #

Hi Richard,

it should be in opposite way. There was done many fixes from beta to fcs to fix performance. Could you describe more?

Also you can unzip and use the development build. For more info look here: http://blogs.sun.com/netbeansphp/entry/userdir .

Thanks,
Petr

Posted by Petr on December 09, 2008 at 02:25 AM CET #

To pcdinh: If you place cursor on the function name and press CTRL+SHIFT+SPACE shortcut, then the PHP doc for the function is displayed in the popup window. It's the same window, which is shown together with code completion window. The cursor has to be inside the function name.

Petr

Posted by Petr Pisl on December 09, 2008 at 06:10 AM CET #

To Petr:

Are those shortcut somewhere documented? And is this functionality implemented in nb 6.5? I was looking for this functionality for long time - i tried to hover mouse cursor over function and excepted that it will show php doc for function (it works this way in eclipse).

Posted by Michal on December 09, 2008 at 11:02 AM CET #

I use ubuntu 8.04. Why are this parameters not antialiased? I tried last nightly build (200812091520) and on ubuntu are toolbars too wide height and editor window are "skipping" for some pixels ... is it some bug?

Posted by gawan on December 10, 2008 at 03:58 AM CET #

To Michal:

If you invoke Keyboard Shortcut Card in Help menu, you get an overview of the most used shortcut, but it's for NB 6.5. But this card doesn't contain CTRL+P.

I think, if you want to know all possible action you have to go to Tools->Options->Keymap.

To gawan:
>Why are this parameters not antialiased?

I have noticed this as well. It looks like a bug. Could you enter it in our Issuezilla?

>I tried last nightly build (200812091520) and on
>ubuntu are toolbars too wide height and editor
>window are "skipping" for some pixels ... is it
>some bug?

Yes, this is a regression from yesterday. It should be fixed in todays build.

Thanks,
Petr

Posted by Petr on December 10, 2008 at 09:08 AM CET #

I enter antialiasing bug in issuezila.

And I have one question of this blog. I check "Notify me by email of new comments" and filled my email address but I do not get any notification about next comments. Is it some bug?

Posted by gawan on December 11, 2008 at 12:30 AM CET #

To gawan,

thanks for entering the bug.

I'm sorry for the inconvenience with sending notifications. I will try to investigate the situation.

Regards,
Petr

Posted by Petr on December 11, 2008 at 08:36 AM CET #

To gawan: I was asking other people and I have got this answer:

I get new comments. There are two places to enable this: one when you write the email and one somewhere in the Account Prefs/Options portion of your account. The Options in my account is always enabled and I always check the box when I write the comment. Maybe both places need to be 'on'?

I don't know whether it helps.

Petr

Posted by Petr on December 11, 2008 at 03:19 PM CET #

To Petr about notification: sorry for annoying you, but you wrote:

1. "when you write the email" do you mean "Post a Comment"? Because when a write a comment I do not write emails I use only "Post a Comment" form upon each articles. And I fill Name and E-mail of course and also I check "Notify me by email of new comments". And I mean this should be enough...

2. Which account do you mean? Because on this blog I cannot find login/reg. box. And on http://blogs.sun.com/ is write "Login for Sun employees only" but I am not employee of Sun. Can you send me a link where can I register?

Posted by gawan on December 12, 2008 at 08:10 AM CET #

sorry not "upon" but "under or below" of each article ;)

Posted by gawan on December 12, 2008 at 08:13 AM CET #

Hi Gawan,

sure I thought "Post a Comment" :). So far it looks like a bug. I will try to discuss this with people, who take care about the blog server.

Thanks,
Petr

Posted by Petr on December 14, 2008 at 01:30 PM CET #

Tested. The issue 155670 has been filed.

Posted by Mikhail Matveev on December 17, 2008 at 08:44 AM CET #

Is there a way to remap the CTRL+P binding for this utility?

CTRL+P is reserved by jVi for hippy completion and hence the the PHP behaviour does not work.

Posted by Adam Jorgensen on February 25, 2009 at 03:47 AM CET #

Great post and draw. Thank you for sharing.

Posted by buy wow gold on October 29, 2009 at 09:00 PM CET #

Post a Comment:
  • HTML Syntax: NOT allowed
About

This blogs is written by NetBeans developers who contribute to the PHP support mainly.

Search

Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today