Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

initial draft of VT function support spec #1884

Merged
merged 1 commit into from
Nov 13, 2020

Conversation

oising
Copy link
Collaborator

@oising oising commented Jul 8, 2019

I'm making this a draft PR while I continue to parse out data, format and add value (like sync scripts etc)

TODO:

  • pull all pure virtual functions out from interface that are commented with a VT mnemonic
  • gather all implemented overrides for conhost in adaptDispatch.hpp
  • gather all implemented overrides for terminal in terminalDispatch.hpp
  • merge with master list of VT mnemonics and categories in sequences.csv
  • generate markdown skeleton with checkmarks per conhost/terminal implementation
  • link implemented checkmarks directly to operation definition in github source tree
  • allow overrides on adaptDispatch/terminalDispatch to provide more metadata to differentiate impl differences between conhost and terminal (define // comment schema)
  • allow overrides for outliers in the attempts to link to vt100.net docs
  • add columns for git blame - introduction dates / commit hashes etc
  • add more data to sequences.csv to represent sub operations (e.g. SGR ops supported)

@DHowett-MSFT
Copy link
Contributor

Perhaps to preserve tabulation we could use ✅❎ emoji instead of markdown checkboxen? I realize that on my phone the X is in green just like the check is, but perhaps GitHub has something different on offer? ❌

@oising
Copy link
Collaborator Author

oising commented Jul 9, 2019

Well, my thought was that when this is completed, it should be embedded in an open issue as a specification, representing "VT support" -- that way we (developers) can simply check a box when the feature is implemented. It might serve as a master list of implemented sequences. Does this make sense?

@DHowett-MSFT
Copy link
Contributor

Ah, yeah, that seems reasonable!

@miniksa
Copy link
Member

miniksa commented Jul 10, 2019

The plan here was to also include the columns where we first introduced it to the conhost and what level of actual test/fuzz/etc coverage and support it has, right?

@oising
Copy link
Collaborator Author

oising commented Jul 10, 2019

@miniksa Yes, absolutely, but I let's get the "minimum viable product" out there first and then we can dig into the extras. You say what "level" -- do you see test/fuzz/coverage for an individual sequence as a non-binary evaluation?

@zadjii-msft
Copy link
Member

@oising Considering #1883, should we have one column for conhost, and another for Windows Terminal? Theoretically at some point, we'd want the terminal to be able to stand on it's own as a terminal emulator, without the crutch of conpty.

@miniksa
Copy link
Member

miniksa commented Jul 11, 2019

@miniksa Michael Niksa FTE Yes, absolutely, but I let's get the "minimum viable product" out there first and then we can dig into the extras. You say what "level" -- do you see test/fuzz/coverage for an individual sequence as a non-binary evaluation?

I mean, in theory, it shouldn't be GREEN or GOOD unless all of the things are covered. But in practice, I'm going to guess that the (UnitTested&&Fuzzed&&FeatureTested) is going to be FALSE for nearly every row in your table. So it might be nice to show that some would be TRUE if only we'd fix the Fuzzed portion of the matrix. Might have to be a manual or manually assisted process...

@oising
Copy link
Collaborator Author

oising commented Jul 12, 2019

Ah, I think I'm going to drop the spec/checkbox task list trickery. Not supporting them inside tables in github markdown really prevents me from coming up with functional and informative layout. There are too many columns now and without a tabular layout, it'll be a bit too dense to visually parse easily. I'll take a stab at doing it like @DHowett-MSFT says, with emoji. Ultimately if it's going to be driven from code, then the checkboxes are not that neccessary.

@oising
Copy link
Collaborator Author

oising commented Jul 26, 2019

REBASE HELL. WHO IS THE IDIOT WHO GAVE ME MY GIT LICENSE

@DHowett-MSFT
Copy link
Contributor

REBASE HELL. WHO IS THE IDIOT WHO GAVE ME MY GIT LICENSE

image

@oising
Copy link
Collaborator Author

oising commented Aug 7, 2019

VT Function Support

Table of Contents

Code Extension Functions

Control Coding

Symbol Function Origin 🖳 Console Host Terminal
CAN Cancel VT100
SUB Substitute VT100
ESC Escape VT100
DCS Device Control String VT220
CSI Control Sequence Introducer VT100
ST String Terminator VT220
OSC Operating System Command DECterm
PM Privacy Message ``
APC Application Program Command VT420
S7C1T Select 7-bit C1 Transmission VT220
S8C1T Select 8-bit C1 Transmission VT220

Character Coding

Symbol Function Origin 🖳 Console Host Terminal
LS0 Locking Shift Zero (SI) VT100
LS1 Locking Shift One (SO) VT100
LS2 Locking Shift Two VT220
LS3 Locking Shift Three VT220
LS1R Locking Shift One Right VT220
LS2R Locking Shift Two Right VT220
LS3R Locking Shift Three Right VT220
SS2 Single Shift Two VT220
SS3 Single Shift Three VT220

Graphic Character Sets

Symbol Function Origin 🖳 Console Host Terminal
SCS Select Character Set VT100
DECNRCM (National Replacement) Character Set Mode VT220
DECAUPSS Assign User-Preference Supplemental Set VT320
DECRQUPSS Request User-Preference Supplemental Set VT320

Terminal Management Functions

Identification, status, and Initialization

Symbol Function Origin 🖳 Console Host Terminal
DA1 Primary Device Attributes VT100
DA2 Secondary Device Attributes VT220
DECRPTUI Report Terminal Unit ID VT420
DSR Device Status Report VT100
DECID Identify Device VT100
DECTID Select Terminal ID VT510
DECSCL Select Conformance Level VT220
DECSR Secure Reset VT420
DECSRC Secure Reset Confirmation VT420
DECSTR Soft Terminal Reset VT220
DECSTUI Set Terminal Unit ID (Restricted) VT420
RIS Reset to Initial state VT100

Emulations

Symbol Function Origin 🖳 Console Host Terminal
DECPCTERM Enter/Exit PC Term Mode from DEC VT mode VT420PC
DECTME Terminal Mode Emulation VT510

Set-Up

Symbol Function Origin 🖳 Console Host Terminal
DECSSL Select Set-Up Language VT510
DECCRTSM CRT Save Mode (not required) VT510
DECOSCNM Overscan Mode VT510
DECSRFR Select Refresh Rate VT510
DECLTOD Load Time of Day VT510
DECLBAN Load Banner Message VT510

Display Coordinate System and Addressing

Active Position and Cursor

Symbol Function Origin 🖳 Console Host Terminal
DECTCEM Text Cursor Enable Mode VT220
DECSCUSR Set Cursor Style VT510

Margins and Scrolling

Symbol Function Origin 🖳 Console Host Terminal
DECSTBM Set Top and Bottom Margin VT100
DECSLRM Set Left and Right Margin VT420
DECLRMM Left Right Margin Mode VT420
DECOM Origin Mode VT100
DECSCLM Scrolling Mode VT100
IND Index VT100
RI Reverse Index VT100
DECFI Forward Index VT420
DECBI Back Index VT420
DECSSCLS Set Scroll Speed VT510

Cursor Movement

Symbol Function Origin 🖳 Console Host Terminal
BS Backspace VT100
LF Line Feed VT100
VT Vertical Tab VT100
FF Form Feed VT100
CR Carriage Return VT100
NEL Next Line VT100
LNM Line Feed/New Line Mode VT100
CUU Cursor Up VT100
CUD Cursor Down VT100
CUF Cursor Forward VT100
CUB Cursor Backward VT100
CUP Cursor Position VT100
HVP Horizontal/Vertical Position VT100
CPR Cursor Position Report VT100
DECXCPR Extended Cursor Position Report VT340 VT420
CHA Cursor Horizontal Absolute VT510
CNL Cursor Next Line VT510
CPL Cursor Previous Line VT510
HPA Horizontal Position Absolute VT510
HPR Horizontal Position Relative VT510
VPA Vertical Line Position Absolute VT510
VPR Vertical Position Relative VT510

Horizontal Tabulation

Symbol Function Origin 🖳 Console Host Terminal
HT Horizontal Tab VT100
HTS Horizontal Tabulation Set VT100
TBC Tabulation Clear VT100
CBT Cursor Backward Tabulation VT510
CHT Cursor Horizontal Forward Tabulation VT510
DECST8C Set Tab at every 8 columns VT420PC

Page Size and Arrangement

Symbol Function Origin 🖳 Console Host Terminal
DECCOLM Column Mode VT100
DECNCSM No Clear Screen on column Mode VT510
DECSCPP Set Columns Per Page VT340 VT420
DECSLPP Set Lines Per Page VT340 VT420

Page Movement

Symbol Function Origin 🖳 Console Host Terminal
NP Next Page VT340 VT420
PP Preceding Page VT340 VT420
PPA Page Position Absolute VT340 VT420
PPR Page Position Relative VT340 VT420
PPB Page Position Backward VT340 VT420

Status Display

Symbol Function Origin 🖳 Console Host Terminal
DECSASD Select Active Status Display VT340 VT320
DECSSDT Select Status Display Type VT340 VT320

Right to Left

Symbol Function Origin 🖳 Console Host Terminal
DECRLM Right to Left Mode VT510
DECRLCM Right to Left Copy Mode VT510
DDD1 VT100 mode Hebrew VT510
DDD2 VT100 mode Hebrew VT510
DDD3 VT100 mode Hebrew VT510

Window Management

Symbol Function Origin 🖳 Console Host Terminal
DECHCCM Horizontal Cursor Coupling Mode VT340 VT420
DECVCCM Vertical Cursor Coupling Mode VT340 VT420
DECPCCM Page Cursor Coupling Mode VT340 VT420
DECRQDE Request Displayed Extent VT340 VT420
DECSNLS Select Number of Lines per Screen (exception) VT420
DECARSM Auto Resize Mode DECterm VT420
SU Pan Down VT340 VT420
SD Pan Up VT340 VT420

Visual Attributes and Renditions

Symbol Function Origin 🖳 Console Host Terminal
DECSCNM Screen Mode VT100

Line Renditions

Symbol Function Origin 🖳 Console Host Terminal
DECSWL Single Width Line VT100
DECDWL Double Width Line VT100
DECDHLT Double Height Line Top VT100
DECDHLB Double Height Line Bottom VT100

Character Renditions

Symbol Function Origin 🖳 Console Host Terminal
SGR Select Graphic Rendition VT100

Audible Indicators

Symbol Function Origin 🖳 Console Host Terminal
BEL Warning Bell VT100
DECSKCV Set Keyclick Volume VT510
DECSWBV Set Warning Bell Volume VT510
DECSMBV Set Margin Bell Volume VT510

Editing Functions

DEC Private

Symbol Function Origin 🖳 Console Host Terminal
IRM Insert/Replacement Mode VT102
ICH Insert Character VT102
DCH Delete Character VT102
IL Insert Line VT100
DL Delete Line VT100
DECIC Insert Column VT420
DECDC Delete Column VT420
ECH Erase Character VT100
EL Erase in Line VT100
DECSEL Selective Erase in Line VT220
ED Erase in Display VT100
DECSED Selective Erase in Display VT220
DECSCA Select Character Attribute (selective erase) VT220

OLTP Features

Rectangular Area Operations

Symbol Function Origin 🖳 Console Host Terminal
DECCRA Copy Rectangular Area VT420
DECFRA Fill Rectangular Area VT420
DECERA Erase Rectangular Area VT420
DECSERA Selective Erase Rectangular Area VT420
DECCARA Change Attribute in Rectangular Area VT420
DECRARA Reverse Attribute in Rectangular Area VT420
DECSACE Select Attribute Change Extent Mode VT420

Data Integrity

Symbol Function Origin 🖳 Console Host Terminal
DECRQCRA Request Checksum of Rectangular Area VT420
DSR Device Status Report (Memory Checksum) VT420
DECCKSR Checksum Report VT420

Macros

Symbol Function Origin 🖳 Console Host Terminal
DECDMAC Define Macro VT420
DECINVM Invoke Macro VT420
DECMSR Macro Space Report VT420

Saving and Restoring Terminal State

Cursor Save Buffer

Symbol Function Origin 🖳 Console Host Terminal
DECSC Save Cursor VT100
DECRC Restore Cursor VT100

Terminal State Interrogation

Symbol Function Origin 🖳 Console Host Terminal
DECRQM Request Mode VT320
DECRPM Report Mode VT320
DECNKM Numeric Keypad Mode VT320
DECRQSS Request Selection or Setting VT320
DECRPSS Report Selection or Setting VT320
DECRQPSR Request Presentation State Report VT320
DECPSR Presentation State Report VT320
DECCIR Cursor Information Report VT320
DECTABSR Tabulation Stop Report VT320
DECRSPS Restore Presentation State VT320
DECRQTSR Request Terminal State Report VT320
DECTSR Terminal State Report VT320
DECRSTS Restore Terminal State VT320

Keyboard Processing Functions

Symbol Function Origin 🖳 Console Host Terminal
DECARM Autorepeat Mode VT100
DECBKM Backarrow Key Mode VT420
DECCKM Cursor Keys Mode VT100
DECEKBD Extended Keyboard Report VT420
DECKBUM Keyboard Usage Mode VT320
DECKPAM Keypad Application Mode VT100
DECKPM Key Position Mode VT420
DECKPNM Keypad Numeric Mode VT100
DECNKM Numeric Keypad Mode VT320
DSR Device Status Report (keyboard status) VT220
KAM Keyboard Action Mode VT220
DECLFC Local Functions Control VT420
DECLFKC Local Function Key Control VT420
DECSMKR Select Modifier Key Reporting VT420
DECHEBM Hebrew Keyboard Map mode VT510
DECHCEM Hebrew Encoding Mode VT510
DECNAKB NA/Greek Selection VT510
DECESKM Secondary Keyboard Language Mode VT510
DECSLCK Set Lock Key Style VT510
DECKBD Keyboard Dialect Selection VT510
DECNUMLK NumLock Mode VT510
DECCAPSLK CapsLock Mode VT510
DECKLHIM Keyboard LEDs Host Indicator Mode VT510
DECLL Load LEDs VT100

Soft Key Mapping (UDK)

Symbol Function Origin 🖳 Console Host Terminal
DECUDK User Defined Keys VT220
DSR Device Status Report (UDK lock) VT220
DECPKA Program Key Action VT510
DECPFK Program Function Key VT510
DECPAK Program Alphanumeric Key VT510
DECCKD Copy Key Default VT510
DECRQPKFM Program Key Free Memory Inquiry VT510
DECPKFMR Program Key Free Memory Report VT510
DECRQKT Inquire a Key Type VT510
DECRPKT Report a Key Type VT510
DECRQKD Inquire a Key Definition VT510
DECRPFK Report definition of a Function Key VT510
DECRPAK Report definition of a Alphanumeric Key VT510

Soft Fonts (DRCS)

Symbol Function Origin 🖳 Console Host Terminal
DECDLD Downline Load VT220

Printing

Symbol Function Origin 🖳 Console Host Terminal
DECPEX Print Extent Mode VT220
DECPFF Print Form Feed Mode VT220
DSR Device Status Report (printer port) VT220
MC Media Copy VT220
DECSPRTT Select Printer Type VT510
DECSDPT Select Digital Printed Data Type VT510
DECSPPCS Select Proprinter Character Set VT510

Terminal Communication and Synchronization

Symbol Function Origin 🖳 Console Host Terminal
BREAK BREAK VT100
XON XON VT100
XOFF XOFF VT100
ENQ Enquiry VT100
SRM Send Receive Mode VT220
DECXRLM Transmit Rate Limiting Mode VT420
DECMCM Modem Control Mode VT510
DECAAM Auto Answerback Mode VT510
DECLANS Load Answerback Message VT510
DECCANSM Conceal Answerback Message Mode VT510
DECNULM Ignore Null Mode VT510
DECHPDXM Half Duplex Mode VT510
DECSFC Select Flow Control VT510
DECSDDT Select Disconnect Delay Time VT510
DECSTRL Set Transmit Rate Limit VT510
DECSCS Select Communication Speed VT510
DECSCP Select Communication Port VT510
DECSPP Set Port Parameter VT510

Text Locator Extension

Symbol Function Origin 🖳 Console Host Terminal
DECEFR Enable Filter Rectangle UWS
DECELR Enable Locator Reports UWS
DECLKD Locator Key Definition UWS
DECLRP Locator Report UWS
DECRQLP Request Locator Position UWS
DECSLE Select Locator Events UWS
DSR Device Status Report (Locator Status) UWS

Session Management Extension

Symbol Function Origin 🖳 Console Host Terminal
DECES Enable Sessions VT340 VT420

Documented Exceptions

Symbol Function Origin 🖳 Console Host Terminal
DECANM ANSI/VT52 Mode VT100
DECALN Screen Alignment VT100
DECAWM Autowrap Mode VT100
DECTST Invoke Confidence Test VT100
CRM Control Representation Mode VT100

Generated on 08/06/2019 23:13:39

@oising oising force-pushed the vt-master-list-spec branch 2 times, most recently from a3437d4 to a7bad84 Compare August 7, 2019 23:14
@DHowett-MSFT
Copy link
Contributor

Hey @oising -- is this good to have the draft tag ripped off? Or does it need a couple more rounds?

@oising
Copy link
Collaborator Author

oising commented Dec 4, 2019

@DHowett-MSFT Oh, jeez, it's still marked draft? Let me give it a once over this evening and I'll get back to you. I think it needs to be released into the wild and let people shoot it or feed it.

@DHowett-MSFT
Copy link
Contributor

Thanks! 😄

@oising
Copy link
Collaborator Author

oising commented Dec 4, 2019

@DHowett-MSFT what do you think anyway, should it go into the build pipeline to generate an asset for the release?

@DHowett-MSFT
Copy link
Contributor

I think that's a very cool idea. In a pinch, if we do not feel a pressing need to publish that asset alongside the release, we can drop it in or adjacent to the wiki too

@oising
Copy link
Collaborator Author

oising commented Dec 4, 2019

@DHowett-MSFT yeah, it would good to at least be able to tag it as a point in time reference to the identically tagged source

@oising
Copy link
Collaborator Author

oising commented Dec 5, 2019

Ok, I've refamiliarized myself with my frame of mind, and I've got a tweak or two to implement. I'm on it!

@oising
Copy link
Collaborator Author

oising commented Jan 25, 2020

I'll be at this forever... it's been too long already. Have at it, and give me some specific things to fix up. Would be nice to get this into a devops pipeline or something.

@DHowett-MSFT
Copy link
Contributor

he lives!

@oising
Copy link
Collaborator Author

oising commented Jan 25, 2020

he lives!

I had a insanely busy couple of months on a new project, and then fell and gave myself a moderate concussion before the new year. Only easing back into screens and stuff now... sigh.

@j4james
Copy link
Collaborator

j4james commented Feb 13, 2020

I suspect you already know this, but in case you aren't aware, a number of the links in the symbol column don't work. I'm assuming they were all just generated automatically from the name, but not every control sequence has its own page in the VT510 manual. For example, I think the best you could do for the control characters would be to link to the tables in chapter 4 (here and here).

Also, just from a brief scan of the list, I think there are quite a lot of sequences that I would have considered implemented, but aren't ticked in the conhost column. Would it be helpful if I made a list, or should I wait until this is merged and submit a PR?

Edit: I've only realised now that the documentation in the comment above isn't an actual file being committed, so suggesting changes to that isn't going to help much. 🤦‍♂️ The ps script is beyond me, but I guess it's magically generated by scanning the source code somehow? I can understand it may not have been run in a while, so won't have picked up some of the recently added sequences, but the fact it's missing basic control chars like BS and CR suggests that it might need more work.

@j4james
Copy link
Collaborator

j4james commented Feb 15, 2020

I've now had a chance to try out the script on my local build, and it's definitely still missing operations that we do support, but many of them can quite easily be fixed just by updating the comments.

There are operations that are aliases, which just need to have the alias name added to the comments (e.g. HVP is an alias of CUP, and HPA is an alias of CHA). Some aren't strictly aliases, but are variants of other operations that share the same dispatch (this includes many of the control characters - BS, HT, LF, VT, and FF).

Then there is DA1, which doesn't get picked up because we have it labelled as DA (that's what is was called on the VT100). I think it probably makes sense for us to rename that to DA1, given that we'll eventually want to implement the other DA operations too.

