-
Notifications
You must be signed in to change notification settings - Fork 9k
Implement DECSET 2026 - Synchronized Output #18826
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
Conversation
b511704 to
424b1d3
Compare
DHowett
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No notes / 360 noscope
|
After sleeping through it, I think I figured out why I felt like the logic wasn't completely correct. |
DHowett
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm still cool with this but the "jiggle the handle" operation worries me
|
You could think of it as "give the renderer an opportunity at this precise time to render" which makes sense IMO given that 2026l operates a bit like a V-Sync. |
|
Ideally I think this should be tracked as a render mode in This is less crucial, but it should really also be reset in |
|
I was reading the linked issue, and it seemed to me like apps are not expected to do feature detection. It did seem to work at least in btop. I'll happily make the changes though.
Could you explain what you meant with that?
I'm indeed not entirely sure how important this is since the delay set by |
|
yes the codes should work without having to ask if supported, that’s important (as by definition unsupported codes are ignored) |
Apps shouldn't need to do feature detection, but some apps may still choose to skip using the mode if they know it's not supported. Because if you're trying to avoid flickering, and the target terminal doesn't support this mode, then sending a bunch of non-functional mode changes is not going to help matters. I also suspect the fact that the feature detection is documented in the spec is partially responsible for a lot of apps and libraries choosing to make use of that functionality.
I was envisioning something simpler in in the _renderSettings.SetRenderMode(RenderSettings::Mode::SynchronizedOutput, enable);
if (_renderer)
{
_renderer->UpdateSynchronizedOutput();
}And then the _isSynchronizingOutput = _renderSetting.GetRenderMode(RenderSettings::Mode::SynchronizedOutput);
if (!_isSynchronizingOutput)
{
// Do the the wakeup thing...
}This is assuming you still need
Yeah, it's just a technicality really. But if you set the mode, send a hard reset, and then query the mode immediately afterwards, it should report as unset, but that wouldn't be the case if all of that happened within 100ms. Nobody is likely to care, but it's technically wrong. But all that's really required to fix that, assuming you're using a render mode, is to add it to the reset call here (and update the comment): terminal/src/renderer/base/RenderSettings.cpp Lines 49 to 51 in d2bb4ee
If you want to make sure the screen will also be immediately refreshed (which is less important), then we'd also need a call to terminal/src/terminal/adapter/adaptDispatch.cpp Lines 3048 to 3053 in 093f5d1
|
|
Since |
Yeah, if it has to be separate variable then the value needs to be synced back to the mode. It should just require a call to |
`RenderSettings` already stores `DECSCNM` (reversed screen), so it only makes sense to also store DECSET 2026 there. ## Validation Steps Performed * Same as in #18826 ✅
Now that we have passthrough mode (#17510), as well as the render thread
rewrite (#18632), adding support for DECSET 2026 is a piece of cake.
Closes #8331
Validation Steps Performed
btopvia ssh in a huge window