diff options
| author | Jason Rumney | 2002-06-20 20:44:02 +0000 |
|---|---|---|
| committer | Jason Rumney | 2002-06-20 20:44:02 +0000 |
| commit | afcca90b4e54a6b49af67e9ac011271e3ccfb36f (patch) | |
| tree | f9d9ce0e2571e51f7064597c764e2a0e679e157b | |
| parent | d78b64a088414ff8f8d991e09c6f7ca144e0f1e1 (diff) | |
| download | emacs-afcca90b4e54a6b49af67e9ac011271e3ccfb36f.tar.gz emacs-afcca90b4e54a6b49af67e9ac011271e3ccfb36f.zip | |
Add MS-Windows specific docs for envvars
| -rw-r--r-- | man/cmdargs.texi | 84 |
1 files changed, 73 insertions, 11 deletions
diff --git a/man/cmdargs.texi b/man/cmdargs.texi index 67d3f714112..6f7e610b400 100644 --- a/man/cmdargs.texi +++ b/man/cmdargs.texi | |||
| @@ -351,13 +351,14 @@ and here's how to do it in csh or tcsh: | |||
| 351 | setenv ORGANIZATION "not very much" | 351 | setenv ORGANIZATION "not very much" |
| 352 | @end example | 352 | @end example |
| 353 | 353 | ||
| 354 | When Emacs is uses the X Window System, it inherits the use | 354 | When Emacs uses the X Window System, it inherits the use |
| 355 | of a large number of environment variables from the X libraries. See | 355 | of a large number of environment variables from the X libraries. See |
| 356 | the X documentation for more information. | 356 | the X documentation for more information. |
| 357 | 357 | ||
| 358 | @menu | 358 | @menu |
| 359 | * General Variables:: Environment variables that all versions of Emacs use. | 359 | * General Variables:: Environment variables that all versions of Emacs use. |
| 360 | * Misc Variables:: Certain system-specific variables. | 360 | * Misc Variables:: Certain system-specific variables. |
| 361 | * MS-Windows Registry:: An alternative to the environment on MS-Windows. | ||
| 361 | @end menu | 362 | @end menu |
| 362 | 363 | ||
| 363 | @node General Variables | 364 | @node General Variables |
| @@ -408,7 +409,7 @@ The location of the user's files in the directory tree; used for | |||
| 408 | expansion of file names starting with a tilde (@file{~}). On MS-DOS, it | 409 | expansion of file names starting with a tilde (@file{~}). On MS-DOS, it |
| 409 | defaults to the directory from which Emacs was started, with @samp{/bin} | 410 | defaults to the directory from which Emacs was started, with @samp{/bin} |
| 410 | removed from the end if it was present. On Windows, the default value | 411 | removed from the end if it was present. On Windows, the default value |
| 411 | of @code{HOME} is @file{C:/}, the root directory of drive @file{C:}. | 412 | of @env{HOME} is @file{C:/}, the root directory of drive @file{C:}. |
| 412 | @item HOSTNAME | 413 | @item HOSTNAME |
| 413 | The name of the machine that Emacs is running on. | 414 | The name of the machine that Emacs is running on. |
| 414 | @item INCPATH | 415 | @item INCPATH |
| @@ -434,7 +435,12 @@ variables is not set, the category defaults to the value of the | |||
| 434 | @env{LANG} is not set. But if @env{LC_ALL} is specified, it overrides | 435 | @env{LANG} is not set. But if @env{LC_ALL} is specified, it overrides |
| 435 | the settings of all the other locale environment variables. | 436 | the settings of all the other locale environment variables. |
| 436 | 437 | ||
| 437 | The value of the LC_CTYPE category is | 438 | On MS-Windows, if @env{LANG} is not already set in the environment |
| 439 | when Emacs starts, Emacs sets it based on the system-wide default | ||
| 440 | language, which you can set in the @samp{Regional Settings} Control Panel | ||
| 441 | on some versions of MS-Windows. | ||
| 442 | |||
| 443 | The value of the @env{LC_CTYPE} category is | ||
| 438 | matched against entries in @code{locale-language-names}, | 444 | matched against entries in @code{locale-language-names}, |
| 439 | @code{locale-charset-language-names}, and | 445 | @code{locale-charset-language-names}, and |
| 440 | @code{locale-preferred-coding-systems}, to select a default language | 446 | @code{locale-preferred-coding-systems}, to select a default language |
| @@ -469,13 +475,13 @@ Used by the Gnus package. | |||
| 469 | @item SHELL | 475 | @item SHELL |
| 470 | The name of an interpreter used to parse and execute programs run from | 476 | The name of an interpreter used to parse and execute programs run from |
| 471 | inside Emacs. | 477 | inside Emacs. |
| 472 | @cindex background mode, on @code{xterm} | 478 | @cindex background mode, on @command{xterm} |
| 473 | @item TERM | 479 | @item TERM |
| 474 | The type of the terminal that Emacs is using. This variable must be | 480 | The type of the terminal that Emacs is using. This variable must be |
| 475 | set unless Emacs is run in batch mode. On MS-DOS, it defaults to | 481 | set unless Emacs is run in batch mode. On MS-DOS, it defaults to |
| 476 | @samp{internal}, which specifies a built-in terminal emulation that | 482 | @samp{internal}, which specifies a built-in terminal emulation that |
| 477 | handles the machine's own display. If the value of @env{TERM} indicates | 483 | handles the machine's own display. If the value of @env{TERM} indicates |
| 478 | that Emacs runs in non-windowed mode from @code{xterm} or a similar | 484 | that Emacs runs in non-windowed mode from @command{xterm} or a similar |
| 479 | terminal emulator, the background mode defaults to @samp{light}, and | 485 | terminal emulator, the background mode defaults to @samp{light}, and |
| 480 | Emacs will choose colors that are appropriate for a light background. | 486 | Emacs will choose colors that are appropriate for a light background. |
| 481 | @item TERMCAP | 487 | @item TERMCAP |
| @@ -486,10 +492,10 @@ terminal specified by the @env{TERM} variable. This defaults to | |||
| 486 | Used by the Emerge package as a prefix for temporary files. | 492 | Used by the Emerge package as a prefix for temporary files. |
| 487 | @item TZ | 493 | @item TZ |
| 488 | This specifies the current time zone and possibly also daylight | 494 | This specifies the current time zone and possibly also daylight |
| 489 | saving time information. On MS-DOS, if @code{TZ} is not set in the | 495 | saving time information. On MS-DOS, if @env{TZ} is not set in the |
| 490 | environment when Emacs starts, Emacs defines a default value as | 496 | environment when Emacs starts, Emacs defines a default value as |
| 491 | appropriate for the country code returned by DOS. On MS-Windows, Emacs | 497 | appropriate for the country code returned by DOS. On MS-Windows, Emacs |
| 492 | does not use @code{TZ} at all. | 498 | does not use @env{TZ} at all. |
| 493 | @item USER | 499 | @item USER |
| 494 | The user's login name. See also @env{LOGNAME}. On MS-DOS, this | 500 | The user's login name. See also @env{LOGNAME}. On MS-DOS, this |
| 495 | defaults to @samp{root}. | 501 | defaults to @samp{root}. |
| @@ -544,8 +550,64 @@ actually used. | |||
| 544 | 550 | ||
| 545 | @item WINDOW_GFX | 551 | @item WINDOW_GFX |
| 546 | Used when initializing the Sun windows system. | 552 | Used when initializing the Sun windows system. |
| 553 | |||
| 554 | @item PRELOAD_WINSOCK | ||
| 555 | On MS-Windows, if you set this variable, Emacs will load and initialize | ||
| 556 | the network library at startup, instead of waiting until the first | ||
| 557 | time it is required. | ||
| 558 | |||
| 559 | @item emacs_dir | ||
| 560 | On MS-Windows, @env{emacs_dir} is a special environment variable, which | ||
| 561 | indicates the full path of the directory in which Emacs is installed. | ||
| 562 | If Emacs is installed in the standard directory structure, it | ||
| 563 | calculates this value automatically. It is not much use setting this | ||
| 564 | variable yourself unless your installation is non-standard, since | ||
| 565 | unlike other environment variables, it will be overridden by Emacs at | ||
| 566 | startup. When setting other environment variables, such as | ||
| 567 | @env{EMACSLOADPATH}, you may find it useful to use @env{emacs_dir} | ||
| 568 | rather than hard-coding an absolute path. This allows multiple | ||
| 569 | versions of Emacs to share the same environment variable settings, and | ||
| 570 | it allows you to move the Emacs installation directory, without | ||
| 571 | changing any environment or registry settings. | ||
| 547 | @end table | 572 | @end table |
| 548 | 573 | ||
| 574 | @node MS-Windows Registry | ||
| 575 | @appendixsubsec The MS-Windows System Registry | ||
| 576 | @pindex addpm, MS-Windows installation program | ||
| 577 | @cindex registry, setting environment variables and resources on MS-Windows | ||
| 578 | |||
| 579 | On MS-Windows, the installation program @command{addpm.exe} adds values | ||
| 580 | for @env{emacs_dir}, @env{EMACSLOADPATH}, @env{EMACSDATA}, | ||
| 581 | @env{EMACSPATH}, @env{EMACSDOC}, @env{SHELL} and @env{TERM} to the | ||
| 582 | @file{HKEY_LOCAL_MACHINE} section of the system registry, under | ||
| 583 | @file{/Software/GNU/Emacs}. It does this because there is no standard | ||
| 584 | place to set environment variables across different versions of | ||
| 585 | Windows. Running @command{addpm.exe} is no longer strictly | ||
| 586 | necessary in recent versions of Emacs, but if you are upgrading from | ||
| 587 | an older version, running @command{addpm.exe} ensures that you do not have | ||
| 588 | older registry entries from a previous installation, which may not be | ||
| 589 | compatible with the latest version of Emacs. | ||
| 590 | |||
| 591 | When Emacs starts, as well as checking the environment, it also checks | ||
| 592 | the System Registry for those variables and for @env{HOME}, @env{LANG} | ||
| 593 | and @env{PRELOAD_WINSOCK}. | ||
| 594 | |||
| 595 | To determine the value of those variables, Emacs goes through the | ||
| 596 | following procedure. First, the environment is checked. If the | ||
| 597 | variable is not found there, Emacs looks for registry keys by that | ||
| 598 | name under @file{/Software/GNU/Emacs}; first in the | ||
| 599 | @file{HKEY_CURRENT_USER} section of the registry, and if not found | ||
| 600 | there, in the @file{HKEY_LOCAL_MACHINE} section. Finally, if Emacs | ||
| 601 | still cannot determine the values, compiled-in defaults are used. | ||
| 602 | |||
| 603 | In addition to the environment variables above, you can also add many | ||
| 604 | of the settings which on X belong in the @file{.Xdefaults} file | ||
| 605 | (@pxref{X Resources}) to the @file{/Software/GNU/Emacs} registry key. | ||
| 606 | Settings you add to the @file{HKEY_LOCAL_MACHINE} section will affect | ||
| 607 | all users of the machine. Settings you add to the | ||
| 608 | @file{HKEY_CURRENT_USER} section will only affect you, and will | ||
| 609 | override machine wide settings. | ||
| 610 | |||
| 549 | @node Display X | 611 | @node Display X |
| 550 | @appendixsec Specifying the Display Name | 612 | @appendixsec Specifying the Display Name |
| 551 | @cindex display name (X Window System) | 613 | @cindex display name (X Window System) |
| @@ -598,7 +660,7 @@ Xlib: connection to "glasperle:0.0" refused by server | |||
| 598 | @end smallexample | 660 | @end smallexample |
| 599 | 661 | ||
| 600 | @noindent | 662 | @noindent |
| 601 | You might be able to overcome this problem by using the @code{xhost} | 663 | You might be able to overcome this problem by using the @command{xhost} |
| 602 | command on the local system to give permission for access from your | 664 | command on the local system to give permission for access from your |
| 603 | remote machine. | 665 | remote machine. |
| 604 | 666 | ||
| @@ -694,7 +756,7 @@ Normally you should use @samp{iso8859-1}. | |||
| 694 | You will probably want to use a fixed-width default font---that is, | 756 | You will probably want to use a fixed-width default font---that is, |
| 695 | a font in which all characters have the same width. Any font with | 757 | a font in which all characters have the same width. Any font with |
| 696 | @samp{m} or @samp{c} in the @var{spacing} field of the long name is a | 758 | @samp{m} or @samp{c} in the @var{spacing} field of the long name is a |
| 697 | fixed-width font. Here's how to use the @code{xlsfonts} program to | 759 | fixed-width font. Here's how to use the @command{xlsfonts} program to |
| 698 | list all the fixed-width fonts available on your system: | 760 | list all the fixed-width fonts available on your system: |
| 699 | 761 | ||
| 700 | @example | 762 | @example |
| @@ -704,7 +766,7 @@ xlsfonts -fn '*-*-*-*-*-*-*-*-*-*-*-c*' | |||
| 704 | @end example | 766 | @end example |
| 705 | 767 | ||
| 706 | @noindent | 768 | @noindent |
| 707 | To see what a particular font looks like, use the @code{xfd} command. | 769 | To see what a particular font looks like, use the @command{xfd} command. |
| 708 | For example: | 770 | For example: |
| 709 | 771 | ||
| 710 | @example | 772 | @example |
| @@ -877,7 +939,7 @@ screen, and a minus sign there indicates the distance from the bottom. | |||
| 877 | The values @var{xoffset} and @var{yoffset} may themselves be positive or | 939 | The values @var{xoffset} and @var{yoffset} may themselves be positive or |
| 878 | negative, but that doesn't change their meaning, only their direction. | 940 | negative, but that doesn't change their meaning, only their direction. |
| 879 | 941 | ||
| 880 | Emacs uses the same units as @code{xterm} does to interpret the geometry. | 942 | Emacs uses the same units as @command{xterm} does to interpret the geometry. |
| 881 | The @var{width} and @var{height} are measured in characters, so a large font | 943 | The @var{width} and @var{height} are measured in characters, so a large font |
| 882 | creates a larger frame than a small font. (If you specify a proportional | 944 | creates a larger frame than a small font. (If you specify a proportional |
| 883 | font, Emacs uses its maximum bounds width as the width unit.) The | 945 | font, Emacs uses its maximum bounds width as the width unit.) The |