DSR I'm not sure what to do about. There are a number of different reports that can be requested, but we only currently support DSR-CPR. The problem is that the master-sequence-list has all of them listed separately, but mostly with the same name (DSR). So the fact that we support one DSR results in us claiming to support nearly all of them. Ironically the one report we do support (CPR) is marked as not supported, because that one is actually named uniquely in the csv.

Finally there are the controls that we do support, but don't pass through the dispatch interface, so they're never going to be picked up by this script. This includes CAN, SUB, ESC, CSI, OSC, ST (possibly others). I'm not sure what we could do about those either.

Anyway, is it worth my putting together a little PR to update the comments for the operations that can easily be fixed? Or would it be better if that was included as part of this PR?

@jdebp
Copy link

jdebp commented Feb 18, 2020

ECMA-35 and ECMA-48 are better references to work from for the stuff that is not DEC private. For starters, they explain the actual structure of control sequences (with parameter, intermediate, and final characters) and indeed what "private" means. There are ITU standards from the 1990s that deal with SGR indexed and direct colour control sequences, moreover.

This StackExchange answer should help with reference doco.

@j4james
Copy link
Collaborator

j4james commented Feb 27, 2020

OK, I've started putting together a PR to update the ITermDispatch comments to fix some of the issues described above, but before I submit it I'd like to discuss the DSR issue a little more.

