[Ttssh2-commit] [4393] プリンタ制御コードが来ても無視することができるエントリを追加した。

Back to archive index

svnno****@sourc***** svnno****@sourc*****
2011年 3月 25日 (金) 21:04:41 JST


Revision: 4393
          http://sourceforge.jp/projects/ttssh2/svn/view?view=rev&revision=4393
Author:   yutakapon
Date:     2011-03-25 21:04:41 +0900 (Fri, 25 Mar 2011)

Log Message:
-----------
プリンタ制御コードが来ても無視することができるエントリを追加した。
デフォルトは下位互換性のため、オフ。

; Ignore printer control sequence(MC)
IgnorePrinterCtrl=off

ランニング試験中、ホストからプリンタ制御コードが届くと、印刷ダイアログが
表示され、Tera Termが一時停止し、試験が止まらないようにしたい。

メモ:
# echo -e '\x1b\x5b\x69'
とすれば、擬似的にテストできる。ESC [ 'i' でMC(Media Copy)を示す。

Modified Paths:
--------------
    trunk/installer/release/TERATERM.INI
    trunk/teraterm/common/tttypes.h
    trunk/teraterm/teraterm/vtterm.c
    trunk/teraterm/ttpset/ttset.c


-------------- next part --------------
Modified: trunk/installer/release/TERATERM.INI
===================================================================
--- trunk/installer/release/TERATERM.INI	2011-03-22 00:05:50 UTC (rev 4392)
+++ trunk/installer/release/TERATERM.INI	2011-03-25 12:04:41 UTC (rev 4393)
@@ -450,6 +450,9 @@
 ; Direct pass-thru printing
 PassThruPort=
 
+; Ignore printer control sequence(MC)
+IgnorePrinterCtrl=off
+
 ; Delay for paste per each lines (in msec)
 PasteDelayPerLine=10
 

Modified: trunk/teraterm/common/tttypes.h
===================================================================
--- trunk/teraterm/common/tttypes.h	2011-03-22 00:05:50 UTC (rev 4392)
+++ trunk/teraterm/common/tttypes.h	2011-03-25 12:04:41 UTC (rev 4393)
@@ -506,6 +506,7 @@
 	WORD DisableMenuNewConnection;
 	char TerminalUID[9];
 	WORD ConfirmChangePasteCR;
+	BOOL IgnorePrinterCtrl; 
 };
 
 typedef struct tttset TTTSet, *PTTSet;

Modified: trunk/teraterm/teraterm/vtterm.c
===================================================================
--- trunk/teraterm/teraterm/vtterm.c	2011-03-22 00:05:50 UTC (rev 4392)
+++ trunk/teraterm/teraterm/vtterm.c	2011-03-25 12:04:41 UTC (rev 4393)
@@ -1724,6 +1724,15 @@
 
   void CS_i_Mode()		// MC
   {
+	  /* ƒvƒŠƒ“ƒ^§ŒäƒR[ƒh‚ª—ˆ‚Ä‚à–³Ž‹‚·‚éB
+	   * ƒ‰ƒ“ƒjƒ“ƒOŽŽŒ±’†AƒzƒXƒg‚©‚çƒvƒŠƒ“ƒ^§ŒäƒR[ƒh‚ª“Í‚­‚ƁAˆóüƒ_ƒCƒAƒƒO‚ª
+	   * •\Ž¦‚³‚êATera Term‚ªˆêŽž’âŽ~‚µAŽŽŒ±‚ªŽ~‚Ü‚ç‚È‚¢‚悤‚É‚µ‚½‚¢B
+	   * (2011.3.25 yutaka)
+	   */
+	  if (ts.IgnorePrinterCtrl)
+		  return;
+
+
     if (Param[1]==-1) Param[1] = 0;
     switch (Param[1]) {
       /* print screen */

Modified: trunk/teraterm/ttpset/ttset.c
===================================================================
--- trunk/teraterm/ttpset/ttset.c	2011-03-22 00:05:50 UTC (rev 4392)
+++ trunk/teraterm/ttpset/ttset.c	2011-03-25 12:04:41 UTC (rev 4393)
@@ -922,6 +922,9 @@
 	GetPrivateProfileString(Section, "PassThruPort", "",
 	                        ts->PrnDev, sizeof(ts->PrnDev), FName);
 
+	/* ƒvƒŠƒ“ƒ^—p§ŒäƒR[ƒh‚𖳎‹‚·‚é‚©‚Ç‚¤‚© */
+	ts->IgnorePrinterCtrl = GetOnOff(Section, "IgnorePrinterCtrl", FName, FALSE);
+
 	/* Printer Font --- special option */
 	GetPrivateProfileString(Section, "PrnFont", "",
 	                        Temp, sizeof(Temp), FName);
@@ -2105,6 +2108,9 @@
 	/*   -- special option */
 	WritePrivateProfileString(Section, "PassThruPort", ts->PrnDev, FName);
 
+	/* ƒvƒŠƒ“ƒ^—p§ŒäƒR[ƒh‚𖳎‹‚·‚é‚©‚Ç‚¤‚© */
+	WriteOnOff(Section, "IgnorePrinterCtrl", FName, ts->IgnorePrinterCtrl);
+
 	/* Printer Font --- special option */
 	WriteFont(Section, "PrnFont", FName,
 	          ts->PrnFont, ts->PrnFontSize.x, ts->PrnFontSize.y,



Ttssh2-commit メーリングリストの案内
Back to archive index