XTerm Geometry

How Big?

If you use XTerm and want to control window size and window position, use -geometry switch.

I want my window to be 100 characters wide and 24 chars high, I do this:

xterm -geometry 100x24

You can specify a position for your XTerm if you desire. Do it by adding a little more to the geometry already given.

Explanation:
xterm -geometry <width>x<height>+<left>+<top>

Examples:

xterm -geometry 100x24+0+0

Will open an XTerm 100 chars wide, 24 chars high in the top left hand corner of the screen

xterm -geometry 100x24+0+100

Opens an XTerm 100 chars wide, 24 chars high on the top left but 100 pixels down from the top edge of the screen.

Of course we can add it to .Xdefaults config file and looks like this:

XTerm*geometry: 100x24+200+200

After making changes to .Xdefaults, let the xserver now so it can update settings. Do this using merge switch:

xrdb -merge ~/.Xdefaults

~/.Xdefaults tells xserver to use file in my home directory as "~" is shorthand for my home dir.

You can even "cd ~" to change to your home dir.

Thats it!

No comments:

Post a Comment