Skip to content

Instantly share code, notes, and snippets.

@saitoha
saitoha / screen-bracketed-paste-mode.diff
Created June 11, 2012 12:06
bracketed paste mode patch for GNU screen
diff --git a/src/ansi.c b/src/ansi.c
index d88e153..ecc6e69 100644
--- a/src/ansi.c
+++ b/src/ansi.c
@@ -193,6 +193,7 @@ register struct win *p;
p->w_insert = 0;
p->w_revvid = 0;
p->w_mouse = 0;
+ p->w_bracketed = 0;
p->w_curinv = 0;
@saitoha
saitoha / mouseterm-Japanse-French-localization.diff
Created June 12, 2012 11:50
mouseterm Japanese/French localization support
diff --git a/Japanese.lproj/Localizable.strings b/Japanese.lproj/Localizable.strings
new file mode 100644
index 0000000..02a8de8
--- /dev/null
+++ b/Japanese.lproj/Localizable.strings
@@ -0,0 +1,2 @@
+/* Send Mouse Events menu item */
+"Send Mouse Events" = "マウスイベントを送る";
diff --git a/Makefile b/Makefile
index 0cf09f5..ab7945b 100644
@saitoha
saitoha / drcsconv.pl
Created June 20, 2012 13:45
Convert image file to VT-320's DRCS format.
#!/usr/bin/env perl
use strict;
use warnings;
if ($#ARGV != 0) {
print "ussage: drcsconv.pl <filename>.";
exit 0;
}
my $file = $ARGV[0];
diff -r dbb084863466 src/option.c
--- a/src/option.c Wed Jun 20 22:56:02 2012 +0200
+++ b/src/option.c Sat Jun 23 12:46:42 2012 +0900
@@ -5818,6 +5818,10 @@
else if (set_chars_option(&p_fcs) != NULL)
errmsg = (char_u *)_("E835: Conflicts with value of 'fillchars'");
# endif
+ else if (STRCMP(p_ambw, "double") == 0)
+ out_str(ESC_STR "[?8840h");
+ else /* if (STRCMP(p_ambw, "single") == 0) */
@saitoha
saitoha / screen-bpm-cursorstyle.diff
Created June 23, 2012 11:01
add Bracketed Paste Mode and DECSCUSR support for GNU Screen (http://savannah.gnu.org/git/?group=screen)
diff --git a/src/ansi.c b/src/ansi.c
index d88e153..89116c3 100644
--- a/src/ansi.c
+++ b/src/ansi.c
@@ -193,6 +193,8 @@ register struct win *p;
p->w_insert = 0;
p->w_revvid = 0;
p->w_mouse = 0;
+ p->w_bracketed = 0;
+ p->w_cursorstyle = 0;
@saitoha
saitoha / xterm-license.txt
Created June 30, 2012 05:47
xterm's license block
here is the license block of term-279
/*
* Copyright 2001-2010,2011 by Thomas E. Dickey
*
* All Rights Reserved
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the
* "Software"), to deal in the Software without restriction, including
@saitoha
saitoha / mlterm-3.1.3pre-for-osx-lion.patch
Created July 12, 2012 11:48
patch for mlterm-3.1.3pre, for MacOSX Lion
diff -r 7a4846d08dd0 kiklib/src/kik_pty_streams.c
--- a/kiklib/src/kik_pty_streams.c Thu Jul 12 05:56:56 2012 +0900
+++ b/kiklib/src/kik_pty_streams.c Thu Jul 12 20:47:08 2012 +0900
@@ -107,9 +107,7 @@
if( fcntl( *master, F_SETFL, O_NDELAY) == -1)
{
- close(*master) ;
-
- return -1 ;
@saitoha
saitoha / screen-sgr-mouse.diff
Created July 12, 2012 12:04
Support SGR 1006 mouse reporting, for GNU Screen
diff --git a/src/ansi.c b/src/ansi.c
index d88e153..088ab0b 100644
--- a/src/ansi.c
+++ b/src/ansi.c
@@ -193,6 +193,7 @@ register struct win *p;
p->w_insert = 0;
p->w_revvid = 0;
p->w_mouse = 0;
+ p->w_mouse_protocol = 0;
p->w_curinv = 0;
@saitoha
saitoha / putty-sgr-style.diff
Created July 13, 2012 12:26
SGR 1006/urxvt 1015/any event mouse reporting, for putty r9575
Index: terminal.c
===================================================================
--- terminal.c (revision 9575)
+++ terminal.c (working copy)
@@ -45,6 +45,17 @@
#define TM_VTXXX (TM_VT220|CL_VT340TEXT|CL_VT510|CL_VT420|CL_VT320)
#define TM_SCOANSI (CL_ANSIMIN|CL_SCOANSI)
+/** Mouse tracking modes */
+#define MM_NONE 0x00 /* No tracking */
@saitoha
saitoha / w3m-sgr-style.diff
Last active October 7, 2015 05:38
SGR 1006 mouse reporting for w3m
Index: keybind.c
===================================================================
RCS file: /cvsroot/w3m/w3m/keybind.c,v
retrieving revision 1.10
diff -u -r1.10 keybind.c
--- keybind.c 29 May 2006 12:17:25 -0000 1.10
+++ keybind.c 14 Jul 2012 21:20:27 -0000
@@ -91,7 +91,7 @@
/* 0 1 2 3 4 5 6 7 */
nulcmd, nulcmd, nulcmd, nulcmd, nulcmd, nulcmd, nulcmd, nulcmd,