To start with, I think we need to update the CSV to give each of the DSR reports a unique name. I think the easiest choice would be to use the page name on vt100.net site so the links just work, even if those names aren't official (e.g. DSR-CPR for Cursor Position Report, DSR-PP for the Printer Port report, etc.). I'll add review comments on this PR to mark each of the entries I think need to be updated like that.

I don't know if we also want to keep DSR itself as a separate entry, but if we do, then in my PR I'd make the comment for our current DeviceStatusReport method // DSR, DSR-CPR, to indicate that we support DSR as a general concept, but only the Cursor Position Report variant.

I'm not sure this is a workable long-term solution though. If/when we support additional reports, they may be broken out into separate methods, but they're unlikely to be added to the ITermDispatch interface - they're purely a private implementation detail. This assumedly means they wouldn't be picked up by the current script.

The fact that the various mode operations are in the interface seems like a mistake to me - technically they should also be private. The only reason I can think they might be there is for testing purposes, but even that seems like a hack. That said, this isn't a problem we need to solve now, so we can worry about it later. I just thought it worth mentioning.

The other thing I noticed when going through the list, is there are quite a lot of reporting sequences that are essentially listed as two entries. For example, we have the DECRQM (Request Mode) command, which is responded to with a DECRPM sequence. DECRPM isn't something we would parse - it's the value we return - so I don't think it makes sense to list it as a separate entry. My recommendation would be to drop those report sequences from the CSV. Again I'll add review comments on the PR to mark each of these individually.

