-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #8 from haruki-taka8/working-branch-23.06
23.06
- Loading branch information
Showing
88 changed files
with
3,163 additions
and
2,327 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,31 @@ | ||
## 📌 rowsSharp | ||
C#/WPF-based CSV filtering and editing tool. Rewritten from [Rows](https://github.com/haruki-taka8/rows). | ||
C#/WPF-based CSV filtering and editing tool. Rewritten and enhanced from [Rows](https://github.com/haruki-taka8/rows). | ||
<br><br> | ||
|
||
## ✔️ Features | ||
|
||
**Filtering** | ||
* Display user-friendly aliases instead of raw data | ||
* Display a preview image based on the selected row | ||
* Conditional formatting support | ||
* Regular expressions support | ||
* Display an image based on the selected row | ||
* Conditional formatting | ||
* Regular expressions | ||
<br> | ||
|
||
**Editing** | ||
* Add/remove rows | ||
* Add/edit/remove rows and columns | ||
* Add rows with a template | ||
* Change existing rows | ||
* Unlimited undo & redo | ||
* Shortcut keys | ||
<br> | ||
|
||
## 🌎 Using | ||
* [CsvHelper](https://joshclose.github.io/CsvHelper/) | ||
* [Microsoft.Xaml.Behaviors.Wpf](https://github.com/microsoft/XamlBehaviorsWpf) | ||
* [NLog](https://nlog-project.org/) | ||
## 🌎 Dependencies | ||
* [CsvHelper](https://joshclose.github.io/CsvHelper/) ([License](https://github.com/JoshClose/CsvHelper/blob/master/LICENSE.txt)) | ||
* [Material Symbols](https://github.com/marella/material-symbols/) ([License](https://github.com/marella/material-symbols/blob/main/LICENSE)) | ||
* Font was converted to `.otf` for WPF compatibility | ||
* Font content is rotated and/or flipped inside the UI | ||
* [Microsoft.Xaml.Behaviors.Wpf](https://github.com/microsoft/XamlBehaviorsWpf) ([License](https://github.com/microsoft/XamlBehaviorsWpf/blob/master/LICENSE)) | ||
* [NLog](https://nlog-project.org/) ([License](https://github.com/NLog/NLog/blob/dev/LICENSE.txt)) | ||
<br> | ||
|
||
## 🧪 Building | ||
Official binaries are built with Visual Studio 2022 and .NET 6, using the _release_ configuration. | ||
Official binaries are built with Visual Studio 2022 and .NET 6 using the _release_ configuration. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
using System; | ||
|
||
namespace rowsSharp.Domain; | ||
|
||
internal static class BaseDir | ||
{ | ||
private const string Metavariable = "$baseDir"; | ||
private static readonly string BasePath = Environment.CurrentDirectory + "/Userdata/"; | ||
|
||
internal static string Expand(string path) | ||
{ | ||
return path.Replace(Metavariable, BasePath); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
using System.Collections.Generic; | ||
using System.Collections.ObjectModel; | ||
using System.Linq; | ||
using System.Windows.Controls; | ||
|
||
namespace rowsSharp.Domain; | ||
|
||
internal static class Cell | ||
{ | ||
private static IEnumerable<DataGridCellInfo> WhereValid(this IList<DataGridCellInfo> cells) | ||
{ | ||
return cells.Where(x => x.IsValid); | ||
} | ||
|
||
// Rows | ||
internal static IEnumerable<ObservableCollection<string?>> Rows(this IList<DataGridCellInfo> cells) | ||
{ | ||
return cells.WhereValid() | ||
.Select(x => (ObservableCollection<string?>)x.Item) | ||
.Distinct(); | ||
} | ||
|
||
internal static IEnumerable<int> RowIndices(this IList<DataGridCellInfo> cells, IList<ObservableCollection<string?>> records) | ||
{ | ||
return cells.Rows() | ||
.Select(x => records.IndexOf(x)); | ||
} | ||
|
||
// Columns | ||
internal static IEnumerable<string> Columns(this IList<DataGridCellInfo> cells) | ||
{ | ||
return cells.WhereValid() | ||
.Select(x => (string)x.Column.Header) | ||
.Distinct(); | ||
} | ||
|
||
internal static IEnumerable<int> ColumnIndices(this IList<DataGridCellInfo> cells, IList<string> headers) | ||
{ | ||
return cells.Columns() | ||
.Select(x => headers.IndexOf(x)); | ||
} | ||
|
||
// Cell | ||
internal static int RowIndex(this DataGridCellInfo cell, IList<ObservableCollection<string?>> records) | ||
{ | ||
return records.IndexOf((ObservableCollection<string?>)cell.Item); | ||
} | ||
|
||
internal static int ColumnIndex(this DataGridCellInfo cell, IList<string> headers) | ||
{ | ||
return headers.IndexOf((string)cell.Column.Header); | ||
} | ||
} |
Oops, something went wrong.