Skip to content

Update to latest v2 develop branch#307

Merged
tznind merged 55 commits into
v2from
updatev2
Mar 21, 2025
Merged

Update to latest v2 develop branch#307
tznind merged 55 commits into
v2from
updatev2

Conversation

@tznind

@tznind tznind commented Feb 16, 2025

Copy link
Copy Markdown
Collaborator

Outstanding issues

Cannot create abstract
System.IndexOutOfRangeException: 'Index was outside the bounds of the array.'


 	Terminal.Gui.dll!Terminal.Gui.MenuBar.NextMenu(bool isSubMenu, bool ignoreUseSubMenusSingleFrame)	Unknown
 	Terminal.Gui.dll!Terminal.Gui.Menu.BeginInit.AnonymousMethod__5_0()	Unknown
 	Terminal.Gui.dll!Terminal.Gui.View.InvokeCommands<Terminal.Gui.KeyBinding>(Terminal.Gui.Command[] commands, Terminal.Gui.KeyBinding binding)	Unknown
 	Terminal.Gui.dll!Terminal.Gui.View.InvokeCommands(Terminal.Gui.Key key)	Unknown
 	Terminal.Gui.dll!Terminal.Gui.View.NewKeyDownEvent(Terminal.Gui.Key key)	Unknown
 	Terminal.Gui.dll!Terminal.Gui.View.NewKeyDownEvent(Terminal.Gui.Key key)	Unknown
 	Terminal.Gui.dll!Terminal.Gui.Application.RaiseKeyDownEvent(Terminal.Gui.Key key)	Unknown
 	Terminal.Gui.dll!Terminal.Gui.Application.Driver_KeyDown(object sender, Terminal.Gui.Key e)	Unknown
 	Terminal.Gui.dll!Terminal.Gui.WindowsInputProcessor.Process(Terminal.Gui.WindowsConsole.InputRecord inputEvent)	Unknown
 	Terminal.Gui.dll!Terminal.Gui.InputProcessor<Terminal.Gui.WindowsConsole.InputRecord>.ProcessQueue()	Unknown
 	Terminal.Gui.dll!Terminal.Gui.MainLoop<Terminal.Gui.WindowsConsole.InputRecord>.IterationImpl()	Unknown
 	Terminal.Gui.dll!Terminal.Gui.MainLoop<Terminal.Gui.WindowsConsole.InputRecord>.Iteration()	Unknown
 	Terminal.Gui.dll!Terminal.Gui.ApplicationV2.Run(Terminal.Gui.Toplevel view, System.Func<System.Exception, bool> errorHandler)	Unknown
 	Terminal.Gui.dll!Terminal.Gui.Application.Run(Terminal.Gui.Toplevel view, System.Func<System.Exception, bool> errorHandler)	Unknown
>	TerminalGuiDesigner.dll!TerminalGuiDesigner.UI.Editor.Run(TerminalGuiDesigner.Options options) Line 221	C#
 	TerminalGuiDesigner.dll!TerminalGuiDesigner.Program.Main.AnonymousMethod__0_0(TerminalGuiDesigner.Options o) Line 25	C#
 	CommandLine.dll!CommandLine.ParserResultExtensions.WithParsed<TerminalGuiDesigner.Options>(CommandLine.ParserResult<TerminalGuiDesigner.Options> result, System.Action<TerminalGuiDesigner.Options> action)	Unknown
 	TerminalGuiDesigner.dll!TerminalGuiDesigner.Program.Main(string[] args) Line 18	C#
  • Click events need to be Esc or they trigger defaults

  • Color editor is probably dubious

  • Add view does not focus search box properly

  • Adding views shows full class name (has always been this bad?!)

  • There is a broken behaviour when editing sliders with shadow adornment. After adding option in array editor things seem to soft break and not save

  • Adornment test is breaking in CI (fixed, unit test had out of date package)

    /// <summary>
    /// Gets the <see cref="Color"/> to use for <see cref="ColorScheme.Disabled"/> <see cref="Attribute.Foreground"/>.
    /// </summary>
    [JsonConverter(typeof(JsonStringEnumConverter<Color> ))]
    [YamlMember( typeof(Color), ScalarStyle = ScalarStyle.Plain, DefaultValuesHandling = DefaultValuesHandling.Preserve)]
    public Color DisabledForeground { get; init; } = DisabledForeground;
  • Need to be able to serialize Color.Red as "red" and deserialize again sensibly for both json and yaml now that there are no ColorNames
  • View.FindDeepestView(w, m.Position); is gone
    • Ok seems to be replaced by View.GetViewsUnderMouse (mouseEvent.ScreenPosition)
  • Drag select does not render
  • Cannot drag resize buttons because of Margin/Shadow

