jed-users mailing list

[2004 Date Index] [2004 Thread Index] [Other years]
[Thread Prev] [Thread Next]      [Date Prev] [Date Next]

Odd problem with regions


Greetings,

I'm writing some S-Lang code that should act on a region if one is defined
and on the curent line if one isn't.

I have a problem where the code will sometimes behave as if it is acting on
a region when one _isn't_ obviously defined and no region is visible. I've
realised that the problem is (?) that I'm using markp() and I should (I
think) be using is_visible_mark() instead.

The difference between the two according to the documentation is that
markp() will return 1 if a mark is defined and is_visible_mark() only
returns 1 if a mark is defined _and_ it is visible.

My question: What are invisible marks, and how do they get defined (and
why).

Also, in the s-lang files in the lib directory, markp() is used far more
often than is_visible_mark() and often in a context where I would have
thought that is_visible_mark() should be used instead (unless I'm wrong
about what my code is doing) - so, my bonus question: Are many of these
uses of markp() wrong as well, or am I just confused?

John Skilleter

-----------------------------------------
John Skilleter - john@xxxxxxxxxxxxxxxx & elsewhere
'DOS is best spelt backwards!'
    http://www.skilleter.org.uk
    http://www.roada.org.uk
-----------------------------------------



--------------------------
To unsubscribe send email to <jed-users-request@xxxxxxxxxxx> with
the word "unsubscribe" in the message body.
Need help? Email <jed-users-owner@xxxxxxxxxxx>.


[2004 date index] [2004 thread index]
[Thread Prev] [Thread Next]      [Date Prev] [Date Next]