Commit Graph

15 Commits

Author SHA1 Message Date
Thomas Nind
29c14876c0 Changed CellColorGetterDelegate to use its own class for args CellColorGetterArgs to future proof the API against breaking changes 2021-07-07 12:15:35 +01:00
Thomas Nind
f536d906d4 Made selected cell invert first character optional as a TableStyle 2021-06-29 09:27:28 +01:00
Thomas Nind
fe464b0b94 Added test helper method AssertDriverColorsAre 2021-06-29 08:03:35 +01:00
Charlie Kindel
8d8025329e Added Attributes tests; balanced Application.Init/Shutdown 2021-05-17 18:22:46 -07:00
Thomas Nind
fe9c984d5c Changed Console.WriteLine to ITestOutputHelper in tests (#1305)
* Changed Console.WriteLine to ITestOutputHelper in tests

* Added ITestOutputHelper
2021-05-16 07:21:21 -07:00
Thomas Nind
0dd0f2e5c4 TableView - adds last column dividing line (#1289)
* Adds a final vertical column line at the end of the last header in TableView

* Added clear line as first step in RenderRow

* Added TableStyle.EnforceMaxWidthOnLastColumn

* Added Scenario toggle setting and tests

* Fixed EnforceMaxWidthOnLastColumn when Bounds match exactly the last column width

* Fixed whitespace and comment on ColumntoRender.Width

* Renamed EnforceMaxWidthOnLastColumn to ExpandLastColumn
2021-05-10 20:58:15 -07:00
Thomas Nind
a8628e7c28 Feature/graphs (#1201)
* Empty GraphView with basic axis

* Added ISeries

* Added zoom

* Fixed zoom

* Tests and scrolling

* Refactored AxisView into abstract base

* Added atomic mass example

* Added Y axis labels

* Added Y axis labels

* comments

* Refactored axis to not be floating views

* Split axis drawing code to seperate draw line from draw labels

* Added MarginBottom and MarginLeft

* Added bar graph

* Fixes horizontal axis label generation

* Fixed axis labels changing during scrolling

* Added test for overlapping cells

* Added TestReversing_ScreenToGraphSpace

* Changed graph space from float to decimal

* Added axis labels

* Fixed issues where labels/axis overspilled bounds

* Fixed origin screen coordinates being off by 1 in y axis

* Added Orientation to BarSeries

* Added comments and standardised Name to Text

* Added prototype 'population pyramid'

* Fixed bar graphs not stopping at axis

* Added Reset and Ctrl to speed up scrolling

* Added line graph

* Fixed LineSeries implementation

* Made LineSeries Points readonly and sort on add

* Fixed RectangleD.GetHasCode()

* Improved performance of LineSeries

* Added color to graph

* Fixed colors not working on linux

* Added Visible and ColorGetter

* Added Ctrl+G Next Graph

* Added MultiBarSeries

* Fixed layout issue with population pyramid

* fixed y label overspill and origin rendering

* Fixed warnings

* Made examples prettier

* Fixed xAxis potentially drawing labels outside of control area

* Fixed multi bar example labels

* Added IAnnotation

* Added example of using GraphPosition in IAnnotation

* Fixed Annotations drawing outside of graph bounds

* Fixed Reset() not clearing Annotations and sp fixes

* Changed line drawing to Bresenham's line algorithm and deleted CohenSutherland
Testing for collisions with screen space is very slow and gives quite thick lines.  I looked at Xiaolin Wu which supports anti aliasing but this also would require more work to look good (out of the box it just looks thick).

* Fixed layout/whitespace

* Graph now renders without series if annotations are present

* Fixed ScreenToGraphSpace rect overload

* Added SeriesDrawMode for when it is easier/faster for a series to draw itself all in one go

* Added LegendAnnotation

* Added tests for correct bounds

* Added more tests

* Changed GraphView namespace to Terminal.Gui.Graphs

* Made Line2D and Horizontal/Vertical axis private classes

* Made AxisIncrementToRender.Text internal to avoid confusing user when implementing `LabelGetterDelegate`

* Changed back from decimal to float

* Refactored axis label drawing to avoid rounding errors

* Fixed over spilling bounds when drawing bars/axis increments

* Re-implemented disco colors

* Added Minimum to Axis

* Fixed tests build and render order

* Fixed test by adjusting epsilon

* tidyup, docs and warning fixes

* Standardised parameter order and added axis test

* Fixed x axis line drawing into margins and added tests

* Fixed axis increment rendering in margins, tests and tidyup examples

* Added test for BarSeries

* Added more BarSeriesTests

* Split GraphView.cs into sub files as suggested

* Fixed pointlessly passing around ConsoleDriver and Bounds

* Fixed colored bars not reseting color before drawing labels

* spelling fixes

* Replaced System.Drawing with code copied from dotnet/corefx repo

* Change to trigger CI

* Added tests for MultiBarSeries

* Added test support for Asserting exact graph contents

* Added xml doc where missing from System.Drawing Types

* Standardised unit test namespaces to Terminal.Gui

* Fixed namespace correctly this time after merging main

* Fixed test to avoid using Attribute constructor

* Reduced code duplication in test by moving InitFakeDriver to static in GraphViewTests

* Added TextAnnotationTests and improved GraphViewTests.AssertDriverContentsAre

* Added more TextAnnotation tests and fixed file indentation

* Added tests for Legend and Path
And fixed TruncateOrPad being off by 1 when truncating

* Removed unused paths in TruncateOrPad
2021-04-28 08:38:25 -07:00
Thomas Nind
6a9e27761f Nested types for TabView and TableView (#1243)
* Made TabView classes nested

* Moved TableView classes to nested
2021-04-26 08:58:40 -07:00
Charlie Kindel
b29240f362 Code coverage (#1235)
* tweaked version # for v1.0.0-beta.10

* tweaked version # for v1.0.0-beta.11

* Updated readme and revision history for 1.0

* excluding test results

* Added support for viewing code coverage results with Fine Code Coverage

* add generating CC to CI/CD

* refactored unit test namespaces

* more refactoring. commented out failing test.

* Removed UnitTests and UICatalog from code coverage reporting

* made Application and test more deterministic

* disabled Multi_Thread_Toplevels because it is currently broken and don't understand why

* updated threading test per @bdisp

* testing cc badge stuff

* another test

* using coverlet.settings

* trying copy

* trying cp. duh.

* trying mv.

* wrong path

* print

* chaging badge output for testing

* yaml error

* fixed code coverage

* moved dimtests to core
2021-04-25 10:18:31 -07:00
tznind
d988a34444 Added SelectAll, better selection iteration and validation 2021-01-03 21:57:00 +00:00
tznind
b2e54ec83d Fixed page up/down offset and added test 2021-01-03 10:28:27 +00:00
tznind
0c2685bcbe Added test for box selection 2021-01-02 19:20:00 +00:00
tznind
f610cc8416 better handling of unicode in table view 2020-12-31 10:06:49 +00:00
tznind
65806b1ba2 Added SelectedCellChangedEventArgs and tests 2020-12-29 09:54:50 +00:00
tznind
52af2a609e Fixed namespace, comments and added tests 2020-12-29 06:47:51 +00:00