DialogDesign0R V1.86

Applications, Games, Tools, User libs and useful stuff coded in PureBasic
Mesa
Enthusiast
Enthusiast
Posts: 433
Joined: Fri Feb 24, 2012 10:19 am

Re: DialogDesign0R V1.83

Post by Mesa »

I've got strange messages when i use ID's gadget and ID's windows.
11:54:03 [PLAUSIBILITY CHECK] Window '#0' => '0' is not allowed as first character in a constant name!
11:54:03 [PLAUSIBILITY CHECK] Window '1' => First character of an ID has to be '#'!
11:54:03 [PLAUSIBILITY CHECK] Window '2' => First character of an ID has to be '#'!
11:54:03 [PLAUSIBILITY CHECK] Window '#3' => '3' is not allowed as first character in a constant name!
11:54:03 [PLAUSIBILITY CHECK] Window '4' => First character of an ID has to be '#'!
and the .pbi made makes bad runtime enumerations

Code: Select all

...
; Runtime Enumeration Windows
; 	0
; EndEnumeration


Dim DD_WindowNames.s(#DD_WindowCount)

DD_WindowNames(1) = "window_1"


; Runtime Enumeration Gadgets
; 	1
; 	2
; EndEnumeration
M.
User avatar
HeX0R
Addict
Addict
Posts: 1187
Joined: Mon Sep 20, 2004 7:12 am
Location: Hell

Re: DialogDesign0R V1.83

Post by HeX0R »

Ktim07 wrote: Fri Jun 30, 2023 10:51 am I tried this very interesting utility today, I am a new user. But I quickly noticed something, when for example one adds a menu bar, and the first Item is File. How do you add an item under File eg Open?? (I don't know if I am doing it wrong but I couldn't figure this out as some options are disabled). Then I also think It would be useful if for example say one could add a button say "Click me" and then the window shown outside (the out put structure) allows one to edit some of the Button properties visually in that out put window like the size & position & results automatically reflected in the dialog designer ( I know this is done manually inside the dialog because those options are provided for) I am just saying it would be easier

First you add the menu (Right Mouse click on the Window entry, then "Add Menu/StatusBar/ToolBar" -> "Menu"
Then you select the menu entry with RMC and select "Add Menu/StatusBar/ToolBar" -> Title and give it a Text "File"
Then you select the Title "File" with RMC and select "Add Menu/StatusBar/ToolBar" -> MenuItem and give it a Text "Open"
...
That's simply how menus are working in PB.
Please be aware that this Menu/StatusBar/ToolBar feature is based on a hack!
PBs Dialogs don't support them until now out of the box.


Your second request will not happen, those dialogs are defined by virtual containers, not the gadgets inside (like buttons) influence the main behaviour, but the parent containers.
In the help file is a link to a video, that should help to understand how dialogs work.
User avatar
HeX0R
Addict
Addict
Posts: 1187
Joined: Mon Sep 20, 2004 7:12 am
Location: Hell

Re: DialogDesign0R V1.83

Post by HeX0R »

Mesa wrote: Fri Jun 30, 2023 11:08 am I've got strange messages when i use ID's gadget and ID's windows.
That doesn't help, I need to see the xml
User avatar
HeX0R
Addict
Addict
Posts: 1187
Joined: Mon Sep 20, 2004 7:12 am
Location: Hell

Re: DialogDesign0R V1.83

Post by HeX0R »

I just saw that the Extra Stuff (for menus, statusbars, toolbars) is triggering an IMA with PB6.02, anything < PB6.02 works just fine.
So better don't use those compilers for now, I'll look deeper into that, when I find the time.
User avatar
Ktim07
User
User
Posts: 21
Joined: Wed Jun 28, 2023 7:55 pm

Re: DialogDesign0R V1.83

Post by Ktim07 »

HeX0R wrote: Fri Jun 30, 2023 11:36 am First you add the menu (Right Mouse click on the Window entry, then "Add Menu/StatusBar/ToolBar" -> "Menu"
Then you select the menu entry with RMC and select "Add Menu/StatusBar/ToolBar" -> Title and give it a Text "File"
Then you select the Title "File" with RMC and select "Add Menu/StatusBar/ToolBar" -> MenuItem and give it a Text "Open"
...
That's simply how menus are working in PB.
Please be aware that this Menu/StatusBar/ToolBar feature is based on a hack!
PBs Dialogs don't support them until now out of the box.
Thanks
This works fine, I see "based on a hack!"
This is a pretty hidden hack for a newbie,
Serious souls !!!
Mesa
Enthusiast
Enthusiast
Posts: 433
Joined: Fri Feb 24, 2012 10:19 am

Re: DialogDesign0R V1.83

Post by Mesa »

Code: Select all

  <?xml version="1.0" encoding="UTF-8" ?> 
- <dialogs>
- <!-- Created by Dialog Design0R V1.83 => get it from: https://hex0rs.coderbu.de/en/sdm_downloads/dialogdesign0r/
  --> 
- <window flags="#PB_Window_SystemMenu | #PB_Window_MinimizeGadget | #PB_Window_MaximizeGadget | #PB_Window_SizeGadget" width="800" height="600" name="window_1" xpos="44" ypos="46" id="#0">
- <vbox id="1">
- <hbox expand="item:1" id="2">
  <canvas width="500" name="canvas_1" id="#3" /> 
  <tree width="300" name="tree_1" id="4" /> 
  </hbox>
  </vbox>
  </window>
  </dialogs>
- <!-- DDesign0R Definition: PureBasic|1|1|1|v|example_with_declares|0
  --> 
I know that id="#x" is a bad id but if i set an id="1" for example, i've got this message: [PLAUSIBILITY CHECK] Window '1' => First character of an ID has to be '#'!
So if i add an "#", i've got that message: [PLAUSIBILITY CHECK] Window '#1' => '1' is not allowed as first character in a constant name!
User avatar
HeX0R
Addict
Addict
Posts: 1187
Joined: Mon Sep 20, 2004 7:12 am
Location: Hell

Re: DialogDesign0R V1.83

Post by HeX0R »

You are making strange things (as usual), I think I make the plausibility check optional.

I mean the messages are correct and I have no idea what the benefit of your ids might be, they are typically used as constants or what are you doing with them?
A constant #1 is not allowed in PB.

Latest when you use the *.pbi output of DD, that will result in compiler errors, that was the reason for the plausi check.

[Edit]
o.k., you are trying to enumerate them yourself (id="1", id="2", ...)?
Ah o.k., didn't expect anyone is doing that, that should be easily integratable to the plausi check.
But I have no time these days, might need some days/weeks
User avatar
HeX0R
Addict
Addict
Posts: 1187
Joined: Mon Sep 20, 2004 7:12 am
Location: Hell

Re: DialogDesign0R V1.84

Post by HeX0R »

Updated to 1.84 (finally, sorry, too warm these days...), but only the Sources are up to date.
Changes can be seen in the head of DDesign0r_v02.pb
User avatar
Mindphazer
Enthusiast
Enthusiast
Posts: 456
Joined: Mon Sep 10, 2012 10:41 am
Location: Savoie

Re: DialogDesign0R V1.84

Post by Mindphazer »

HeX0R wrote: Mon Jul 10, 2023 2:29 pm (finally, sorry, too warm these days...)
Well, isn't that normal, in Hell ? :mrgreen:
MacBook Pro 16" M4 Pro - 24 Gb - MacOS 15.4.1 - Iphone 15 Pro Max - iPad at home
...and unfortunately... Windows at work...
User avatar
HeX0R
Addict
Addict
Posts: 1187
Joined: Mon Sep 20, 2004 7:12 am
Location: Hell

Re: DialogDesign0R V1.84

Post by HeX0R »

:lol:
hoangdiemtinh
User
User
Posts: 97
Joined: Wed Nov 16, 2022 1:51 pm

Re: DialogDesign0R V1.84

Post by hoangdiemtinh »

@Hex0r,

I updated the DD Vietnamese Language to DD v1.84.
Please add into the next your release.
.
File Vietnamese Language for Dialog Design0R: https://bit.ly/3NXOByQ
SHA1 zip: 88A2D888ACE3DB51CBF39034F29AAA300946B824
Last edited by hoangdiemtinh on Mon Jul 17, 2023 8:20 am, edited 1 time in total.
PC: Windows 10 x64, 8GB RAM. PB ver: 6.x
--
I love PB5 vs PB6 :)
User avatar
HeX0R
Addict
Addict
Posts: 1187
Joined: Mon Sep 20, 2004 7:12 am
Location: Hell

Re: DialogDesign0R V1.84

Post by HeX0R »

Great, thanks!
User avatar
HeX0R
Addict
Addict
Posts: 1187
Joined: Mon Sep 20, 2004 7:12 am
Location: Hell

Re: DialogDesign0R V1.84

Post by HeX0R »

Binaries are updated now (including the updated Vietnamese translation)
I've also updated the source, nothing new, besides the new language file from hoangdiemtinh.
devox
User
User
Posts: 32
Joined: Thu Apr 01, 2021 7:25 pm

Re: DialogDesign0R V1.84

Post by devox »

I noticed that DialogDesign0R adds the xpos, and ypos attributes on the windows elements. As the Dialog library does not uses these attributes, how are we to make use of them?

I see OpenXMLDialog can take x/y coords. I' guessing we have to extract the values from the xml and then feed it in this function?
User avatar
HeX0R
Addict
Addict
Posts: 1187
Joined: Mon Sep 20, 2004 7:12 am
Location: Hell

Re: DialogDesign0R V1.84

Post by HeX0R »

Yes, there are some attributes added, where PB makes no use of (yet?).
For now, the xpos/ypos are only used inside DD, If you want to use them in your final dialog, you first have to extract them from the XML.
Maybe PB supports them in future, who knows?
Post Reply