Fixes #4204. v2win and v2net aren't refreshing the Character Map correctly (#4205)

* Fixes #4204. v2win and v2net aren't refreshing the Character Map correctly

* Reformat to run CI again

* Revert "Reformat to run CI again"

This reverts commit 3efad83f52.

* Revert "Fixes #4204. v2win and v2net aren't refreshing the Character Map correctly"

This reverts commit 6ec4adcc45.

* Apply @tig suggested changes

* Fixes #4208. MainLoopSyncContext doesn't work with the v2 drivers

* Trying fix unit test error

* Revert "Trying fix unit test error"

This reverts commit 3aaefd6053.

---------

Co-authored-by: Tig <tig@users.noreply.github.com>
This commit is contained in:
BDisp
2025-07-25 12:54:14 +01:00
committed by GitHub
parent 2025a81511
commit 807f1fdcc8

View File

@@ -245,12 +245,13 @@ public partial class View : IDisposable, ISupportInitializeNotification
}
}
if (ApplicationImpl.Instance.IsLegacy)
{
// TODO: Figure out how to move this out of here and just depend on LayoutNeeded in Mainloop
Layout (); // the EventLog in AllViewsTester fails to layout correctly if this is not here (convoluted Dim.Fill(Func)).
}
// Force a layout each time a View is initialized
// See: https://github.com/gui-cs/Terminal.Gui/issues/3951
// See: https://github.com/gui-cs/Terminal.Gui/issues/4204
Layout (); // the EventLog in AllViewsTester fails to layout correctly if this is not here (convoluted Dim.Fill(Func)).
// Complex layout scenarios (e.g. DimAuto and PosAlign) may require multiple layouts to be performed.
// Thus, we call SetNeedsLayout() to ensure that the layout is performed at least once.
SetNeedsLayout ();
Initialized?.Invoke (this, EventArgs.Empty);