[code] [textadept] Block comments

From: Richard Philips <richard.philips.att.gmail.com>
Date: Sun, 19 May 2013 17:07:03 +0200


I think I found a small (but annoying) error in block_comment

After executing a block comment, the caret is on the wrong place.

I think the reason for that is that the variable 'pos' is local to the
for-loop used in the code.

In a similar situation I worked with a variable 'origin', defined as

    local origin = buffer.length - pos

(before executing the loop).

After the loop:

    pos = buffer.length - origin

brought the caret in the right position.


You are subscribed to code.att.foicica.com.
To change subscription settings, send an e-mail to code+help.att.foicica.com.
To unsubscribe, send an e-mail to code+unsubscribe.att.foicica.com.
Received on Sun 19 May 2013 - 11:07:03 EDT

This archive was generated by hypermail 2.2.0 : Mon 20 May 2013 - 06:30:22 EDT