[PB 4.60beta4] CreateImageMenu doesnt show images

Linux specific forum
Ramihyn_
Enthusiast
Enthusiast
Posts: 314
Joined: Fri Feb 24, 2006 9:40 am

[PB 4.60beta4] CreateImageMenu doesnt show images

Post by Ramihyn_ »

OS: multiple 32-bit linux versions, executed in VirtualBox

The following code sample (taken from the Help entry with added "UsePNGImageDecoder()")

Code: Select all

UsePNGImageDecoder()

  If LoadImage(0, OpenFileRequester("Choose an icon file", "", "", 0))
    If OpenWindow(0, 200, 200, 200, 100, "Image menu Example")
      If CreateImageMenu(0, WindowID(0))    ; menu creation starts....
        MenuTitle("Project")
          MenuItem(1, "Open"   +Chr(9)+"Ctrl+O", ImageID(0))
          MenuItem(2, "Save"   +Chr(9)+"Ctrl+S")
          MenuItem(3, "Save as"+Chr(9)+"Ctrl+A")
          MenuItem(4, "Close"  +Chr(9)+"Ctrl+C")
      EndIf
      
      Repeat : Until WaitWindowEvent() = #PB_Event_CloseWindow
    EndIf
  EndIf
The result for different 32-bit linux versions:

Image

ps: for beginners it might help to add a hint about the missing image decoders to the help. Or just add all image decoders. Especially for beginners, it is not good if manual examples "dont work" out of the box.
Fred
Administrator
Administrator
Posts: 18350
Joined: Fri May 17, 2002 4:39 pm
Location: France
Contact:

Re: [PB 4.60beta4] CreateImageMenu doesnt show images

Post by Fred »

The problem with image menu is it's a global OS options, you can set it in the preferences of your OS. Don't ask me why such options exists...
Ramihyn_
Enthusiast
Enthusiast
Posts: 314
Joined: Fri Feb 24, 2006 9:40 am

Re: [PB 4.60beta4] CreateImageMenu doesnt show images

Post by Ramihyn_ »

You are right (it is a change in the default gnome interface settings) and therefore this bug report is invalid.

It is a bit confusing as they still appear in some menu's - for example Firefox history and the gnome applications menu.

I will add this to my "installing purebasic on linux" thread later to reduce confusion :)
Post Reply