Page 1 of 1

String+String in Beta 2

Posted: Mon Jan 01, 2007 12:04 pm
by Pinhead
Hi,
a small Error:

Code: Select all

  If OpenWindow(0 , x, y, 500, 162, "Test",  #PB_Window_TitleBar )

      If CreateGadgetList(WindowID(0))
        StringGadget(0, 130, 50, 340, 27, "")               
        ButtonGadget(1, 260, 110, 80, 30, "xyz")                 
      EndIf
  EndIf
  
  Repeat 
 
  Event = WaitWindowEvent() 
  GadgetID = EventGadget() 
    
  If Event = #PB_Event_CloseWindow
    End
  EndIf
  
    If Event = #PB_Event_Gadget
      If GadgetID = 1
         text$=GetGadgetText(0)+GetGadgetText(1) ; not working
           
          ;this is working:
          ; text$=GetGadgetText(0)
          ;text$=text$+GetGadgetText(0)
          ;text$=text$+GetGadgetText(1)
           
         SetGadgetText(0,text$)
       
      EndIf
   EndIf 
   
 ForEver
It works under XP but not under Linux...
Why? Bug or feature?

Posted: Mon Jan 01, 2007 8:41 pm
by bembulak
:?:

Works perfectly here.

Mandriva 2006, official.
Kernel 2.6.16
XFCE 4.1
PB 4.0 beta 2

Posted: Tue Jan 02, 2007 8:45 am
by Pinhead
Works perfectly here.
:?: :?: :?:

When I press the button the StringGadget is still empty!

Slackware 11
Kernel 2.6.18
Fluxbox
PB 4.0 beta 2

Posted: Wed Jan 03, 2007 11:08 am
by Pinhead
Same problem with Suse 10.2

Posted: Wed Jan 03, 2007 11:47 am
by FloHimself
here it works fine!

openSUSE 10.2
Kernel 2.6.18.2-34-default
Gnome 2.16.1
PureBasic 4.0b2

Posted: Wed Jan 03, 2007 12:27 pm
by Pinhead
with the default suse installation?
I tested it again under Gnome, same Problem...
When I use

Code: Select all

text$=GetGadgetText(0)+GetGadgetText(1)
the StringGadget ist still empty after pressing the button...

This is a very strange problem :shock:

Posted: Wed Jan 03, 2007 1:03 pm
by Pinhead
Problem is found :!: :!: :!:

If I use the compiler option 'unicode executable' then it goes wrong.
I think unicode is one of the big problems in PB4 for Linux.

Posted: Wed Jan 03, 2007 1:51 pm
by FloHimself
Yes, with unicode enabled I get the same problem.