Page 1 of 10

PureBasic 5.60 final is available !

Posted: Fri Jan 27, 2017 11:35 am
by Fred
Hello everyone !

We are very happy to announce the release of PureBasic 5.60 ! Thank you all for the feedback and tests, we hope you will enjoy the new features :D

- beta 8 is available and fix toolbar regression on Windows

- beta 7 is available and bring some more fixes and new function:

Code: Select all

- Added: SetImageFrameDelay()
- Renamed: ImageFrameDelay() to GetImageFrameDelay()
- beta 6 is available and bring some more fixes and new function

Code: Select all

- Added: ImageFrameDelay()
- beta 5 is available with some more bug fixes

- beta 4 is available with some more bug fixes

- beta 3 is available with the usual bug fixes and it brings new 3D commands:

Code: Select all

- Added: ParticleAcceleration(), ParticleColorFader(), ParticleEmitterAngle()
- Added: #PB_Material_AlphaReject, #PB_Material_TAM and #PB_Material_EnvironmentMap support to SetMaterialAttribute()
- Added: new 'Layer' optional paramater to SetMaterialAttribute()
- Added: new orientation modes for SetNodeAnimationKeyFrameRotation() and AddStaticGeometryEntity()
- beta 2 is available with the usual bug fixes and it brings the following changes

Code: Select all

- ToolBar, Menu and StatusBar are now back in inner window area for all OS (like before)
- MenuHeight(), StatusBarHeight() and ToolBarHeight() are back (like before)
The beta version of PureBasic 5.60 is available on your account, just in time to wishes you again an Happy New Year 2017 and best luck in your projects ! We took a deep look in the "feature and request" forum and tried to implemented some of the most wanted wishes :). Here is the full change log:

Code: Select all

- Added: GIF decoder support
- Added: SetImageFrame(), GetImageFrame(), ImageFrameCount(), AddImageFrame(), RemoveImageFrame()
- Added: UserAgent support to ReceiveHTTPMemory(), ReceiveHTTPFile() and GetHTTPHeaders()
- Added: #PB_Http_NoRedirect support for GetHTTPHeaders()
- Added: "Joe Doe <joe.doe@domain.com>" email format support for SendMail()
- Added: HTTPProxy() for Http related commands proxy support
- Added: Compression level support for CreatePack() and CompressMemory()
- Added: Large icons and text support to ToolBar library
- Added: GetUserDirectory() to get user specific directories
- Added: more flexibility to Base64Decoder to handle non padded input
- Added: Base64Encoder() and Base64Decoder() which takes string as input/output for easier use
- Added: color constants like #Black, #Blue etc. for all OS
- Added: Event() to get the current event (mainly useful from callback)
- Added: #PB_Canvas_Container support to have a container behaviour for canvas
- Added: #PB_EventType_Resize support for PanelGadget(), ContainerGadget(), CanvasGadget() and ScrollAreaGadget()
- Added: #PB_ListIcon_ColumnCount to GetGadgetAttribute() for ListIconGadget() to get the column count
- Added: #PB_All support to RemoveGadgetColumn() to remove all the columns
- Added: (IDE) templates are now saved when created to prevent lost if the IDE is not properly closed
- Added: (IDE) jump to a procedure now automatically unfold it if it was folded
- Added: (IDE) new specific popup menu for file tab to ease source file management
- Added: (IDE) find previous (reverse find)

- Changed: ToolBar, Menu and StatusBar are now excluded from inner window area for all OS
- Changed: MenuHeight(), StatusBarHeight() and ToolBarHeight() are now deprecated (all returns 0)
- Changed: renamed Base64Encoder() to Base64EncoderBuffer()
- Changed: renamed Base64Decoder() to Base64DecoderBuffer()
- Changed: removed 'define.b' syntax to change default type as it could create hard to find bugs.
Have fun,

The Fantaisie Software Team

Re: PureBasic 5.60 beta 1 is available

Posted: Fri Jan 27, 2017 11:39 am
by Dude

Code: Select all

Added: GIF decoder support
Nice! :D Thanks for this update; it looks very useful.

Code: Select all

RecieveHTTPMemory(), RecieveHTTPFile()
Wrong spelling. Should be: ReceiveHTTPMemory(), ReceiveHTTPFile().

Re: PureBasic 5.60 beta 1 is available

Posted: Fri Jan 27, 2017 11:56 am
by ts-soft
Image thanks.

Nice new funtions!

Re: PureBasic 5.60 beta 1 is available

Posted: Fri Jan 27, 2017 12:08 pm
by HanPBF
Thanks a lot!!!

My fav:
Added: #PB_Canvas_Container support to have a container behaviour for canvas

Someone able to open a forum topic what that does mean?
Should make possible really great things in user interface, shouldn't it???


Thanks again PureBasic team!

Re: PureBasic 5.60 beta 1 is available

Posted: Fri Jan 27, 2017 12:08 pm
by Marc56us
Happy! :mrgreen:

(KCC will be very very happy too, and for proxy) 8)
- Added: GIF decoder support
But how to use it ? (nothing in french help)

I just tried to add UseGIFImageDecoder() (autocomplet know it) in my viewer projetc
but when run:

Code: Select all

UseGIFImageDecoder() is not a function, array, list, map or macro.
:?:

Edit: Help is present in english help file (but without example)

Re: PureBasic 5.60 beta 1 is available

