comparison lisp/startup.el @ 83098:0643dc72a250

Merged in changes from CVS trunk. Patches applied: * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-213 Update from CVS * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-214 Update from CVS * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-215 Update from CVS * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-216 Update from CVS * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-217 Update from CVS git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-138
author Karoly Lorentey <lorentey@elte.hu>
date Thu, 15 Apr 2004 16:49:22 +0000
parents 34a7a8f40548 dd005a791c40
children 24e9d5ea9a88
comparison
equal deleted inserted replaced
83097:01716205773e 83098:0643dc72a250
271 Set this to nil if you want to prevent `auto-save-list-file-name' 271 Set this to nil if you want to prevent `auto-save-list-file-name'
272 from being initialized." 272 from being initialized."
273 :type '(choice (const :tag "Don't record a session's auto save list" nil) 273 :type '(choice (const :tag "Don't record a session's auto save list" nil)
274 string) 274 string)
275 :group 'auto-save) 275 :group 'auto-save)
276
277 (defvar emacs-quick-startup nil)
276 278
277 (defvar init-file-debug nil) 279 (defvar init-file-debug nil)
278 280
279 (defvar init-file-had-error nil) 281 (defvar init-file-had-error nil)
280 282
688 (error "Option `%s' is ambiguous" argi)) 690 (error "Option `%s' is ambiguous" argi))
689 (setq argi (substring (car elt) 1))) 691 (setq argi (substring (car elt) 1)))
690 (setq argval nil 692 (setq argval nil
691 argi orig-argi))))) 693 argi orig-argi)))))
692 (cond 694 (cond
695 ((equal argi "-Q")
696 (setq init-file-user nil
697 site-run-file nil
698 emacs-quick-startup t)
699 (push '(vertical-scroll-bars . nil) initial-frame-alist))
693 ((member argi '("-q" "-no-init-file")) 700 ((member argi '("-q" "-no-init-file"))
694 (setq init-file-user nil)) 701 (setq init-file-user nil))
695 ((member argi '("-u" "-user")) 702 ((member argi '("-u" "-user"))
696 (setq init-file-user (or argval (pop args)) 703 (setq init-file-user (or argval (pop args))
697 argval nil)) 704 argval nil))
719 (when (fboundp 'frame-initialize) 726 (when (fboundp 'frame-initialize)
720 (frame-initialize)) 727 (frame-initialize))
721 728
722 ;; If frame was created with a menu bar, set menu-bar-mode on. 729 ;; If frame was created with a menu bar, set menu-bar-mode on.
723 (unless (or noninteractive 730 (unless (or noninteractive
731 emacs-quick-startup
724 (and (memq initial-window-system '(x w32)) 732 (and (memq initial-window-system '(x w32))
725 (<= (frame-parameter nil 'menu-bar-lines) 0))) 733 (<= (frame-parameter nil 'menu-bar-lines) 0)))
726 (menu-bar-mode 1)) 734 (menu-bar-mode 1))
727 735
728 ;; If frame was created with a tool bar, switch tool-bar-mode on. 736 ;; If frame was created with a tool bar, switch tool-bar-mode on.
729 (unless (or noninteractive 737 (unless (or noninteractive
738 emacs-quick-startup
730 (not (display-graphic-p)) 739 (not (display-graphic-p))
731 (<= (frame-parameter nil 'tool-bar-lines) 0)) 740 (<= (frame-parameter nil 'tool-bar-lines) 0))
732 (tool-bar-mode 1)) 741 (tool-bar-mode 1))
733 742
734 ;; Can't do this init in defcustom because initial-window-system isn't set. 743 ;; Can't do this init in defcustom because initial-window-system isn't set.
735 (unless (or noninteractive 744 (unless (or noninteractive
745 emacs-quick-startup
736 (eq system-type 'ms-dos) 746 (eq system-type 'ms-dos)
737 (not (memq initial-window-system '(x w32)))) 747 (not (memq initial-window-system '(x w32))))
738 (setq-default blink-cursor t) 748 (setq-default blink-cursor t)
739 (blink-cursor-mode 1)) 749 (blink-cursor-mode 1))
740 750
752 (eq tty-erase-char 8))) 762 (eq tty-erase-char 8)))
753 (setq-default normal-erase-is-backspace t) 763 (setq-default normal-erase-is-backspace t)
754 (normal-erase-is-backspace-mode 1))) 764 (normal-erase-is-backspace-mode 1)))
755 765
756 (unless (or noninteractive 766 (unless (or noninteractive
767 emacs-quick-startup
757 (not (display-graphic-p)) 768 (not (display-graphic-p))
758 (not (fboundp 'x-show-tip))) 769 (not (fboundp 'x-show-tip)))
759 (setq-default tooltip-mode t) 770 (setq-default tooltip-mode t)
760 (tooltip-mode 1)) 771 (tooltip-mode 1))
761 772
1104 (image-width (and img (car (image-size img)))) 1115 (image-width (and img (car (image-size img))))
1105 (window-width (window-width (selected-window)))) 1116 (window-width (window-width (selected-window))))
1106 (when img 1117 (when img
1107 (when (> window-width image-width) 1118 (when (> window-width image-width)
1108 ;; Center the image in the window. 1119 ;; Center the image in the window.
1109 (let ((pos (/ (- window-width image-width) 2))) 1120 (insert (propertize " " 'display
1110 (insert (propertize " " 'display `(space :align-to ,pos)))) 1121 `(space :align-to (+ center (-0.5 . ,img)))))
1111 1122
1112 ;; Change the color of the XPM version of the splash image 1123 ;; Change the color of the XPM version of the splash image
1113 ;; so that it is visible with a dark frame background. 1124 ;; so that it is visible with a dark frame background.
1114 (when (and (memq 'xpm img) 1125 (when (and (memq 'xpm img)
1115 (eq (frame-parameter nil 'background-mode) 'dark)) 1126 (eq (frame-parameter nil 'background-mode) 'dark))
1654 (not inhibit-startup-buffer-menu) 1665 (not inhibit-startup-buffer-menu)
1655 (or (get-buffer-window first-file-buffer) 1666 (or (get-buffer-window first-file-buffer)
1656 (list-buffers))))) 1667 (list-buffers)))))
1657 1668
1658 ;; Maybe display a startup screen. 1669 ;; Maybe display a startup screen.
1659 (when (and (not inhibit-startup-message) (not noninteractive) 1670 (unless (or inhibit-startup-message
1671 noninteractive
1672 emacs-quick-startup
1660 ;; Don't display startup screen if init file 1673 ;; Don't display startup screen if init file
1661 ;; has started some sort of server. 1674 ;; has started some sort of server.
1662 (not (and (fboundp 'process-list) 1675 (and (fboundp 'process-list)
1663 (process-list)))) 1676 (process-list)))
1664 ;; Display a startup screen, after some preparations. 1677 ;; Display a startup screen, after some preparations.
1665 1678
1666 ;; If there are no switches to process, we might as well 1679 ;; If there are no switches to process, we might as well
1667 ;; run this hook now, and there may be some need to do it 1680 ;; run this hook now, and there may be some need to do it
1668 ;; before doing any output. 1681 ;; before doing any output.