config.but

来自「远程登陆工具软件源码 用于远程登陆unix」· BUT 代码 · 共 1,542 行 · 第 1/5 页

BUT
1,542
字号

If you want to prevent the application from taking over the mouse at
all, you can do this using the Features control panel; see
\k{config-features-mouse}.

\S{config-rectselect} Default selection mode

\cfg{winhelp-topic}{selection.rect}

As described in \k{using-selection}, PuTTY has two modes of
selecting text to be copied to the clipboard. In the default mode
(\q{Normal}), dragging the mouse from point A to point B selects to
the end of the line containing A, all the lines in between, and from
the very beginning of the line containing B. In the other mode
(\q{Rectangular block}), dragging the mouse between two points
defines a rectangle, and everything within that rectangle is copied.

Normally, you have to hold down Alt while dragging the mouse to
select a rectangular block. Using the \q{Default selection mode}
control, you can set rectangular selection as the default, and then
you have to hold down Alt to get the \e{normal} behaviour.

\S{config-charclasses} Configuring word-by-word selection

\cfg{winhelp-topic}{selection.charclasses}

PuTTY will select a word at a time in the terminal window if you
double-click to begin the drag. This panel allows you to control
precisely what is considered to be a word.

Each character is given a \e{class}, which is a small number
(typically 0, 1 or 2). PuTTY considers a single word to be any
number of adjacent characters in the same class. So by modifying the
assignment of characters to classes, you can modify the word-by-word
selection behaviour.

In the default configuration, the character classes are:

\b Class 0 contains white space and control characters.

\b Class 1 contains most punctuation.

\b Class 2 contains letters, numbers and a few pieces of punctuation
(the double quote, minus sign, period, forward slash and
underscore).

So, for example, if you assign the \c{@} symbol into character class
2, you will be able to select an e-mail address with just a double
click.

In order to adjust these assignments, you start by selecting a group
of characters in the list box. Then enter a class number in the edit
box below, and press the \q{Set} button.

This mechanism currently only covers ASCII characters, because it
isn't feasible to expand the list to cover the whole of Unicode.

Character class definitions can be modified by control sequences
sent by the server. This configuration option controls the
\e{default} state, which will be restored when you reset the
terminal (see \k{reset-terminal}). However, if you modify this
option in mid-session using \q{Change Settings}, it will take effect
immediately.

\H{config-colours} The Colours panel

The Colours panel allows you to control PuTTY's use of colour.

\S{config-boldcolour} \q{Bolded text is a different colour}

\cfg{winhelp-topic}{colours.bold}

When the server sends a control sequence indicating that some text
should be displayed in bold, PuTTY can handle this two ways. It can
either change the font for a bold version, or use the same font in a
brighter colour. This control lets you choose which.

By default the box is checked, so non-bold text is displayed in
light grey and bold text is displayed in bright white (and similarly
in other colours). If you uncheck the box, bold and non-bold text
will be displayed in the same colour, and instead the font will
change to indicate the difference.

\S{config-logpalette} \q{Attempt to use logical palettes}

\cfg{winhelp-topic}{colours.logpal}

Logical palettes are a mechanism by which a Windows application
running on an 8-bit colour display can select precisely the colours
it wants instead of going with the Windows standard defaults.

If you are not getting the colours you ask for on an 8-bit display,
you can try enabling this option. However, be warned that it's never
worked very well.

\S{config-syscolour} \q{Use system colours}

\cfg{winhelp-topic}{colours.system}

Enabling this option will cause PuTTY to ignore the configured colours
for \q{Default Background/Foreground} and \q{Cursor Colour/Text} (see
\k{config-colourcfg}), instead going with the system-wide defaults.

Note that non-bold and bold text will be the same colour if this
option is enabled. You might want to change to indicating bold text
by font changes (see \k{config-boldcolour}).

\S{config-colourcfg} Adjusting the colours in the terminal window

\cfg{winhelp-topic}{colours.config}

The main colour control allows you to specify exactly what colours
things should be displayed in. To modify one of the PuTTY colours,
use the list box to select which colour you want to modify. The RGB
values for that colour will appear on the right-hand side of the
list box. Now, if you press the \q{Modify} button, you will be
presented with a colour selector, in which you can choose a new
colour to go in place of the old one.

PuTTY allows you to set the cursor colour, the default foreground
and background, and the precise shades of all the ANSI configurable
colours (black, red, green, yellow, blue, magenta, cyan, and white).
You can also modify the precise shades used for the bold versions of
these colours; these are used to display bold text if you have
selected \q{Bolded text is a different colour}, and can also be used
if the server asks specifically to use them.

\H{config-connection} The Connection panel

The Connection panel allows you to configure options that apply to
more than one type of connection.

\S{config-termtype} \q{Terminal-type string}

\cfg{winhelp-topic}{connection.termtype}

Most servers you might connect to with PuTTY are designed to be
connected to from lots of different types of terminal. In order to
send the right control sequences to each one, the server will need
to know what type of terminal it is dealing with. Therefore, each of
the SSH, Telnet and Rlogin protocols allow a text string to be sent
down the connection describing the terminal.

PuTTY attempts to emulate the Unix \c{xterm} program, and by default
it reflects this by sending \c{xterm} as a terminal-type string. If
you find this is not doing what you want - perhaps the remote
terminal reports \q{Unknown terminal type} - you could try setting
this to something different, such as \c{vt220}.

If you're not sure whether a problem is due to the terminal type
setting or not, you probably need to consult the manual for your
application or your server.

\S{config-termspeed} \q{Terminal speeds}

\cfg{winhelp-topic}{connection.termspeed}

The Telnet, Rlogin, and SSH protocols allow the client to specify
terminal speeds to the server.

This parameter does \e{not} affect the actual speed of the connection,
which is always \q{as fast as possible}; it is just a hint that is
sometimes used by server software to modify its behaviour. For
instance, if a slow speed is indicated, the server may switch to a
less bandwidth-hungry display mode.

The value is usually meaningless in a network environment, but
PuTTY lets you configure it, in case you find the server is reacting
badly to the default value.

The format is a pair of numbers separated by a comma, for instance,
\c{38400,38400}. The first number represents the output speed
(\e{from} the server) in bits per second, and the second is the input
speed (\e{to} the server). (Only the first is used in the Rlogin
protocol.)

This option has no effect on Raw connections.

\S{config-username} \q{Auto-login username}

\cfg{winhelp-topic}{connection.username}

All three of the SSH, Telnet and Rlogin protocols allow you to
specify what user name you want to log in as, without having to type
it explicitly every time. (Some Telnet servers don't support this.)

In this box you can type that user name.

\S{config-keepalive} Using keepalives to prevent disconnection

\cfg{winhelp-topic}{connection.keepalive}

If you find your sessions are closing unexpectedly (\q{Connection
reset by peer}) after they have been idle for a while, you might
want to try using this option.

Some network routers and firewalls need to keep track of all
connections through them. Usually, these firewalls will assume a
connection is dead if no data is transferred in either direction
after a certain time interval. This can cause PuTTY sessions to be
unexpectedly closed by the firewall if no traffic is seen in the
session for some time.

The keepalive option (\q{Seconds between keepalives}) allows you to
configure PuTTY to send data through the session at regular
intervals, in a way that does not disrupt the actual terminal
session. If you find your firewall is cutting idle connections off,
you can try entering a non-zero value in this field. The value is
measured in seconds; so, for example, if your firewall cuts
connections off after ten minutes then you might want to enter 300
seconds (5 minutes) in the box.

Note that keepalives are not always helpful. They help if you have a
firewall which drops your connection after an idle period; but if
the network between you and the server suffers from breaks in
connectivity then keepalives can actually make things worse. If a
session is idle, and connectivity is temporarily lost between the
endpoints, but the connectivity is restored before either side tries
to send anything, then there will be no problem - neither endpoint
will notice that anything was wrong. However, if one side does send
something during the break, it will repeatedly try to re-send, and
eventually give up and abandon the connection. Then when
connectivity is restored, the other side will find that the first
side doesn't believe there is an open connection any more.
Keepalives can make this sort of problem worse, because they
increase the probability that PuTTY will attempt to send data during
a break in connectivity. Therefore, you might find they help
connection loss, or you might find they make it worse, depending on
what \e{kind} of network problems you have between you and the
server.

Keepalives are only supported in Telnet and SSH; the Rlogin and Raw
protocols offer no way of implementing them. (For an alternative, see
\k{config-tcp-keepalives}.)

Note that if you are using SSH1 and the server has a bug that makes
it unable to deal with SSH1 ignore messages (see
\k{config-ssh-bug-ignore1}), enabling keepalives will have no effect.

\S{config-nodelay} \q{Disable Nagle's algorithm}

\cfg{winhelp-topic}{connection.nodelay}

Nagle's algorithm is a detail of TCP/IP implementations that tries
to minimise the number of small data packets sent down a network
connection. With Nagle's algorithm enabled, PuTTY's bandwidth usage
will be slightly more efficient; with it disabled, you may find you
get a faster response to your keystrokes when connecting to some
types of server.

The Nagle algorithm is disabled by default.

\S{config-tcp-keepalives} \q{Enable TCP keepalives}

\cfg{winhelp-topic}{connection.tcpkeepalive}

\e{NOTE:} TCP keepalives should not be confused with the
application-level keepalives described in \k{config-keepalive}. If in
doubt, you probably want application-level keepalives; TCP keepalives
are provided for completeness.

The idea of TCP keepalives is similar to application-level keepalives,
and the same caveats apply. The main differences are:

\b TCP keepalives are available on \e{all} connection types, including
Raw and Rlogin.

\b The interval between TCP keepalives is usually much longer,
typically two hours; this is set by the operating system, and cannot
be configured within PuTTY.

\b If the operating system does not receive a response to a keepalive,
it may send out more in quick succession and if terminate the connection
if no response is received.

TCP keepalives may be more useful for ensuring that half-open connections
are terminated than for keeping a connection alive.

TCP keepalives are disabled by default.

\H{config-proxy} The Proxy panel

\cfg{winhelp-topic}{proxy.main}

The Proxy panel allows you to configure PuTTY to use various types
of proxy in order to make its network connections. The settings in
this panel affect the primary network connection forming your PuTTY
session, but also any extra connections made as a result of SSH port
forwarding (see \k{using-port-forwarding}).

\S{config-proxy-type} Setting the proxy type

\cfg{winhelp-topic}{proxy.type}

The \q{Proxy type} radio buttons allow you to configure what type of
proxy you want PuTTY to use for its network connections. The default
setting is \q{None}; in this mode no proxy is used for any
connection.

\b Selecting \q{HTTP} allows you to proxy your connections through a
web server supporting the HTTP \cw{CONNECT} command, as documented
in \W{http://www.ietf.org/rfc/rfc2817.txt}{RFC 2817}.

\b Selecting \q{SOCKS 4} or \q{SOCKS 5} allows you to proxy your
connections through a SOCKS server.

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?