doc/reference/master-sequence-list.csv Outdated Show resolved Hide resolved
doc/reference/master-sequence-list.csv Outdated Show resolved Hide resolved
doc/reference/master-sequence-list.csv Outdated Show resolved Hide resolved
doc/reference/master-sequence-list.csv Outdated Show resolved Hide resolved
doc/reference/master-sequence-list.csv Outdated Show resolved Hide resolved
doc/reference/master-sequence-list.csv Outdated Show resolved Hide resolved
doc/reference/master-sequence-list.csv Outdated Show resolved Hide resolved
doc/reference/master-sequence-list.csv Outdated Show resolved Hide resolved
doc/reference/master-sequence-list.csv Outdated Show resolved Hide resolved
doc/reference/master-sequence-list.csv Outdated Show resolved Hide resolved
@ghost ghost added the Needs-Author-Feedback The original author of the issue/PR needs to come back and respond to something label Feb 28, 2020
@ghost ghost removed the Needs-Author-Feedback The original author of the issue/PR needs to come back and respond to something label Feb 29, 2020
@zadjii-msft zadjii-msft added the Area-VT Virtual Terminal sequence support label Mar 10, 2020
ghost pushed a commit that referenced this pull request Mar 17, 2020
… VT commands that are supported. (#4752)

## Summary of the Pull Request

Most of the methods in the `ITermDispatch` interface have a comment following them that indicates the VT function that they implement. These comments are then used by the script in PR #1884 to generate a table of supported VT functions. This PR updates some of those comments, to more accurately reflect the functions that are actually supported.

## References

PR #1884 

## PR Checklist
* [ ] Closes #xxx
* [x] CLA signed.
* [x] No new tests.
* [x] No new docs.
* [ ] I've discussed this with core contributors already. If not checked, I'm ready to accept this work might be rejected in favor of a different grand plan. Issue number where discussion took place: #1884

## Detailed Description of the Pull Request / Additional comments

In some cases there are methods that implement multiple VT functions which are essentially aliases. Originally the comments listed only one of the functions, so I've now updated them to list both. This includes `HPA` as an alias of `CHA`, and `HVP` as an alias of `CUP`.

Similarly, some control characters are implemented in terms of another VT function, but only the main function was listed in the comment. Again I've now updated the comments to list both the main function and any related control characters. This includes `BS` (sharing the same method as `CUB`), `HT` (the same method as `CHT`), and `LF`, `FF`, and `VT` (the same method as `IND` and `NEL`).

Then there were some minor corrections. The `DeviceAttributes` method was commented as `DA`, but it really should be `DA1`. `DesignateCharset` was simply commented as _DesignateCharset_, when it should be `SCS`. The `DECSCNM` comment was missing a space, so it wasn't picked up by the script. And the `SetColumns` comment mistakenly included `DECSCPP`, but we don't actually support that.

Finally there is the `DeviceStatusReport` method, which potentially covers a wide range of different reports. But for now we only support the _Cursor Position Report_, so I've commented it as `DSR, DSR-CPR` to more clearly indicate our level of support. In the long term we'll probably need a better way of handling these reports though.

## Validation Steps Performed

I've run the script from PR #1884 and confirmed that the output is now a more accurate reflection of our actual VT support.
@microsoft-github-updates microsoft-github-updates bot changed the base branch from master to main October 22, 2020 00:28
@zadjii-msft
Copy link
Member

Hey @oising - sorry we've let this one sit for so long! I'm not sure why this got lost in February, maybe we all panicked over a certain global pandemic or something. I think this looks just about ready to merge - do you want to just give it a quick once-over to make sure it's up to date?

I know we discussed having this as a build artifact, but that sounds like more engineering effort and I wouldn't want to hold this up too much longer. Maybe we should just run the script once for the "current state" of the support, and throw that in the docs folder, and update it as needed?

The only other thing I'd look for is a quick "this is how you update the doc" oneliner, just so little old me who doesn't know powershell can update the doc without thinking about it 😉

@zadjii-msft zadjii-msft added the Needs-Author-Feedback The original author of the issue/PR needs to come back and respond to something label Nov 5, 2020
@oising
Copy link
Collaborator Author

oising commented Nov 6, 2020

Hey @oising - sorry we've let this one sit for so long! I'm not sure why this got lost in February, maybe we all panicked over a certain global pandemic or something. I think this looks just about ready to merge - do you want to just give it a quick once-over to make sure it's up to date?

I've gone through two new laptops since I started this :P But since I don't need to compile anything to test this, it shouldn't be a problem...

I know we discussed having this as a build artifact, but that sounds like more engineering effort and I wouldn't want to hold this up too much longer. Maybe we should just run the script once for the "current state" of the support, and throw that in the docs folder, and update it as needed?

Sure -- let's just get it in there, and iterate later.

The only other thing I'd look for is a quick "this is how you update the doc" oneliner, just so little old me who doesn't know powershell can update the doc without thinking about it 😉

Will do.

Now I'm about to rebase 769 commits from a branch that has changed name (master -> main) -- I wonder how that will go.

EDIT: it went fine :)

