-
-
Notifications
You must be signed in to change notification settings - Fork 335
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
Gtk Sharp within Windows #442
Comments
How did you install GTK#? After installing using the package from here (and rebooting), I can run the GTK2 app just fine on Windows 10. |
I did the same thing, downloaded from the same link but for whatever reason it didn't find the dll's |
Yeah I've seen those unofficial Gtk#3 nuget packages, but haven't tried them yet. GTK3 is definitely the way to go if that works for you. As for this error, did you get the error when initially running the app, or with one of the tests? |
I think it was when initially running the example app, and setting it to use gtk in code. It might just be a paths related issue I'm not sure |
It looks like some people have found re-installing GTK# got things working for them. BTW, I finally tried GTK#3 on windows and it seems to work semi-okay. I'm not sure why, but it appeared as if anti-aliasing was turned off completely.. or perhaps it didn't know what to do with high DPI. Either way, it seems to work at least (; |
I have a fix for that, it's cairo's default settings which are the problem If using gtksharp directly Public Shared Sub ApplyTheme()
' Based on this Link http://awesome.naquadah.org/wiki/Better_Font_Rendering
' Get the Global Settings
Dim setts = Gtk.Settings.Default
' This enables clear text on Win32, makes the text look a lot less crappy
setts.XftRgba = "rgb"
' This enlarges the size of the controls based on the dpi
setts.XftDpi = 96
' By Default Anti-aliasing is enabled, if you want to disable it for any reason set this value to 0
'setts.XftAntialias = 0
' Enable text hinting
setts.XftHinting = 1
'setts.XftHintstyle = "hintslight"
setts.XftHintstyle = "hintfull"
' Load the Theme
Dim css_provider As New Gtk.CssProvider
'css_provider.LoadFromPath("themes/DeLorean-3.14/gtk-3.0/gtk.css")
css_provider.LoadFromPath("themes/DeLorean-Dark-3.14/gtk-3.0/gtk.css")
Gtk.StyleContext.AddProviderForScreen(Gdk.Screen.Default, css_provider, 800)
End Sub |
Closing this as it seems to be an installation or environment issue with GTK#2, and it looks like using GTK#3 might be the best way forward instead. Feel free to reopen if you feel it still needs to be addressed within Eto.Forms directly, though I don't feel this is something that Eto.Forms should be doing. Thanks for submitting the issue and providing a sample, it is very appreciated! |
Hi, I've recently been trying out Eto.Forms using different backends under Windows 10 (since I'm looking for a cross platform toolkit).
One things I have noticed when running the Eto.Test.Gtk2
under windows 10 / Visual Studio 2015 / with the latest Gtk Sharp
was the following exception
"Unable to load DLL 'libgtk-win32-2.0-0.dll': The specified procedure could not be found"
This led me to this link https://forums.xamarin.com/discussion/15568/unable-to-load-dll-libgtk-win32-2-0-0-dll
It turns out the fix is to include a function which fixes up most of the issues with the finding of gtk dll's when running under windows
The following seems to fix the problem, although I'm not sure if this is something that needs to be rolled into Eto.Forms or not in some way
The text was updated successfully, but these errors were encountered: