'How to render diagrams in gi-gtk?
I want to render a diagram on top of a GUI written with gi-gtk. I tryed to use the defaultRender function from the Diagrams.Backend.Gtk but the compiler is complaining with :
• Couldn't match expected type ‘gtk-0.15.5:Graphics.UI.Gtk.Types.DrawingArea’
with actual type ‘Gtk.DrawingArea’
NB: ‘Gtk.DrawingArea’
is defined in ‘GI.Gtk.Objects.DrawingArea’
in package ‘gi-gtk-3.0.36’
‘gtk-0.15.5:Graphics.UI.Gtk.Types.DrawingArea’
is defined in ‘Graphics.UI.Gtk.Types’ in package ‘gtk-0.15.5’
• In the first argument of ‘defaultRender’, namely ‘canvas’
After verifying the Diagrams.Backend.Gtk, I saw that it is builded with the old Graphics.UI.Gtk.Types from GTk2Hs which seems the cause of this error.
Is there a similar module as Diagrams.Backend.Gtk written with the GI.Gtk package ?
Do you know if in the future the diagrams backend will be build with the GI.Gtk package ?
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
