noliar / devzh.ui Goto Github PK
View Code? Open in Web Editor NEWA simple binding (Experimental!!!) using .NET Core for https://github.com/andlabs/libui, which is an awesome native UI library for Unix, OSX and Windows
A simple binding (Experimental!!!) using .NET Core for https://github.com/andlabs/libui, which is an awesome native UI library for Unix, OSX and Windows
Hy,
if in running application too fast change the tab view then application not response.
Test case:
Env: Mac OS 10.10
You have 2 nuget package at the moment.
DevZH.UI -> this repository.
And DevZH.LibUI.
The DevZH.LibUI is what this repo of yours is using.
I cannot look inside your "DevZH.LibUI" package, but I suspect that's where you can update to the latest libui.
The gui works well, but after you try exit it crashes: Fault Module Name: StackHash_58aa
Consider putting this simple code to a button click event:
for (int i = 0; i < 10000; i++)
{
var a = new int[100];
}
Maybe the numbers vary, depending on your machine.
SafeHandles are the preferred method of controlling access to unmanaged resources in .NET.
'Mono-Test.exe' (CLR v4.0.30319: DefaultDomain): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_32\mscorlib\v4.0_4.0.0.0__b77a5c561934e089\mscorlib.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'Mono-Test.exe' (CLR v4.0.30319: DefaultDomain): Loaded 'C:\Users\shadowblitz16\Documents\Visual Studio 2017\Projects\Mono-Test\Mono-Test\bin\Debug\Mono-Test.exe'. Symbols loaded.
'Mono-Test.exe' (CLR v4.0.30319: Mono-Test.exe): Loaded 'C:\Users\shadowblitz16\Documents\Visual Studio 2017\Projects\Mono-Test\Mono-Test\bin\Debug\DevZH.UI.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'Mono-Test.exe' (CLR v4.0.30319: Mono-Test.exe): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Runtime\v4.0_4.0.0.0__b03f5f7f11d50a3a\System.Runtime.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'Mono-Test.exe' (CLR v4.0.30319: Mono-Test.exe): Loaded 'C:\Users\shadowblitz16\Documents\Visual Studio 2017\Projects\Mono-Test\Mono-Test\bin\Debug\System.Text.Encoding.CodePages.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'Mono-Test.exe' (CLR v4.0.30319: Mono-Test.exe): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Text.Encoding\v4.0_4.0.0.0__b03f5f7f11d50a3a\System.Text.Encoding.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'Mono-Test.exe' (CLR v4.0.30319: Mono-Test.exe): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Threading\v4.0_4.0.0.0__b03f5f7f11d50a3a\System.Threading.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'Mono-Test.exe' (CLR v4.0.30319: Mono-Test.exe): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Core\v4.0_4.0.0.0__b77a5c561934e089\System.Core.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'Mono-Test.exe' (CLR v4.0.30319: Mono-Test.exe): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System\v4.0_4.0.0.0__b77a5c561934e089\System.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'Mono-Test.exe' (CLR v4.0.30319: Mono-Test.exe): Loaded 'C:\Users\shadowblitz16\Documents\Visual Studio 2017\Projects\Mono-Test\Mono-Test\bin\Debug\System.Console.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'Mono-Test.exe' (CLR v4.0.30319: Mono-Test.exe): Loaded 'C:\Users\shadowblitz16\Documents\Visual Studio 2017\Projects\Mono-Test\Mono-Test\bin\Debug\Microsoft.Win32.Primitives.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'Mono-Test.exe' (CLR v4.0.30319: Mono-Test.exe): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Runtime.InteropServices.RuntimeInformation\v4.0_4.0.0.0__b03f5f7f11d50a3a\System.Runtime.InteropServices.RuntimeInformation.dll'. Module was built without symbols.
Exception thrown: 'System.DllNotFoundException' in DevZH.UI.dll
An unhandled exception of type 'System.DllNotFoundException' occurred in DevZH.UI.dll
Unable to load DLL 'libui': The specified module could not be found. (Exception from HRESULT: 0x8007007E)
'Mono-Test.exe' (CLR v4.0.30319: Mono-Test.exe): Loaded 'C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\common7\ide\PrivateAssemblies\Runtime\Microsoft.VisualStudio.Debugger.Runtime.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
The program '[1380] Mono-Test.exe' has exited with code -1 (0xffffffff).```
Hi, I'm working on an F# wrapper for this lib: https://github.com/czifro-tech/FSharpUI . I'm have made quite a bit of progress as can be seen in the readme. I'm trying to provide a simple API where multiple types can use a single function to be altered some way. For instance, using reflection and generics, I refactored all code related to adding an event handler to a single function call:
// create a button and add a click event
create<Button>("Say Hello")
|> addOnEvent<EventArgs>(fun (sender,e) -> printfn "Hello!")
// create app and add on exit event
create<Application>()
|> addOnEvent<CancelEventArgs>(fun (sender,e) -> printfn "Goodbye!")
I have been able to do this for pretty much every class that I have wrapped that has some sort of event handler. The only two event handlers I cannot support this way and instead have specific functions for is Control::Resize
and Control::LocationChanged
. It would be nice if one of these used a subtype to EventArgs
, like perhaps the following changes could happen:
public event EventHandler Resize;
// changes to...
public event EventHandler<ResizeEventArgs> Resize;
And perhaps add class:
public class ResizeEventArgs : EventArgs { }
The class would not need to do anything, instead it would just be for using reflection. It would really help provide a clean F# API. I don't see this hurting/breaking anything given that typically lambdas are used to add event handlers. I would be willing to submit a PR with the changes if it is something you would be willing to allow.
When I try to compile the solution the error list is as follow:
Severity Code Description Project File Line Suppression State
Error CS0535 'AreaHandler' does not implement interface member 'IAreaHandler.MouseCrossed(AreaBase, bool)' Histogram C:\DFNetResearch-Projects-Core\Source\DevZH.UI-master\samples\Histogram\AreaHandler.cs 11 Active
Error CS0535 'Page15.AreaHandler' does not implement interface member 'IAreaHandler.MouseCrossed(AreaBase, bool)' Tester C:\DFNetResearch-Projects-Core\Source\DevZH.UI-master\samples\Tester\Page15.cs 128 Active
Error CS0535 'Page6.AreaHandler' does not implement interface member 'IAreaHandler.MouseCrossed(AreaBase, bool)' Tester C:\DFNetResearch-Projects-Core\Source\DevZH.UI-master\samples\Tester\Page6.cs 13 Active
Warning CS0168 The variable 'ex' is declared but never used DevZH.UI C:\DFNetResearch-Projects-Core\Source\DevZH.UI-master\src\DevZH.UI\Application.cs 114 Active
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.