+ -
当前位置:首页 → 问答吧 → emacs -nw 在 xterm下,和在screen 中的配色为啥会不一样呢?

emacs -nw 在 xterm下,和在screen 中的配色为啥会不一样呢?

时间:2010-05-01

来源:互联网

如果在xterm 下screen 中开 emacs -nw 和 直接在 xterm中 emacs -nw 的配色效果大大不同。

右下是xtem ,右上是xterm中开screen后的。

附上我的.Xresources
-----------------------------------------------------
!!Emacs set
Emacs.UseXIM: true
;;Emacs.geometry: 184x53
Xft.antialias: 1
Emacs.fontBackend: xft
!!Urxvt set
URxvt.background: rgba:0000/0000/0000/ffff
URxvt.foreground: gray
!URxvt.foreground: white
URxvt.depth: 32
urxvt*color0: #2e3436
urxvt*color1: #cc0000
urxvt*color2: #4e9a06
urxvt*color3: #c4a000
urxvt*color4: #3465a3
urxvt*color5: #75507b
urxvt*color6: #0b939b
urxvt*color7: #d3d7cf
urxvt*color8: #555753
urxvt*color9: #ef2929
urxvt*color10: #8ae234
urxvt*color11: #fce94f
urxvt*color12: #729fcf
urxvt*color13: #ad7fa8
urxvt*color14: #00f5e9
urxvt*color15: #eeeeec

! scroll set
URxvt.scrollBar: False
URxvt.scrollWithBuffer: false
URxvt.saveLines: 5000

! font set
URxvt.font:xft:Bitstream Vera Sans Mono:size=11:antialias=true,xft:LiHei Pro:size=10:antialias=true
!URxvt.font:xft:Terminus:size=10:antialias=true,xft:LiHei Pro:size=10:antialias=true

! Input Method set
!URxvt.inputMethod: xim

URxvt.preeditType: OverTheSpot
URxvt.thickness: 0
! window geometry set
URxvt.geometry: 80x28+40+40
URxvt.title: Rxvt-Unicode
urxvt.termName:rxvt-256color
! Perl Script set
URxvt.urlLauncher: firefox
URxvt.matcher.button: 1

!look and feel
xterm.termName: xterm-256color
xterm.geometry: 80x36
xterm*scrollBar: false
xterm*rightScrollBar: true
xterm*loginshell: true
xterm*cursorBlink: true
xterm*background: black
xterm*foreground: gray
xterm.borderLess: true
xterm.cursorBlink: true
xterm*colorUL: yellow
xterm*colorBD: white



!fix alt key input
xterm*eightBitInput: false
xterm*altSendsEscape: true

!mouse selecting to copy, ctrl-v to paste
!Ctrl p to print screen content to file
!XTerm*VT100.Translations: #override \
! Ctrl <KeyPress> V: insert-selection(CLIPBOARD,PRIMARY,CUT_BUFFER0) \n\
! <BtnUp>: select-end(CLIPBOARD,PRIMARY,CUT_BUFFER0) \n\
! Ctrl <KeyPress> P: print() \n


!font and locale
xterm*locale: true
xterm.utf8: true
xterm*utf8Title: true
xterm*fontMenu*fontdefault*Label: Default
!xterm*faceName: Monaco:antialias=Trueixelsize=15
xterm*faceName: Envy Code R:antialias=True:size=11
!xter*boldFont: DejaVu Sans Mono:style=Boldixelsize=15
xterm*faceNameDoublesize: LiHei proixelsize=16:antialias=True
xterm*xftAntialias: true
xterm*cjkWidth: false



!-- Tango color scheme
*xterm*color0: #2e3436
*xterm*color1: #cc0000
*xterm*color2: #4e9a06
*xterm*color3: #c4a000
*xterm*color4: #3465a4
*xterm*color5: #75507b
*xterm*color6: #0b939b
*xterm*color7: #d3d7cf
*xterm*color8: #555753
*xterm*color9: #ef2929
*xterm*color10: #8ae234
*xterm*color11: #fce94f
*xterm*color12: #729fcf
*xterm*color13: #ad7fa8
*xterm*color14: #00f5e9
*xterm*color15: #eeeeec
------------------------------------------------------------------------------
上传的图像
2010-05-01-134455_1680x1050_scrot.png (156.4 KB, 20 次查看)

作者: pigjj   发布时间: 2010-05-01

以我的经验,screen 开256色,在某些场合下会出现16色模式中的后8色被显示成前8色的情况。现象上看,你遇到的貌似可能是这个情况。通常如果 screen 不启用 256 色支持就不会有这个问题。

作者: poet   发布时间: 2010-05-02

呃,非常感谢,我刚在 screen 中 emacs -nw 然后 M-x list-color-display ,结果只有8色,而在xterm中是256色,

作者: pigjj   发布时间: 2010-05-02