@ghost ghost removed the Needs-Author-Feedback The original author of the issue/PR needs to come back and respond to something label Nov 6, 2020
conhost and windows terminal

renamed files; updated script to do summary output only, also quiet mode and option file path for output (else stdout)

added -quiet and fixed -summaryonly parameters

added hyperlink directly to soruce implementation for conhost and terminal seqs

Update doc/reference/master-sequence-list.csv

Co-Authored-By: James Holderness <j4_james@hotmail.com>

Apply suggestions from code review

Co-Authored-By: James Holderness <j4_james@hotmail.com>
@github-actions
Copy link

github-actions bot commented Nov 6, 2020

New misspellings found, please review:

  • Answerback
  • autogenerate
  • Autorepeat
  • cmdletbinding
  • consolehost
  • CRM
  • Cterm
  • DECAAM
  • DECARM
  • DECARSM
  • DECBI
  • DECBKM
  • DECCANSM
  • DECCAPSLK
  • DECCARA
  • DECCKD
  • DECCKSR
  • DECCRA
  • DECCRTSM
  • DECDC
  • DECDHLB
  • DECDHLT
  • DECDLD
  • DECDMAC
  • DECDWL
  • DECEFR
  • DECELR
  • DECERA
  • DECES
  • DECESKM
  • DECFI
  • DECFRA
  • DECHCCM
  • DECHCEM
  • DECHEBM
  • DECHPDXM
  • DECIC
  • DECID
  • DECINVM
  • DECKBD
  • DECKBUM
  • DECKLHIM
  • DECLANS
  • DECLBAN
  • DECLFC
  • DECLFKC
  • DECLKD
  • DECLL
  • DECLRP
  • DECLTOD
  • DECMCM
  • DECNAKB
  • DECNCSM
  • DECNULM
  • DECNUMLK
  • DECOSCNM
  • DECPAK
  • DECPCCM
  • DECPEX
  • DECPFF
  • DECPFK
  • DECPKA
  • DECRARA
  • DECRLCM
  • DECRQCRA
  • DECRQDE
  • DECRQKD
  • DECRQKT
  • DECRQLP
  • DECRQPKFM
  • DECRQPSR
  • DECRQSS
  • DECRQTSR
  • DECRQUPSS
  • DECRSPS
  • DECSACE
  • DECSCL
  • DECSCLM
  • DECSCP
  • DECSDDT
  • DECSDPT
  • DECSERA
  • DECSFC
  • DECSKCV
  • DECSLCK
  • DECSLE
  • DECSMBV
  • DECSNLS
  • DECSPP
  • DECSPPCS
  • DECSPRTT
  • DECSRC
  • DECSRFR
  • DECSSCLS
  • DECSSDT
  • DECSSL
  • DECST
  • DECSTRL
  • DECSTUI
  • DECSWBV
  • DECSWL
  • DECTID
  • DECTME
  • DECTST
  • DECUDK
  • DECVCCM
  • DECXRLM
  • drcs
  • erminaldispatch
  • Keyclick
  • oltp
  • Overscan
  • Proprinter
  • semver
  • terminalurl
  • udk
  • XCPR
  • XOFF
  • XON
