- 论坛徽章:
- 0
|
- ;; example 1: if windowing (X window or windows etc.), use color theme gnome2,
- ;; otherwise, use color theme calm-forest
- (if window-system
- (color-theme-gnome2)
- (color-theme-calm-forest))
复制代码window-system is a variable defined in `C source code'.
Its value is w32
Documentation:
Name of window system that Emacs is displaying through.
The value is a symbol--for instance, `x' for X windows.
The value is nil if Emacs is using a text-only terminal.
- ;; example 2: only do following actions if run in windows nt (2000, XP)
- (when (eq system-type 'windows-nt)
- (load-file (concat my-extension-path "w32-fontified-region-to-clipboard.el"))
- (require 'w32-winprint)
- (defun w32-maximize-frame (&optional arg)
- "Maximize the current frame"
- (interactive)
- (w32-send-sys-command 61488 arg))
- (w32-maximize-frame)
- )
复制代码
[ 本帖最后由 lgfang 于 2007-9-21 12:41 编辑 ] |
|