@tznind tznind marked this pull request as draft February 16, 2025 17:52
@tznind tznind mentioned this pull request Feb 16, 2025
2 tasks
@tznind

tznind commented Feb 16, 2025

Copy link
Copy Markdown
Collaborator Author

Copied from closed PR

tznind added 12 commits February 18, 2025 23:37
- Remove TGD shadow drawing code now that it is part of main codebase
- Regenerate ChoicesDialog (load/save)
- Change to Dim.Auto for button Widths
- Fix bug in RecursivelyIgnoreAllNonDesignableSubviews when used during loading processes that incorrectly flagged sub views as 'non designable'
Previously when prompted if you want to save changes on exit any clicked button results in Yes
…ture proof ReflectionHelper to renaming private fields to have prefix underscore
@tznind

tznind commented Mar 4, 2025

Copy link
Copy Markdown
Collaborator Author

I have added logging and target v2 driver.

Mark ComboBox as not a supported control
ComboBox has always been buggy, lets just get rid of it till it works.
@tznind

tznind commented Mar 15, 2025

Copy link
Copy Markdown
Collaborator Author

ComboBox does not work and honestly never has. It should hopefully get fixed in the tui-cs/Terminal.Gui#3852

In the mean time I have marked it as not supported view in TGD and switched pos relative (the only place we use combo box in TGD) to use radio group and text box with autocomplete instead:

image

@tznind tznind marked this pull request as ready for review March 17, 2025 18:12
@tznind

tznind commented Mar 17, 2025

Copy link
Copy Markdown
Collaborator Author

@BDisp ok think this is good to go, I've kicked the tyres a lot and think I have found all the bugs and they've been fixed upstream. Give it a go and see if you can find any other bugs and if not lets ship it!

Hmn actually there is still

Yeah that is a dealbreaker. As soon as you add a TabView to the Window it breaks keyboard navigation in context menu very badly.

@tznind tznind requested a review from BDisp March 17, 2025 18:13
@tznind tznind changed the title WIP - Update to latest v2 develop branch Update to latest v2 develop branch Mar 17, 2025
@BDisp

BDisp commented Mar 18, 2025

Copy link
Copy Markdown
Contributor

I did my best in the PR tui-cs/Terminal.Gui#3995. I hope fixed that. Then it's all good to go on.

@tznind

tznind commented Mar 21, 2025

Copy link
Copy Markdown
Collaborator Author

I'm still seeing Views getting key presses while context menu is open... I will have to experiment in core Terminal.Gui and see if its something about the designer or just general issue with context menu.

It only kicks in after adding a TabView, does tab view somehow use grab mouse or what makes it break the normal focus systems that make context menu behave? Any ideas @BDisp ?

Hmn actually I might be using stale dependency

@BDisp

BDisp commented Mar 21, 2025

Copy link
Copy Markdown
Contributor

Now I don't think so. Do you have same repo code that I can investigate?

@tznind

tznind commented Mar 21, 2025

Copy link
Copy Markdown
Collaborator Author

Its working, I had updated showcase and version numbers in csproj but not the package version on the csproj 🤦

@tznind tznind merged commit 06c63c3 into v2 Mar 21, 2025
@tznind tznind deleted the updatev2 branch March 21, 2025 20:29
@tznind

tznind commented Mar 21, 2025

Copy link
Copy Markdown
Collaborator Author

Its live! Or at least should be soon.

Pushing TerminalGuiDesigner.2.0.0-develop.4400.nupkg to 'https://www.nuget.org/api/v2/package'...
  PUT https://www.nuget.org/api/v2/package/
  Created https://www.nuget.org/api/v2/package/ 1520ms
Your package was pushed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants