Commit Graph

22 Commits

Author SHA1 Message Date
Charlie Kindel
bf1ed31281 Refactored UI Catalog and added tons of unit tests 2022-11-03 15:58:15 -06:00
BDisp
09f005448e Fixes #1800. TextView now uses the same colors as TextField. (#1971)
* Fixes #1800. TextView now uses the same colors as TextField.

* Replacing the textview to default in some scenarios.

* Removing TextView ColorScheme from the Wizard component.

* Changing someText color to be different from the help text color.

* Renamed some color methods as requested.

Co-authored-by: Tig Kindel <tig@users.noreply.github.com>
2022-09-15 06:43:18 -07:00
Charlie Kindel
32ae3cb62f Cleaned up Categories and Scenario descripitons. 2022-04-17 15:48:48 -07:00
BDisp
239191cde0 Fixes #1434. Regenerating the docs. (#1528)
* Fixes #1434. Regenerating the docs.

* Fixing warnings on docs regeneration and improving.
2021-12-18 05:33:40 -08:00
BDisp
64b00e3000 Fixes #1499. Allowing border settings for the MessageBox. (#1505) 2021-11-03 22:28:47 -07:00
BDisp
8dabd16975 Fixes #1276. Added TextDirection constructor to View and Label and improving AutoSize. (#1277)
* Added AutoSize. CalcRect calculates vertical. Fixes Draw bug.

* Added TextDirection constructor. Ensuring set frame on Pos/Dim absolute. Improves AutoSize.

* Added a scenario for the AutoSize and TextDirection.

* Added more unit tests.

* Fixing some broken scenarios.

* Fixes others TextDirection that was not working.
2021-05-02 11:21:08 -07:00
BDisp
e784765094 Fixes #1179. TextView does not copy to the clipboard on deleting. (#1180)
* Fixes #1133. Flaw in LayoutSubviews/TopologicalSort.

* Toplevel can't be used on Pos/Dim but only his subviews. Was not caught before because the LayoutSubviews  method never gone so deep before.

* Fixed the error that is triggered when the Pos/Dim is the current Application.Top.

* Application.Top is the only exception in the TopologicalSort method check.

* Fixes #1179. TextView does not copy to the clipboard on deleting.

* Added Button DoubleClick and fixed WordForward/WordBackward issues.

* Prevents a negative height.

* Fixes the enter key line feed.

* Fixes #1187. Prevents WordBackward throwing an exception if point is greater than the text length.

* Fixes #1189. Prevents negative index.

* Fixes #1193. A  non auto size default Button now preserves his width and thus the text alignment now work.

* Fixing the Width and Height checks of the Dim class with AutoSize dependence.

* Fixes #1197. Prevents width negative value if added directly to the Application.Top

* Fixes #1199. Normalize views constructors and did some typo fixing.

* Fixing the Application.Top Pos/Dim settings.

* Always uses inverted color for selected text to avoid same colors.

* Prevents throw an exception if the clipboard content is null.

* Added Find and Replace (next/previous). Replace All and Select All. A non modal dialog box.

* Keeps tracking the selected replaced text.

* Fixes #1202. CheckBox now deals with a functional '_' underscore hotkey.

* The selected text should be maintained when losing focus.

* Fixes an extra line on page down.

* Fixes the WordBackward if it text has more than one whitespaces or when has only one digit or letter.

* Fixes WordForward/WordBackward on text with more than one whitespace or with only one digit or letter.

* Forgot to replace the hacking.

* Added unit tests for the TextField view. Fixed some more bugs.

* Redraw should only show the selected text if it is focused.

* Fixes cursor position on double click and ensures the setting of the selected text.

* Added match whole word checking.

* Added missing parameters documentation.

* Ensures the SelectedLength property to be always with positive value.

* Fixes the WordBackward when at the end of the text has a character between two whitespace.

* Added unit tests to the TextView, Used property and fixed some more bugs.

* Fixed Used to only show if it has focus.

* Fixed ReplaceAll and prevents Debug.Assert from showing.
2021-04-13 13:37:13 -07:00
BDisp
1a9720f471 Fixes #1159. Dialog must have a default button if none is provided. (#1160)
* Fixes #1159. Dialog must have a default button if none is provided.

* Reverting this because someone may don't want buttons at all. Thanks @tig

* Allow to specify which default button for MessageBox.

* Added a check if default button is greater than the buttons length and changing the MessageBox scenario.
2021-04-01 12:38:18 -07:00
BDisp
06a001d5ea horizontalRuler.Text and verticalRuler.Text of the Scrolling scenario only need setted once, avoiding continuous redrawing. 2020-11-17 14:49:42 +00:00
BDisp
fa0827a4af Fixes #1007. Added a Loaded event in the Toplevel class. 2020-11-15 20:57:08 +00:00
BDisp
4bbe50c506 Fixes #990. Pos and Dim only can be properly used when all the views are totally initialized. 2020-11-04 16:45:35 +00:00
BDisp
550392cab6 Fixes #979. Force call LayoutSubviews to perform layout. 2020-10-28 21:52:05 +00:00
Artyom
6aef632633 Button.Clicked as a C# event 2020-09-23 01:01:53 +03:00
Charlie Kindel
a08a411a91 crazy refactoring 2020-06-15 22:52:35 -07:00
Charlie Kindel
f00cdb0258 RadioGroup event fix 2020-06-07 16:00:39 -06:00
Charlie Kindel
dc878b899c enabled better characters 2020-06-07 15:12:25 -06:00
Charlie Kindel
fddfcf8802 Charlie's Mondo Patch (#600)
This PR includes:

#586 - Fixed Clipping
#587 - LayoutComplete
#591 - Sys Console Scenario
#590 - Significantly improves MessageBox, Dialog, Frame drawning and more
See the PRs above for all the details.

Here are the issues this closes:

Closes #299 - MessageBox now auto sizes
Closes #557 - MessageBoxes on small screens
Closes #432 - MessageBox does not deal with long text; width/height params are goofy
Closes #521 - MessageBox should take ustrings (BREAKING CHANGE)
Closes #35 - Dialog should have 1 char padding around edges
Closes #570 - Dialog should use computed layout for buttons
Closes #470 - UI Catalog: Add Dialogs Scenario
Closes #569 - LayoutComplete event
Plus probably more.
2020-06-03 11:33:06 -04:00
Charlie Kindel
1024f073b2 Fixing many clipping issues (#580)
* almost got clip rect working

* fixes many bugs related to clipping incl #399

* Merge tweaks.
2020-05-29 17:41:49 -06:00
Charlie Kindel
bd999a4823 fixed dumb bug (#576)
fixed dumb bug in MessageBoxes scenario
2020-05-28 16:45:19 -06:00
Charlie Kindel
abe7f25f29 Revamped messagebox scenario 2020-05-28 10:46:41 -06:00
Charlie Kindel
09920e0b9b Tons of Scenario fixes 2020-05-23 17:27:52 -06:00
Charlie Kindel
5b845307a2 UI catalog (#387)
* key down/up support

* line endings?

* line endings

* KeyDown/Up support

* line endings

* line endings

* Revert "Drop NuGet restore"

This reverts commit 5c7a0d05f0.

* Revert "Revert "Drop NuGet restore""

This reverts commit 2dc5fce865.

* updated demo

* defined styles

* Smarter StatusBar bottom tracking.

* Prepping for https://github.com/migueldeicaza/gui.cs/issues/376

* Oops.

* Fixed StatusBar 'snap to bottom'

* line endings

* Revert "Fixed StatusBar 'snap to bottom'"

This reverts commit 9a91c957e2.

* started UICatalog project

* Initial working POC.

* Fix newlines

* merge

* textalignment demo tweaks

* textalignment demo tweaks

* Unicode Menu Scenario

* not sure why this keeps changing

* re-added project to .sln file

* re-enabled status bar

* moved scenarios to dir

* building a dim and pos demo

* terminal.sln

* progress...barely

* fixed exit

* progress with some underlying fixes to Label

* added readme

* fixes build issue

* launch

* made default colors readable on Windows

* major UI Catalog upgrade

* added more demos and updated readme

* refactored and added more tests

* added ref to Issue #437

* added OnKeyUp support to Curses and Net drivers

* more tweaks - grab PR #438 first

* Added a OpenSelectedItem event to the ListView #429

* updates

* moved KeyUpHandler out of special ESC stuff

* more tweaks & improvements

* testing top window bug

* supported OpenSelectedItem

* lots of updates

* fixed regression, fixed #444

* better button scenario

* tweaks

* add Ready event to Toplevel

* dotfx .gitignroe

* ready for ready

* updated colors based on feedback; consolodated config code

* tweaked readme

* readme

* Added Editor demonstrating TextView

* Added Editor demonstrating TextView

* added hexeditor scenario

Co-authored-by: Miguel de Icaza <miguel@gnome.org>
Co-authored-by: BDisp <bd.bdisp@gmail.com>
2020-05-20 13:37:12 -04:00