Gnus development mailing list
 help / color / mirror / Atom feed
* [PATCH] Support opaque display-table objects on XEmacs
@ 2008-05-21 22:57 Aidan Kehoe
  2008-05-22  3:31 ` Miles Bader
  0 siblings, 1 reply; 8+ messages in thread
From: Aidan Kehoe @ 2008-05-21 22:57 UTC (permalink / raw)
  To: ding; +Cc: xemacs-patches


Hi, 

This patch adds support for the non-sequence display tables of XEmacs 21.5,
without any run-time overhead on GNU. A patch that’s equivalent in
functionality for that version has been integrated into the XEmacs package
repository; this conflicts with that, though--sorry Mike!--and is more
compatible with GNU. I’ve tested this (somewhat superficially) with XEmacs
21.5, 21.4 and GNU.

Please advise me if this is the wrong list to submit this to. I have papers
on file with the FSF for Gnus and for GNU Emacs as a whole, so that
shouldn’t be an issue.

Bye, 

Aidan

ChangeLog addition: 

2008-05-22  Aidan Kehoe  <kehoea@parhasard.net>

	* gnus-util.el (gnus-put-display-table): New.
	(gnus-get-display-table): New. 
	Macros that expand to an #'aset call under GNU, and to a runtime choice
	under XEmacs. 
	* gnus-sum.el (gnus-summary-set-display-table): 
	Use #'gnus-{put,get}-display-table, gnus-set-display-table for the
	display table, instead of #'aset. 
	* gnus-xmas.el (gnus-xmas-summary-set-display-table): 
	Use #'gnus-{put,get}-display-table, gnus-set-display-table for the
	display table.


Index: lisp/gnus-sum.el
===================================================================
RCS file: /usr/local/cvsroot/gnus/lisp/gnus-sum.el,v
retrieving revision 7.226
diff -u -r7.226 gnus-sum.el
--- lisp/gnus-sum.el	19 May 2008 08:47:42 -0000	7.226
+++ lisp/gnus-sum.el	21 May 2008 22:54:32 -0000
@@ -3417,13 +3417,13 @@
 	(i 32))
     ;; Nix out all the control chars...
     (while (>= (setq i (1- i)) 0)
-      (aset table i [??]))
+      (gnus-put-display-table i [??] table))
    ;; ... but not newline and cr, of course.  (cr is necessary for the
     ;; selective display).
-    (aset table ?\n nil)
-    (aset table ?\r nil)
+    (gnus-put-display-table ?\n nil table)
+    (gnus-put-display-table ?\r nil table)
     ;; We keep TAB as well.
-    (aset table ?\t nil)
+    (gnus-put-display-table ?\t nil table)
     ;; We nix out any glyphs 127 through 255, or 127 through 159 in
     ;; Emacs 23 (unicode), that are not set already.
     (let ((i (if (ignore-errors (= (make-char 'latin-iso8859-1 160) 160))
@@ -3431,8 +3431,8 @@
 	       256)))
       (while (>= (setq i (1- i)) 127)
 	;; Only modify if the entry is nil.
-	(unless (aref table i)
-	  (aset table i [??]))))
+	(unless (get-display-table i table)
+	  (put-display-table i [??] table))))
     (setq buffer-display-table table)))
 
 (defun gnus-summary-set-article-display-arrow (pos)
Index: lisp/gnus-util.el
===================================================================
RCS file: /usr/local/cvsroot/gnus/lisp/gnus-util.el,v
retrieving revision 7.80
diff -u -r7.80 gnus-util.el
--- lisp/gnus-util.el	19 May 2008 08:47:42 -0000	7.80
+++ lisp/gnus-util.el	21 May 2008 22:54:32 -0000
@@ -1798,6 +1798,27 @@
 	     ;; that intends to handle the quit signal next time.
 	     (eval '(ignore nil))))))
 
+(defmacro gnus-put-display-table (range value display-table)
+  "Set the value for char RANGE to VALUE in DISPLAY-TABLE.  "
+  (if (featurep 'xemacs)
+      (progn
+        `(if (fboundp 'put-display-table)
+          (put-display-table ,range ,value ,display-table)
+          (if (sequencep ,display-table)
+              (aset ,display-table ,range ,value)
+            (put-char-table ,range ,value ,display-table))))
+    `(aset ,display-table ,range ,value)))
+
+(defmacro gnus-get-display-table (character display-table)
+  "Find value for CHARACTER in DISPLAY-TABLE.  "
+  (if (featurep 'xemacs)
+      `(if (fboundp 'get-display-table)
+          (get-display-table ,character ,display-table)
+          (if (sequencep ,display-table)
+              (aref ,display-table ,character)
+            (get-char-table ,character ,display-table)))
+    `(aref ,display-table ,char-table)))
+
 (provide 'gnus-util)
 
 ;; arch-tag: f94991af-d32b-4c97-8c26-ca12a934de49
Index: lisp/gnus-xmas.el
===================================================================
RCS file: /usr/local/cvsroot/gnus/lisp/gnus-xmas.el,v
retrieving revision 7.25
diff -u -r7.25 gnus-xmas.el
--- lisp/gnus-xmas.el	10 Mar 2008 00:53:11 -0000	7.25
+++ lisp/gnus-xmas.el	21 May 2008 22:54:32 -0000
@@ -39,6 +39,7 @@
 (defvar menu-bar-mode (featurep 'menubar))
 (require 'messagexmas)
 (require 'wid-edit)
+(require 'gnus-util)
 
 (defgroup gnus-xmas nil
   "XEmacsoid support for Gnus"
@@ -173,18 +174,18 @@
 	(i 32))
     ;; Nix out all the control chars...
     (while (>= (setq i (1- i)) 0)
-      (aset table i [??]))
+      (gnus-put-display-table i [??] table))
     ;; ... but not newline and cr, of course.  (cr is necessary for the
     ;; selective display).
-    (aset table ?\n nil)
-    (aset table ?\r nil)
+    (gnus-put-display-table ?\n nil table)
+    (gnus-put-display-table ?\r nil table)
     ;; We keep TAB as well.
-    (aset table ?\t nil)
+    (gnus-put-display-table ?\t nil table)
     ;; We nix out any glyphs over 126 below ctl-arrow.
     (let ((i (if (integerp ctl-arrow) ctl-arrow 160)))
       (while (>= (setq i (1- i)) 127)
-	(unless (aref table i)
-	  (aset table i [??]))))
+	(unless (gnus-get-display-table i table)
+	  (gnus-put-display-table i [??] table))))
     ;; Can't use `set-specifier' because of a bug in 19.14 and earlier
     (add-spec-to-specifier current-display-table table (current-buffer) nil)))

