-
Notifications
You must be signed in to change notification settings - Fork 549
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add a WPF renderer for Xamarin.Forms #486
Comments
Not trying to push you or rush you, but any eta on this, or semi-working preview nuget packages? |
This is going to be a bit harder to do since I will have to update to Xamarin.Forms v3.0. This is mostly fine, but the packaging is going to be tougher. If I update to v3.0, then so does everyone else who uses SkiaSharp with Xamarin.Forms. I might create a new set of preview packages that target v3.0, and then when we get further on in life, I will update the existing package. But this makes life harder for everyone. Also, I just added Tizen support, which appears to only support v2.5.0. But, after all this, I can start a new branch and just upgrade to v3.0 for the world and hope something happens which will make life easier - maybe Tizen updates, maybe everyone does :) |
You updating to XF3 is per project right? For the world to update to xamarin forms 3, well, isn't that how things just work? if people want to stay on entity framework core, you have to be careful as well... |
I mean, do you have things working for XF3? If so, what's the way to get things usable with XF3? |
In the meantime, maybe could you make ISKCanvasViewController public? That way I can implement it myself.. |
I see there's some WPF work included in the dev/forms-v3 branch, do you happen to know the status of this with WPF? I'm currently trying to investigate the feasibility of adding a WPF client so happy to work with an unfinished build for now if it can get me started with the basics. |
@DuncWatts To me it seems, that if the ISKCanvasViewController interface was public, the actual work needed for xamarin forms support is minimal (matter of 2-3 event handlers that need hooking up) @mattleibow Maybe you can shed a light here? |
I created a PR that makes those types public so additional platforms can be added: #522 This should be in the v1.60.1 release. |
The I had a chat to the Tizen guys, and I didn't realize that Forms 3.0 has the Tizen types built in, so that makes life much easier. |
Awesome! Regarding v3 etc. It seems that the v2 packages work fine there, just not for WPF (obviously)... I could hack it together with reflection, but that's not worth it for me, so I'll wait for the v1.60.1 release then. |
The backwards compat info is good news. |
I merged #522 so adding additional renderers should be much easier - until I manage to add them to the official repo. If you do get a nice version, a PR is always welcome ;) |
No WPF renderer just yet, but you should be able to quickly whip up your own now that the interfaces are all public: https://github.com/mono/SkiaSharp/releases/tag/v1.60.1 I created a test renderer for GTK#, and all I had to do was copy this code into my project and add a Then I added this for GTK#: |
@mterwoord, I hope this helps. |
Works! Only thing I have to figure out for WPF is DPI translation. For me, images get shown now. |
Nice, with some of these things, I just have a look at how Xamarin.Forms does it. For example, I am going to look at how they do touch and do something similar. |
Hello, |
I'm trying to port an Xamarin.Forms Android app to WPF, and I'm using SkiaSharp there. Has anyone managed to get the renderer to work? I had some issues compiling the code in the examples above. |
This is something that we will be looking at in the future. |
I've hit a roadblock because the Mapsui.Forms uses SkiaSharp and seems to be using the SKGLViewRenderer for map rendering. Is there a solution in the works for WPF? I can't use UWP as need to support legacy systems. Going to look at their codebase too to see if I can switch the rendering to something else for WPF. I also can happily hack together something with the SkiaSharp.Views.Desktop.SKGLControl is that would work, just not 100% sure that road is the correct one. Happy to help, but obviously, no expert in this side of things (just using someone else's library...) |
Nothing shown on WPF with |
Good news folks! Adding WPF as we speak (or as close as we can get) #917 |
Just merged the bits. As soon as the build finishes, I'll push the the preview feed: https://nugetized.blob.core.windows.net/skiasharp-eap/index.json |
The text was updated successfully, but these errors were encountered: