unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: David Kastrup <dak@gnu.org>
Cc: juri@jurta.org, lennart.borgman.073@student.lu.se,
	teirllm@dms.auburn.edu, rms@gnu.org, emacs-devel@gnu.org
Subject: Re: Todays exercise of sanity (or does "see" really match "not"?)
Date: Wed, 23 Mar 2005 12:01:41 +0100	[thread overview]
Message-ID: <x5fyymmxre.fsf@lola.goethe.zz> (raw)
In-Reply-To: <m3ll8ed6b8.fsf@kfs-l.imdomain.dk> (Kim F. Storm's message of "Wed, 23 Mar 2005 11:07:07 +0100")

[-- Attachment #1: Type: text/plain, Size: 1673 bytes --]

storm@cua.dk (Kim F. Storm) writes:

> Instead we can explicitly put an inivisible property together with
> the display property on a priece of "hidden" text which should be
> ignored by searches.  That need a little work to check all uses of
> display properties, but it doesn't break any old code relying on the
> current behaviour.
>
> I don't know whether it actually works to put both invisible and
> display on some text (with the effect of showing the image and
> ignoring the under-laying text).

It did in the past.  I remember that effect from when we were
desperately trying to find a combination of text properties that would
work with both Emacs and XEmacs.

> Would someone make some examples to check it?

I just patched up preview-latex to place the invisible property on the
overlays it creates (obviously, not the desired default behavior).
Now this is using overlays, not text properties, but the results
should be pretty much the same.

And the results are that stuff is not found indeed when using isearch.
query-replace-regexp, however, still finds it.  Non-interactive search
doesn't find it.

I also remember that in the Emacs-21.1 code base, placing the
"invisible" property on displayed stuff had the effect that scrolling
did no longer account for the amount of vertical space taken by the
image.  However, with the current HEAD, this effect is not to be seen.

In case that you want to experiment with it, here is the patch I
used.  Unfortunately, the main work is done in a macro, so you need
something like

(let ((load-path (cons "." load-path))) (load "preview.el"))

to let it take effect unless you recompile and reinstall
preview-latex.


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: Type: text/x-patch, Size: 937 bytes --]

--- prv-emacs.el	18 Mar 2005 22:36:24 +0100	1.63
+++ prv-emacs.el	23 Mar 2005 11:48:08 +0100	
@@ -168,6 +168,7 @@
 	  `(propertize
 	    "x"
 	    'display ,glyph
+	    'invisible t
 	    'mouse-face 'highlight
 	    'help-echo
 	    ,(if (stringp helpstring)
@@ -347,12 +348,12 @@
 	    (overlay-put ov 'category 'preview-overlay)
 	    (if (eq (overlay-start ov) (overlay-end ov))
 		(overlay-put ov 'before-string (car strings))
-	      (dolist (prop '(display keymap mouse-face help-echo))
+	      (dolist (prop '(invisible display keymap mouse-face help-echo))
 		(overlay-put ov prop
 			     (get-text-property 0 prop (car strings))))
 	      (overlay-put ov 'before-string nil))
 	    (overlay-put ov 'face nil))
-	(dolist (prop '(display keymap mouse-face help-echo))
+	(dolist (prop '(invisible display keymap mouse-face help-echo))
 	  (overlay-put ov prop nil))
 	(overlay-put ov 'face 'preview-face)
 	(unless (cdr strings)

[-- Attachment #3: Type: text/plain, Size: 52 bytes --]



-- 
David Kastrup, Kriemhildstr. 15, 44793 Bochum

[-- Attachment #4: Type: text/plain, Size: 142 bytes --]

_______________________________________________
Emacs-devel mailing list
Emacs-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-devel

  reply	other threads:[~2005-03-23 11:01 UTC|newest]

Thread overview: 46+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-03-21 13:20 Todays exercise of sanity (or does "see" really match "not"?) Lennart Borgman
2005-03-21 13:49 ` Luc Teirlinck
2005-03-21 14:00   ` Lennart Borgman
2005-03-21 19:27     ` Juri Linkov
2005-03-21 20:18       ` David Kastrup
2005-03-22 13:57       ` Richard Stallman
2005-03-22 14:46         ` David Kastrup
2005-03-22 17:29           ` Juri Linkov
2005-03-22 22:22             ` David Kastrup
2005-03-23  6:21             ` Richard Stallman
2005-03-23 13:08               ` Juri Linkov
2005-03-23 14:19                 ` Luc Teirlinck
2005-03-23 15:19                   ` Juri Linkov
2005-03-23 17:03                     ` Luc Teirlinck
2005-03-23 20:21                       ` Juri Linkov
2005-03-23 20:33                         ` Stefan Monnier
2005-03-23 21:16                         ` Luc Teirlinck
2005-03-23 21:42                           ` Luc Teirlinck
2005-03-23 22:54                             ` Kim F. Storm
2005-03-24  1:18                               ` Luc Teirlinck
2005-03-25  6:42                               ` Richard Stallman
2005-03-23 21:44                           ` Drew Adams
2005-03-24  0:21                           ` Juri Linkov
2005-03-24  1:12                             ` Luc Teirlinck
2005-03-25  6:41                           ` Richard Stallman
2005-03-23 21:30                         ` Luc Teirlinck
2005-03-24  5:18                       ` Richard Stallman
2005-03-23 20:26                 ` Richard Stallman
2005-03-24  0:19                   ` Juri Linkov
2005-03-25  6:42                     ` Richard Stallman
2005-03-23  0:59           ` Richard Stallman
2005-03-23  1:10             ` David Kastrup
2005-03-23 10:07               ` Kim F. Storm
2005-03-23 11:01                 ` David Kastrup [this message]
2005-03-23 22:57                   ` Kim F. Storm
2005-03-23 23:00                   ` Kim F. Storm
2005-03-23 23:57                     ` David Kastrup
2005-03-25  6:42                     ` Richard Stallman
2005-03-23 12:59                 ` Juri Linkov
2005-08-10  0:19       ` Drew Adams
2005-08-10  3:42         ` Eli Zaretskii
2005-08-10  4:19           ` Drew Adams
2005-08-10  4:03         ` Juri Linkov
2005-03-21 23:20   ` Drew Adams
2005-03-22  4:57     ` Miles Bader
2005-03-22 10:51       ` David Kastrup

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=x5fyymmxre.fsf@lola.goethe.zz \
    --to=dak@gnu.org \
    --cc=emacs-devel@gnu.org \
    --cc=juri@jurta.org \
    --cc=lennart.borgman.073@student.lu.se \
    --cc=rms@gnu.org \
    --cc=teirllm@dms.auburn.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).