To accept these changes, run the following commands
perl -e '
my @expect_files=qw('".github/actions/spell-check/expect/5757ec679b03a4240130c3c53766c91bbc5cd6a7.txt
.github/actions/spell-check/expect/655f007265b351e140d20b3976792523ad689241.txt
.github/actions/spell-check/expect/alphabet.txt
.github/actions/spell-check/expect/expect.txt
.github/actions/spell-check/expect/web.txt"');
@ARGV=@expect_files;
my @stale=qw('"AAAAA Bopomofo CParams CSV DECRST DECSC GENERATEPROJECTPRIFILE hhhh Inlines renamer rgus SGRXY UDKs Unfocus xe xlang "');
my $re=join "|", @stale;
my $suffix=".".time();
my $previous="";
sub maybe_unlink { unlink($_[0]) if $_[0]; }
while (<>) {
  if ($ARGV ne $old_argv) { maybe_unlink($previous); $previous="$ARGV$suffix"; rename($ARGV, $previous); open(ARGV_OUT, ">$ARGV"); select(ARGV_OUT); $old_argv = $ARGV; }
  next if /^($re)(?:$| .*)/; print;
}; maybe_unlink($previous);'
perl -e '
my $new_expect_file=".github/actions/spell-check/expect/afece109ccdaf234e4b5174e2f89789e3b8c82e7.txt";
open FILE, q{<}, $new_expect_file; chomp(my @words = <FILE>); close FILE;
my @add=qw('"Answerback autogenerate Autorepeat cmdletbinding consolehost CRM csv Cterm DECAAM DECARM DECARSM DECBI DECBKM DECCANSM DECCAPSLK DECCARA DECCKD DECCKSR DECCRA DECCRTSM DECDC DECDHLB DECDHLT DECDLD DECDMAC DECDWL DECEFR DECELR DECERA DECES DECESKM DECFI DECFRA DECHCCM DECHCEM DECHEBM DECHPDXM DECIC DECID DECINVM DECKBD DECKBUM DECKLHIM DECLANS DECLBAN DECLFC DECLFKC DECLKD DECLL DECLRP DECLTOD DECMCM DECNAKB DECNCSM DECNULM DECNUMLK DECOSCNM DECPAK DECPCCM DECPEX DECPFF DECPFK DECPKA DECRARA DECRLCM DECRQCRA DECRQDE DECRQKD DECRQKT DECRQLP DECRQPKFM DECRQPSR DECRQSS DECRQTSR DECRQUPSS DECRSPS decrst DECSACE decsc DECSCL DECSCLM DECSCP DECSDDT DECSDPT DECSERA DECSFC DECSKCV DECSLCK DECSLE DECSMBV DECSNLS DECSPP DECSPPCS DECSPRTT DECSRC DECSRFR DECSSCLS DECSSDT DECSSL DECST DECSTRL DECSTUI DECSWBV DECSWL DECTID DECTME DECTST DECUDK DECVCCM DECXRLM drcs erminaldispatch inlines Keyclick oltp Overscan Proprinter Renamer semver terminalurl udk unfocus XCPR XOFF XON "');
my %items; @items{@words} = @words x (1); @items{@add} = @add x (1);
@words = sort {lc($a) cmp lc($b)} keys %items;
open FILE, q{>}, $new_expect_file; for my $word (@words) { print FILE "$word\n" if $word =~ /\w/; };
close FILE;'
git add .github/actions/spell-check/expect || echo '... you want to ensure .github/actions/spell-check/expect/afece109ccdaf234e4b5174e2f89789e3b8c82e7.txt is added to your repository...'
✏️ Contributor please read this

By default the command suggestion will generate a file named based on your commit. That's generally ok as long as you add the file to your commit. Someone can reorganize it later.

⚠️ The command is written for posix shells. You can copy the contents of each perl command excluding the outer ' marks and dropping any '"/"' quotation mark pairs into a file and then run perl file.pl from the root of the repository to run the code. Alternatively, you can manually insert the items...

If the listed items are:

  • ... misspelled, then please correct them instead of using the command.
  • ... names, please add them to .github/actions/spell-check/dictionary/names.txt.
  • ... APIs, you can add them to a file in .github/actions/spell-check/dictionary/.
  • ... just things you're using, please add them to an appropriate file in .github/actions/spell-check/expect/.
  • ... tokens you only need in one place and shouldn't generally be used, you can add an item in an appropriate file in .github/actions/spell-check/patterns/.

See the README.md in each directory for more information.

🔬 You can test your commits without appending to a PR by creating a new branch with that extra change and pushing it to your fork. The :check-spelling action will run in response to your push -- it doesn't require an open pull request. By using such a branch, you can limit the number of typos your peers see you make. 😉

⚠️ Reviewers

At present, the action that triggered this message will not show its ❌ in this PR unless the branch is within this repository.
Thus, you should make sure that this comment has been addressed before encouraging the merge bot to merge this PR.

Copy link
Member

@zadjii-msft zadjii-msft left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lets ship it and iterate on it in post. We've got the commandline posted in chat, so I'm less worried about that. Let's just get the spellcheck bot happy 😄

@oising
Copy link
Collaborator Author

oising commented Nov 8, 2020

lets ship it and iterate on it in post. We've got the commandline posted in chat, so I'm less worried about that. Let's just get the spellcheck bot happy 😄

The spellcheck thing, is that a you job or a me job?

@zadjii-msft
Copy link
Member

lets ship it and iterate on it in post. We've got the commandline posted in chat, so I'm less worried about that. Let's just get the spellcheck bot happy 😄

The spellcheck thing, is that a you job or a me job?

Typically that's the responsibility of the contributor, but I don't think the CI will block an external PR over it. If this gets the signoffs before the spellcheck fixes, then I'll just take care of it 😃

@zadjii-msft zadjii-msft added Issue-Docs It's a documentation issue that really should be on MicrosoftDocs/Console-Docs Product-Meta The product is the management of the products. labels Nov 10, 2020
Copy link
Member

@DHowett DHowett left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lovely. Lovely lovely lovely. Thank you. This is gonna be the lowest numbered PR merged in a long time--thanks for hanging out with us. 😄

@zadjii-msft since I'm your second signoff, let's do the spellbot and merge!

@zadjii-msft
Copy link
Member

(I'm just gonna fix the spellbot in post, because I end up breaking other people's PR's literally 100% of the time I try pushing to their branches)

@zadjii-msft zadjii-msft merged commit d4b6355 into microsoft:main Nov 13, 2020
@zadjii-msft zadjii-msft mentioned this pull request Nov 13, 2020
1 task
@oising
Copy link
Collaborator Author

oising commented Nov 13, 2020

Nice! It'll be so much easier to submit incremental improvements now....

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-VT Virtual Terminal sequence support Issue-Docs It's a documentation issue that really should be on MicrosoftDocs/Console-Docs Product-Meta The product is the management of the products.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants