GabrielStranak
Topic Author
Posts: 20
Joined: 06 Apr 2017, 15:50

Noesis GUI in business application

07 Apr 2017, 08:37

We are developing business application for mobile devices. This includes iOS, Android and UWP.
Our application needs to have configurable UI, because we are working with changeable data model.
Because of this we choose Xamarin with Xamarin Forms. But we found out that Xamarin Forms are very limited and we can’t create the UI as we want. The other approach would be to use the native UI for each platform, but I don’t want to go this route, because it would basically mean to create and maintain 3 applications (code sharing below 50%).

So, I was really excited when I have found Noesis GUI.
There are some questions I would like to ask:
  • Can I use the Managed SDK in our Xamarin project to create the whole UI for our application?
  • Are there some samples or documentation on how can I integrate Noesis GUI into Xamarin project?
  • Can I download UI definition file from our server and load it at runtime? This should be possible with compiling the XAML files to NSB files. Is this correct?
    This feature could be used to configure our UI.
  • Can I show Web content, Map or other 3rd party elements inside the Noesis GUI?
  • I assume that it is possible to create custom controls. Because for example you don’t have DateTime picker, which is essential for our application.
  • Is the UI rendering done inside a loop like in games, or is it event driven?
    I ask this because of battery life.
 
User avatar
sfernandez
Site Admin
Posts: 2974
Joined: 22 Dec 2011, 19:20

Re: Noesis GUI in business application

07 Apr 2017, 17:04

Can I use the Managed SDK in our Xamarin project to create the whole UI for our application?
Yes, the only requirement is to set up a render context (DirectX, OpenGL, ...) and a render surface where we can draw the UI elements.
Are there some samples or documentation on how can I integrate Noesis GUI into Xamarin project?
Not yet, but we plan to add them in future versions. Maybe it would be a good idea to create a public repository to share the integration with Xamarin as it occurs with other frameworks.
Can I download UI definition file from our server and load it at runtime? This should be possible with compiling the XAML files to NSB files. Is this correct?
This feature could be used to configure our UI.
In NoesisGUI 2.0 xaml files are not preprocessed by any tool, so you can directly load xaml files if they can be accessed by the XamlProvider (it can be overriden with your own provider).
Can I show Web content, Map or other 3rd party elements inside the Noesis GUI?
It can be done by rendering that content to a texture, then using that texture as an ImageSource for an Image or an ImageBrush.
I assume that it is possible to create custom controls. Because for example you don’t have DateTime picker, which is essential for our application.
Custom controls support is a bit limited in C# API as we don't provide yet the virtual methods (OnMouseDown and similar). But some things can be workaround, for example by registering a handler to the desired event (MouseDown += OnMyControlMouseDown) in your control constructor. Another option is using UserControls to create more complex controls.
Is the UI rendering done inside a loop like in games, or is it event driven?
I ask this because of battery life.
When NoesisGUI renders the UI is decided by the application. If you want to be event driven you will have to render to a texture. Then use the bool returned by Renderer.UpdateRenderTree() to determine if you need to update the texture or not.
 
GabrielStranak
Topic Author
Posts: 20
Joined: 06 Apr 2017, 15:50

Re: Noesis GUI in business application

07 Apr 2017, 18:14

Thank you for your answers.
Roughly when do you think you will have samples or documentation for Xamarin integration? Because I don’t have any experience in this area, and I don’t know if I could figure it all out by myself.
 
Ziriax
Posts: 60
Joined: 10 Dec 2015, 17:59
Location: Belgium
Contact:

Re: Noesis GUI in business application

09 Apr 2017, 13:18

IMHO (highly opinionated) the business IT sector is where NoesisGUI could fill a major gap. With Microsoft having acquired Xamarin and open sourcing of .NET, this platform is gaining popularity. Many companies picked Silverlight in 200X, and when that platform was nearly perfect, it got abandoned and blacklisted because browser vendors hyped HTML5 as the future for client side development, blocking plugins. Strangly enough one of those vendors with a fruit logo made their HTML5 platform full of bugs and limitations, forcing developers to also make native apps for the vendor's store...

So many .NET developers were forced to learn JavaScript and HTML5, or learn the fruit plaform.

And that sure pays the bill, JavaScript "fullstack" mediors make a lot of money in these crazy overhyped days, but many coders don't just do it for the money... IMO many so called fullstack developers don't know the difference between a stack or a heap ;-)

Of course NoesisGUI would need to be tweaked for battery life, not rendering every frame, etc... It should also be adapted so it works well with Redux style programming, that especially with F# or the new C# pattern matching feature sound appealing.
Peter Verswyvelen,
Strongly Typed Solutions
 
GabrielStranak
Topic Author
Posts: 20
Joined: 06 Apr 2017, 15:50

Re: Noesis GUI in business application

11 Apr 2017, 09:52

I’m starting to experiment with the Managed SDK, but I cannot reference the NoesisManaged.dll library in my UWP project. The problem is that it targets the full .NETFramework, while the UWP targets only .NETCore. I could reference the library if it would target .NETPortable or .NETStandard.
The .NETPortable is not possible because of use of HandleRef.
Could the Noesis team create .NETStandard version of the NoesisManaged.dll library, or rewrite the code so it could use .NETPortable?
 
User avatar
sfernandez
Site Admin
Posts: 2974
Joined: 22 Dec 2011, 19:20

Re: Noesis GUI in business application

11 Apr 2017, 17:17

You have all the sources required to build NoesisManaged.dll yourself (look under Src/NoesisManaged folder in Managed SDK).
Just create a new project that matches your framework requirements and build it.

I tried to create a new UWP class library and after fixing a couple of minor issues (described below), I was able to create a new NoesisManaged.dll for UWP:
- Define a placeholder for "System.ApplicationException" inside Core/NetCoreAdapter.cs
- Add "using System.Reflection;" to Proxies/DependencyObjectExtend.cs

Let me know if worked for you.
 
GabrielStranak
Topic Author
Posts: 20
Joined: 06 Apr 2017, 15:50

Re: Noesis GUI in business application

11 Apr 2017, 22:11

Hello sfernandez. I have successfully created and build the Universal Windows Class Library.
To verify the functionality I have tried to call Noesis.GUI.Init(); but I got the System.DllNotFoundException
Unable to load DLL 'Noesis': The specified module could not be found. (Exception from HRESULT: 0x8007007E)
I have placed the Noesis UWP libraries into the project and added post build event:
xcopy /Y "$(ProjectDir)ExternalReferences\NoesisGUI\uwp_$(Platform)\*.*" "$(TargetDir)"
I have verified that the correct library is copied to the build directory.

Do you know what could be the cause of this error?
 
User avatar
sfernandez
Site Admin
Posts: 2974
Joined: 22 Dec 2011, 19:20

Re: Noesis GUI in business application

12 Apr 2017, 11:36

Are you getting the DllNotFoundException running the application in desktop or it happens on an emulator/device?

I tried with a basic UWP app in my PC and it loaded Noesis.dll fine.
 
GabrielStranak
Topic Author
Posts: 20
Joined: 06 Apr 2017, 15:50

Re: Noesis GUI in business application

12 Apr 2017, 11:49

I'm trying it in the desktop.
The problem is with deploying. The deploy does not copy the dll into the AppX folder. When I copy the dll there, It does work as expected.
I have posted question on Stack Overflow, but I have no solution yet.
http://stackoverflow.com/questions/4336 ... on-package

How did you configure your project to copy the dll into the AppX folder when deploying?
 
User avatar
sfernandez
Site Admin
Posts: 2974
Joined: 22 Dec 2011, 19:20

Re: Noesis GUI in business application

12 Apr 2017, 12:05

I included Noesis.dll in the project and set its properties to:
Build Action = "Content"
Copy to Output Directory = "Copy always"

Who is online

Users browsing this forum: Bing [Bot] and 3 guests