Return-Path: <handa@etl.go.jp>
Reply-To: mule@etl.go.jp
Errors-To: handa@etl.go.jp
Sender: handa@etl.go.jp
X-Seqno: 1804
To: mule@etl.go.jp
Subject: Re: w3 and mule-beta
References: <199609300933.SAA08964@orion.kurims.kyoto-u.ac.jp>
From: Thierry Emery <Thierry.Emery@aar.alcatel-alsthom.fr>
Date: 30 Sep 1996 10:52:05 +0100
In-Reply-To: Jens-U H Petersen's message of Mon, 30 Sep 1996 18:33:52 +0900
Lines: 679
X-Mailer: Gnus v5.3/Emacs 19.33
Content-Type: text
Content-Length: 24023

Jens-U H Petersen <petersen@kurims.kyoto-u.ac.jp> writes:

> Does anyone have w3 working under mule-beta?
> 

Hi,

Here are some *unofficial* patches I made for Emacs-w3 3.0.22
on Mule 2.4 beta version based on Gnu Emacs 19.33. I have sent them to
W.M. Perry too.

--
Thierry Emery

*** w3.old/Makefile	Tue Sep 24 17:55:14 1996
--- w3/Makefile	Fri Sep 27 12:34:32 1996
***************
*** 49,54 ****
--- 51,57 ----
  
  SOURCES = \
  	w3.el w3-display.el w3-e19.el w3-mule.el w3-parse.el w3-print.el\
+ 	w3-mule-2-4.el							\
  	w3-vars.el w3-xemac.el w3-style.el w3-about.el w3-hot.el	\
  	xpm-button.el xbm-button.el w3-toolbar.el font.el w3-sysdp.el	\
  	w3-annotat.el w3-auto.el w3-forms.el images.el w3-imap.el	\
***************
*** 58,63 ****
--- 61,67 ----
  
  OBJECTS = \
  	w3.elc w3-display.elc w3-e19.elc w3-mule.elc w3-parse.elc	\
+ 	w3-mule-2-4.elc							\
  	w3-print.elc w3-vars.elc w3-xemac.elc w3-style.elc		\
  	w3-about.elc w3-hot.elc xpm-button.elc xbm-button.elc		\
  	w3-toolbar.elc font.elc w3-annotat.elc w3-auto.elc		\
*** w3.old/docomp.el	Mon Sep 23 06:54:56 1996
--- w3/docomp.el	Fri Sep 27 12:44:50 1996
***************
*** 60,68 ****
  		      'has-modeline-p 'baud-rate)
  
  ;; For MULE
! (w3-declare-variables '*noconv* '*autoconv* '*euc-japan* '*internal*
! 		      'w3-mime-list-for-code-conversion 'lc-ltn1
! 		      'file-coding-system-for-read 'file-coding-system)
  
  ;; For Mailcrypt
  (w3-declare-variables 'mc-pgp-path 'mc-pgp-key-begin-line 'mc-ripem-pubkeyfile
--- 60,73 ----
  		      'has-modeline-p 'baud-rate)
  
  ;; For MULE
