Adds support for users to be able to set font features and axes (see the spec for more details!)
## Detailed Description
**CustomTextLayout**
- Asks the `DxFontRenderData` for the font features when getting glyphs
- _If any features have been set/updated, we always skip the "isTextSimple" shortcut_
- Asks the `_formatInUse` for any font axes when mapping characters in `_AnalyzeFontFallback`
**DxFontRenderData**
- Stores a map of font features (initialized to the [standard feature list])
- Stores a map of font axes
- Has methods to add font features/axes to the map or update existing ones
- Has methods to retrieve the font features/axes
- Sets the font axes in the `IDWriteTextFormat` when creating it
## Validation Steps Performed
It works!
[standard feature list]: ac5aef67d1/DrawableObject.ixx (L802)
Specified in #10457
Related to #1790
Closes #759
Closes #5828
58 lines
1.6 KiB
Plaintext
58 lines
1.6 KiB
Plaintext
// Copyright (c) Microsoft Corporation.
|
|
// Licensed under the MIT license.
|
|
|
|
import "IKeyBindings.idl";
|
|
import "IControlAppearance.idl";
|
|
|
|
namespace Microsoft.Terminal.Control
|
|
{
|
|
enum ScrollbarState
|
|
{
|
|
Visible = 0,
|
|
Hidden
|
|
};
|
|
|
|
enum TextAntialiasingMode
|
|
{
|
|
Grayscale = 0,
|
|
Cleartype,
|
|
Aliased
|
|
};
|
|
|
|
// Class Description:
|
|
// TerminalSettings encapsulates all settings that control the
|
|
// TermControl's behavior. In these settings there is both the entirety
|
|
// of the Core ITerminalSettings interface, and any additional settings
|
|
// for specifically the control.
|
|
interface IControlSettings requires Microsoft.Terminal.Core.ICoreSettings, Microsoft.Terminal.Control.IControlAppearance
|
|
{
|
|
String ProfileName;
|
|
|
|
Boolean UseAcrylic;
|
|
Double TintOpacity;
|
|
ScrollbarState ScrollState;
|
|
|
|
String FontFace;
|
|
Int32 FontSize;
|
|
Windows.UI.Text.FontWeight FontWeight;
|
|
String Padding;
|
|
Windows.Foundation.Collections.IMap<String, UInt32> FontFeatures;
|
|
Windows.Foundation.Collections.IMap<String, Single> FontAxes;
|
|
|
|
Microsoft.Terminal.Control.IKeyBindings KeyBindings;
|
|
|
|
Boolean CopyOnSelect;
|
|
Boolean FocusFollowMouse;
|
|
|
|
String Commandline;
|
|
String StartingDirectory;
|
|
String EnvironmentVariables;
|
|
|
|
TextAntialiasingMode AntialiasingMode;
|
|
|
|
// Experimental Settings
|
|
Boolean ForceFullRepaintRendering;
|
|
Boolean SoftwareRendering;
|
|
};
|
|
}
|