Form Designer 5.10

You need some new stunning features ? Tell us here.
luciano
Enthusiast
Enthusiast
Posts: 151
Joined: Wed Mar 09, 2011 8:25 pm

Re: Form Designer for Mac/Windows/Linux -5.00b2

Post by luciano »

Sorry, but I don't find any drawer "gdpcomputing" in the "Application Support" drawer.
Andre,
I had similar problems when I crashed Form Designer, then I did a search for "gdpcomputing" on my computer.
I found a folder "gdpcomputing\formdesig" wich contains "setting.prefs", deleting or renaming it should solve the problem, as a new file is created when the application restarts.
I am on Windows, but I think that this can help you as well.
Polo
Addict
Addict
Posts: 2422
Joined: Tue May 06, 2003 5:07 pm
Location: UK

Re: Form Designer for Mac/Windows/Linux -5.00b2

Post by Polo »

ts-soft wrote:I still miss the #PB_Ignore Flags for Windows X and Y, this should the default-value, better than 0
Added (set x and/or y position to -1 to use PB_Ignore).
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Re: Form Designer for Mac/Windows/Linux -5.00b2

Post by ts-soft »

Thanks, but only to make it sure: you replace -1 with #PB_Ignore (-65535)?
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
Polo
Addict
Addict
Posts: 2422
Joined: Tue May 06, 2003 5:07 pm
Location: UK

Re: Form Designer for Mac/Windows/Linux -5.00b2

Post by Polo »

ts-soft wrote:Thanks, but only to make it sure: you replace -1 with #PB_Ignore (-65535)?
When the code is generated, I indeed replace -1 with the #PB_Ignore constant. It is read back to -1 when the file is opened in FD :)
User avatar
KJ67
Enthusiast
Enthusiast
Posts: 218
Joined: Fri Jun 26, 2009 3:51 pm
Location: Westernmost tip of Norway

Re: Form Designer for Mac/Windows/Linux -5.00b2

Post by KJ67 »

While I really like to see this constant added since I have it almost as a default;
is it really wise to (ab)use the value -1 this way? It is a very valid position for a window.
The best preparation for tomorrow is doing your best today.
Polo
Addict
Addict
Posts: 2422
Joined: Tue May 06, 2003 5:07 pm
Location: UK

Re: Form Designer for Mac/Windows/Linux -5.00b2

Post by Polo »

KJ67 wrote:While I really like to see this constant added since I have it almost as a default;
is it really wise to (ab)use the value -1 this way? It is a very valid position for a window.
Is it? Well I'll add something more sofisticated then.

Edit: now you just have to type #PB_Ignore in the x/y field and it'll work out of the box. The value stored is the actual #PB_Ignore so there won't be any conflicts.
Thanks for the information/suggestions! :)
User avatar
Andre
PureBasic Team
PureBasic Team
Posts: 2137
Joined: Fri Apr 25, 2003 6:14 pm
Location: Germany (Saxony, Deutscheinsiedel)
Contact:

Re: Form Designer for Mac/Windows/Linux -5.00b2

Post by Andre »

luciano wrote: I had similar problems when I crashed Form Designer, then I did a search for "gdpcomputing" on my computer.
I found a folder "gdpcomputing\formdesig" wich contains "setting.prefs", deleting or renaming it should solve the problem, as a new file is created when the application restarts.
I am on Windows, but I think that this can help you as well.
Thanks for the tip. But this doesn't help here - I don't find "gdpcomputing" anywhere on my harddisk on MacOS, so no preference file seem to be saved.

Polo contacted me already per PM to try other executable versions of FormDesigner for testing, it seems to be a "Leopard-only" (MacOS 10.5.8) problem...
Bye,
...André
(PureBasicTeam::Docs & Support - PureArea.net | Order:: PureBasic | PureVisionXP)
Polo
Addict
Addict
Posts: 2422
Joined: Tue May 06, 2003 5:07 pm
Location: UK

Re: Form Designer for Mac/Windows/Linux -5.00b2

Post by Polo »

The crash linked to splitter being resized too small won't happen in next version.
Andre's crash is more problematic but as soon as I have Leopard installed I'll debug that :)
luciano
Enthusiast
Enthusiast
Posts: 151
Joined: Wed Mar 09, 2011 8:25 pm

Re: Form Designer for Mac/Windows/Linux -5.00b2

Post by luciano »

The crash linked to splitter being resized too small won't happen in next version.
Gaetan,
no problem here, I have no more crash with 5,00 b2.
I only had crashes previously.

I discovered that icons get smaller or larger according to windows size, that's really a nice interface.
Just a small glitch with Code/Design icons which reamain small.

Image
Polo
Addict
Addict
Posts: 2422
Joined: Tue May 06, 2003 5:07 pm
Location: UK

Re: Form Designer for Mac/Windows/Linux -5.00b2

Post by Polo »

Thanks Luciano, that was actually a pain to code that, but in the end it's quite good to work with a ribbon, I know much people despise it but I think MS Office got much better with those :)

I've got the code/design icon not growing bigger too, I'll have a look :)
Edit: fixed.

I've improved the code parser a little bit further, you can actually do things like:

