Index: config.c
===================================================================
--- config.c	(revision 6716)
+++ config.c	(working copy)
@@ -1179,17 +1179,17 @@
 		      HELPCTX(keyboard_backspace),
 		      dlg_stdradiobutton_handler,
 		      I(offsetof(Config, bksp_is_delete)),
-		      "Control-H", I(0), "Control-? (127)", I(1), NULL);
+		      "MFG/Pro Control-H", I(0), "Control-? (127)", I(1), NULL);
     ctrl_radiobuttons(s, "The Home and End keys", 'e', 2,
 		      HELPCTX(keyboard_homeend),
 		      dlg_stdradiobutton_handler,
 		      I(offsetof(Config, rxvt_homeend)),
-		      "Standard", I(0), "rxvt", I(1), NULL);
+		      "Standard", I(0), "MFG/Pro", I(1), NULL);
     ctrl_radiobuttons(s, "The Function keys and keypad", 'f', 3,
 		      HELPCTX(keyboard_funkeys),
 		      dlg_stdradiobutton_handler,
 		      I(offsetof(Config, funky_type)),
-		      "ESC[n~", I(0), "Linux", I(1), "Xterm R6", I(2),
+		      "ESC[n~", I(0), "Linux", I(1), "MFG/Pro", I(2),
 		      "VT400", I(3), "VT100+", I(4), "SCO", I(5), NULL);
 
     s = ctrl_getset(b, "Terminal/Keyboard", "appkeypad",
Index: settings.c
===================================================================
--- settings.c	(revision 6716)
+++ settings.c	(working copy)
@@ -590,9 +590,9 @@
 	 sizeof(cfg->remote_cmd));
     gppi(sesskey, "RFCEnviron", 0, &cfg->rfc_environ);
     gppi(sesskey, "PassiveTelnet", 0, &cfg->passive_telnet);
-    gppi(sesskey, "BackspaceIsDelete", 1, &cfg->bksp_is_delete);
-    gppi(sesskey, "RXVTHomeEnd", 0, &cfg->rxvt_homeend);
-    gppi(sesskey, "LinuxFunctionKeys", 0, &cfg->funky_type);
+    gppi(sesskey, "BackspaceIsDelete", 0, &cfg->bksp_is_delete);
+    gppi(sesskey, "RXVTHomeEnd", 1, &cfg->rxvt_homeend);
+    gppi(sesskey, "LinuxFunctionKeys", 2, &cfg->funky_type);
     gppi(sesskey, "NoApplicationKeys", 0, &cfg->no_applic_k);
     gppi(sesskey, "NoApplicationCursors", 0, &cfg->no_applic_c);
     gppi(sesskey, "NoMouseReporting", 0, &cfg->no_mouse_rep);
@@ -648,7 +648,7 @@
     gppi(sesskey, "DisableArabicShaping", 0, &cfg->arabicshaping);
     gppi(sesskey, "DisableBidi", 0, &cfg->bidi);
     gppi(sesskey, "WinNameAlways", 1, &cfg->win_name_always);
-    gpps(sesskey, "WinTitle", "", cfg->wintitle, sizeof(cfg->wintitle));
+    gpps(sesskey, "WinTitle", "APFoods QAD - MFG/Pro", cfg->wintitle, sizeof(cfg->wintitle));
     gppi(sesskey, "TermWidth", 80, &cfg->width);
     gppi(sesskey, "TermHeight", 24, &cfg->height);
     gppfont(sesskey, "Font", &cfg->font);
Index: windows/windefs.c
===================================================================
--- windows/windefs.c	(revision 6716)
+++ windows/windefs.c	(working copy)
@@ -13,7 +13,7 @@
 	strcpy(ret.name, "Courier New");
 	ret.isbold = 0;
 	ret.charset = ANSI_CHARSET;
-	ret.height = 10;
+	ret.height = 12;
     } else {
 	ret.name[0] = '\0';
     }
