mirror of
https://github.com/microsoft/terminal.git
synced 2025-12-10 00:48:23 -06:00
Make a VTApiRoutines servicer that does minimal translations instead of environmental simulation for some output methods. Remaining methods are backed on the existing console host infrastructure (primarily input related methods). ## PR Checklist * [x] I work here * [x] It's Fix-Hack-Learn quality so it's behind a feature gate so we can keep refining it. But it's a start! To turn this on, you will have to be in the Dev or Preview rings (feature staged). Then add `experimental.connection.passthroughMode: true` to a profile and on the next launch, the flags will propagate down through the `ConptyConnection` into the underlying `Openconsole.exe` startup and tell it to use the passthrough mode instead of the full simulation mode. ## Validation Steps Performed - Played with it manually in CMD.exe, it seems to work mostly. - Played with it manually in Ubuntu WSL, it seems to work. - Played with it manually in Powershell and it's mostly sad. It'll get there. Starts #1173
54 lines
1.7 KiB
C++
54 lines
1.7 KiB
C++
/*++
|
|
Copyright (c) Microsoft Corporation
|
|
Licensed under the MIT license.
|
|
|
|
Module Name:
|
|
- Xterm256Engine.hpp
|
|
|
|
Abstract:
|
|
- This is the definition of the VT specific implementation of the renderer.
|
|
This is the xterm-256color implementation, which supports advanced sequences such as
|
|
inserting and deleting lines, and true rgb color.
|
|
|
|
Author(s):
|
|
- Mike Griese (migrie) 01-Sept-2017
|
|
--*/
|
|
|
|
#pragma once
|
|
|
|
#include "XtermEngine.hpp"
|
|
|
|
class VtApiRoutines;
|
|
|
|
namespace Microsoft::Console::Render
|
|
{
|
|
class Xterm256Engine : public XtermEngine
|
|
{
|
|
public:
|
|
Xterm256Engine(_In_ wil::unique_hfile hPipe,
|
|
const Microsoft::Console::Types::Viewport initialViewport);
|
|
|
|
virtual ~Xterm256Engine() override = default;
|
|
|
|
[[nodiscard]] HRESULT UpdateDrawingBrushes(const TextAttribute& textAttributes,
|
|
const RenderSettings& renderSettings,
|
|
const gsl::not_null<IRenderData*> pData,
|
|
const bool usingSoftFont,
|
|
const bool isSettingDefaultBrushes) noexcept override;
|
|
|
|
[[nodiscard]] HRESULT ManuallyClearScrollback() noexcept override;
|
|
|
|
friend class ::VtApiRoutines;
|
|
|
|
private:
|
|
[[nodiscard]] HRESULT _UpdateExtendedAttrs(const TextAttribute& textAttributes) noexcept;
|
|
[[nodiscard]] HRESULT _UpdateHyperlinkAttr(const TextAttribute& textAttributes,
|
|
const gsl::not_null<IRenderData*> pData) noexcept;
|
|
|
|
#ifdef UNIT_TESTING
|
|
friend class VtRendererTest;
|
|
friend class ConptyOutputTests;
|
|
#endif
|
|
};
|
|
}
|