homer drops his donut, doh, homer spills his soda, doh, homer hits the doorway, doh, homer ruins his whole day, doh!

This commit is contained in:
2026-08-06 13:33:55 +01:00
parent 74f5761e06
commit 37266ab8d4
4 changed files with 94 additions and 42 deletions
+10
View File
@@ -71,6 +71,16 @@ func newImageFromPath(path string) (*gtk.Image, error) {
return gtk.NewImageFromPaintable(tex), nil
}
func setImageFromPath(path string, i *gtk.Image) (error) {
tex, err := getTexture(path)
if err != nil {
return err
}
i.SetFromPaintable(tex)
return nil
}
func newPictureFromWeb(url string) (*gtk.Picture, error) {
pa, _ := ensureCache()
// step 1: get a sha256 sum of the URL