Skip to content

Commit

Permalink
[minor typo] Update newinv2.md (gui-cs#3765)
Browse files Browse the repository at this point in the history
Fix minor typo
  • Loading branch information
ris-work authored Oct 2, 2024
1 parent 10bdd4b commit 894b1e2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docfx/docs/newinv2.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ Apps built with Terminal.Gui now feel modern thanks to these improvements:
The entire library has been reviewed and simplified. As a result, the API is more consistent and uses modern .NET API standards (e.g. for events). This refactoring resulted in the removal of thousands of lines of code, better unit tests, and higher performance than v1.

## [View](~/api/Terminal.Gui.View.yml) Improvements
* *Improved!* View Lifetime Management is Now Deterministic - In v1 the rules ofr lifetime management of `View` objects was unclear and led to non-dterministic behavior and hard to diagnose bugs. This was particularly acute in the behavior of `Application.Run`. In v2, the rules are clear and the code and unit test infrastructure tries to enforce them. See [Migrating From v1 To v2](migratingfromv1.md) for more details.
* *Improved!* View Lifetime Management is Now Deterministic - In v1 the rules for lifetime management of `View` objects was unclear and led to non-dterministic behavior and hard to diagnose bugs. This was particularly acute in the behavior of `Application.Run`. In v2, the rules are clear and the code and unit test infrastructure tries to enforce them. See [Migrating From v1 To v2](migratingfromv1.md) for more details.
* *New!* Adornments - Adornments are a special form of View that appear outside the `Viewport`: @Terminal.Gui.View.Margin, @Terminal.Gui.View.Border, and @Terminal.Gui.View.Padding.
* *New!* Built-in Scrolling/Virtual Content Area - In v1, to have a view a user could scroll required either a bespoke scrolling implementation, inheriting from `ScrollView`, or managing the complexity of `ScrollBarView` directly. In v2, the base-View class supports scrolling inherently. The area of a view visible to the user at a given moment was previously a rectangle called `Bounds`. `Bounds.Location` was always `Point.Empty`. In v2 the visible area is a rectangle called `Viewport` which is a protal into the Views content, which can be bigger (or smaller) than the area visible to the user. Causing a view to scroll is as simple as changing `View.Viewport.Location`. The View's content described by `View.GetContentSize()`. See [Layout](layout.md) for details.
* *New!* @Terminal.Gui.DimAuto - Automatically sizes the view to fit the view's Text, SubViews, or ContentArea.
Expand Down Expand Up @@ -61,4 +61,4 @@ The API for mouse input is now internally consistent and easiser to use.
* The `MouseEvent` class replaces `MouseEventEventArgs`.
* More granular APIs are provided to ease handling specific mouse actions. See [Mouse API](mouse.md).
* Views can use the `View.Highlight` event to have the view be visibly highlighted on various mouse events.
* Views can set `View.WantContinousButtonPresses = true` to ahve their `Command.Accept` command be invoked repeatedly as the user holds a mouse button down on the view.
* Views can set `View.WantContinousButtonPresses = true` to ahve their `Command.Accept` command be invoked repeatedly as the user holds a mouse button down on the view.

0 comments on commit 894b1e2

Please sign in to comment.