-- 
¿Dónde estará ahora mi sobrino Yoghurtu Nghé, que tuvo que huir
precipitadamente de la aldea por culpa de la escasez de rinocerontes?

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH] Support opaque display-table objects on XEmacs
  2008-05-21 22:57 [PATCH] Support opaque display-table objects on XEmacs Aidan Kehoe
@ 2008-05-22  3:31 ` Miles Bader
  2008-05-27 20:34   ` Reiner Steib
  0 siblings, 1 reply; 8+ messages in thread
From: Miles Bader @ 2008-05-22  3:31 UTC (permalink / raw)
  To: ding; +Cc: xemacs-patches

Aidan Kehoe <kehoea@parhasard.net> writes:
> @@ -3431,8 +3431,8 @@
>  	       256)))
>        (while (>= (setq i (1- i)) 127)
>  	;; Only modify if the entry is nil.
> -	(unless (aref table i)
> -	  (aset table i [??]))))
> +	(unless (get-display-table i table)
> +	  (put-display-table i [??] table))))
>      (setq buffer-display-table table)))

Should those be `gnus-get-display-table' and `gnus-put-display-table'?

-Miles

-- 
Fast, small, soon; pick any 2.




^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH] Support opaque display-table objects on XEmacs
  2008-05-22  3:31 ` Miles Bader
@ 2008-05-27 20:34   ` Reiner Steib
  2008-05-27 21:02     ` Aidan Kehoe
  0 siblings, 1 reply; 8+ messages in thread
From: Reiner Steib @ 2008-05-27 20:34 UTC (permalink / raw)
  To: Aidan Kehoe; +Cc: ding, xemacs-patches

On Thu, May 22 2008, Miles Bader wrote:

> Aidan Kehoe <kehoea@parhasard.net> writes:
>> This patch adds support for the non-sequence display tables of XEmacs 21.5,
>> without any run-time overhead on GNU. A patch that’s equivalent in
>> functionality for that version has been integrated into the XEmacs package
>> repository; this conflicts with that, though--sorry Mike!--and is more
>> compatible with GNU. 

I gather that it should be applied to the stable and development
branch.  Right?

>> I’ve tested this (somewhat superficially) with XEmacs 21.5, 21.4
>> and GNU.

(Just call the later "Emacs".)

>> Please advise me if this is the wrong list to submit this to. 

It's the right list.  Thanks.

>> I have papers on file with the FSF for Gnus and for GNU Emacs as a
>> whole, so that shouldn’t be an issue.

Confirmed.
 
>> 	* gnus-util.el (gnus-put-display-table): New.
>> 	(gnus-get-display-table): New. 
>> 	Macros that expand to an #'aset call under GNU, and to a runtime choice
>> 	under XEmacs. 

Is writing “#'” a new XEmacsy ChangeLog convention?

>> 	* gnus-sum.el (gnus-summary-set-display-table): 
>> 	Use #'gnus-{put,get}-display-table, gnus-set-display-table for the
>> 	display table, instead of #'aset. 
>> 	* gnus-xmas.el (gnus-xmas-summary-set-display-table): 
>> 	Use #'gnus-{put,get}-display-table, gnus-set-display-table for the
>> 	display table.

It's better (e.g. for searching) to spell out the macro names (not
using {put,get}).

>> @@ -3431,8 +3431,8 @@
>>  	       256)))
>>        (while (>= (setq i (1- i)) 127)
>>  	;; Only modify if the entry is nil.
>> -	(unless (aref table i)
>> -	  (aset table i [??]))))
>> +	(unless (get-display-table i table)
>> +	  (put-display-table i [??] table))))
>>      (setq buffer-display-table table)))
>
> Should those be `gnus-get-display-table' and `gnus-put-display-table'?

Aidan?

>> +(defmacro gnus-put-display-table (range value display-table)
>> +  "Set the value for char RANGE to VALUE in DISPLAY-TABLE.  "
>> +  (if (featurep 'xemacs)
>> +      (progn

Useless `progn'?

>> +        `(if (fboundp 'put-display-table)
>> +          (put-display-table ,range ,value ,display-table)
>> +          (if (sequencep ,display-table)
>> +              (aset ,display-table ,range ,value)
>> +            (put-char-table ,range ,value ,display-table))))

`cond' would be more readable than an `if'-cascade, IMHO.

>> +    `(aset ,display-table ,range ,value)))

Bye, Reiner.
-- 
       ,,,
      (o o)
---ooO-(_)-Ooo---  |  PGP key available  |  http://rsteib.home.pages.de/



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH] Support opaque display-table objects on XEmacs
  2008-05-27 20:34   ` Reiner Steib
@ 2008-05-27 21:02     ` Aidan Kehoe
  2008-05-27 21:21       ` Reiner Steib
  2008-06-09 20:03       ` [PATCH] Support opaque display-table objects on XEmacs (revised) Aidan Kehoe
  0 siblings, 2 replies; 8+ messages in thread
From: Aidan Kehoe @ 2008-05-27 21:02 UTC (permalink / raw)
  To: Reiner Steib; +Cc: xemacs-patches, ding


 Ar an seachtú lá is fiche de mí Bealtaine, scríobh Reiner Steib: 

 > On Thu, May 22 2008, Miles Bader wrote:
 > 
 > > Aidan Kehoe <kehoea@parhasard.net> writes:
 > >> This patch adds support for the non-sequence display tables of XEmacs
 > >> 21.5, without any run-time overhead on GNU. A patch that’s equivalent
 > >> in functionality for that version has been integrated into the XEmacs
 > >> package repository; this conflicts with that, though--sorry Mike!--and
 > >> is more compatible with GNU.
 > 
 > I gather that it should be applied to the stable and development
 > branch.  Right?

That would be ideal from my perspective, yes. 

 > >> I’ve tested this (somewhat superficially) with XEmacs 21.5, 21.4
 > >> and GNU.
 > 
 > (Just call the later "Emacs".)

That’s something I’ve considered, yes. (Also, “latter”.)

 > >> Please advise me if this is the wrong list to submit this to. 
 > 
 > It's the right list.  Thanks.
 > 
 > >> I have papers on file with the FSF for Gnus and for GNU Emacs as a
 > >> whole, so that shouldn’t be an issue.
 > 
 > Confirmed.
 >  
 > >> 	* gnus-util.el (gnus-put-display-table): New.
 > >> 	(gnus-get-display-table): New. 
 > >> 	Macros that expand to an #'aset call under GNU, and to a runtime choice
 > >> 	under XEmacs. 
 > 
 > Is writing “#'” a new XEmacsy ChangeLog convention?

No, it’s a Common Lisp thing that I picked up from the SXEmacs folk, and
that I find helpful and clear. (In CL it’s a macro that throws an error at
read time if the following symbol doesn’t have a function definition.) 

 > >> 	* gnus-sum.el (gnus-summary-set-display-table): 
 > >> 	Use #'gnus-{put,get}-display-table, gnus-set-display-table for the
 > >> 	display table, instead of #'aset. 
 > >> 	* gnus-xmas.el (gnus-xmas-summary-set-display-table): 
 > >> 	Use #'gnus-{put,get}-display-table, gnus-set-display-table for the
 > >> 	display table.
 > 
 > It's better (e.g. for searching) to spell out the macro names (not
 > using {put,get}).

This is unclear to me; are you asking me to resubmit the patch for this
reason?

 > >> @@ -3431,8 +3431,8 @@
 > >>  	       256)))
 > >>        (while (>= (setq i (1- i)) 127)
 > >>  	;; Only modify if the entry is nil.
 > >> -	(unless (aref table i)
 > >> -	  (aset table i [??]))))
 > >> +	(unless (get-display-table i table)
 > >> +	  (put-display-table i [??] table))))
 > >>      (setq buffer-display-table table)))
 > >
 > > Should those be `gnus-get-display-table' and `gnus-put-display-table'?
 > 
 > Aidan?

Ah, yes, they should. I’ll resubmit the patch on that basis. 

 > >> +(defmacro gnus-put-display-table (range value display-table)
 > >> +  "Set the value for char RANGE to VALUE in DISPLAY-TABLE.  "
 > >> +  (if (featurep 'xemacs)
 > >> +      (progn
 > 
 > Useless `progn'?

Yes. 

 > >> +        `(if (fboundp 'put-display-table)
 > >> +          (put-display-table ,range ,value ,display-table)
 > >> +          (if (sequencep ,display-table)
 > >> +              (aset ,display-table ,range ,value)
 > >> +            (put-char-table ,range ,value ,display-table))))
 > 
 > `cond' would be more readable than an `if'-cascade, IMHO.

Meh, part of the cascade is at compile time, part at run time, and the
latter is only two deep. One more level and I would agree with you. 

-- 
¿Dónde estará ahora mi sobrino Yoghurtu Nghé, que tuvo que huir
precipitadamente de la aldea por culpa de la escasez de rinocerontes?

_______________________________________________
XEmacs-Patches mailing list
XEmacs-Patches@xemacs.org
http://calypso.tux.org/cgi-bin/mailman/listinfo/xemacs-patches

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH] Support opaque display-table objects on XEmacs
  2008-05-27 21:02     ` Aidan Kehoe
@ 2008-05-27 21:21       ` Reiner Steib
  2008-06-09 20:03       ` [PATCH] Support opaque display-table objects on XEmacs (revised) Aidan Kehoe
  1 sibling, 0 replies; 8+ messages in thread
From: Reiner Steib @ 2008-05-27 21:21 UTC (permalink / raw)
  To: Aidan Kehoe; +Cc: xemacs-patches, ding

On Tue, May 27 2008, Aidan Kehoe wrote:

>  Ar an seachtú lá is fiche de mí Bealtaine, scríobh Reiner Steib: 
>  > Is writing “#'” a new XEmacsy ChangeLog convention?
>
> No, it’s a Common Lisp thing that I picked up from the SXEmacs folk, and
> that I find helpful and clear. (In CL it’s a macro that throws an error at
> read time if the following symbol doesn’t have a function definition.) 

I'd rather follow the Emacs convention, i.e. strip it (or use
e.g. `aset').

>  > It's better (e.g. for searching) to spell out the macro names (not
>  > using {put,get}).
>
> This is unclear to me; are you asking me to resubmit the patch for this
> reason?

No.  But if you re-submit because of the other changes (useless
`progn', missing "gnus-" prefix), you may fix the ChangeLog as
well. ;-)

Bye, Reiner.
-- 
       ,,,
      (o o)
---ooO-(_)-Ooo---  |  PGP key available  |  http://rsteib.home.pages.de/



^ permalink raw reply	[flat|nested] 8+ messages in thread

* [PATCH] Support opaque display-table objects on XEmacs (revised)
  2008-05-27 21:02     ` Aidan Kehoe
  2008-05-27 21:21       ` Reiner Steib
@ 2008-06-09 20:03       ` Aidan Kehoe
  2008-06-14 15:48         ` Reiner Steib
  1 sibling, 1 reply; 8+ messages in thread
From: Aidan Kehoe @ 2008-06-09 20:03 UTC (permalink / raw)
  To: ding; +Cc: xemacs-patches, Reiner Steib


This supersedes the patch in 18492.30425.377545.700503@parhasard.net, taking
on board Reiner’s input. Tested with XEmacs 21.5; the other
incompatibilities there are independent of this.

lisp/ChangeLog addition: 

2008-05-22  Aidan Kehoe  <kehoea@parhasard.net>

	* gnus-util.el (gnus-put-display-table): New.
	(gnus-get-display-table): New. 
	Macros that expand to an `aset' call under GNU, and to a runtime choice
	under XEmacs. 
	* gnus-sum.el (gnus-summary-set-display-table): 
	Use `gnus-put-display-table', `gnus-get-display-table', 
	`gnus-set-display-table' for the display table, instead of `aset';
	* gnus-xmas.el (gnus-xmas-summary-set-display-table): 
	Use `gnus-put-display-table', `gnus-get-display-table', 
	`gnus-set-display-table' for the display table.


Index: lisp/gnus-sum.el
===================================================================
RCS file: /usr/local/cvsroot/gnus/lisp/gnus-sum.el,v
retrieving revision 7.227
diff -u -u -r7.227 gnus-sum.el
--- lisp/gnus-sum.el	24 May 2008 13:06:11 -0000	7.227
+++ lisp/gnus-sum.el	9 Jun 2008 20:00:15 -0000
@@ -3419,13 +3419,13 @@
 	(i 32))
     ;; Nix out all the control chars...
     (while (>= (setq i (1- i)) 0)
-      (aset table i [??]))
+      (gnus-put-display-table i [??] table))
    ;; ... but not newline and cr, of course.  (cr is necessary for the
     ;; selective display).
-    (aset table ?\n nil)
-    (aset table ?\r nil)
+    (gnus-put-display-table ?\n nil table)
+    (gnus-put-display-table ?\r nil table)
     ;; We keep TAB as well.
-    (aset table ?\t nil)
+    (gnus-put-display-table ?\t nil table)
     ;; We nix out any glyphs 127 through 255, or 127 through 159 in
     ;; Emacs 23 (unicode), that are not set already.
     (let ((i (if (ignore-errors (= (make-char 'latin-iso8859-1 160) 160))
@@ -3433,8 +3433,8 @@
 	       256)))
       (while (>= (setq i (1- i)) 127)
 	;; Only modify if the entry is nil.
-	(unless (aref table i)
-	  (aset table i [??]))))
+	(unless (gnus-get-display-table i table)
+	  (gnus-put-display-table i [??] table))))
     (setq buffer-display-table table)))
 
 (defun gnus-summary-set-article-display-arrow (pos)
Index: lisp/gnus-util.el
===================================================================
RCS file: /usr/local/cvsroot/gnus/lisp/gnus-util.el,v
retrieving revision 7.80
diff -u -u -r7.80 gnus-util.el
--- lisp/gnus-util.el	19 May 2008 08:47:42 -0000	7.80
+++ lisp/gnus-util.el	9 Jun 2008 20:00:15 -0000
@@ -1798,6 +1798,27 @@
 	     ;; that intends to handle the quit signal next time.
 	     (eval '(ignore nil))))))
 
+(defmacro gnus-put-display-table (range value display-table)
+  "Set the value for char RANGE to VALUE in DISPLAY-TABLE.  "
+  (if (featurep 'xemacs)
+      (progn
+        `(if (fboundp 'put-display-table)
+          (put-display-table ,range ,value ,display-table)
+          (if (sequencep ,display-table)
+              (aset ,display-table ,range ,value)
+            (put-char-table ,range ,value ,display-table))))
+    `(aset ,display-table ,range ,value)))
+
+(defmacro gnus-get-display-table (character display-table)
+  "Find value for CHARACTER in DISPLAY-TABLE.  "
+  (if (featurep 'xemacs)
+      `(if (fboundp 'get-display-table)
+          (get-display-table ,character ,display-table)
+          (if (sequencep ,display-table)
+              (aref ,display-table ,character)
+            (get-char-table ,character ,display-table)))
+    `(aref ,display-table ,char-table)))
+
 (provide 'gnus-util)
 
 ;; arch-tag: f94991af-d32b-4c97-8c26-ca12a934de49
Index: lisp/gnus-xmas.el
===================================================================
RCS file: /usr/local/cvsroot/gnus/lisp/gnus-xmas.el,v
retrieving revision 7.25
diff -u -u -r7.25 gnus-xmas.el
--- lisp/gnus-xmas.el	10 Mar 2008 00:53:11 -0000	7.25
+++ lisp/gnus-xmas.el	9 Jun 2008 20:00:15 -0000
@@ -39,6 +39,7 @@
 (defvar menu-bar-mode (featurep 'menubar))
 (require 'messagexmas)
 (require 'wid-edit)
+(require 'gnus-util)
 
 (defgroup gnus-xmas nil
   "XEmacsoid support for Gnus"
@@ -173,18 +174,18 @@
 	(i 32))
     ;; Nix out all the control chars...
     (while (>= (setq i (1- i)) 0)
-      (aset table i [??]))
+      (gnus-put-display-table i [??] table))
     ;; ... but not newline and cr, of course.  (cr is necessary for the
     ;; selective display).
-    (aset table ?\n nil)
-    (aset table ?\r nil)
+    (gnus-put-display-table ?\n nil table)
+    (gnus-put-display-table ?\r nil table)
     ;; We keep TAB as well.
-    (aset table ?\t nil)
+    (gnus-put-display-table ?\t nil table)
     ;; We nix out any glyphs over 126 below ctl-arrow.
     (let ((i (if (integerp ctl-arrow) ctl-arrow 160)))
       (while (>= (setq i (1- i)) 127)
-	(unless (aref table i)
-	  (aset table i [??]))))
+	(unless (gnus-get-display-table i table)
+	  (gnus-put-display-table i [??] table))))
     ;; Can't use `set-specifier' because of a bug in 19.14 and earlier
     (add-spec-to-specifier current-display-table table (current-buffer) nil)))
 

-- 
¿Dónde estará ahora mi sobrino Yoghurtu Nghé, que tuvo que huir
precipitadamente de la aldea por culpa de la escasez de rinocerontes?

_______________________________________________
XEmacs-Patches mailing list
XEmacs-Patches@xemacs.org
http://calypso.tux.org/cgi-bin/mailman/listinfo/xemacs-patches

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH] Support opaque display-table objects on XEmacs (revised)
  2008-06-09 20:03       ` [PATCH] Support opaque display-table objects on XEmacs (revised) Aidan Kehoe
@ 2008-06-14 15:48         ` Reiner Steib
  0 siblings, 0 replies; 8+ messages in thread
From: Reiner Steib @ 2008-06-14 15:48 UTC (permalink / raw)
  To: Aidan Kehoe; +Cc: ding, xemacs-patches

On Mon, Jun 09 2008, Aidan Kehoe wrote:

> This supersedes the patch in 18492.30425.377545.700503@parhasard.net, taking
> on board Reiner’s input. Tested with XEmacs 21.5; the other
> incompatibilities there are independent of this.

Which "other incompatibilities"?  Related to Gnus?

> 	* gnus-util.el (gnus-put-display-table): New.
> 	(gnus-get-display-table): New. 
> 	Macros that expand to an `aset' call under GNU, and to a runtime choice
> 	under XEmacs. 
> 	* gnus-sum.el (gnus-summary-set-display-table): 
> 	Use `gnus-put-display-table', `gnus-get-display-table', 
> 	`gnus-set-display-table' for the display table, instead of `aset';
> 	* gnus-xmas.el (gnus-xmas-summary-set-display-table): 
> 	Use `gnus-put-display-table', `gnus-get-display-table', 
> 	`gnus-set-display-table' for the display table.

Committed to the trunk, with a slightly modified ChangeLog entry and
the fix mentioned below (please confirm that is it correct).

I'll install it on v5-10 as well if nobody finds a problem within a
couple of days.

> +(defmacro gnus-get-display-table (character display-table)
> +  "Find value for CHARACTER in DISPLAY-TABLE.  "
> +  (if (featurep 'xemacs)
> +      `(if (fboundp 'get-display-table)
> +          (get-display-table ,character ,display-table)
> +          (if (sequencep ,display-table)
> +              (aref ,display-table ,character)
> +            (get-char-table ,character ,display-table)))
> +    `(aref ,display-table ,char-table)))

I suppose this should read...

       `(aref ,display-table ,character)))

,----
| In gnus-get-display-table:
| gnus-util.el:1823:28:Warning: reference to free variable `char-table'
`----

Bye, Reiner.
-- 
       ,,,
      (o o)
---ooO-(_)-Ooo---  |  PGP key available  |  http://rsteib.home.pages.de/



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH] Support opaque display-table objects on XEmacs (revised)
@ 2008-06-16 18:02 Aidan Kehoe
  0 siblings, 0 replies; 8+ messages in thread
From: Aidan Kehoe @ 2008-06-16 18:02 UTC (permalink / raw)
  To: Reiner Steib; +Cc: xemacs-patches, ding

In-Reply-To: <v9ve0c81b6.fsf@marauder.physik.uni-ulm.de>
References: <18484.43203.462970.885072@parhasard.net>
	<buo7idnggl5.fsf@dhapc248.dev.necel.com>
	<v9od6r5vwf.fsf@marauder.physik.uni-ulm.de>
	<18492.30425.377545.700503@parhasard.net>
	<18509.35990.374622.216796@parhasard.net>
	<v9ve0c81b6.fsf@marauder.physik.uni-ulm.de>
X-Mailer: VM 7.19 under 21.5  (beta28) "fuki" XEmacs Lucid
FCC: ~/mail/outgoing
X-Echelon-distraction:  KWT-46 Saddam Hussein wwics FX WWABNCP SAPM 


 Ar an ceathrú lá déag de mí Meitheamh, scríobh Reiner Steib: 

 > On Mon, Jun 09 2008, Aidan Kehoe wrote:
 > 
 > > This supersedes the patch in 18492.30425.377545.700503@parhasard.net,
 > > taking on board Reiner’s input. Tested with XEmacs 21.5; the other
 > > incompatibilities there are independent of this.
 > 
 > Which "other incompatibilities"?  Related to Gnus?

Yes. They weren’t a priority for me at the time, and I can’t reproduce them
with a few minutes’ testing. 

 > > 	* gnus-util.el (gnus-put-display-table): New.
 > > 	(gnus-get-display-table): New. 
 > > 	Macros that expand to an `aset' call under GNU, and to a runtime choice
 > > 	under XEmacs. 
 > > 	* gnus-sum.el (gnus-summary-set-display-table): 
 > > 	Use `gnus-put-display-table', `gnus-get-display-table', 
 > > 	`gnus-set-display-table' for the display table, instead of `aset';
 > > 	* gnus-xmas.el (gnus-xmas-summary-set-display-table): 
 > > 	Use `gnus-put-display-table', `gnus-get-display-table', 
 > > 	`gnus-set-display-table' for the display table.
 > 
 > Committed to the trunk, with a slightly modified ChangeLog entry and
 > the fix mentioned below (please confirm that is it correct).

It is correct, thank you for that. 

-- 
¿Dónde estará ahora mi sobrino Yoghurtu Nghé, que tuvo que huir
precipitadamente de la aldea por culpa de la escasez de rinocerontes?

_______________________________________________
XEmacs-Patches mailing list
XEmacs-Patches@xemacs.org
http://calypso.tux.org/cgi-bin/mailman/listinfo/xemacs-patches

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2008-06-16 18:02 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-05-21 22:57 [PATCH] Support opaque display-table objects on XEmacs Aidan Kehoe
2008-05-22  3:31 ` Miles Bader
2008-05-27 20:34   ` Reiner Steib
2008-05-27 21:02     ` Aidan Kehoe
2008-05-27 21:21       ` Reiner Steib
2008-06-09 20:03       ` [PATCH] Support opaque display-table objects on XEmacs (revised) Aidan Kehoe
2008-06-14 15:48         ` Reiner Steib
2008-06-16 18:02 Aidan Kehoe

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 NNTP newsgroup(s).