Posted: Fri Jan 27, 2017 12:13 pm
by TI-994A
Thank you very much, Team Fantaisie! :D

A true greatest-hits collection.

Re: PureBasic 5.60 beta 1 is available

Posted: Fri Jan 27, 2017 12:15 pm
by HanPBF
Added: #PB_EventType_Resize support for PanelGadget(), ContainerGadget(), CanvasGadget() and ScrollAreaGadget()
What does this mean?

Resized by whom or what???
Dialog Library?

SplitterGadget?

Re: PureBasic 5.60 beta 1 is available

Posted: Fri Jan 27, 2017 12:15 pm
by djes
Wow, it's the KCC's birthday or what ? :D Thank you Fred !

Re: PureBasic 5.60 beta 1 is available

Posted: Fri Jan 27, 2017 12:18 pm
by HanPBF
Changed: removed 'define.b' syntax to change default type as it could create hard to find bugs.
Yes! Good idea!

(Force/global setting: EnableExplicit; even some examples are tricky to understand...)

Re: PureBasic 5.60 beta 1 is available

Posted: Fri Jan 27, 2017 12:45 pm
by Fred
Here is a small code sample for GIF:

Code: Select all

UseGIFImageDecoder()

Filename$ = OpenFileRequester("Select a GIF file", "", "GIF Files|*.gif", 0)
If Filename$ And LoadImage(0, Filename$)

  OpenWindow(0, 100, 100, ImageWidth(0), ImageHeight(0), "")
  
  CanvasGadget(0, 0, 0, ImageWidth(0), ImageHeight(0))
  AddWindowTimer(0, 1, 150)
  
  Repeat
    Event = WaitWindowEvent()
    
    If Event = #PB_Event_Timer
      SetImageFrame(0, Frame)
      
      Frame+1
      If Frame >= ImageFrameCount(0) : Frame = 0 : EndIf
      
      If StartDrawing(CanvasOutput(0))
        DrawImage(ImageID(0), 0, 0)
        StopDrawing()
      EndIf
    EndIf
    
  Until Event = #PB_Event_CloseWindow
Else
  Debug "Impossible to load the file: " + Filename$
EndIf
And a sample code for canvas container:

Code: Select all

If OpenWindow(0, 0, 0, 220, 220, "Canvas container example", #PB_Window_SystemMenu | #PB_Window_ScreenCentered)
  
  CanvasGadget(0, 10, 10, 200, 200, #PB_Canvas_Container)
    ButtonGadget(1, 10, 10, 80, 30, "Hello")
  CloseGadgetList()
    
  Repeat 
    Event = WaitWindowEvent()
    
    If Event = #PB_Event_Gadget And EventGadget() = 0
        If EventType() = #PB_EventType_LeftButtonDown Or (EventType() = #PB_EventType_MouseMove And GetGadgetAttribute(0, #PB_Canvas_Buttons) & #PB_Canvas_LeftButton)
          If StartDrawing(CanvasOutput(0))
            x = GetGadgetAttribute(0, #PB_Canvas_MouseX)
            y = GetGadgetAttribute(0, #PB_Canvas_MouseY)
            Circle(x, y, 10, RGB(Random(255), Random(255), Random(255)))
            StopDrawing()
          EndIf
        EndIf
      EndIf    
    
  Until Event = #PB_Event_CloseWindow
EndIf

Re: PureBasic 5.60 beta 1 is available

Posted: Fri Jan 27, 2017 12:56 pm
by Marc56us
Fred wrote:Here is a small code sample for GIF:
Thank's Fred.
This sample you provide work fine :P

And I have no message error if I do a single UseGIFImageDecoder() in an empty program, so error is on my project. I will investigate my error.

:wink:

Edit: found :idea:
I was working in Project mode and compiler(s) options was set to use 5.51
Sorry :oops:

Now, set to 5.60b1: all work fine. Happy :P 8)
I will be able to modify old projects that used external elements

Re: PureBasic 5.60 beta 1 is available

Posted: Fri Jan 27, 2017 1:57 pm
by walbus
Canvas container !

This looking very cool :!:

Re: PureBasic 5.60 beta 1 is available

Posted: Fri Jan 27, 2017 2:02 pm
by Keya
WOWZERS there's some real gems in this update Fred, brilliant work as always!!! THANKYOU especially from me for adding compression level support so we can choose between fast vs strong, super cool :) :) :) oh and #Color constants! and email name format!! and GIF!!!

Re: PureBasic 5.60 beta 1 is available

Posted: Fri Jan 27, 2017 2:24 pm
by walbus
On the weekend i must make a look for the canvas container

I think, it is combinable with BucketFill advanced for canvas
http://www.purebasic.fr/english/viewtop ... 12&t=66927

Work this fine, this is a very mighty new feature, for creating endless cool new other features :wink:

Re: PureBasic 5.60 beta 1 is available

Posted: Fri Jan 27, 2017 2:54 pm
by HanPBF
Hello Walbus!

I think the same about #PB_Canvas_Container.

For me the gadgets where always limited compared to what we see today in web.
And RSBasic.de has a great web page with extensions to gadgets.
But that's all very tricky.

Drawing once own gadgets with CanvasGadget completely, including handling of text, etc. is far too complex.

So maybe #PB_Canvas_Container will bring some really good style improvements!
Which are now also easier to handle!