SlickEdit Community

Archived Beta Discussions => SlickEdit® Core for Eclipse => Topic started by: sean_kelly on February 19, 2009, 06:42:10 PM

Title: smarttab formatting for actionscript
Post by: sean_kelly on February 19, 2009, 06:42:10 PM
I cannot seem to get smarttab in emacs emulation mode to do the right thing with function arguments spread across multiple lines - I always get the below

  public function judge(analyses:kdraw_list,
    size_index:Number,
    corr:Number,
    standard_margin:Number) : kdraw_response
    {


as opposed to

  public function judge(analyses:kdraw_list, 
                        size_index:Number,
                        corr:Number,
                        standard_margin:Number) : kdraw_response


Applying the beatify command to the selection produces the latter.  I do have "use continuation indent on function parameters" checked. 

Another issue with smart tab is it alway seems to indent curly braces n spaces irrespective of my style choice.

Thanks for any help.

Sean


Title: Re: smarttab formatting for actionscript
Post by: SlickEdit Support on February 19, 2009, 08:16:10 PM
Sean,

I have been able to reproduce the issue.  I have filed a defect against the issue.   The same issue exists in the full SlickEdit product as well.  I imagine that it has something to do with the :'s (colons) in the params. 
Title: Re: smarttab formatting for actionscript
Post by: Ryan on February 27, 2009, 07:07:38 PM
If you get the fixes attached here: http://community.slickedit.com/index.php?topic=4509.0 this should be fixed.  Note that in order to see the desired behavior when you hit ENTER at the end of following line:

Code: [Select]
public function judge(analyses:kdraw_list, <cursor here>

you actually want "Use continuation indent on function parameters" turned OFF.  This will put the cursor even with the open paren, lining up all the function parameters.

- Ryan