1
0
mirror of https://git.tartarus.org/simon/putty.git synced 2025-01-10 01:48:00 +00:00
putty-source/windows
Simon Tatham 41e1a586fb Centralise key escape sequences into terminal.c.
A long time ago, in commit 4d77b6567, I moved the generation of the
arrow-key escape sequences into a function format_arrow_key(). Mostly
the reason for that was a special purpose I had in mind at the time
which involved auto-generating the same sequences in response to
things other than a keypress, but I always thought it would be nice to
centralise a lot more of PuTTY's complicated keyboard handling in the
same way - at least the handling of the function keys and their
numerous static and dynamic config options.

In this year's general spirit of tidying up and refactoring, I think
it's finally time. So here I introduce three more centralised
functions for dealing with the numbered function keys, the small
keypad (Ins, Home, PgUp etc) and the numeric keypad. Lots of horrible
and duplicated code from the key handling functions in window.c and
gtkwin.c is now more sensibly centralised: each platform keyboard
handler concerns itself with the local format of a keyboard event and
platform-specific enumeration of key codes, and once it's decided what
the logical key press actually _is_, it hands off to the new functions
in terminal.c to generate the appropriate escape code.

Mostly this is intended to be a refactoring without functional change,
leaving the keyboard handling how it's always been. But in cases where
the Windows and GTK handlers were accidentally inconsistent, I've
fixed the inconsistency rather than carefully keeping both sides how
they were. Known consistency fixes:

 - swapping the arrow keys between normal (ESC [ A) and application
   (ESC O A) is now done by pressing Ctrl with them, and _not_ by
   pressing Shift. That was how it was always supposed to work, and
   how it's worked on GTK all along, but on Windows it's been done by
   Shift as well since 2010, due to a bug at the call site of
   format_arrow_key() introduced when I originally wrote that function.

 - in Xterm function key mode plus application keypad mode, the /*-
   keys on the numeric keypad now send ESC O {o,j,m} in place of ESC O
   {Q,R,S}. That's how the Windows keyboard handler has worked all
   along (it was a deliberate behaviour tweak for the Xterm-like
   function key mode, because in that mode ESC O {Q,R,S} are generated
   by F2-F4). But the GTK keyboard handler omitted that particular
   special case and was still sending ESC O {Q,R,S} for those keys in
   all application keypad modes.

 - also in Xterm function key mode plus app keypad mode, we only
   generates the app-keypad escape sequences if Num Lock is on; with
   Num Lock off, the numeric keypad becomes arrow keys and
   Home/End/etc, just as it would in non-app-keypad mode. Windows has
   done this all along, but again, GTK lacked that special case.
2018-12-08 16:08:47 +00:00
..
installer.wxs Fix platform field in Windows on Arm installers. 2018-08-21 07:17:06 +01:00
msiplatform.py Fix platform field in Windows on Arm installers. 2018-08-21 07:17:06 +01:00
pageant.ico Tweak the icon script, and the generated icons, to more closely 2007-01-07 10:17:12 +00:00
pageant.mft Make manifest files work with 64bit builds of PuTTY. 2015-08-15 13:54:44 +01:00
pageant.rc Pageant and PuTTYgen About boxes: add the website button. 2017-02-22 07:06:00 +00:00
pageants.ico Tweak the icon script, and the generated icons, to more closely 2007-01-07 10:17:12 +00:00
plink.rc `win-versioninfo': all builds of all Windows binaries now contain 2005-10-04 14:13:28 +00:00
pscp.ico Tweak the icon script, and the generated icons, to more closely 2007-01-07 10:17:12 +00:00
pscp.rc `win-versioninfo': all builds of all Windows binaries now contain 2005-10-04 14:13:28 +00:00
psftp.rc `win-versioninfo': all builds of all Windows binaries now contain 2005-10-04 14:13:28 +00:00
putty.ico Tweak the icon script, and the generated icons, to more closely 2007-01-07 10:17:12 +00:00
putty.iss Update version number for 0.70 release. 2017-07-04 20:29:54 +01:00
putty.mft Make manifest files work with 64bit builds of PuTTY. 2015-08-15 13:54:44 +01:00
putty.rc `win-versioninfo': all builds of all Windows binaries now contain 2005-10-04 14:13:28 +00:00
puttycfg.ico Tweak the icon script, and the generated icons, to more closely 2007-01-07 10:17:12 +00:00
puttygen.ico Tweak the icon script, and the generated icons, to more closely 2007-01-07 10:17:12 +00:00
puttygen.mft Make manifest files work with 64bit builds of PuTTY. 2015-08-15 13:54:44 +01:00
puttygen.rc Pageant and PuTTYgen About boxes: add the website button. 2017-02-22 07:06:00 +00:00
puttyins.ico `installer.ico' doesn't fit into 8.3, so gets truncated to INSTALLE.ICO in 2007-02-06 22:39:15 +00:00
puttytel.mft Give PuTTYtel its own Windows manifest file. 2018-10-06 11:57:59 +01:00
puttytel.rc Give PuTTYtel its own Windows manifest file. 2018-10-06 11:57:59 +01:00
rcstuff.h Remove Makefile.bor. 2017-09-13 19:26:28 +01:00
README-msi.txt Switch chiark URLs to https. 2017-05-07 16:29:01 +01:00
README.txt Switch chiark URLs to https. 2017-05-07 16:29:01 +01:00
sizetip.c Convert a lot of 'int' variables to 'bool'. 2018-11-03 13:45:00 +00:00
version.rc2 Rewrite some comments with FIXMEs in them. 2018-10-06 11:57:59 +01:00
website.url Switch chiark URLs to https. 2017-05-07 16:29:01 +01:00
win_res.h Use readonly edit controls in some Windows dialogs. 2016-02-29 19:59:35 +00:00
win_res.rc2 Rewrite some comments with FIXMEs in them. 2018-10-06 11:57:59 +01:00
wincapi.c Convert a lot of 'int' variables to 'bool'. 2018-11-03 13:45:00 +00:00
wincapi.h Convert a lot of 'int' variables to 'bool'. 2018-11-03 13:45:00 +00:00
wincfg.c Convert a lot of 'int' variables to 'bool'. 2018-11-03 13:45:00 +00:00
wincons.c Convert a lot of 'int' variables to 'bool'. 2018-11-03 13:45:00 +00:00
winctrls.c Convert a lot of 'int' variables to 'bool'. 2018-11-03 13:45:00 +00:00
windefs.c Convert a lot of 'int' variables to 'bool'. 2018-11-03 13:45:00 +00:00
windlg.c Move all extern declarations into header files. 2018-11-03 13:47:29 +00:00
window.c Centralise key escape sequences into terminal.c. 2018-12-08 16:08:47 +00:00
wingss.c Fix a Windows warning on a strange cast. 2018-06-03 16:52:25 +01:00
winhandl.c Convert a lot of 'int' variables to 'bool'. 2018-11-03 13:45:00 +00:00
winhelp.c Convert a lot of 'int' variables to 'bool'. 2018-11-03 13:45:00 +00:00
winhelp.h Add option whether to include header when logging. 2018-09-26 12:13:01 +01:00
winhsock.c Convert a lot of 'int' variables to 'bool'. 2018-11-03 13:45:00 +00:00
winjump.c Nitpick: fix missing 'void' in one declaration. 2018-11-03 13:45:00 +00:00
winmisc.c Rework mungestr() and unmungestr(). 2018-11-03 13:45:00 +00:00
winnet.c Move all extern declarations into header files. 2018-11-03 13:47:29 +00:00
winnoise.c Convert a lot of 'int' variables to 'bool'. 2018-11-03 13:45:00 +00:00
winnojmp.c Fix up svn:eol-style and svn:keywords on new files. 2010-12-27 00:24:48 +00:00
winnpc.c Move all extern declarations into header files. 2018-11-03 13:47:29 +00:00
winnps.c Move all extern declarations into header files. 2018-11-03 13:47:29 +00:00
winpgen.c Move all extern declarations into header files. 2018-11-03 13:47:29 +00:00
winpgnt.c Move all extern declarations into header files. 2018-11-03 13:47:29 +00:00
winpgntc.c Convert a lot of 'int' variables to 'bool'. 2018-11-03 13:45:00 +00:00
winplink.c Remove 'static' qualifier from Conf pointer 2018-11-04 08:29:15 +00:00
winprint.c Convert a lot of 'int' variables to 'bool'. 2018-11-03 13:45:00 +00:00
winproxy.c Move all extern declarations into header files. 2018-11-03 13:47:29 +00:00
winsecur.c Convert a lot of 'int' variables to 'bool'. 2018-11-03 13:45:00 +00:00
winsecur.h Convert a lot of 'int' variables to 'bool'. 2018-11-03 13:45:00 +00:00
winser.c Convert a lot of 'int' variables to 'bool'. 2018-11-03 13:45:00 +00:00
winsftp.c Move all extern declarations into header files. 2018-11-03 13:47:29 +00:00
winshare.c Move all extern declarations into header files. 2018-11-03 13:47:29 +00:00
winstore.c Fix a segfault in store_host_key. 2018-11-07 21:12:21 +00:00
winstuff.h Move the malloc helpers out of misc.c. 2018-11-27 19:59:45 +00:00
wintime.c wintime: add a precautionary memset to zero. 2017-02-14 23:25:25 +00:00
winucs.c Convert a lot of 'int' variables to 'bool'. 2018-11-03 13:45:00 +00:00
winutils.c Convert a lot of 'int' variables to 'bool'. 2018-11-03 13:45:00 +00:00
winx11.c Convert a lot of 'int' variables to 'bool'. 2018-11-03 13:45:00 +00:00

PuTTY README
============

This is the README file for the PuTTY installer distribution. If
you're reading this, you've probably just run our installer and
installed PuTTY on your system.

What should I do next?
----------------------

If you want to use PuTTY to connect to other computers, or use PSFTP
to transfer files, you should just be able to run them from the
Start menu.

If you want to use the command-line-only file transfer utility PSCP,
you will probably want to put the PuTTY installation directory on
your PATH. On Windows 7 and similar versions, you can do this at
Control Panel > System and Security > System > Advanced system
settings > Environment Variables.

Some versions of Windows will refuse to run HTML Help files (.CHM)
if they are installed on a network drive. If you have installed
PuTTY on a network drive, you might want to check that the help file
works properly. If not, see http://support.microsoft.com/kb/896054
for information on how to solve this problem.

What do I do if it doesn't work?
--------------------------------

The PuTTY home web site is

    https://www.chiark.greenend.org.uk/~sgtatham/putty/

Here you will find our list of known bugs and pending feature
requests. If your problem is not listed in there, or in the FAQ, or
in the manuals, read the Feedback page to find out how to report
bugs to us. PLEASE read the Feedback page carefully: it is there to
save you time as well as us. Do not send us one-line bug reports
telling us `it doesn't work'.