]> code.delx.au - gnu-emacs/blobdiff - src/intervals.h
(Fwhile): If mocklisp, test for nonzeroness.
[gnu-emacs] / src / intervals.h
index e7ebb8f5cd6fd7155ae4425a494e1c8d52a2a748..74854add752b79aa2fa3d331e786766ff9ec923d 100644 (file)
@@ -137,11 +137,16 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.  */
 
 /* Is this interval visible?  Replace later with cache access */
 #define INTERVAL_VISIBLE_P(i) \
-  (! NULL_INTERVAL_P (i) && NILP (Fmemq (Qinvisible, (i)->plist)))
+  (! NULL_INTERVAL_P (i) && NILP (textget ((i)->plist, Qinvisible)))
 
 /* Is this interval writable?  Replace later with cache access */
-#define INTERVAL_WRITABLE_P(i) \
-  (! NULL_INTERVAL_P (i) && NILP (Fmemq (Qread_only, (i)->plist)))
+#define INTERVAL_WRITABLE_P(i)                                 \
+  (! NULL_INTERVAL_P (i)                                       \
+   && (NILP (textget ((i)->plist, Qread_only))                 \
+       || ((CONSP (Vinhibit_read_only)                         \
+           ? !NILP (Fmemq (textget ((i)->plist, Qread_only),   \
+                           Vinhibit_read_only))                \
+           : !NILP (Vinhibit_read_only)))))                    \
 
 /* Macros to tell whether insertions before or after this interval
    should stick to it. */
@@ -196,6 +201,8 @@ extern Lisp_Object Ftext_properties_at ();
 extern Lisp_Object Fnext_property_change (), Fprevious_property_change ();
 extern Lisp_Object Fadd_text_properties (), Fset_text_properties ();
 extern Lisp_Object Fremove_text_properties (), Ferase_text_properties ();
+extern Lisp_Object Ftext_property_any (), Ftext_property_all ();
+extern Lisp_Object copy_text_properties ();
 
 extern void syms_of_textprop ();