1
1
mirror of https://github.com/wez/wezterm.git synced 2024-09-20 03:09:06 +03:00

withdraw DEC private SGR handling for super/subscript

refs: https://github.com/mintty/mintty/issues/1189
refs: https://github.com/mintty/mintty/issues/1171
This commit is contained in:
Wez Furlong 2022-12-19 11:37:53 -07:00
parent 0fa8e9bc86
commit fe60155d3d
No known key found for this signature in database
GPG Key ID: 7A7F66A31EC9B387
3 changed files with 19 additions and 7 deletions

View File

@ -23,6 +23,9 @@ As features stabilize some brief notes about them will accumulate here.
#### Changed
* Window title reporting escape sequences are now disabled by default.
[See here for more details](https://marc.info/?l=bugtraq&m=104612710031920&w=2)
* Withdraw DEC private SGR escapes that affect superscript and
subscript due to xterm/vim conflict
[mintty/#1189](https://github.com/mintty/mintty/issues/1189)
### 20221119-145034-49b9839f

View File

@ -2460,12 +2460,6 @@ impl<'a> CSIParser<'a> {
Ok(self.advance_by(1, params, $t))
};
}
// Consume two parameters and return the parsed result
macro_rules! two {
($t:expr) => {
Ok(self.advance_by(2, params, $t))
};
}
match &params[0] {
CsiParam::P(b';') => {
@ -2484,7 +2478,16 @@ impl<'a> CSIParser<'a> {
// Level 2 Programming Reference Manual"
// on page 7-78.
// <https://vaxhaven.com/images/f/f7/EK-PPLV2-PM-B01.pdf>
/* Withdrawn because xterm introduced a conflict:
* <https://github.com/mintty/mintty/issues/1171#issuecomment-1336174469>
* <https://github.com/mintty/mintty/issues/1189>
CsiParam::P(b'?') if params.len() > 1 => match &params[1] {
// Consume two parameters and return the parsed result
macro_rules! two {
($t:expr) => {
Ok(self.advance_by(2, params, $t))
};
}
CsiParam::Integer(i) => match FromPrimitive::from_i64(*i) {
None => Err(()),
Some(code) => match code {
@ -2499,6 +2502,7 @@ impl<'a> CSIParser<'a> {
},
_ => Err(()),
},
*/
CsiParam::P(_) => Err(()),
CsiParam::Integer(i) => match FromPrimitive::from_i64(*i) {
None => Err(()),

View File

@ -338,7 +338,7 @@ impl<'a, F: FnMut(Action)> VTActor for Performer<'a, F> {
#[cfg(test)]
mod test {
use super::*;
use crate::cell::{Intensity, Underline, VerticalAlign};
use crate::cell::{Intensity, Underline};
use crate::color::ColorSpec;
use crate::escape::csi::{
CharacterPath, DecPrivateMode, DecPrivateModeCode, Device, Mode, Sgr, Window, XtSmGraphics,
@ -942,8 +942,12 @@ mod test {
);
}
/* Withdrawn because xterm introduced a conflict:
* <https://github.com/mintty/mintty/issues/1171#issuecomment-1336174469>
* <https://github.com/mintty/mintty/issues/1189>
#[test]
fn dec_private_sgr() {
use crate::cell::{VerticalAlign};
assert_eq!(
parse_as("\x1b[?0m", "\x1b[0m"),
vec![Action::CSI(CSI::Sgr(Sgr::Reset))]
@ -975,6 +979,7 @@ mod test {
vec![Action::CSI(CSI::Sgr(Sgr::Overline(false)))]
);
}
*/
#[test]
fn decset() {