-
-
Notifications
You must be signed in to change notification settings - Fork 154
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Untyped dictionary serializer and experimental viewer based on it
- Loading branch information
Showing
79 changed files
with
1,654 additions
and
122 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
<PropertyGroup> | ||
<OutputType>WinExe</OutputType> | ||
<TargetFramework>net8.0</TargetFramework> | ||
<Nullable>enable</Nullable> | ||
<BuiltInComInteropSupport>true</BuiltInComInteropSupport> | ||
<ApplicationManifest>app.manifest</ApplicationManifest> | ||
<AssemblyName>floor</AssemblyName> | ||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<PackageReference Include="Avalonia.Desktop" Version="11.0.6" /> | ||
</ItemGroup> | ||
|
||
<ItemGroup> | ||
<ProjectReference Include="..\Parquet.Floor\Parquet.Floor.csproj" /> | ||
</ItemGroup> | ||
</Project> |
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,9 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | ||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'"> | ||
<DebuggerFlavor>ProjectDebugger</DebuggerFlavor> | ||
</PropertyGroup> | ||
<PropertyGroup> | ||
<ActiveDebugProfile>customer</ActiveDebugProfile> | ||
</PropertyGroup> | ||
</Project> |
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,23 @@ | ||
using System; | ||
using Avalonia; | ||
|
||
namespace Parquet.Floor.Desktop; | ||
|
||
class Program { | ||
// Initialization code. Don't use any Avalonia, third-party APIs or any | ||
// SynchronizationContext-reliant code before AppMain is called: things aren't initialized | ||
// yet and stuff might break. | ||
[STAThread] | ||
public static void Main(string[] args) => BuildAvaloniaApp() | ||
.StartWithClassicDesktopLifetime(args); | ||
|
||
// Avalonia configuration, don't remove; also used by visual designer. | ||
public static AppBuilder BuildAvaloniaApp() { | ||
|
||
return AppBuilder.Configure<App>() | ||
.UsePlatformDetect() | ||
.WithInterFont() | ||
.LogToTrace(); | ||
} | ||
|
||
} |
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,16 @@ | ||
{ | ||
"profiles": { | ||
"WSL": { | ||
"commandName": "WSL2", | ||
"distributionName": "" | ||
}, | ||
"all_var": { | ||
"commandName": "Project", | ||
"commandLineArgs": "C:\\dev\\parquet-dotnet\\src\\Parquet.Test\\data\\all_var1.parquet" | ||
}, | ||
"customer": { | ||
"commandName": "Project", | ||
"commandLineArgs": "C:\\dev\\parquet-dotnet\\src\\Parquet.Test\\data\\customer.impala.parquet" | ||
} | ||
} | ||
} |
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,18 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<assembly manifestVersion="1.0" xmlns="urn:schemas-microsoft-com:asm.v1"> | ||
<!-- This manifest is used on Windows only. | ||
Don't remove it as it might cause problems with window transparency and embeded controls. | ||
For more details visit https://learn.microsoft.com/en-us/windows/win32/sbscs/application-manifests --> | ||
<assemblyIdentity version="1.0.0.0" name="AvaloniaTest.Desktop"/> | ||
|
||
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1"> | ||
<application> | ||
<!-- A list of the Windows versions that this application has been tested on | ||
and is designed to work with. Uncomment the appropriate elements | ||
and Windows will automatically select the most compatible environment. --> | ||
|
||
<!-- Windows 10 --> | ||
<supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}" /> | ||
</application> | ||
</compatibility> | ||
</assembly> |
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 @@ | ||
<Application xmlns="https://github.com/avaloniaui" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | ||
x:Class="Parquet.Floor.App" | ||
RequestedThemeVariant="Default"> | ||
<!-- "Default" ThemeVariant follows system theme variant. "Dark" or "Light" are other available options. --> | ||
|
||
<Application.Styles> | ||
<FluentTheme DensityStyle="Compact" /> | ||
<StyleInclude Source="/Styles.axaml"/> | ||
<StyleInclude Source="avares://Avalonia.Controls.DataGrid/Themes/Fluent.xaml"/> | ||
<StyleInclude | ||
Source="avares://Avalonia.Controls.TreeDataGrid/Themes/Fluent.axaml"/> | ||
</Application.Styles> | ||
</Application> |
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,33 @@ | ||
using Avalonia; | ||
using Avalonia.Controls.ApplicationLifetimes; | ||
using Avalonia.Data.Core.Plugins; | ||
using Avalonia.Markup.Xaml; | ||
|
||
using Parquet.Floor.ViewModels; | ||
using Parquet.Floor.Views; | ||
|
||
namespace Parquet.Floor; | ||
|
||
public partial class App : Application { | ||
public override void Initialize() { | ||
AvaloniaXamlLoader.Load(this); | ||
} | ||
|
||
public override void OnFrameworkInitializationCompleted() { | ||
// Line below is needed to remove Avalonia data validation. | ||
// Without this line you will get duplicate validations from both Avalonia and CT | ||
BindingPlugins.DataValidators.RemoveAt(0); | ||
|
||
if(ApplicationLifetime is IClassicDesktopStyleApplicationLifetime desktop) { | ||
desktop.MainWindow = new MainWindow { | ||
DataContext = new MainViewModel() | ||
}; | ||
} else if(ApplicationLifetime is ISingleViewApplicationLifetime singleViewPlatform) { | ||
singleViewPlatform.MainView = new MainView { | ||
DataContext = new MainViewModel() | ||
}; | ||
} | ||
|
||
base.OnFrameworkInitializationCompleted(); | ||
} | ||
} |
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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,49 @@ | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
<PropertyGroup> | ||
<TargetFramework>net8.0</TargetFramework> | ||
<Nullable>enable</Nullable> | ||
<LangVersion>latest</LangVersion> | ||
<AvaloniaUseCompiledBindingsByDefault>true</AvaloniaUseCompiledBindingsByDefault> | ||
</PropertyGroup> | ||
|
||
|
||
<ItemGroup> | ||
<AvaloniaResource Include="Assets\**" /> | ||
</ItemGroup> | ||
|
||
|
||
<ItemGroup> | ||
<None Remove="Assets\icon.ico" /> | ||
<None Remove="Assets\icons\bat_dead.png" /> | ||
<None Remove="Assets\icons\map.png" /> | ||
<None Remove="Assets\icons\trophy.png" /> | ||
</ItemGroup> | ||
|
||
|
||
<ItemGroup> | ||
<Compile Include="..\NetBox.cs" Link="NetBox.cs" /> | ||
</ItemGroup> | ||
|
||
<ItemGroup> | ||
<PackageReference Include="Avalonia" Version="11.0.6" /> | ||
<PackageReference Include="Avalonia.Controls.DataGrid" Version="11.0.6" /> | ||
<PackageReference Include="Avalonia.Controls.TreeDataGrid" Version="11.0.2" /> | ||
<PackageReference Include="Avalonia.Themes.Fluent" Version="11.0.6" /> | ||
<PackageReference Include="Avalonia.Fonts.Inter" Version="11.0.6" /> | ||
<PackageReference Include="CommunityToolkit.Mvvm" Version="8.2.2" /> | ||
|
||
<!--Condition below is needed to remove Avalonia.Diagnostics package from build output in Release configuration.--> | ||
<PackageReference Condition="'$(Configuration)' == 'Debug'" Include="Avalonia.Diagnostics" Version="11.0.6" /> | ||
|
||
</ItemGroup> | ||
|
||
<ItemGroup> | ||
<ProjectReference Include="..\Parquet\Parquet.csproj" /> | ||
</ItemGroup> | ||
|
||
<ItemGroup> | ||
<Compile Update="Views\DataView.axaml.cs"> | ||
<DependentUpon>DataView.axaml</DependentUpon> | ||
</Compile> | ||
</ItemGroup> | ||
</Project> |
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,139 @@ | ||
<Styles xmlns="https://github.com/avaloniaui" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | ||
xmlns:system="clr-namespace:System"> | ||
<Design.PreviewWith> | ||
|
||
<StackPanel> | ||
|
||
<StackPanel Classes="toolbar"> | ||
<Button> | ||
<Image Source="/Assets/icons/open.png"/> | ||
</Button> | ||
<Button> | ||
<Image Source="/Assets/icons/map.png"/> | ||
</Button> | ||
</StackPanel> | ||
|
||
|
||
<TextBlock Classes="data-cell"> | ||
hello! | ||
</TextBlock> | ||
|
||
<TextBlock Classes="data-cell data-cell-null"> | ||
null | ||
</TextBlock> | ||
|
||
<TextBlock Classes="data-cell data-cell-key"> | ||
key | ||
</TextBlock> | ||
|
||
|
||
<Expander Header="fatty"> | ||
|
||
</Expander> | ||
|
||
<Grid Classes="error"> | ||
<StackPanel> | ||
<Image Source="/Assets/icons/bat_dead.png"/> | ||
<TextBlock Text="design time error message" /> | ||
</StackPanel> | ||
</Grid> | ||
|
||
<TextBlock Classes="hyperlink" Text="more..."/> | ||
|
||
<StackPanel Orientation="Horizontal" Classes="status-bar"> | ||
<TextBlock Text="12121" Classes="data"/> | ||
<TextBlock Text="|" Classes="sep"/> | ||
<TextBlock Text="7" Classes="data"/> | ||
</StackPanel> | ||
|
||
</StackPanel> | ||
|
||
</Design.PreviewWith> | ||
|
||
<!-- status bar --> | ||
|
||
<Style Selector="StackPanel.status-bar"> | ||
<Setter Property="Margin" Value="3"/> | ||
</Style> | ||
|
||
<Style Selector="StackPanel.status-bar TextBlock.data"> | ||
<Setter Property="FontWeight" Value="Bold"/> | ||
<Setter Property="FontSize" Value="15"/> | ||
</Style> | ||
|
||
<Style Selector="StackPanel.status-bar TextBlock.sep"> | ||
<Setter Property="FontSize" Value="10"/> | ||
<Setter Property="Opacity" Value="0.8"/> | ||
<Setter Property="Padding" Value="9,4,9,0"/> | ||
</Style> | ||
|
||
|
||
<!-- general --> | ||
|
||
<Style Selector="FlyoutPresenter.wider"> | ||
<Setter Property="MaxWidth" Value="850"/> | ||
</Style> | ||
|
||
<Style Selector="TextBlock.hyperlink"> | ||
<Setter Property="Foreground" Value="Blue"/> | ||
<Setter Property="Cursor" Value="Hand"/> | ||
<Setter Property="FontStyle" Value="Italic"/> | ||
</Style> | ||
|
||
<!-- Toolbar --> | ||
|
||
<Style Selector="StackPanel.toolbar"> | ||
<Setter Property="Orientation" Value="Horizontal"/> | ||
<Setter Property="Margin" Value="0,0,0,0"/> | ||
</Style> | ||
|
||
<Style Selector="StackPanel.toolbar Button"> | ||
<Setter Property="Padding" Value="6"/> | ||
<Setter Property="Margin" Value="0,0,5,0"/> | ||
<Setter Property="Background" Value="Transparent"/> | ||
</Style> | ||
|
||
<Style Selector="StackPanel.toolbar Button Image"> | ||
<Setter Property="Width" Value="26"/> | ||
</Style> | ||
|
||
<!-- DataGrid --> | ||
|
||
<Style Selector="TextBlock.data-cell"> | ||
<Setter Property="FontSize" Value="12"/> | ||
<Setter Property="VerticalAlignment" Value="Center"/> | ||
<Setter Property="Padding" Value="2"/> | ||
</Style> | ||
|
||
<Style Selector="TextBlock.data-cell-null"> | ||
<Setter Property="Foreground" Value="Gray"/> | ||
</Style> | ||
|
||
<Style Selector="TextBlock.data-cell-key"> | ||
<Setter Property="Foreground" Value="Green"/> | ||
<Setter Property="FontWeight" Value="Bold"/> | ||
</Style> | ||
|
||
<!-- error message --> | ||
|
||
<Style Selector="Grid.error"> | ||
<Setter Property="Background" Value="Black"/> | ||
</Style> | ||
|
||
<Style Selector="Grid.error Image"> | ||
<Setter Property="Width" Value="40"/> | ||
</Style> | ||
|
||
<Style Selector="Grid.error TextBlock.error"> | ||
<Setter Property="Foreground" Value="Red"/> | ||
<Setter Property="FontWeight" Value="Bold"/> | ||
</Style> | ||
|
||
<!-- Thinner expander --> | ||
|
||
<!-- todo --> | ||
|
||
|
||
|
||
</Styles> |
Oops, something went wrong.