Index: windows/windlg.c
===================================================================
--- windows/windlg.c	(revision 6716)
+++ windows/windlg.c	(working copy)
@@ -659,7 +659,7 @@
     winctrl_init(&ctrls_panel);
     dp_add_tree(&dp, &ctrls_base);
     dp_add_tree(&dp, &ctrls_panel);
-    dp.wintitle = dupprintf("%s Configuration", appname);
+    dp.wintitle = dupprintf("%s MFG/Pro Configuration", appname);
     dp.errtitle = dupprintf("%s Error", appname);
     dp.data = &cfg;
     dp.shortcuts['g'] = TRUE;	       /* the treeview: `Cate&gory' */
@@ -691,7 +691,7 @@
     winctrl_init(&ctrls_panel);
     dp_add_tree(&dp, &ctrls_base);
     dp_add_tree(&dp, &ctrls_panel);
-    dp.wintitle = dupprintf("%s Reconfiguration", appname);
+    dp.wintitle = dupprintf("%s MFG/Pro Reconfiguration", appname);
     dp.errtitle = dupprintf("%s Error", appname);
     dp.data = &cfg;
     dp.shortcuts['g'] = TRUE;	       /* the treeview: `Cate&gory' */
Index: windows/window.c
===================================================================
--- windows/window.c	(revision 6716)
+++ windows/window.c	(working copy)
@@ -3867,9 +3867,10 @@
 	    return -2;
 	}
 	if (wParam == VK_TAB && shift_state == 1) {	/* Shift tab */
-	    *p++ = 0x1B;
-	    *p++ = '[';
-	    *p++ = 'Z';
+	    /* *p++ = 0x1B;
+	    *p++ = '['; */
+/* added by jamesm to get shift tab to send CTRL-U */
+	    *p++ = 0x15;
 	    return p - output;
 	}
 	if (wParam == VK_SPACE && shift_state == 2) {	/* Ctrl-Space */
@@ -4071,15 +4072,38 @@
 		p += sprintf((char *) p, "\x1BO%c", code + 'P' - 11);
 	    return p - output;
 	}
+	
 	if (cfg.rxvt_homeend && (code == 1 || code == 4)) {
-	    p += sprintf((char *) p, code == 1 ? "\x1B[H" : "\x1BOw");
+	      p += sprintf((char *) p, code == 1 ? "\x1B\x1B[D" : "\x1B\x1B[C");
+			/* Sends the correct RIGHT-END LEFT-END */
+
 	    return p - output;
 	}
-	if (code) {
-	    p += sprintf((char *) p, "\x1B[%d~", code);
-	    return p - output;
-	}
 
+/* MFG /Pro added by james */
+
+ if (cfg.funky_type == FUNKY_XTERM && code == 15) {
+            p += sprintf((char *) p, "%c", 4); /* added so F5 is ^D=0x04h=EOT */
+          return p - output;
+      } else if (cfg.funky_type == FUNKY_XTERM && code == 3) {
+          p += sprintf((char *) p, "%c", 127); /* added so DEL sends ASCII DEL \177   127   0x7F   DEL */
+          return p - output;
+      } else if (cfg.funky_type == FUNKY_XTERM && code == 2) {
+          p += sprintf((char *) p, "\x1B[20~"); /* added so INSERT key sends the same as F9 ^[[20~ */
+          return p - output;
+			} else if (cfg.funky_type == FUNKY_XTERM && code == 5) {
+					p += sprintf((char *) p, "\x1B\x1B[A");
+					return p - output;
+	/* send ESC Up Arrow for Page Up */
+			} else if ( cfg.funky_type == FUNKY_XTERM && code == 6) {
+					p += sprintf((char *) p, "\x1B\x1B[B");
+					return p - output;
+/* send ESC Down Arrow for Page Down */
+      } else if(code) {
+           p += sprintf((char *) p, "\x1B[%d~", code);
+           return p - output;
+       }
+
 	/*
 	 * Now the remaining keys (arrows and Keypad 5. Keypad 5 for
 	 * some reason seems to send VK_CLEAR to Windows...).