Code: Select all

  Button_0 = ButtonGadget(#PB_Any, 120, 60, 220, 40, Language("Group","Name"))
This is the syntax used by the FD/PB IDE for multi language support, so that's really nice to be able to do it directly in the FD!
luciano
Enthusiast
Enthusiast
Posts: 151
Joined: Wed Mar 09, 2011 8:25 pm

Re: Form Designer for Mac/Windows/Linux -5.00b2

Post by luciano »

Just an idea, is it possible to have just the pointer without any gadget creation?
I mean a "select" icon in the ribbon so that you can only select and move or resize objects without the risk of putting small objects in the window; when you are in the "home" tab you do not see the gadget icon you had clicked on previously.
Polo
Addict
Addict
Posts: 2422
Joined: Tue May 06, 2003 5:07 pm
Location: UK

Re: Form Designer for Mac/Windows/Linux -5.00b2

Post by Polo »

luciano wrote:Just an idea, is it possible to have just the pointer without any gadget creation?
I mean a "select" icon in the ribbon so that you can only select and move or resize objects without the risk of putting small objects in the window; when you are in the "home" tab you do not see the gadget icon you had clicked on previously.
Added.
Polo
Addict
Addict
Posts: 2422
Joined: Tue May 06, 2003 5:07 pm
Location: UK

Re: Form Designer for Mac/Windows/Linux -5.00b2

Post by Polo »

Huge update (or hudge work...!) - full automatic resizing!
This is too cool, just check the lock states (left, right, top, bottom), and all is done for you.
Try the code below to see what the end result (the code doesn't look especially nice, but is fully generated by the FD and can be opened back).
There's probably quite some bugs in the code generation/loading, but it's just brilliant to be able to do that kind of stuff with a few clicks instead of long line of codes - and with no external lib :)

Code: Select all

Global Window_0

Global Button_0, Button_0_1, Tree_0, Panel_0

Declare ResizeGadgetsWindow_0()

Procedure InitWindow_0()
  Window_0 = OpenWindow(#PB_Any, 0, 0, 600, 400, "", #PB_Window_SystemMenu | #PB_Window_MinimizeGadget | #PB_Window_MaximizeGadget | #PB_Window_SizeGadget)
  Button_0 = ButtonGadget(#PB_Any, WindowWidth(Window_0) - 100, WindowHeight(Window_0) - 30, 90, 25, "Save")
  Button_0_1 = ButtonGadget(#PB_Any, WindowWidth(Window_0) - 200, WindowHeight(Window_0) - 30, 90, 25, "Cancel")
  Tree_0 = TreeGadget(#PB_Any, 10, 10, 210, WindowHeight(Window_0) - 50)
  Panel_0 = PanelGadget(#PB_Any, 230, 10, WindowWidth(Window_0) - 240, WindowHeight(Window_0) - 50)
  AddGadgetItem(Panel_0, -1, "Tab 1")
  CloseGadgetList()
EndProcedure

Procedure ResizeGadgetsWindow_0()
  ResizeGadget(Button_0, WindowWidth(Window_0) - 100, WindowHeight(Window_0) - 30, 90, 25)
  ResizeGadget(Button_0_1, WindowWidth(Window_0) - 200, WindowHeight(Window_0) - 30, 90, 25)
  ResizeGadget(Tree_0, 10, 10, 210, WindowHeight(Window_0) - 50)
  ResizeGadget(Panel_0, 230, 10, WindowWidth(Window_0) - 240, WindowHeight(Window_0) - 50)
EndProcedure

Procedure Window_0_Events(event)
  Select event
    Case #PB_Event_Gadget
      Select EventGadget()
      EndSelect
  EndSelect
EndProcedure

InitWindow_0()

Repeat
  event = WaitWindowEvent()
  
  If event = #PB_Event_SizeWindow
    ResizeGadgetsWindow_0()
  EndIf
  
  
Until event = #PB_Event_CloseWindow
User avatar
Andre
PureBasic Team
PureBasic Team
Posts: 2137
Joined: Fri Apr 25, 2003 6:14 pm
Location: Germany (Saxony, Deutscheinsiedel)
Contact:

Re: Form Designer for Mac/Windows/Linux -5.00b2

Post by Andre »

@Polo: just an idea (without having tested it) - wouldn't it be better to store WindowWidth() and WindowHeight() value in variables at the beginning of the procedures, to avoid calling the PB functions a lot of times for each gadget?
Bye,
...André
(PureBasicTeam::Docs & Support - PureArea.net | Order:: PureBasic | PureVisionXP)
Polo
Addict
Addict
Posts: 2422
Joined: Tue May 06, 2003 5:07 pm
Location: UK

Re: Form Designer for Mac/Windows/Linux -5.00b2

Post by Polo »

Andre wrote:@Polo: just an idea (without having tested it) - wouldn't it be better to store WindowWidth() and WindowHeight() value in variables at the beginning of the procedures, to avoid calling the PB functions a lot of times for each gadget?
It would work the same - not sure if it would change anything, I'm pretty sure WindowWidth() and so on return a stored variable and do not actually retrieve it each time?
Post Reply