VirtualBox

Changeset 2437 in kBuild for trunk/VSlickMacros


Ignore:
Timestamp:
Mar 28, 2011 7:17:08 PM (14 years ago)
Author:
bird
Message:

kkeys.e: Finally fixed C+Delete to work correctly across newlines.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/VSlickMacros/kkeys.e

    r2428 r2437  
    136136_command kkeys_delete_right()
    137137{
    138    col=p_col
    139    search('[ \t]#|?|$|^','r+');
    140    if ( match_length()&& get_text(1,match_length('s'))=='' )
    141    {
    142       _nrseek(match_length('s'));
    143       _delete_text(match_length());
    144    }
    145    else
     138   col=p_col;
     139
     140   /* virtual space hack*/
     141   keyin(" ");
     142   left();
     143   _delete_char();
     144
     145   /* are we in a word, delete it? */
     146   ch = get_text();
     147   if (ch != ' ' && ch != "\t" && ch != "\r" && ch != "\n")
    146148      delete_word();
     149
     150   /* delete spaces and newlines until the next word. */
     151   ch = get_text();
     152   if (ch == ' ' || ch == "\t" || ch == "\r" || ch == "\n")
     153   {
     154      if (search('[ \t\n\r]#','r+') == 0)
     155      {
     156         _nrseek(match_length('s'));
     157         _delete_text(match_length());
     158      }
     159   }
     160
    147161   p_col=col
    148162   //retrieve_command_results()
    149 
    150163}
    151164
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette