From 8423f79e326f463364aa1274180cd39eba1b98d9 Mon Sep 17 00:00:00 2001 From: Simon Tatham Date: Thu, 14 May 2015 13:19:15 +0100 Subject: [PATCH] Fix layout overflow in Windows PuTTYgen due to ED25519. Adding an extra radio button to the key-type selector caused it to wrap on to another line and push the bottom of the containing control box down off the bottom of the window. In the long term, should more public key formats continue to appear, we'll probably have to replace the radio buttons with something more extensible like a drop-down list. For the moment, though, I've fixed it by just reducing the space per radio button to bring all five controls back on to the same line. To fit the text into the smaller space, I also removed the 'SSH-2' prefix on each key type, which ought to be unnecessary these days since SSH-2 is a well established default. Only the SSH-1 RSA key type is still labelled with an SSH version. (And I've moved it to the far end rather than the start of the line, while I'm here.) --- windows/winpgen.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/windows/winpgen.c b/windows/winpgen.c index 20146da6..c1b84a1b 100644 --- a/windows/winpgen.c +++ b/windows/winpgen.c @@ -925,12 +925,13 @@ static int CALLBACK MainDlgProc(HWND hwnd, UINT msg, "&Save private key", IDC_SAVE); endbox(&cp); beginbox(&cp, "Parameters", IDC_BOX_PARAMS); - radioline(&cp, "Type of key to generate:", IDC_TYPESTATIC, 4, + radioline(&cp, "Type of key to generate:", IDC_TYPESTATIC, 5, + "&RSA", IDC_KEYSSH2RSA, + "&DSA", IDC_KEYSSH2DSA, + "&ECDSA", IDC_KEYSSH2ECDSA, + "ED&25519", IDC_KEYSSH2ED25519, "SSH-&1 (RSA)", IDC_KEYSSH1, - "SSH-2 &RSA", IDC_KEYSSH2RSA, - "SSH-2 &DSA", IDC_KEYSSH2DSA, - "SSH-2 &ECDSA", IDC_KEYSSH2ECDSA, - "SSH-2 ED&25519", IDC_KEYSSH2ED25519, NULL); + NULL); staticedit(&cp, "Number of &bits in a generated key:", IDC_BITSSTATIC, IDC_BITS, 20); endbox(&cp);