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

Scroll from selection dragging out of window (#1247) #1523

Merged
merged 88 commits into from
Jul 24, 2019
Merged
Show file tree
Hide file tree
Changes from 25 commits
Commits
Show all changes
88 commits
Select commit Hold shift + click to select a range
8078faf
Scroll from selection dragging out of window
mcpiroman Jun 24, 2019
45a48b3
Review changes, dynamic dt measurement, function separation
mcpiroman Jun 26, 2019
b222607
Fix formatting
mcpiroman Jun 26, 2019
d1623aa
doc: fix some punctuation in README.md (#1512)
aayush420 Jun 24, 2019
aa2f5f5
Make the about dialog's contents selectable (#1452)
Jun 24, 2019
4676618
Set the default startup project (#1314)
davkean Jun 24, 2019
4eefdcc
Add a fallback to software rendering (#1263)
ZoeyR Jun 25, 2019
a428484
Connect clipboard functionality to their keybindings (#1093)
d-bingham Jun 25, 2019
1c60e84
Apply a GDI region to the top level Island window to allow dragging w…
ocalvo Jun 25, 2019
1efcf04
Add feature to ColorTool to write color scheme as JSON for Windows Te…
DJackman123 Jun 25, 2019
cee54ed
move version to vs2019, the 1903 sdk, and the 14.2 build tools. (#1012)
miniksa Jun 26, 2019
f5576df
Fix a bug where Terminal may crash or hang at shutdown (#1651)
ocalvo Jun 26, 2019
5a16a8b
Disable the AppContainer bit on our C++/WinRT binaries (#1653)
DHowett Jun 26, 2019
151d228
Update bot doc for In-PR label rule (#1678)
miniksa Jun 27, 2019
10f9ef6
Fixed #521 - AltGr combinations not working (#1436)
lhecker Jun 27, 2019
de5f211
Update bot tag system enforcement
miniksa Jun 28, 2019
abd16b8
App now initializes the connection instead of term control. (#1676)
PankajBhojwani Jun 28, 2019
d05ab94
Spec for #1235 Azure Cloud Shell connector (#1624)
PankajBhojwani Jun 28, 2019
2d89dfc
Move to Microsoft.UI.Xaml 2.2.109211001-prerelease (#1707)
DHowett Jun 29, 2019
21437d2
Revoke old event handlers correctly on pane close (#1279)
peterdn Jun 29, 2019
6dda81b
Change Campbell's default foreground color (#1629)
RyanBee-MSFT Jun 29, 2019
892109b
Replace caption buttons with ones that look close to correct (#1627)
DHowett Jul 1, 2019
cfd93f4
Update the title of the bug report template (#1767)
zadjii-msft Jul 2, 2019
f67b2ac
Review changes 2
mcpiroman Jul 2, 2019
cf3a0b6
Merge branch 'master' into 1247-offscreen-scrolling
mcpiroman Jul 3, 2019
c687948
Make padding applied as swap chain panel's margin (#1778)
Jul 5, 2019
b4ea1dc
added default values to global and profiles (#1784)
cinnamon-msft Jul 5, 2019
046f04e
Fixed #1186, incorrect path was calculted when module already install…
MartinSGill Jul 6, 2019
e933123
The start of some User docs (#1577)
alecthegeek Jul 8, 2019
c486bae
Make opening the settings file more robust (#1841)
maru-sama Jul 9, 2019
1f5c3cc
Added fontSize and acrylicOpacity changing tip (#1889)
gautamnaik1994 Jul 9, 2019
05fe605
Move most of TerminalApp's runtime Xaml to a .xaml file and class (#1…
DHowett Jul 9, 2019
caddcf4
Enable resizing the panes with the keyboard. (#1207)
zadjii-msft Jul 10, 2019
0cde0d9
Added "Vintage" color scheme to defaults; fixes #1781 (#1901)
metathinker Jul 10, 2019
df8cbd1
bugfix: crash on selection on wide glyphs in scrollback buffer (#1879)
carlos-zamora Jul 10, 2019
9a1924d
Fix margin boundary tests in the RI, DL, and IL escape sequences. (#1…
j4james Jul 10, 2019
3bcf16f
Fixed DirectX RTL text issue where it'd be over other text / offscree…
schorrm Jul 10, 2019
8a22038
inbox: reflect incoming changes up to uxp aa5182a2 (#1916)
DHowett Jul 10, 2019
42a5259
Implement background image over acrylic or solid color (#1107)
Jul 10, 2019
8267ed2
Fix interpretation of DECSTBM margin parameters (#1881)
j4james Jul 10, 2019
e72a424
Obstruct the user when they try to run WT under WOW (#1648)
DHowett Jul 11, 2019
88fabd0
Fix wrong maximized window offset on non primary monitors (#1921)
dsafa Jul 11, 2019
2e4df6d
Set utf-8 for the entire project (#1929)
miniksa Jul 11, 2019
15fa91f
Added links to user docs inside About popup (#1887)
cinnamon-msft Jul 11, 2019
1e1663f
Allow the DX rendering engine to run on Windows 7 (#1274)
ZoeyR Jul 11, 2019
a89d9b5
Update the README to clear out references to VS2017 (#1932)
DHowett Jul 11, 2019
9393ed5
Double and Triple Click Selection (#1197)
carlos-zamora Jul 11, 2019
fcf4576
Fix the conhost command line not being properly escaped (#1815)
fcharlie Jul 12, 2019
a3373d3
Don't NCPAINT our window, PAINT our window (#1898)
zadjii-msft Jul 12, 2019
d3a1024
Style the button and tab view background to match the titlebar (#1934)
cinnamon-msft Jul 12, 2019
a8f436a
Force the use of v2 (non-legacy) conhost when in ConPTY mode (#1935)
DHowett Jul 12, 2019
5080f8e
Fix the WAP packaging project (#1900)
DHowett Jul 12, 2019
a2c44aa
Host our own NuGet feed for packages that we need that aren't elsewhe…
miniksa Jul 12, 2019
928d94b
user docs: Fix the capitalization on “Color Schemes” (#1953)
ksyx Jul 13, 2019
a5830de
Refactor TerminalApp and Add Tests for Xaml Content (#1164)
zadjii-msft Jul 15, 2019
4b6e53d
Add a ControlKeyStates wrapper class (#1718)
lhecker Jul 16, 2019
a1fbd6d
Fix for UTF-8 partials in function `ConhostConnection::_OutputThread`…
german-one Jul 16, 2019
c1f990f
Mark ESC as handled so that it doesn't come back in CharacterHandler …
DHowett Jul 16, 2019
e8f6ca2
Add support for moving focus between panes with the keyboard (#1910)
zadjii-msft Jul 17, 2019
302df52
Roll up WindowsTerminal's subprojects into packaging outputs (#2007)
DHowett Jul 17, 2019
099d935
Fix the static UTF8OutPipeReader & tests (#1998)
DHowett Jul 17, 2019
1a00e94
Fix test runner commands (runut.cmd and friends; Invoke-OpenConsoleTe…
metathinker Jul 18, 2019
6de0c4f
Roll up dependencies through TerminalApp so the package is right (#2018)
DHowett Jul 18, 2019
41b0b6c
Enable dragging with the entire titlebar (#1948)
zadjii-msft Jul 18, 2019
3d29b63
Add a keybinding for ClosePane (#2012)
zadjii-msft Jul 19, 2019
20da37b
Changes link to go to latest ColorTool release (#2027)
WSLUser Jul 19, 2019
cc9f332
Fix conhost.exe detect os version (#2059)
fcharlie Jul 23, 2019
e2fec02
Automatically generate an SxS manifest for WindowsTerminal's winmds (…
DHowett Jul 23, 2019
0b4df04
Change some default keybindings (#2014)
zadjii-msft Jul 23, 2019
580a5b7
Review changes, dynamic dt measurement, function separation
mcpiroman Jun 26, 2019
534e726
Fix formatting
mcpiroman Jun 26, 2019
421cec8
Fixed #521 - AltGr combinations not working (#1436)
lhecker Jun 27, 2019
ecc14ee
Merge into master
mcpiroman Jul 23, 2019
2beb4ee
Double and Triple Click Selection (#1197)
carlos-zamora Jul 11, 2019
045e8ce
doc: fix some punctuation in README.md (#1512)
aayush420 Jun 24, 2019
29eb59d
Make the about dialog's contents selectable (#1452)
Jun 24, 2019
bbfc815
Connect clipboard functionality to their keybindings (#1093)
d-bingham Jun 25, 2019
ab2a862
Apply a GDI region to the top level Island window to allow dragging w…
ocalvo Jun 25, 2019
6e2580d
move version to vs2019, the 1903 sdk, and the 14.2 build tools. (#1012)
miniksa Jun 26, 2019
1ec19a2
App now initializes the connection instead of term control. (#1676)
PankajBhojwani Jun 28, 2019
282c5ce
Move to Microsoft.UI.Xaml 2.2.109211001-prerelease (#1707)
DHowett Jun 29, 2019
15234ce
Refactor TerminalApp and Add Tests for Xaml Content (#1164)
zadjii-msft Jul 15, 2019
08943f7
Review changes, dynamic dt measurement, function separation
mcpiroman Jun 26, 2019
7f4c3b0
Recommit everything, merge with master, exchange timer at close
mcpiroman Jul 23, 2019
00446d5
fixxxxxxx 2
mcpiroman Jul 23, 2019
9a79d63
fixXXx 3
mcpiroman Jul 23, 2019
ae2b454
just fix 4
mcpiroman Jul 23, 2019
406fda4
fikz formatting 1
mcpiroman Jul 23, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
166 changes: 158 additions & 8 deletions src/cascadia/TerminalControl/TermControl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,10 @@ namespace winrt::Microsoft::Terminal::TerminalControl::implementation
_settings{ settings },
_closing{ false },
_lastScrollOffset{ std::nullopt },
_autoScrollVelocity{ 0 },
_autoScrollingPointerPoint{ std::nullopt },
_autoScrollTimer{},
_lastAutoScrollUpdateTime{ std::nullopt },
_desiredFont{ DEFAULT_FONT_FACE.c_str(), 0, 10, { 0, DEFAULT_FONT_SIZE }, CP_UTF8 },
_actualFont{ DEFAULT_FONT_FACE.c_str(), 0, 10, { 0, DEFAULT_FONT_SIZE }, CP_UTF8, false },
_touchAnchor{ std::nullopt },
Expand Down Expand Up @@ -521,6 +525,10 @@ namespace winrt::Microsoft::Terminal::TerminalControl::implementation
auto pfnScrollPositionChanged = std::bind(&TermControl::_TerminalScrollPositionChanged, this, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3);
_terminal->SetScrollPositionChangedCallback(pfnScrollPositionChanged);

static constexpr auto autoScrollUpdateInterval = std::chrono::microseconds(static_cast<int>(1.0 / 30.0 * 1000000));
_autoScrollTimer.Interval(autoScrollUpdateInterval);
_autoScrollTimer.Tick({ this, &TermControl::_UpdateAutoScroll });
mcpiroman marked this conversation as resolved.
Show resolved Hide resolved

// Set up blinking cursor
int blinkTime = GetCaretBlinkTime();
if (blinkTime != INFINITE)
Expand Down Expand Up @@ -737,14 +745,33 @@ namespace winrt::Microsoft::Terminal::TerminalControl::implementation

if (ptr.PointerDeviceType() == Windows::Devices::Input::PointerDeviceType::Mouse)
{
if (point.Properties().IsLeftButtonPressed())
if (_terminal->IsSelectionActive() && point.Properties().IsLeftButtonPressed())
{
const auto cursorPosition = point.Position();
const auto terminalPosition = _GetTerminalPosition(cursorPosition);
_SetEndSelectionPointAtCursor(cursorPosition);

// save location (for rendering) + render
_terminal->SetEndSelectionPosition(terminalPosition);
_renderer->TriggerSelection();
const double cursorBelowBottomDist = cursorPosition.Y - _root.Padding().Top - _swapChainPanel.ActualHeight();
const double cursorAboveTopDist = -1 * cursorPosition.Y + _root.Padding().Top;

constexpr double minAutoScrollDist = 2.0; // Arbitrary value
double newAutoScrollVelocity = 0.0;
if (cursorBelowBottomDist > minAutoScrollDist)
{
newAutoScrollVelocity = _GetAutoScrollSpeed(cursorBelowBottomDist);
}
else if (cursorAboveTopDist > minAutoScrollDist)
{
newAutoScrollVelocity = -1.0 * _GetAutoScrollSpeed(cursorAboveTopDist);
}

if (newAutoScrollVelocity != 0)
{
_TryStartAutoScroll(point, newAutoScrollVelocity);
}
else
{
_TryStopAutoScroll(ptr.PointerId());
}
}
}
else if (ptr.PointerDeviceType() == Windows::Devices::Input::PointerDeviceType::Touch && _touchAnchor)
Expand Down Expand Up @@ -800,6 +827,8 @@ namespace winrt::Microsoft::Terminal::TerminalControl::implementation
_touchAnchor = std::nullopt;
}

_TryStopAutoScroll(ptr.PointerId());

args.Handled(true);
}

Expand All @@ -812,7 +841,8 @@ namespace winrt::Microsoft::Terminal::TerminalControl::implementation
void TermControl::_MouseWheelHandler(Windows::Foundation::IInspectable const& /*sender*/,
Input::PointerRoutedEventArgs const& args)
{
auto delta = args.GetCurrentPoint(_root).Properties().MouseWheelDelta();
const auto point = args.GetCurrentPoint(_root);
const auto delta = point.Properties().MouseWheelDelta();
// Get the state of the Ctrl & Shift keys
const auto modifiers = args.KeyModifiers();
const auto ctrlPressed = WI_IsFlagSet(modifiers, VirtualKeyModifiers::Control);
Expand All @@ -828,7 +858,7 @@ namespace winrt::Microsoft::Terminal::TerminalControl::implementation
}
else
{
_MouseScrollHandler(delta);
_MouseScrollHandler(delta, point);
}
}

Expand Down Expand Up @@ -885,7 +915,7 @@ namespace winrt::Microsoft::Terminal::TerminalControl::implementation
// - Scroll the visible viewport in response to a mouse wheel event.
// Arguments:
// - mouseDelta: the mouse wheel delta that triggered this event.
void TermControl::_MouseScrollHandler(const double mouseDelta)
void TermControl::_MouseScrollHandler(const double mouseDelta, Windows::UI::Input::PointerPoint const& pointerPoint)
{
const auto currentOffset = this->GetScrollOffset();

Expand All @@ -907,6 +937,13 @@ namespace winrt::Microsoft::Terminal::TerminalControl::implementation
// The scroll bar's ValueChanged handler will actually move the viewport
// for us.
_scrollBar.Value(static_cast<int>(newValue));

if (_terminal->IsSelectionActive() && pointerPoint.Properties().IsLeftButtonPressed())
{
// If user is mouse selecting and scrolls, they then point at new character.
// Make sure selection reflects that immediately.
_SetEndSelectionPointAtCursor(pointerPoint.Position());
}
}

void TermControl::_ScrollbarChangeHandler(Windows::Foundation::IInspectable const& sender,
Expand Down Expand Up @@ -974,6 +1011,84 @@ namespace winrt::Microsoft::Terminal::TerminalControl::implementation
return false;
}

// Method Description:
// - Starts new pointer related auto scroll behavior, or continues existing one.
// Does nothing when there is already auto scroll associated with another pointer.
// Arguments:
// - pointerPoint: info about pointer that causes auto scroll. Pointer's position
// is later used to update selection.
// - scrollVelocity: target velocity of scrolling in characters / sec
void TermControl::_TryStartAutoScroll(Windows::UI::Input::PointerPoint const& pointerPoint, const double scrollVelocity)
{
// Allow only one pointer at the time
if (!_autoScrollingPointerPoint.has_value() || _autoScrollingPointerPoint.value().PointerId() == pointerPoint.PointerId())
{
_autoScrollingPointerPoint = pointerPoint;
_autoScrollVelocity = scrollVelocity;

// If this is first time the auto scroll update is about to be called,
// kick-start it by initializing its time delta as if it started now
if (!_lastAutoScrollUpdateTime.has_value())
{
_lastAutoScrollUpdateTime = std::chrono::high_resolution_clock::now();
}

// Apparently this check is not necessary but greatly improves performance
if (!_autoScrollTimer.IsEnabled())
{
_autoScrollTimer.Start();
}
}
}

// Method Description:
// - Stops auto scroll if it's active and is associated with supplied pointer id.
// Arguments:
// - pointerId: id of pointer for which to stop auto scroll
void TermControl::_TryStopAutoScroll(const uint32_t pointerId)
{
if (_autoScrollingPointerPoint.has_value() && pointerId == _autoScrollingPointerPoint.value().PointerId())
{
_autoScrollingPointerPoint = std::nullopt;
_autoScrollVelocity = 0;
_lastAutoScrollUpdateTime = std::nullopt;

// Apparently this check is not necessary but greatly improves performance
if (_autoScrollTimer.IsEnabled())
{
_autoScrollTimer.Stop();
}
}
}

// Method Description:
// - Called continuously to gradually scroll viewport when user is
// mouse selecting outside it (to 'follow' the cursor).
// Arguments:
// - none
void TermControl::_UpdateAutoScroll(Windows::Foundation::IInspectable const& /* sender */,
Windows::Foundation::IInspectable const& /* e */)
{
if (_autoScrollVelocity != 0)
{
const auto timeNow = std::chrono::high_resolution_clock::now();

if (_lastAutoScrollUpdateTime.has_value())
{
static constexpr double microSecPerSec = 1000000.0;
const double deltaTime = std::chrono::duration_cast<std::chrono::microseconds>(timeNow - _lastAutoScrollUpdateTime.value()).count() / microSecPerSec;
_scrollBar.Value(_scrollBar.Value() + _autoScrollVelocity * deltaTime);

if (_autoScrollingPointerPoint.has_value())
{
_SetEndSelectionPointAtCursor(_autoScrollingPointerPoint.value().Position());
}
}

_lastAutoScrollUpdateTime = timeNow;
}
}

// Method Description:
// - Event handler for the GotFocus event. This is used to start
// blinking the cursor when the window is focused.
Expand Down Expand Up @@ -1079,6 +1194,25 @@ namespace winrt::Microsoft::Terminal::TerminalControl::implementation
_terminal->SetCursorVisible(!_terminal->IsCursorVisible());
}

// Method Description:
// - Sets selection's end position to match supplied cursor position, e.g. while mouse dragging.
// Arguments:
// - cursorPosition: in pixels, relative to the origin of the control
void TermControl::_SetEndSelectionPointAtCursor(Windows::Foundation::Point const& cursorPosition)
{
auto terminalPosition = _GetTerminalPosition(cursorPosition);

const short lastVisibleRow = std::max(_terminal->GetViewport().Height() - 1, 0);
const short lastVisibleCol = std::max(_terminal->GetViewport().Width() - 1, 0);

terminalPosition.Y = std::clamp(terminalPosition.Y, short{ 0 }, lastVisibleRow);
terminalPosition.X = std::clamp(terminalPosition.X, short{ 0 }, lastVisibleCol);
Copy link
Member

@carlos-zamora carlos-zamora Jun 25, 2019

Choose a reason for hiding this comment

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

Check out Viewport::Clamp(). Is there a way we could use that here? #Resolved

Copy link
Contributor Author

@mcpiroman mcpiroman Jun 26, 2019

Choose a reason for hiding this comment

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

Viewport::Clamp() expects absolute position, whereas src and dst of terminalPosition are relative to scroll offset. #Resolved


// save location (for rendering) + render
_terminal->SetEndSelectionPosition(terminalPosition);
_renderer->TriggerSelection();
}

// Method Description:
// - Process a resize event that was initiated by the user. This can either be due to the user resizing the window (causing the swapchain to resize) or due to the DPI changing (causing us to need to resize the buffer to match)
// Arguments:
Expand Down Expand Up @@ -1219,6 +1353,8 @@ namespace winrt::Microsoft::Terminal::TerminalControl::implementation
// cursorTimer timer, now stopped, is destroyed.
}

_autoScrollTimer.Stop();
Copy link
Member

Choose a reason for hiding this comment

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

Technically this should be cleaned up the same way the other ones are, with swapping null for a local one and stopping the local one, but I think we changed the rest of the method over after this PR was authored. I can file a follow-up issue to polish that line.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Then _autoScrollTimer would have to be nullable, though I don't see the point of doing so.


if (auto localConnection{ std::exchange(_connection, nullptr) })
{
localConnection.Close();
Expand Down Expand Up @@ -1490,6 +1626,20 @@ namespace winrt::Microsoft::Terminal::TerminalControl::implementation
return terminalPosition;
}

// Method Description:
// - Calculates speed of single axis of auto scrolling. It has to allow for both
// fast and precise selection.
// Arguments:
// - cursorDistanceFromBorder: distance from viewport border to cursor, in pixels. Must be non-negative.
// Return Value:
// - positive speed in characters / sec
double TermControl::_GetAutoScrollSpeed(double cursorDistanceFromBorder) const
{
// The numbers below just feel well, feel free to change.
// TODO: Maybe account for space beyond border that user has available
return std::pow(cursorDistanceFromBorder, 2.0) / 25.0 + 2.0;
mcpiroman marked this conversation as resolved.
Show resolved Hide resolved
}

// clang-format off
// -------------------------------- WinRT Events ---------------------------------
// Winrt events need a method for adding a callback to the event and removing the callback.
Expand Down
15 changes: 14 additions & 1 deletion src/cascadia/TerminalControl/TermControl.h
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,12 @@ namespace winrt::Microsoft::Terminal::TerminalControl::implementation

std::optional<int> _lastScrollOffset;

// Auto scroll occurs when user, while selecting, drags cursor outside viewport. View is then scrolled to 'follow' the cursor.
double _autoScrollVelocity;
std::optional<Windows::UI::Input::PointerPoint> _autoScrollingPointerPoint;
Windows::UI::Xaml::DispatcherTimer _autoScrollTimer;
std::optional<std::chrono::high_resolution_clock::time_point> _lastAutoScrollUpdateTime;

// storage location for the leading surrogate of a utf-16 surrogate pair
std::optional<wchar_t> _leadingSurrogate;

Expand Down Expand Up @@ -124,26 +130,33 @@ namespace winrt::Microsoft::Terminal::TerminalControl::implementation
void _LostFocusHandler(Windows::Foundation::IInspectable const& sender, Windows::UI::Xaml::RoutedEventArgs const& e);

void _BlinkCursor(Windows::Foundation::IInspectable const& sender, Windows::Foundation::IInspectable const& e);
void _SetEndSelectionPointAtCursor(Windows::Foundation::Point const& cursorPosition);
void _SendInputToConnection(const std::wstring& wstr);
void _SwapChainSizeChanged(Windows::Foundation::IInspectable const& sender, Windows::UI::Xaml::SizeChangedEventArgs const& e);
void _SwapChainScaleChanged(Windows::UI::Xaml::Controls::SwapChainPanel const& sender, Windows::Foundation::IInspectable const& args);
void _DoResize(const double newWidth, const double newHeight);
void _TerminalTitleChanged(const std::wstring_view& wstr);
void _TerminalScrollPositionChanged(const int viewTop, const int viewHeight, const int bufferSize);

void _MouseScrollHandler(const double delta);
void _MouseScrollHandler(const double delta, Windows::UI::Input::PointerPoint const& pointerPoint);
void _MouseZoomHandler(const double delta);
void _MouseTransparencyHandler(const double delta);

bool _CapturePointer(Windows::Foundation::IInspectable const& sender, Windows::UI::Xaml::Input::PointerRoutedEventArgs const& e);
bool _ReleasePointerCapture(Windows::Foundation::IInspectable const& sender, Windows::UI::Xaml::Input::PointerRoutedEventArgs const& e);

void _TryStartAutoScroll(Windows::UI::Input::PointerPoint const& pointerPoint, const double scrollVelocity);
void _TryStopAutoScroll(const uint32_t pointerId);
void _UpdateAutoScroll(Windows::Foundation::IInspectable const& sender, Windows::Foundation::IInspectable const& e);

void _ScrollbarUpdater(Windows::UI::Xaml::Controls::Primitives::ScrollBar scrollbar, const int viewTop, const int viewHeight, const int bufferSize);
static Windows::UI::Xaml::Thickness _ParseThicknessFromPadding(const hstring padding);

DWORD _GetPressedModifierKeys() const;

const COORD _GetTerminalPosition(winrt::Windows::Foundation::Point cursorPosition);

double _GetAutoScrollSpeed(double cursorDistanceFromBorder) const;
};
}

Expand Down