patchGNU Octave - Patches: patch #9026, Automatically close if, for, while...

 
 

patch #9026: Automatically close if, for, while etc.

Submitted by:  Lachlan Andrew <lachlan>
Submitted on:  Fri 10 Jun 2016 10:06:23 AM UTC  
 
Category:  Core : new feature Priority:  5 - Normal
Status:  Done Privacy:  Public
Assigned to:  Lachlan Andrew <lachlan> Open/Closed:  Closed

Add a New Comment (Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Sun 25 Jun 2017 07:35:55 AM UTC, comment #3: 

I have pushed this changeset with
http://hg.savannah.gnu.org/hgweb/octave/rev/cb36684b7a33

Thanks for the new feature.

Torsten Lilge <ttl>
Project Member
Wed 15 Jun 2016 02:09:54 AM UTC, comment #2: 

Oops!  Here it is.

(file #37481)

Lachlan Andrew <lachlan>In charge of this item.
Mon 13 Jun 2016 07:15:26 PM UTC, comment #1: 

Lachlan, I see no attachment :-)

Philip Nienhuis <philipnienhuis>
Project Member
Fri 10 Jun 2016 10:06:23 AM UTC, original submission:  

This patch causes the GUI editor to insert "endif" or "end" after the user types a line starting with "if", if its indent-based heuristics suggest that there isn't already one there.

The choice between "end" and "endif" is configurable, and this feature can be disabled through the Edit->Preferences menu.

Closings are provided for:
if for while function try unwind_protect classdef methods.

This doesn't check that they user typed the "if" (etc) recently. Whenever ENTER is pressed, it checks the start of the line. Normally, the heuristics stop this from producing too many closings.

Lachlan Andrew <lachlan>In charge of this item.

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #37481:  patch_auto_endif.cset added by lachlan (13KiB - text/x-diff)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by ttl (Posted a comment)
  • -email is unavailable- added by lachlan (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

     

     

    Follow 4 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2017-06-25 ttl StatusNone => Done
        Open/ClosedOpen => Closed
    2016-07-07 lachlan CategoryNone => Core : new feature
    2016-06-15 lachlan Attached File- => Added patch_auto_endif.cset, #37481

    Back to the top


    Powered by Savane 3.5