~vm/vm/vmpc-prompt

« back to all changes in this revision

Viewing changes to lisp/vm-vars.el

  • Committer: Uday S Reddy
  • Date: 2011-03-10 00:27:15 UTC
  • Revision ID: u.s.reddy@cs.bham.ac.uk-20110310002715-splmuomb82oq1h2t
Changed several defvars to defconst's to narrow search for space leaks.  Uninterning symbols from vm-folder-imap-uid-obarray before destroying the obarray, but it doesn't seem to make any difference for the space leak.

Show diffs side-by-side

added added

removed removed

Lines of Context:
2379
2379
  :group 'vm-presentation
2380
2380
  :type 'boolean)
2381
2381
 
2382
 
(defvar vm-default-window-configuration
 
2382
(defconst vm-default-window-configuration
2383
2383
  ;; startup = folder on bottom, summary on top
2384
2384
  ;; quitting = full screen folder
2385
2385
  ;; reading-message = folder on bottom, summary on top
5913
5913
(make-variable-buffer-local 'vm-summary-pointer)
5914
5914
(defvar vm-system-state nil)
5915
5915
(make-variable-buffer-local 'vm-system-state)
5916
 
(defvar vm-undo-record-list nil)
 
5916
(defvar vm-undo-record-list nil
 
5917
  "The list of undo records for the folder.")
5917
5918
(make-variable-buffer-local 'vm-undo-record-list)
5918
 
(defvar vm-saved-undo-record-list nil)
 
5919
(defvar vm-saved-undo-record-list nil
 
5920
  "A saved version of the undo record list used in `vm-toggle-virtual-mirror'.")
5919
5921
(make-variable-buffer-local 'vm-saved-undo-record-list)
5920
 
(defvar vm-undo-record-pointer nil)
 
5922
(defvar vm-undo-record-pointer nil
 
5923
  "A pointer into the `vm-undo-undo-record-list'.")
5921
5924
(make-variable-buffer-local 'vm-undo-record-pointer)
5922
5925
(defvar vm-last-save-folder nil)
5923
5926
(make-variable-buffer-local 'vm-last-save-folder)
5941
5944
(make-variable-buffer-local 'vm-flushed-modification-counter)
5942
5945
(defvar vm-tempfile-counter 0)
5943
5946
(defvar vm-messages-needing-summary-update nil)
5944
 
(defvar vm-buffers-needing-display-update nil)
5945
 
(defvar vm-buffers-needing-undo-boundaries nil)
5946
 
(defvar vm-numbering-redo-start-point nil)
 
5947
(defvar vm-buffers-needing-display-update nil
 
5948
  "Obarray containing the names of VM buffers that need display
 
5949
update.")
 
5950
(defvar vm-buffers-needing-undo-boundaries nil
 
5951
  "Obarray containing the names of VM buffers that need undo
 
5952
boundaries.") 
 
5953
(defvar vm-numbering-redo-start-point nil
 
5954
  "A pointer into `vm-message-list' indicating the position from which
 
5955
messages may need to be renumbered.")
5947
5956
(make-variable-buffer-local 'vm-numbering-redo-start-point)
5948
 
(defvar vm-numbering-redo-end-point nil)
 
5957
(defvar vm-numbering-redo-end-point nil
 
5958
  "A pointer into `vm-message-list' indicating the stopping point
 
5959
for any needed message renumbering.")
5949
5960
(make-variable-buffer-local 'vm-numbering-redo-end-point)
5950
 
(defvar vm-summary-redo-start-point nil)
 
5961
(defvar vm-summary-redo-start-point nil
 
5962
  "A pointer into `vm-message-list' indicating the position from which
 
5963
summary lines may need to be redisplayed.")
5951
5964
(make-variable-buffer-local 'vm-summary-redo-start-point)
5952
 
(defvar vm-need-summary-pointer-update nil)
 
5965
(defvar vm-need-summary-pointer-update nil
 
5966
  "A boolean indicating whether the summary pointer for the current
 
5967
folder needs to be updated.")
5953
5968
(make-variable-buffer-local 'vm-need-summary-pointer-update)
5954
5969
(defvar vm-thread-obarray 'bonk)
5955
5970
(make-variable-buffer-local 'vm-thread-obarray)
6389
6404
    "VM comes with ABSOLUTELY NO WARRANTY; type \\[vm-show-no-warranty] for full details"))
6390
6405
(defconst vm-startup-message-displayed nil)
6391
6406
;; for the mode line
6392
 
(defvar vm-mode-line-format-robf
 
6407
(defconst vm-mode-line-format-robf
6393
6408
  '("- " 
6394
6409
    (vm-compositions-exist ("" vm-ml-composition-buffer-count " / "))
6395
6410
    (vm-drafts-exist ("" vm-ml-draft-count " / "))
6413
6428
    " (VM " vm-version ")"
6414
6429
    global-mode-string
6415
6430
    "%-"))
6416
 
(defvar vm-mode-line-format-classic
 
6431
(defconst vm-mode-line-format-classic
6417
6432
  '("" "  %&%& "
6418
6433
    ("VM " vm-version ": "
6419
6434
     (vm-folder-read-only "read-only ")
6432
6447
      (vm-ml-labels ("; " vm-ml-labels)) " %]    ")
6433
6448
     ("  %[%]   "))
6434
6449
    "%p" "   " global-mode-string))
6435
 
(defvar vm-mode-line-format vm-mode-line-format-classic)
6436
 
 
6437
 
 
6438
 
(defvar vm-ml-message-attributes-alist
 
6450
 
 
6451
(defconst vm-mode-line-format vm-mode-line-format-classic)
 
6452
 
 
6453
 
 
6454
(defconst vm-ml-message-attributes-alist
6439
6455
  '((vm-ml-message-new
6440
6456
     "new"
6441
6457
     (vm-ml-message-unread
6576
6592
(defvar vm-fsfemacs-toolbar-installed-p nil)
6577
6593
;; this defvar matches the XEmacs one so it doesn't matter if VM
6578
6594
;; is loaded before highlight-headers.el
6579
 
(defvar highlight-headers-regexp "Subject[ \t]*:")
6580
 
(defvar vm-url-regexp
 
6595
(defconst highlight-headers-regexp "Subject[ \t]*:")
 
6596
(defconst vm-url-regexp
6581
6597
  "<URL:\\([^>\n]+\\)>\\|\\(\\(file\\|sftp\\|ftp\\|gopher\\|http\\|https\\|news\\|wais\\|www\\)://[^ \t\n\f\r\"<>|()]*[^ \t\n\f\r\"<>|.!?(){}]\\)\\|\\(mailto:[^ \t\n\f\r\"<>|()]*[^] \t\n\f\r\"<>|.!?(){}]\\)\\|\\(file:/[^ \t\n\f\r\"<>|()]*[^ \t\n\f\r\"<>|.!?(){}]\\)"
6582
6598
  "Regular expression that matches an absolute URL.
6583
6599
The URL itself must be matched by a \\(..\\) grouping.
6632
6648
(defvar vm-xface-cache (make-vector 29 0))
6633
6649
(defvar vm-mf-default-action nil)
6634
6650
(defvar vm-mime-compiled-format-alist nil)
6635
 
(defvar vm-mime-default-action-string-alist
 
6651
(defconst vm-mime-default-action-string-alist
6636
6652
  '(("text" . "display text")
6637
6653
    ("multipart/alternative" . "display selected part")
6638
6654
    ("multipart/digest" . "read digest")
6649
6665
    ("application/msword" . "display Word document")
6650
6666
    ("application" . "display attachment")))
6651
6667
 
6652
 
(defvar vm-mime-type-description-alist
 
6668
(defconst vm-mime-type-description-alist
6653
6669
  '(("multipart/digest" . "digest")
6654
6670
    ("multipart/alternative" . "multipart alternative")
6655
6671
    ("multipart/parallel" . "multipart parallel")
6770
6786
         ))
6771
6787
  "Alist that maps MIME character sets to MULE coding systems.")
6772
6788
          
6773
 
(defvar vm-mime-mule-charset-to-charset-alist
 
6789
(defconst vm-mime-mule-charset-to-charset-alist
6774
6790
  '(
6775
6791
    (latin-iso8859-1    "iso-8859-1")
6776
6792
    (latin-iso8859-2    "iso-8859-2")
6789
6805
   )
6790
6806
  "Alist that maps MULE character sets to matching MIME character sets.")
6791
6807
 
6792
 
(defvar vm-mime-mule-coding-to-charset-alist
 
6808
(defconst vm-mime-mule-coding-to-charset-alist
6793
6809
  (cond (vm-fsfemacs-mule-p
6794
6810
         (let ((coding-systems (coding-system-list))
6795
6811
               (alist nil)