I am trying to get my xterm window under gnome to open with large fonts,
with light green foreground and dark green background. I have the
following .Xdefaults file contents:

$ cat .Xdefaults
! This is a comment ;-)

#ifdef COLOR
*customization: -color

!! Let's cast a wide net, for any app supporting these
! Blink instead of beeping
*visualBell: True
*scrollTtyOutput: False
*scrollKey: True

XTerm*saveLines: 1500
! Do not clear the screen after the program exits
XTerm*VT100*titeInhibit: true

! Enable soft cut and paste
XTerm*VT100.translations: #override \

! Fix up xterm's keybindings
xterm*VT100.translations: #override \
<Key>BackSpace: string(0x7F) \n\
<Key>Insert: string(0x1b) string("[2~")\n\
<Key>Delete: string(0x1b) string("[3~")\n\
<Key>Home: string(0x1b) string("[1~")\n\
<Key>End: string(0x1b) string("[4~")\n\
<Key>Page_Up: string(0x1b) string("[5~")\n\
<Key>Page_Down: string(0x1b) string("[6~")\n\
<KeyPress>Prior: scroll-back(1,page)\n\
<KeyPress>Next: scroll-forw(1,page)

! Set xterm defaults
Xterm*background: darkgreen
Xterm*foreground: lightgreen

Xterm*font: 9x15


At some point I had the colours displaying correctly but I could not get
the default font to change to large. In an attempt to get Xterm to use
the above file I ran the command:

$ xrdb ~/.Xdefaults

Now when xterm opens I have a black on white display with tiny fonts. I
have to use Xterm in a specific instance because the version of gnome
terminal that ships with CentOS-5 breaks vt102 emulation horribly. I have
already spent way too much time trying to get Xterm and Xdefaults to work
together as they should. I do not understand what it is that I am missing
or doing wrong. Can somebody please point out what is wrong with my

I have already read, and reread, the man page.


*** E-Mail is NOT a SECURE channel ***
James B. Byrne mailto:[email protected]
Harte & Lyne Limited http://www.harte-lyne.ca
9 Brockley Drive vox: +1 905 561 1241
Hamilton, Ontario fax: +1 905 561 0757
Canada L8E 3C3

