I have some python2 code that I'im migrating to python3 as python2 will reach EOL soon. And in so doing I'm also migrating from gtk2 to gtk3 via GIR. However, I am unable to find any proper documentation on how to do so.
I have the following snippets in my code that I'd like to change:
pixbuf = gtk.gdk.Pixbuf(gtk.gdk.COLORSPACE_RGB,False,8,width,height)
pixbuf.get_from_drawable(
gtk.gdk.get_default_root_window(),
gtk.gdk.colormap_get_system(),
0,0,0,0,
width,height)
pixbuf.save(...)
gtk.gdk.screen_width()
gtk.gdk.screen_width()
I came across https://lazka.github.io/pgi-docs/ and https://developer.gnome.org/pygtk/stable/class-gdkpixbuf.html, but I'm kinda new to python and GTK and am not able to figure out the equivalent transformations
Any references to documentation would help too.