! (if (and (boundp 'mule-version) (string-match "^2.4" mule-version))
!     ; mule 2.4
!     (w3-declare-variables 'w3-mime-list-for-code-conversion 'charset-latin-1
! 			  'coding-system-for-read 'buffer-file-coding-system)
!   ; mule 2.3
!   (w3-declare-variables '*noconv* '*autoconv* '*euc-japan* '*internal*
! 			'w3-mime-list-for-code-conversion 'lc-ltn1
! 			'file-coding-system-for-read 'file-coding-system))
  
  ;; For Mailcrypt
  (w3-declare-variables 'mc-pgp-path 'mc-pgp-key-begin-line 'mc-ripem-pubkeyfile
***************
*** 94,99 ****
--- 99,105 ----
  ;; Turn off most of the warnings here.
  (setq byte-compile-warnings '(free-vars))
  
+ (load-library "w3-sysdp")
  (require 'w3-vars)
  (require 'url)
  (require 'mm)
***************
*** 100,104 ****
  (and w3-running-FSF19
       (< emacs-minor-version 29)
       (require 'font))
- (load-library "w3-sysdp")
  (provide 'ange-ftp)
--- 106,109 ----
*** w3.old/mm.el	Tue Sep 24 07:04:48 1996
--- w3/mm.el	Fri Sep 27 11:36:28 1996
***************
*** 382,389 ****
  	    (require-final-newline nil))
  	(set-buffer old-buff)
  	(if (featurep 'mule)
! 	    (let ((mc-flag t))
! 	      (write-region (point-min) (point-max) file nil nil *noconv*))
  	  (write-region (point-min) (point-max) file))
  	(kill-buffer (current-buffer))))
    (fset 'mm-save-binary-file 'w3-save-binary-file))
--- 382,394 ----
  	    (require-final-newline nil))
  	(set-buffer old-buff)
  	(if (featurep 'mule)
! 	    (cond (mule-2-4-p ; mule 2.4
! 		   (let ((enable-multibyte-characters t)
! 			 (coding-system-for-write 'no-conversion))
! 		     (write-region (point-min) (point-max) file)))
! 		  (t ; mule 2.3
! 		   (let ((mc-flag t))
! 		     (write-region (point-min) (point-max) file nil nil *noconv*))))
  	  (write-region (point-min) (point-max) file))
  	(kill-buffer (current-buffer))))
    (fset 'mm-save-binary-file 'w3-save-binary-file))
***************
*** 1094,1100 ****
    (let ((fname (mm-generate-unique-filename "%s.au"))
  	(synchronous-sounds t))		; Play synchronously
      (if (featurep 'mule)
! 	(write-region (point-min) (point-max) fname nil nil *noconv*)
        (write-region (point-min) (point-max) fname))
      (kill-buffer (current-buffer))
      (play-sound-file fname)
--- 1099,1111 ----
    (let ((fname (mm-generate-unique-filename "%s.au"))
  	(synchronous-sounds t))		; Play synchronously
      (if (featurep 'mule)
! 	(cond (mule-2-4-p
! 	       ; mule 2.4
! 	       (let ((coding-system-for-write 'no-conversion))
! 		 (write-region (point-min) (point-max) fname)))
! 	      ; mule 2.3
! 	      (t
! 	       (write-region (point-min) (point-max) fname nil nil *noconv*)))
        (write-region (point-min) (point-max) fname))
      (kill-buffer (current-buffer))
      (play-sound-file fname)
*** w3.old/url-file.el	Tue Sep 24 07:04:47 1996
--- w3/url-file.el	Fri Sep 27 11:36:24 1996
***************
*** 38,45 ****
  	(jka-compr-compression-info-list nil)
  	(jam-zcat-filename-list nil)
  	(file-coding-system-for-read
! 	  (if (featurep 'mule)
! 	      *noconv*)))
      (setq compressed 
  	  (cond
  	   ((file-exists-p fname) nil)
--- 38,48 ----
  	(jka-compr-compression-info-list nil)
  	(jam-zcat-filename-list nil)
  	(file-coding-system-for-read
! 	  (if (and (featurep 'mule) (not mule-2-4-p)) ; mule 2.3
! 	      *noconv*))
! 	(coding-system-for-read
! 	 (if (and (featurep 'mule) mule-2-4-p) ; mule 2.4
! 	     'no-conversion)))
      (setq compressed 
  	  (cond
  	   ((file-exists-p fname) nil)
*** w3.old/url-hash.el	Tue Sep 24 07:04:47 1996
--- w3/url-hash.el	Thu Sep 19 12:12:50 1996
***************
*** 24,29 ****
--- 24,32 ----
  ;;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
  ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
  
+ (require 'cl)
+ (load-library "cl-extra")
+ 
  ;; Hash tables
  (cond
   ((and (fboundp 'maphash) (subrp (symbol-function 'maphash)))
*** w3.old/url-vars.el	Tue Sep 24 07:04:48 1996
--- w3/url-vars.el	Fri Sep 27 11:36:28 1996
***************
*** 127,145 ****
  the value of url-pgp/pem-entity.")
  
  (defvar url-mule-retrieval-coding-system (if (featurep 'mule)
! 					     (if (boundp '*euc-japan*)
! 						 *euc-japan*
! 					       'euc-japan-unix)
  					  nil)
    "Coding system for retrieval, used before hexified.")
  
! (defvar url-mule-no-coding-system (cond
! 				   ((and (featurep 'mule)
! 					 (string-match "XEmacs" emacs-version))
! 				    'noconv)
! 				   ((featurep 'mule)
! 				    '*noconv*)
! 				   (t nil))
    "*Variable containing a symbol that specifies no coding system is to be used.
  Only used if you are in a Mule-enabled Emacsen.")
  
--- 127,151 ----
  the value of url-pgp/pem-entity.")
  
  (defvar url-mule-retrieval-coding-system (if (featurep 'mule)
! 					     (if mule-2-4-p
! 						 ; mule 2.4
! 						 'coding-system-euc-japan
! 					       ; mule 2.3
! 					       (if (boundp '*euc-japan*)
! 						   *euc-japan*
! 						 'euc-japan-unix))
  					  nil)
    "Coding system for retrieval, used before hexified.")
  
! (defvar url-mule-no-coding-system (if (featurep 'mule)
! 				      (if mule-2-4-p
! 					  ; mule 2.4
! 					  'no-conversion
! 					 ; mule 2.3
! 					(if (string-match "XEmacs" emacs-version)
! 					    'noconv
! 					  '*noconv*))
! 				    nil)
    "*Variable containing a symbol that specifies no coding system is to be used.
  Only used if you are in a Mule-enabled Emacsen.")
  
*** w3.old/url.el	Tue Sep 24 07:04:48 1996
--- w3/url.el	Fri Sep 27 11:36:27 1996
***************
*** 827,837 ****
   	      (if (featurep 'mule)
  		  (save-excursion
  		    (set-buffer (get-buffer-create buffer))
! 		    (setq mc-flag nil)
! 		    (if (not url-running-xemacs)
! 			(set-process-coding-system conn *noconv* *noconv*)
! 		      (set-process-input-coding-system conn 'noconv)
! 		      (set-process-output-coding-system conn 'noconv))))
   	      conn)
  	  (error "Unable to connect to %s:%s" host service))))
       ((eq tmp-gateway-method 'program)
--- 832,847 ----
   	      (if (featurep 'mule)
  		  (save-excursion
  		    (set-buffer (get-buffer-create buffer))
! 		    (if mule-2-4-p
! 			; mule 2.4
! 			(progn (setq enable-multibyte-characters nil)
! 			       (set-process-coding-system conn 'no-conversion 'no-conversion))
! 		      ; mule 2.3
! 		      (progn (setq mc-flag nil)
! 			     (if (not url-running-xemacs)
! 				 (set-process-coding-system conn *noconv* *noconv*)
! 			       (set-process-input-coding-system conn 'noconv)
! 			       (set-process-output-coding-system conn 'noconv))))))
   	      conn)
  	  (error "Unable to connect to %s:%s" host service))))
       ((eq tmp-gateway-method 'program)
***************
*** 1491,1498 ****
  (defun url-hexify-string (str)
    "Escape characters in a string"
    (if (and (featurep 'mule) str)
!       (setq str (code-convert-string 
!  		 str *internal* url-mule-retrieval-coding-system)))
    (setq str (mapconcat
  	     (function
  	      (lambda (char)
--- 1504,1516 ----
  (defun url-hexify-string (str)
    "Escape characters in a string"
    (if (and (featurep 'mule) str)
!       (if mule-2-4-p
! 	  ; mule 2.4
! 	  (setq str (decode-coding-string
! 		     str url-mule-retrieval-coding-system))
! 	; mule 2.3
! 	(setq str (code-convert-string
! 		   str *internal* url-mule-retrieval-coding-system))))
    (setq str (mapconcat
  	     (function
  	      (lambda (char)
***************
*** 1620,1626 ****
  			  (cdr-safe (assoc extn url-uncompressor-alist))))
  	     (done nil)
  	     (default-process-coding-system
! 	       (if (featurep 'mule) (cons *noconv* *noconv*))))
  	(mapcar
  	 (function
  	  (lambda (code)
--- 1638,1649 ----
  			  (cdr-safe (assoc extn url-uncompressor-alist))))
  	     (done nil)
  	     (default-process-coding-system
! 	       (if (featurep 'mule)
! 		   (if mule-2-4-p
! 		       ; mule 2.4
! 		       (cons 'no-conversion 'no-conversion)
! 		     ; mule 2.3
! 		     (cons *noconv* *noconv*)))))
  	(mapcar
  	 (function
  	  (lambda (code)
*** w3.old/w3-forms.el	Tue Sep 24 07:04:47 1996
--- w3/w3-forms.el	Fri Sep 27 11:36:27 1996
***************
*** 33,39 ****
  
  (require 'widget)
  
! (if (featurep 'mule) (fset 'string-width 'length))
  
  ;; These are things in later versions of the widget package that I don't
  ;; have yet.
--- 33,39 ----
  
  (require 'widget)
  
! (or (featurep 'mule) (fset 'string-width 'length))
  
  ;; These are things in later versions of the widget package that I don't
  ;; have yet.
***************
*** 262,274 ****
   If width of the truncated string is less than LEN, and if a character PAD is
   defined, add padding end of it."
    (if (featurep 'mule)
!       (let ((cl (string-to-char-list str)) (n 0) (sw 0))
!  	(if (<= (string-width str) len) str
!  	  (while (<= (setq sw (+ (char-width (nth n cl)) sw)) len)
!  	    (setq n (1+ n)))
!  	  (string-match (make-string n ?.) str)
!  	  (setq str (substring str 0 (match-end 0))))
!  	(if pad (concat str (make-string (- len (string-width str)) pad)) str))
      (concat (if (> (length str) len) (substring str 0 len) str)
   	    (if (or (null pad) (> (length str) len))
   		""
--- 262,284 ----
   If width of the truncated string is less than LEN, and if a character PAD is
   defined, add padding end of it."
    (if (featurep 'mule)
!       (if mule-2-4-p
! 	  ; mule 2.4
! 	  (let ((cl (string-to-vector str)) (n 0) (sw 0))
! 	    (if (<= (string-width str) len) str
! 	      (while (<= (setq sw (+ (char-width (aref cl n)) sw)) len)
! 		(setq n (1+ n)))
! 	      (string-match (make-string n ?.) str)
! 	      (setq str (substring str 0 (match-end 0))))
! 	    (if pad (concat str (make-string (- len (string-width str)) pad)) str))
! 	; mule 2.3
! 	(let ((cl (string-to-char-list str)) (n 0) (sw 0))
! 	  (if (<= (string-width str) len) str
! 	    (while (<= (setq sw (+ (char-width (nth n cl)) sw)) len)
! 	      (setq n (1+ n)))
! 	    (string-match (make-string n ?.) str)
! 	    (setq str (substring str 0 (match-end 0))))
! 	  (if pad (concat str (make-string (- len (string-width str)) pad)) str)))
      (concat (if (> (length str) len) (substring str 0 len) str)
   	    (if (or (null pad) (> (length str) len))
   		""
***************
*** 539,549 ****
  Blasphemous crap because someone didn't think %20 was good enough for encoding
  spaces.  Die Die Die."
    (if (and (featurep 'mule) chunk)
!       (setq chunk (if w3-running-xemacs
! 		      (decode-coding-string
! 		       chunk url-mule-retrieval-coding-system)
! 		    (code-convert-string 
! 		     chunk *internal* url-mule-retrieval-coding-system))))
    (mapconcat
     (function
      (lambda (char)
--- 549,564 ----
  Blasphemous crap because someone didn't think %20 was good enough for encoding
  spaces.  Die Die Die."
    (if (and (featurep 'mule) chunk)
!       (setq chunk (if mule-2-4-p
! 		      ; mule 2.4
! 		      (setq chunk (encode-coding-string
! 				   chunk url-mule-retrieval-coding-system))
! 		    ; mule 2.3
! 		    (if w3-running-xemacs
! 			(decode-coding-string ; DEcode ???
! 			 chunk url-mule-retrieval-coding-system)
! 		      (code-convert-string 
! 		       chunk *internal* url-mule-retrieval-coding-system)))))
    (mapconcat
     (function
      (lambda (char)
*** w3.old/w3-mule-2-4.el
--- w3/w3-mule-2-4.el
***************
*** 0, 0 ***
--- 1, 76 ---
+ ;;; w3-mule.el --- MULE 18/19 specific functions for emacs-w3
+ ;; Author: wmperry
+ ;; Created: 1996/09/09 03:32:38
+ ;; Version: 1.3
+ ;; Keywords: faces, help, i18n, mouse, hypermedia
+ 
+ ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+ ;;; Copyright (c) 1993 - 1996 by William M. Perry (wmperry@cs.indiana.edu)
+ ;;; Copyright (c) 1996 Free Software Foundation, Inc.
+ ;;;
+ ;;; This file is part of GNU Emacs.
+ ;;;
+ ;;; GNU Emacs is free software; you can redistribute it and/or modify
+ ;;; it under the terms of the GNU General Public License as published by
+ ;;; the Free Software Foundation; either version 2, or (at your option)
+ ;;; any later version.
+ ;;;
+ ;;; GNU Emacs is distributed in the hope that it will be useful,
+ ;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+ ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ ;;; GNU General Public License for more details.
+ ;;;
+ ;;; You should have received a copy of the GNU General Public License
+ ;;; along with GNU Emacs; see the file COPYING.  If not, write to
+ ;;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+ ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+ 
+ ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+ ;;; Printing a mule buffer as postscript.  Requires m2ps
+ ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+ (defun w3-m2ps-buffer (&optional buffer)
+   "Print a buffer by passing it through m2ps and lpr."
+   (or buffer (setq buffer (current-buffer)))
+   (let ((x (save-excursion (set-buffer buffer) tab-width)))
+     (save-excursion
+       (set-buffer (get-buffer-create " *mule-print*"))
+       (erase-buffer)
+       (insert-buffer buffer)
+       (if (/= x tab-width)
+ 	  (progn
+ 	    (setq tab-width x)
+ 	    (message "Converting tabs")
+ 	    (untabify (point-min) (point-max))))
+       (setq buffer-file-coding-system 'coding-system-internal)
+       (shell-command-on-region (point-min) (point-max)
+ 			       "m2ps | lpr" t))))
+ 	    
+ ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+ ;;; Multi-Lingual Emacs (MULE) Specific Functions
+ ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+ (defvar attributed-region nil
+   "Bogus definition to get rid of compile-time warnings.")
+ 
+ (defun w3-inhibit-code-conversion (proc buf)
+   "Inhibit Mule's subprocess PROC from code converting in BUF."
+   (save-excursion
+     (set-buffer buf)
+     (setq enable-multibyte-characters nil))
+   (set-process-coding-system proc 'no-conversion 'no-conversion))
+ 
+ (defvar w3-mime-list-for-code-conversion
+   '("text/plain" "text/html")
+   "List of MIME types that require Mules' code conversion.")
+ (make-variable-buffer-local 'w3-mime-list-for-code-conversion)
+ 
+ (defun w3-convert-code-for-mule (mmtype)
+   "Convert current data into the appropriate coding system"
+   (and (or (not mmtype) (member mmtype w3-mime-list-for-code-conversion))
+        (let* ((c (detect-coding-region (point-min) (point-max)))
+ 	      (code (or (and (listp c) (car c)) c)))
+ 	 (setq enable-multibyte-characters t)
+ 	 (cond ((and code (not (eq code 'coding-system-automatic)))
+ 		(decode-coding-region (point-min) (point-max) code)
+ 		(set-buffer-file-coding-system code))))))
+ 
+ (provide 'w3-mule-2-4)
*** w3.old/w3-parse.el	Tue Sep 24 07:04:47 1996
--- w3/w3-parse.el	Fri Sep 27 11:36:26 1996
***************
*** 293,301 ****
                               (cond
                                ((and (> c 127) (boundp 'MULE))
                                 (make-character lc-ltn1 c))
!                               ;;((and (> c 127) (featurep 'mule))
!                               ;; What???
!                               ;;)
                                (t
                                 c))))
  			(cdr (car html-entities)))))
--- 293,303 ----
                               (cond
                                ((and (> c 127) (boundp 'MULE))
                                 (make-character lc-ltn1 c))
!                               ((and (> c 127) (featurep 'mule))
!                                (if mule-2-4-p ; mule 2.4
!                                    (make-char charset-latin-1 c)
!                                  ;; What??? (Xemacs)
!                                  ))
                                (t
                                 c))))
  			(cdr (car html-entities)))))
***************
*** 448,456 ****
                 (cond
                  ((and (boundp 'MULE) (> w3-p-s-num 127))
                   (make-character lc-ltn1 w3-p-s-num))
!                 ;;((and (featurep 'mule) (> w3-p-s-num 127))
!                 ;;what??
!                 ;;)
                  (t
                   w3-p-s-num)))))
       ((looking-at "&#\\(re\\|rs\\|space\\|tab\\)[\ ;\n]?") ; \n should be \r
--- 450,460 ----
                 (cond
                  ((and (boundp 'MULE) (> w3-p-s-num 127))
                   (make-character lc-ltn1 w3-p-s-num))
!                 ((and (featurep 'mule) (> w3-p-s-num 127))
!                  (if mule-2-4-p ; mule 2.4
!                      (make-char charset-latin-1 w3-p-s-num)
!                    ;;what?? (Xemacs)
!                    ))
                  (t
                   w3-p-s-num)))))
       ((looking-at "&#\\(re\\|rs\\|space\\|tab\\)[\ ;\n]?") ; \n should be \r
*** w3.old/w3-sysdp.el	Tue Sep 24 07:04:48 1996
--- w3/w3-sysdp.el	Fri Sep 27 12:44:11 1996
***************
*** 140,145 ****
--- 140,148 ----
  				 (match-beginning 1) (match-end 1)))
  		   0))
  
+ (sysdep-defconst mule-2-4-p
+ 		 (string-match "2\\.4" mule-version))
+ 
  (sysdep-defconst sysdep-running-xemacs
  		 (or (string-match "Lucid" emacs-version)
  		     (string-match "XEmacs" emacs-version)))
*** w3.old/w3.el	Tue Sep 24 07:04:47 1996
--- w3/w3.el	Fri Sep 27 13:29:04 1996
***************
*** 288,294 ****
       ((stringp view)
        (let ((fname (url-generate-unique-filename fmt))
  	    (proc nil)
! 	    (file-coding-system url-mule-no-coding-system))
  	(if (url-file-directly-accessible-p (url-view-url t))
  	    (make-symbolic-link url-current-file fname t)
  	  (write-region (point-min) (point-max) fname))
--- 289,296 ----
       ((stringp view)
        (let ((fname (url-generate-unique-filename fmt))
  	    (proc nil)
! 	    (buffer-file-coding-system url-mule-no-coding-system) ; mule 2.4
! 	    (file-coding-system url-mule-no-coding-system)) ; mule 2.3
  	(if (url-file-directly-accessible-p (url-view-url t))
  	    (make-symbolic-link url-current-file fname t)
  	  (write-region (point-min) (point-max) fname))
***************
*** 324,331 ****
  			       (file-name-nondirectory (url-view-url t)))))
  	(require-final-newline nil))
      (set-buffer old-buff)
!     (let ((mc-flag t)
! 	  (file-coding-system url-mule-no-coding-system))
        (write-region (point-min) (point-max) file))
      (kill-buffer (current-buffer))))
  
--- 326,335 ----
  			       (file-name-nondirectory (url-view-url t)))))
  	(require-final-newline nil))
      (set-buffer old-buff)
!     (let ((enable-multibyte-characters t) ; mule 2.4
! 	  (mc-flag t) ; mule 2.3
! 	  (buffer-file-coding-system url-mule-no-coding-system) ; mule 2.4
! 	  (file-coding-system url-mule-no-coding-system)) ; mule 2.3
        (write-region (point-min) (point-max) file))
      (kill-buffer (current-buffer))))
  
***************
*** 943,949 ****
  	url-setup-done nil
  	w3-hotlist nil
  	url-mime-accept-string nil)
!   (let ((x '(w3 w3-mule w3-e19 w3-xem20 mm url w3-xemac w3-toolbar font)))
      (while x
        (setq features (delq (car x) features)
  	    x (cdr x)))
--- 951,957 ----
  	url-setup-done nil
  	w3-hotlist nil
  	url-mime-accept-string nil)
!   (let ((x '(w3 w3-mule w3-mule-2-4 w3-e19 w3-xem20 mm url w3-xemac w3-toolbar font)))
      (while x
        (setq features (delq (car x) features)
  	    x (cdr x)))
***************
*** 1521,1526 ****
--- 1533,1540 ----
    (cond
     ((boundp 'MULE)
      (require 'w3-mule))
+    ((and (featurep 'mule) mule-2-4-p)
+     (require 'w3-mule-2-4))
     ((featurep 'mule)
      (require 'w3-xem20)
      ))
***************
*** 2329,2336 ****
  	      (file-name-handler-alist nil)
  	      (write-file-hooks nil)
  	      (write-contents-hooks nil)
! 	      (mc-flag t)
! 	      (file-coding-system url-mule-no-coding-system))
  	  (write-file fname)
  	  (message "Download of %s complete." (url-view-url t))
  	  (sit-for 3)
--- 2345,2354 ----
  	      (file-name-handler-alist nil)
  	      (write-file-hooks nil)
  	      (write-contents-hooks nil)
! 	      (enable-multibyte-characters t) ; mule 2.4
! 	      (mc-flag t) ; mule 2.3
! 	      (buffer-file-coding-system url-mule-no-coding-system) ; mule 2.4
! 	      (file-coding-system url-mule-no-coding-system)) ; mule 2.3
  	  (write-file fname)
  	  (message "Download of %s complete." (url-view-url t))
  	  (sit-for 3)
*** w3.old/widget-edit.el	Tue Sep 24 07:04:48 1996
--- w3/widget-edit.el	Fri Sep 27 13:53:45 1996
***************
*** 222,240 ****
  
  (defmacro widget-specify-insert (&rest form)
    ;; Execute FORM without inheriting any text properties.
!   `(save-restriction
!      (let ((inhibit-read-only t)
! 	   result
! 	   after-change-functions)
!        (insert "<>")
!        (narrow-to-region (- (point) 2) (point))
!        (widget-specify-none (point-min) (point-max))
!        (goto-char (1+ (point-min)))
!        (setq result (progn ,@form))
!        (delete-region (point-min) (1+ (point-min)))
!        (delete-region (1- (point-max)) (point-max))
!        (goto-char (point-max))
!        result)))
  
  ;;; Widget Properties.
  
--- 222,240 ----
  
  (defmacro widget-specify-insert (&rest form)
    ;; Execute FORM without inheriting any text properties.
!   (` (save-restriction
!        (let ((inhibit-read-only t)
! 	     result
! 	     after-change-functions)
! 	 (insert "<>")
! 	 (narrow-to-region (- (point) 2) (point))
! 	 (widget-specify-none (point-min) (point-max))
! 	 (goto-char (1+ (point-min)))
! 	 (setq result (progn (,@ form)))
! 	 (delete-region (point-min) (1+ (point-min)))
! 	 (delete-region (1- (point-max)) (point-max))
! 	 (goto-char (point-max))
! 	 result))))
  
  ;;; Widget Properties.
  
***************
*** 480,486 ****
  	    (field (goto-char field)))))
    (let ((help-echo (or (get-text-property (point) 'button)
  		       (get-text-property (point) 'field))))
!     (if (and help-echo (setq help-echo (widget-get help-echo :help-echo)))
  	(message "%s" help-echo))))
  
  (defun widget-backward (arg)
--- 480,487 ----
  	    (field (goto-char field)))))
    (let ((help-echo (or (get-text-property (point) 'button)
  		       (get-text-property (point) 'field))))
!     (if (or (and help-echo (setq help-echo (widget-get help-echo :help-echo)))
! 	    (setq help-echo (get-text-property (point) 'help-echo)))
  	(message "%s" help-echo))))
  
  (defun widget-backward (arg)


