Toolbar.Horiz="FALSE" seems not to work for Win32
Toolbar.Horiz="FALSE" seems not to work for Win32
I've just been cross-compiling an application from AROS to Win32. I wished for a vertical toolbar, and setting Horiz="FALSE" in the xml file worked fine for AROS but did not display the toolbar under Windows. The toolbar was rendered fine when left to the default horizontal.
Cheers,
Nigel.
Cheers,
Nigel.
-
- Posts: 475
- Joined: Fri May 15, 2015 5:15 pm
- Location: Waterville, Minnesota USA
Re: Toolbar.Horiz="FALSE" seems not to work for Win32
Why are there quotes around false? I thought False was a constant. If you pass a string instead of a constant, wouldn't that evaluate to True?
I'm on registered MorphOS using FlowStudio.
Re: Toolbar.Horiz="FALSE" seems not to work for Win32
He is not talking about Hollywood Source Code, but the GUI definiton in the XML file... and there its is meant to be a string. Thus sems ok to me.
Re: Toolbar.Horiz="FALSE" seems not to work for Win32
Yes, this is from an XML file. So is the vertical mode working for you on Windows? If so, would you mind posting up your XML line so I can see what's not right with mine?p-OS wrote:He is not talking about Hollywood Source Code, but the GUI definiton in the XML file... and there its is meant to be a string. Thus sems ok to me.
Thanks,
Nigel.
Re: Toolbar.Horiz="FALSE" seems not to work for Win32
didn't user RapaGUI yet, but according to documentation correct Syntax is:
Code: Select all
<toolbar horiz="false">
.....some buttons....
</toolbar>
- airsoftsoftwair
- Posts: 5446
- Joined: Fri Feb 12, 2010 2:33 pm
- Location: Germany
- Contact:
Re: Toolbar.Horiz="FALSE" seems not to work for Win32
Works here. Please provide a minimal (!) code sample so that I can see what's wrong there...
-
- Posts: 475
- Joined: Fri May 15, 2015 5:15 pm
- Location: Waterville, Minnesota USA
Re: Toolbar.Horiz="FALSE" seems not to work for Win32
In that case, is it all lowercase? XML is case sensitive.p-OS wrote:He is not talking about Hollywood Source Code, but the GUI definiton in the XML file... and there its is meant to be a string. Thus sems ok to me.
I'm on registered MorphOS using FlowStudio.
Re: Toolbar.Horiz="FALSE" seems not to work for Win32
Sorry for taking a while to get back to you.airsoftsoftwair wrote:Works here. Please provide a minimal (!) code sample so that I can see what's wrong there...
The xml code is:
<?xml version="1.0" encoding="iso-8859-1"?>
<application>
<window title="SimpleWhiteboard" notify="closerequest" id="_MAIN" width="60" height="800" StayOnTop="TRUE" left="0" top="0">
<vgroup>
<toolbar id="toolbar" viewmode="Gfx" horiz="FALSE" userdata="draw">
<button id="add_workbench" type = "normal" icon="7" notify="pressed" notifydata="pressed:add_workbench"></button>
<button id="workbench" type="toggle" icon="4" disabled="TRUE" notify="selected" notifydata="selected:toggle_workbench"></button>
<button/>
<button id="add_display" type="normal" icon="5" notify="pressed" notifydata="pressed:add_display"></button>
<button/>
<button id="bin" type="normal" icon="6" notify="pressed" notifydata="pressed:bin" disabled="TRUE"></button>
</toolbar>
</vgroup>
</window>
</application>
Works find on AROS but on Windows 7 & 10 at work it just produces the window top border with a narrow line underneath the border's top bar.
Cheers,
Nigel.
- airsoftsoftwair
- Posts: 5446
- Joined: Fri Feb 12, 2010 2:33 pm
- Location: Germany
- Contact:
Re: Toolbar.Horiz="FALSE" seems not to work for Win32
Ok, so the toolbar on Win32 doesn't seem to impose a minimum size on the window. Thus, it is there, but you won't see it because there's nothing else in your window. To solve this, just add a rectangle to your code, i.e.:
Then it should work.
Code: Select all
<?xml version="1.0" encoding="iso-8859-1"?>
<application>
<window title="SimpleWhiteboard" notify="closerequest" id="_MAIN" width="60" height="800" StayOnTop="TRUE" left="0" top="0">
<vgroup>
<toolbar id="toolbar" viewmode="Gfx" horiz="FALSE" userdata="draw">
<button id="add_workbench" type = "normal" icon="7" notify="pressed" notifydata="pressed:add_workbench"></button>
<button id="workbench" type="toggle" icon="4" disabled="TRUE" notify="selected" notifydata="selected:toggle_workbench"></button>
<button/>
<button id="add_display" type="normal" icon="5" notify="pressed" notifydata="pressed:add_display"></button>
<button/>
<button id="bin" type="normal" icon="6" notify="pressed" notifydata="pressed:bin" disabled="TRUE"></button>
</toolbar>
<rectangle/>
</vgroup>
</window>
</application>
Re: Toolbar.Horiz="FALSE" seems not to work for Win32
Many thanks - I'll give that a try at work tomorrow (if I get a couple of minutes).
Cheers,
Nigel.
Cheers,
Nigel.