Search Discussions

  • Bill Campbell at Jul 29, 2008 at 5:35 pm

    On Tue, Jul 29, 2008, James B. Byrne wrote:
    I am trying to get my xterm window under gnome to open with large fonts,
    with light green foreground and dark green background. I have the
    following .Xdefaults file contents:
    Rather than use the Xdefaults file, create a ~/XTerm file which
    every xterm will read at startup so changes appear immediately.

    I'm attaching the one I use which sets large fonts, a red cursor
    so that characters show in reverse video, and a few other

    The XTerm*pointerShape sets the pointer to an arrow which I find
    much easier to see than the default.

    The XTerm*charClass is a bit of magic that makes left double
    clicks highlight full path names, IP addresses, and other useful

    The XTerm*ttyModes is effectively stty to set my preferences,
    avoiding the DECish ^? DEL instead of ctrl-H backspace as $DEITY

    INTERNET: [email protected] Bill Campbell; Celestial Software LLC
    URL: http://www.celestial.com/ PO Box 820; 6641 E. Mercer Way
    Voice: (206) 236-1676 Mercer Island, WA 98040-0820
    Fax: (206) 232-9186

    We have a two party system and what a party they are giving themselves.
    Since 1960 government spending has grown 8 times as fast as the GNP.
    -------------- next part --------------
    !! set default tty mode.
    !XTerm*ttyModes: intr ^? erase ^H kill ^U
    !! modify mouse functionality so that "Shift <Btn1Down>" has the same
    !! functionality as "<Btn2Down>".
    !! The Ctrl<Btn2Down> xterm window menu CANNOT be popped up using
    !! Shift Ctrl<Btn1Down>
    !*VT100*translations: #override\
    ! Shift <Btn1Down>: insert-selection(PRIMARY, CUT_BUFFER0) \n\
    ! Button1 <Btn3Down>: insert-selection(PRIMARY, CUT_BUFFER0)
    !*VT100*Scrollbar*translations: #override\
    ! Shift <Btn1Down>: StartScroll(Continuous) MoveThumb() NotifyThumb() \n\
    ! Shift <Btn1Motion>: MoveThumb() NotifyThumb() \n\
    ! Button1 <Btn3Down>: StartScroll(Continuous) MoveThumb() NotifyThumb() \n\
    ! Button1 <Btn3Motion>: MoveThumb() NotifyThumb()
    !! menu resources
    !*SimpleMenu*BackingStore: NotUseful
    !*SimpleMenu*menuLabel.font: -adobe-helvetica-bold-r-normal--*-120-*-*-*-*-iso*-*
    !*SimpleMenu*menuLabel.vertSpace: 100
    !*SimpleMenu*HorizontalMargins: 16
    !*SimpleMenu*Sme.height: 16
    !*SimpleMenu*Cursor: left_ptr
    !*mainMenu.Label: Main Options
    !*mainMenu*securekbd*Label: Secure Keyboard
    !*mainMenu*allowsends*Label: Allow SendEvents
    !*mainMenu*logging*Label: Log to File
    !*mainMenu*redraw*Label: Redraw Window
    !*mainMenu*suspend*Label: Send STOP Signal
    !*mainMenu*continue*Label: Send CONT Signal
    !*mainMenu*interrupt*Label: Send INT Signal
    !*mainMenu*hangup*Label: Send HUP Signal
    !*mainMenu*terminate*Label: Send TERM Signal
    !*mainMenu*kill*Label: Send KILL Signal
    !*mainMenu*quit*Label: Quit
    !*vtMenu.Label: VT Options
    !*vtMenu*scrollbar*Label: Enable Scrollbar
    !*vtMenu*jumpscroll*Label: Enable Jump Scroll
    !*vtMenu*reversevideo*Label: Enable Reverse Video
    !*vtMenu*autowrap*Label: Enable Auto Wraparound
    !*vtMenu*reversewrap*Label: Enable Reverse Wraparound
    !*vtMenu*autolinefeed*Label: Enable Auto Linefeed
    !*vtMenu*appcursor*Label: Enable Application Cursor Keys
    !*vtMenu*appkeypad*Label: Enable Application Keypad
    !*vtMenu*scrollkey*Label: Scroll to Bottom on Key Press
    !*vtMenu*scrollttyoutput*Label: Scroll to Bottom on Tty Output
    !*vtMenu*allow132*Label: Allow 80/132 Column Switching
    !*vtMenu*cursesemul*Label: Enable Curses Emulation
    !*vtMenu*visualbell*Label: Enable Visual Bell
    !*vtMenu*marginbell*Label: Enable Margin Bell
    !*vtMenu*altscreen*Label: Show Alternate Screen
    !*vtMenu*softreset*Label: Do Soft Reset
    !*vtMenu*hardreset*Label: Do Full Reset
    !*vtMenu*tekshow*Label: Show Tek Window
    !*vtMenu*tekmode*Label: Switch to Tek Mode
    !*vtMenu*vthide*Label: Hide VT Window
    !*fontMenu.Label: VT Fonts
    !*fontMenu*fontdefault*Label: Default
    !*fontMenu*font1*Label: 6x10
    !*VT100*font1: 6x10
    !*fontMenu*font2*Label: 6x12
    !*VT100*font2: 6x12
    !*fontMenu*font3*Label: 9x15
    !*VT100*font3: 9x15
    !*fontMenu*font4*Label: 10x20
    !*VT100*font4: 10x20
    !*fontMenu*fontescape*Label: Escape Sequence
    !*fontMenu*fontsel*Label: Selection
    !!fontescape and fontsel overridden by application
    !*tekMenu.Label: Tek Options
    !*tekMenu*tektextlarge*Label: Large Characters
    !*tekMenu*tektext2*Label: #2 Size Characters
    !*tekMenu*tektext3*Label: #3 Size Characters
    !*tekMenu*tektextsmall*Label: Small Characters
    !*tekMenu*tekpage*Label: PAGE
    !*tekMenu*tekreset*Label: RESET
    !*tekMenu*tekcopy*Label: COPY
    !*tekMenu*vtshow*Label: Show VT Window
    !*tekMenu*vtmode*Label: Switch to VT Mode
    !*tekMenu*tekhide*Label: Hide Tek Window
    *tek4014*fontLarge: 10x20
    *tek4014*font2: 9x15
    *tek4014*font3: 6x13
    *tek4014*fontSmall: 6x10

    XTerm*font: 10x20
    XTerm*pointerShape: arrow
    XTerm*termName: xterm
    XTerm*blink: true
    XTerm*loginShell: true
    XTerm*scrollBar: true
    ! XTerm*cursorColor: SlateBlue
    XTerm*cursorColor: red3
    XTerm*backarrowKeyIsErase: false
    !XTerm*termName: xterm-color
    XTerm*background: Grey95
    !XTerm*background: AntiqueWhite
    !XTerm*background: seashell2
    !XTerm*background: ivory2

    XTerm*charClass: 33:48,37:48,43:48,45-47:48,64:48,126:48,95:48

    XTerm*ttyModes: intr ^C erase ^H kill ^U

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupcentos @
postedJul 29, '08 at 3:37p
activeJul 29, '08 at 5:35p

2 users in discussion

Bill Campbell: 1 post James B. Byrne: 1 post



site design / logo © 2023 Grokbase