[vte] parser: Add some more known sequences
- From: Christian Persch <chpe src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vte] parser: Add some more known sequences
- Date: Thu, 12 Nov 2020 20:37:26 +0000 (UTC)
commit 24c4be967482aa2c152de7a46be8f6d0498f4b01
Author: Christian Persch <chpe src gnome org>
Date: Thu Nov 12 21:37:16 2020 +0100
parser: Add some more known sequences
src/parser-seq.py | 7 +++++++
src/vteseq.cc | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++--
2 files changed, 58 insertions(+), 2 deletions(-)
---
diff --git a/src/parser-seq.py b/src/parser-seq.py
index a349d1d9..9ba0f0c1 100755
--- a/src/parser-seq.py
+++ b/src/parser-seq.py
@@ -84,6 +84,7 @@ class Source(enum.Enum):
ECMA16 = enum.auto() # eq ISO 1745
ECMA35 = enum.auto() # eq ISO 2022
ECMA48 = enum.auto() # eq ISO 6429
+ HP = enum.auto()
ITERM2 = enum.auto()
RLOGIN = enum.auto()
SCO = enum.auto()
@@ -98,6 +99,8 @@ class Source(enum.Enum):
return cls.DEC
elif name.endswith('_ECMA'):
return cls.ECMA48
+ elif name.startswith('HP') or name.endswith('_HP'):
+ return cls.HP
elif name.startswith('ITERM'):
return cls.ITERM2
elif name.startswith('RLOGIN'):
@@ -643,6 +646,8 @@ sequences = [
comment='set mode ecma'),
seq_CSI('SLS', 'h', intermediates=(Intermediate.SPACE,), flags=Flags.NOP,
comment='set line spacing'),
+ seq_CSI('SM_HP', 'h', pintro=(ParameterIntro.GT,), flags=Flags.NOP,
+ comment='set mode hp'),
seq_CSI('SM_DEC', 'h', pintro=(ParameterIntro.WHAT,),
comment='set mode dec'),
seq_CSI('MC_ECMA', 'i', flags=Flags.NOP,
@@ -661,6 +666,8 @@ sequences = [
comment='select character path'),
seq_CSI('RM_ECMA', 'l',
comment='reset mode ecma'),
+ seq_CSI('RM_HP', 'l', pintro=(ParameterIntro.GT,), flags=Flags.NOP,
+ comment='reset mode hp'),
seq_CSI('RM_DEC', 'l', pintro=(ParameterIntro.WHAT,),
comment='reset mode dec'),
seq_CSI('SGR', 'm',
diff --git a/src/vteseq.cc b/src/vteseq.cc
index 3590aae0..312bd10d 100644
--- a/src/vteseq.cc
+++ b/src/vteseq.cc
@@ -7000,6 +7000,23 @@ Terminal::RM_DEC(vte::parser::Sequence const& seq)
set_mode_private(seq, false);
}
+
+void
+Terminal::RM_HP(vte::parser::Sequence const& seq)
+{
+ /*
+ * RM_HP - set mode hp
+ * This is the same as RM_ECMA but for HP private modes.
+ *
+ * See SM_HP for information about known modes.
+ *
+ * Defaults: none
+ *
+ * References: HP 2397A
+ */
+
+ /* Not worth implementing */
+}
void
Terminal::SCORC(vte::parser::Sequence const& seq)
{
@@ -7554,6 +7571,28 @@ Terminal::SM_DEC(vte::parser::Sequence const& seq)
set_mode_private(seq, true);
}
+void
+Terminal::SM_HP(vte::parser::Sequence const& seq)
+{
+ /*
+ * SM_HP - set mode hp
+ * This is the same as SM_ECMA but for HP private modes.
+ *
+ * Known modes:
+ * 1: multipage mode
+ * If reset, the terminal only has one page of 24 lines of display memory
+ * Default: reset
+ * 2: memory lock
+ * Default: reset
+ *
+ * Defaults: none
+ *
+ * References: HP 2397A
+ */
+
+ /* Not worth implementing */
+}
+
void
Terminal::SOH(vte::parser::Sequence const& seq)
{
@@ -8520,7 +8559,12 @@ Terminal::XTERM_MLHP(vte::parser::Sequence const& seq)
/*
* XTERM_MLHP - xterm-memory-lock-hp-bugfix
*
- * Probably not worth implementing.
+ * This seems bogus; SM_HP 2 is the way to set the memory lock on
+ * HP terminal.
+ *
+ * References: XTERM
+ *
+ * Not worth implementing.
*/
}
@@ -8530,7 +8574,12 @@ Terminal::XTERM_MUHP(vte::parser::Sequence const& seq)
/*
* XTERM_MUHP - xterm-memory-unlock-hp-bugfix
*
- * Probably not worth implementing.
+ * This seems bogus; RM_HP 2 is the way to unset the memory lock on
+ * HP terminal.
+ *
+ * References: XTERM
+ *
+ * Not worth implementing.
*/
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]