ImageGadget and ButtonImageGadget not working on Linux?
Posted: Mon Jan 12, 2026 11:14 am
Hi
I am on Ubuntu 22.04 and Purebasic 6.20
When I run a form designed with the form designer. And it has a image or a button image. The program stops unexpected. I can't add it afterwards or even in a manually designed window. So it's probably me doing it the wrong way.
the code of de form:
code to run the form
Many thanks in advance
Rudi
I am on Ubuntu 22.04 and Purebasic 6.20
When I run a form designed with the form designer. And it has a image or a button image. The program stops unexpected. I can't add it afterwards or even in a manually designed window. So it's probably me doing it the wrong way.
the code of de form:
Code: Select all
;
; This code is automatically generated by the Form Designer.
; Manual modification is possible to adjust existing commands, but anything else will be dropped when the code is compiled.
; Event procedures need to be put in another source file.
;
Enumeration FormWindow
#frmIssues
EndEnumeration
Enumeration FormGadget
#Text_0
#ButtonImage_1
EndEnumeration
Enumeration FormImage
#Img_frmIssues_0
EndEnumeration
LoadImage(#Img_frmIssues_0,"/home/rudi/Apps/projecten/Issues/Preference.ico")
Procedure OpenfrmIssues(x = 0, y = 0, width = 600, height = 400)
OpenWindow(#frmIssues, x, y, width, height, "", #PB_Window_SystemMenu)
ButtonImageGadget(#ButtonImage_1, 215, 115, 100, 25, ImageID(#Img_frmIssues_0))
EndProcedure
Code: Select all
;Design view frmIssues
IncludeFile "frmIssues.pbf"
Procedure frmIssues_close_window_handler()
End
EndProcedure
OpenfrmIssues();
;LoadImage(123,"/home/rudi/Apps/projecten/EyeOpener/Preference.ico")
;ButtonImageGadget(#ButtonImage_1, 215, 115, 100, 25, ImageID(123))
BindEvent(#PB_Event_CloseWindow, @frmIssues_close_window_handler(),#frmIssues)
Repeat : WaitWindowEvent() : ForEverRudi