You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@pivot.apache.org by Bojan Vučinić <bo...@ma-cad.com> on 2010/11/22 21:04:18 UTC

Form in a ScrollPane

Hello,

I'm building a Pivot 2.0 application with Scala.
I've encountered the following problem:
In my bxml file I have:
 > Stack Pane
 >> Image
 >> ScrollPane
 >>> Form
if I define the ScrollPane with no attributes the form is transparent, 
the image is visible in the background (desired behavior), but the form 
is not getting the scroll bars.
If I add a preferredHeight attribute to the ScrollPane The form is not 
transparent (undesired behavior) but the scrollbars are active.

Am I doing something wrong? I'd like to have a transparent form with the 
background image and the scroll bars when needed.
Any help is appreciated,
Bojan


-- 
*Dr. Bojan Vučinić *
President, Ma-CAD <http://www.ma-cad.com/>
bojan.vucinic@ma-cad.com <ma...@ma-cad.com>
IM: bvucinic (Skype)
*http://fr.linkedin.com/in/bvucinic*

/Maintenance Concept Adjustment & Design/ 	31, rue Chanzy
Paris, Ile de France 75011 France
Work: +33 (6) 14 15 36 70
Mobile: +33 (6) 14 15 36 70
Fax: +33 (1) 53 01 38 28
See who we know in common <http://www.linkedin.com/e/wwk/4839994/> 	Want 
a signature like this? <http://www.linkedin.com/e/sig/4839994/>


Re: Form in a ScrollPane

Posted by Bojan Vučinić <bo...@ma-cad.com>.
Thanks Greg, that solved the binding.
Sorry for polluting an older thread which indeed has been solved.


Greg Brown said the following on 24/11/2010 19:10:
> You can add inline="true" to the bxml:include tag. That will cause the includes to share the same namespace as the parent file.
>
> However, this won't have any effect on the issue you were seeing (which I believe has already been resolved anyways).
>
> G
>
> On Nov 24, 2010, at 10:08 AM, Bojan Vučinić wrote:
>
>> Hi Sandro,
>>
>> As you have suggested, I have tried to split the bxml file in a number of smaller files.
>> But, I encountered a problem, so what I did is:
>>
>> <bxml:include src="lc.bxml"/>
>>
>> in the main file, and this is working, however my @BXML bindings (mostly TextInputs) are not working anymore.
>>
>> Any hints?
>> Thanks,
>> Bojan
>>
>>
>>
>> Sandro Martini said the following on 23/11/2010 12:02:
>>> Hi Bojan,
>>>> Congratulations to the Pivot-team, and keep up with the good work.
>>> thank you very much for this.
>>>
>>> On the scrollbar problem I'm sorry but we have to see what say Greg ... in
>>> the meantime I can suggest you to try to change the hierarchy of your
>>> containers inside bxml (if possible), and maybe splitting them in more than
>>> one (big) file.
>>>
>>> I hope to update soon, and to have your problem solved too.
>>>
>>> Bye,
>>> Sandro
>>>
>
>

Re: Form in a ScrollPane

Posted by Sandro Martini <sa...@gmail.com>.
Hi Bojan, 
sorry for the delay ...

As Greg suggested, have you tried adding the inline attribute, and even the
id attribute (so you can refer to them via namespace) ? 
Have you got a custom class for your main Window, that extends Window and
implements Bindable ?

Otherwise, I can suggest you to try to partition your bxml files like in the
"Kitchen Sink" (but it doesn't use data binding), so this could be the last
option.


I'm sorry but for these things I can't help so much at the moment ...


Greg, maybe a paragraph on this could be really useful in the "BXML Primer"
(even for me :-) ).


Bye,
Sandro

-- 
View this message in context: http://apache-pivot-users.399431.n3.nabble.com/Form-in-a-ScrollPane-tp1948360p1962370.html
Sent from the Apache Pivot - Users mailing list archive at Nabble.com.

Re: Form in a ScrollPane

Posted by Greg Brown <gk...@mac.com>.
You can add inline="true" to the bxml:include tag. That will cause the includes to share the same namespace as the parent file. 

However, this won't have any effect on the issue you were seeing (which I believe has already been resolved anyways).

G

On Nov 24, 2010, at 10:08 AM, Bojan Vučinić wrote:

> Hi Sandro,
> 
> As you have suggested, I have tried to split the bxml file in a number of smaller files.
> But, I encountered a problem, so what I did is:
> 
> <bxml:include src="lc.bxml"/>
> 
> in the main file, and this is working, however my @BXML bindings (mostly TextInputs) are not working anymore.
> 
> Any hints?
> Thanks,
> Bojan
> 
> 
> 
> Sandro Martini said the following on 23/11/2010 12:02:
>> Hi Bojan,
>>> Congratulations to the Pivot-team, and keep up with the good work.
>> thank you very much for this.
>> 
>> On the scrollbar problem I'm sorry but we have to see what say Greg ... in
>> the meantime I can suggest you to try to change the hierarchy of your
>> containers inside bxml (if possible), and maybe splitting them in more than
>> one (big) file.
>> 
>> I hope to update soon, and to have your problem solved too.
>> 
>> Bye,
>> Sandro
>> 


Re: Form in a ScrollPane

Posted by Bojan Vučinić <bo...@ma-cad.com>.
Hi Sandro,

As you have suggested, I have tried to split the bxml file in a number 
of smaller files.
But, I encountered a problem, so what I did is:

<bxml:include src="lc.bxml"/>

in the main file, and this is working, however my @BXML bindings (mostly 
TextInputs) are not working anymore.

Any hints?
Thanks,
Bojan



Sandro Martini said the following on 23/11/2010 12:02:
> Hi Bojan,
>> Congratulations to the Pivot-team, and keep up with the good work.
> thank you very much for this.
>
> On the scrollbar problem I'm sorry but we have to see what say Greg ... in
> the meantime I can suggest you to try to change the hierarchy of your
> containers inside bxml (if possible), and maybe splitting them in more than
> one (big) file.
>
> I hope to update soon, and to have your problem solved too.
>
> Bye,
> Sandro
>

Re: Form in a ScrollPane

Posted by Sandro Martini <sa...@gmail.com>.
Hi Bojan,
> Congratulations to the Pivot-team, and keep up with the good work.
thank you very much for this.

On the scrollbar problem I'm sorry but we have to see what say Greg ... in
the meantime I can suggest you to try to change the hierarchy of your
containers inside bxml (if possible), and maybe splitting them in more than
one (big) file.

I hope to update soon, and to have your problem solved too.

Bye,
Sandro

-- 
View this message in context: http://apache-pivot-users.399431.n3.nabble.com/Form-in-a-ScrollPane-tp1948360p1952710.html
Sent from the Apache Pivot - Users mailing list archive at Nabble.com.

Re: Form in a ScrollPane

Posted by Bojan Vučinić <bo...@ma-cad.com>.
Hi Sandro,

Thanks for your good wishes.
I've seen the work you have done to initiate Scala (actually it's what I 
used to start my development), thanks for that. I've also looked at the 
presentation you did at JUG Torino (or Milano?). I am both a novice for 
Scala (the better Java we have all been waiting for, and hoped we'll get 
there from the Java beta days in '94-'95) and Pivot, both are very nice!!

I've been using the latest 2.0 trunk, I'd gladly post a sample, but to 
cut-out from a 800-lines bxml file would take me to much time, and 
deadlines are tough ;-)

Of course, I'll post any suggestions/problems in Scala, but for the 
moment I'm focusing on the GUI, that is, the bxml file.

Congratulations to the Pivot-team, and keep up with the good work.

Best regards,
Bojan

P.S. FYI, I'm using Netbeans 7.0 beta, so importing the eclipse 
projects, but no problems otherwise, and my OS is xubuntu 10.10.



Sandro Martini said the following on 23/11/2010 11:11:
> Hi Bojan,
> congratulations and good luck for your new Pivot application :-) .
>
> On the scrollbars problem, are you using: an updated 2.0 from the trunk ?
> Can you post here a minimal sample to test the wrong behavior ?
>
>
> And last, just for curiosity, in your work on Pivot and Scala, are you
> finding problems in interoperability or all is working good ?
> Or if you have some suggestion, you are welcome.
>
> All this because we are starting to write some extensions to Pivot for
> Scala, for example to see if it will be possible to have transparent
> conversion between Scala collections and Pivot collections, and others ...
> but in next months. But if you have found other (Scala-related) things more
> important to fix or to have before, tell us.
> At the moment the related project is here:
> http://code.google.com/p/pivot-scala/
> but there is nothing inside ... contents will be put as soon as possible.
>
>
> Thank you very much,
> Sandro
>

Re: Form in a ScrollPane

Posted by Sandro Martini <sa...@gmail.com>.
Hi Bojan,
congratulations and good luck for your new Pivot application :-) .

On the scrollbars problem, are you using: an updated 2.0 from the trunk ?
Can you post here a minimal sample to test the wrong behavior ?


And last, just for curiosity, in your work on Pivot and Scala, are you
finding problems in interoperability or all is working good ? 
Or if you have some suggestion, you are welcome.

All this because we are starting to write some extensions to Pivot for
Scala, for example to see if it will be possible to have transparent
conversion between Scala collections and Pivot collections, and others ...
but in next months. But if you have found other (Scala-related) things more
important to fix or to have before, tell us.
At the moment the related project is here:
http://code.google.com/p/pivot-scala/
but there is nothing inside ... contents will be put as soon as possible.


Thank you very much,
Sandro

-- 
View this message in context: http://apache-pivot-users.399431.n3.nabble.com/Form-in-a-ScrollPane-tp1948360p1952532.html
Sent from the Apache Pivot - Users mailing list archive at Nabble.com.

Re: Form in a ScrollPane

Posted by Greg Brown <gk...@mac.com>.
Nice! Looks good.

On Nov 23, 2010, at 10:23 AM, Bojan Vučinić wrote:

> Perfect! attached a pic of the GUI and the XML hierarchy down to the form level.
> 
> Thanks again,
> Bojan
> 
> 
> Greg Brown said the following on 23/11/2010 16:01:
>> 
>> Did you try setting the column width to 1*?
>> 
>> On Nov 23, 2010, at 9:57 AM, Bojan Vučinić wrote:
>> 
>>> Works like a charm. Many thanks.
>>> 
>>> If you could just tell me how to fill the width by the TableView in the first row, that would be great.
>>> 
>>> 
>>> Greg Brown said the following on 23/11/2010 14:43:
>>>> 
>>>> What type of container is the parent of the second scroll pane? Looks like maybe it is a vertical box pane? Try using a TablePane with two rows: the first one should have a height of -1 (the default), and the second should have a height of 1*.
>>>> 
>>>> On Nov 23, 2010, at 4:17 AM, Bojan Vučinić wrote:
>>>> 
>>>>> Hi Greg,
>>>>> 
>>>>> Thanks for your help.
>>>>> The form transparency issue has been solved by setting  styles="{backgroundColor:null}" on the ScrollPane, as per your instructions.
>>>>> 
>>>>> However, the scroll bars issue is still present.
>>>>> In one form which is closer to the top of the hierarchy (Window - TablePane - TabPane - StackPane - ScrollPane - Form) the scroll bars appear when needed (see scroll1.png).
>>>>> But in another, where the form is a bit down the hierarchy (Window - TablePane - TabPane - BoxPane - ScrollPane - BoxPane - Form the scroll bars don't appear (see scroll2.png).
>>>>> 
>>>>> Any idea why this is happening?
>>>>> Best regards,
>>>>> Bojan
>>>>> 
>>>>> 
>>>>> Greg Brown said the following on 23/11/2010 01:05:
>>>>>> 
>>>>>> Hi Bojan,
>>>>>> 
>>>>>> Does the form actually exceed the size of the scroll pane? If not, then the scroll bars would not appear. If you want scroll bars to always appear, you can set the scroll bar policy to "always".
>>>>>> 
>>>>>> By default, scroll panes have a white background - you can set the background color to null to make it transparent.
>>>>>> 
>>>>>> Hope this helps,
>>>>>> Greg
>>>>>> 
>>>>>> On Nov 22, 2010, at 3:04 PM, Bojan Vučinić wrote:
>>>>>> 
>>>>>>> Hello,
>>>>>>> 
>>>>>>> I'm building a Pivot 2.0 application with Scala.
>>>>>>> I've encountered the following problem:
>>>>>>> In my bxml file I have:
>>>>>>> > Stack Pane
>>>>>>> >> Image
>>>>>>> >> ScrollPane
>>>>>>> >>> Form
>>>>>>> if I define the ScrollPane with no attributes the form is transparent, the image is visible in the background (desired behavior), but the form is not getting the scroll bars.
>>>>>>> If I add a preferredHeight attribute to the ScrollPane The form is not transparent (undesired behavior) but the scrollbars are active.
>>>>>>> 
>>>>>>> Am I doing something wrong? I'd like to have a transparent form with the background image and the scroll bars when needed.
>>>>>>> Any help is appreciated,
>>>>>>> Bojan
>>>>>>> 
>>>>>>> 
>>>>>>> -- 
>>>>>>> Dr. Bojan Vučinić 
>>>>>>> President, Ma-CAD
>>>>>>> bojan.vucinic@ma-cad.com
>>>>>>> IM: bvucinic (Skype)
>>>>>>> http://fr.linkedin.com/in/bvucinic
>>>>>>> 
>>>>>>> Maintenance Concept Adjustment & Design	 31, rue Chanzy
>>>>>>> Paris, Ile de France 75011 France
>>>>>>> Work: +33 (6) 14 15 36 70
>>>>>>> Mobile: +33 (6) 14 15 36 70
>>>>>>> Fax: +33 (1) 53 01 38 28
>>>>>>> See who we know in common	Want a signature like this?
>>>>>> 
>>>>> <scroll1.png><scroll2.png>
>>>> 
>> 
> <Form-hierarchy.jpg><working.jpg>


Re: Form in a ScrollPane

Posted by Bojan Vučinić <bo...@ma-cad.com>.
Perfect! attached a pic of the GUI and the XML hierarchy down to the 
form level.

Thanks again,
Bojan


Greg Brown said the following on 23/11/2010 16:01:
> Did you try setting the column width to 1*?
>
> On Nov 23, 2010, at 9:57 AM, Bojan Vučinić wrote:
>
>> Works like a charm. Many thanks.
>>
>> If you could just tell me how to fill the width by the TableView in 
>> the first row, that would be great.
>>
>>
>> Greg Brown said the following on 23/11/2010 14:43:
>>> What type of container is the parent of the second scroll pane? 
>>> Looks like maybe it is a vertical box pane? Try using a TablePane 
>>> with two rows: the first one should have a height of -1 (the 
>>> default), and the second should have a height of 1*.
>>>
>>> On Nov 23, 2010, at 4:17 AM, Bojan Vučinić wrote:
>>>
>>>> Hi Greg,
>>>>
>>>> Thanks for your help.
>>>> The form transparency issue has been solved by setting  
>>>> styles="{backgroundColor:null}" on the ScrollPane, as per your 
>>>> instructions.
>>>>
>>>> However, the scroll bars issue is still present.
>>>> In one form which is closer to the top of the hierarchy (Window - 
>>>> TablePane - TabPane - StackPane - ScrollPane - Form) the scroll 
>>>> bars appear when needed (see scroll1.png).
>>>> But in another, where the form is a bit down the hierarchy (Window 
>>>> - TablePane - TabPane - BoxPane - ScrollPane - BoxPane - Form the 
>>>> scroll bars don't appear (see scroll2.png).
>>>>
>>>> Any idea why this is happening?
>>>> Best regards,
>>>> Bojan
>>>>
>>>>
>>>> Greg Brown said the following on 23/11/2010 01:05:
>>>>> Hi Bojan,
>>>>>
>>>>> Does the form actually exceed the size of the scroll pane? If not, 
>>>>> then the scroll bars would not appear. If you want scroll bars to 
>>>>> always appear, you can set the scroll bar policy to "always".
>>>>>
>>>>> By default, scroll panes have a white background - you can set the 
>>>>> background color to null to make it transparent.
>>>>>
>>>>> Hope this helps,
>>>>> Greg
>>>>>
>>>>> On Nov 22, 2010, at 3:04 PM, Bojan Vučinić wrote:
>>>>>
>>>>>> Hello,
>>>>>>
>>>>>> I'm building a Pivot 2.0 application with Scala.
>>>>>> I've encountered the following problem:
>>>>>> In my bxml file I have:
>>>>>> > Stack Pane
>>>>>> >> Image
>>>>>> >> ScrollPane
>>>>>> >>> Form
>>>>>> if I define the ScrollPane with no attributes the form is 
>>>>>> transparent, the image is visible in the background (desired 
>>>>>> behavior), but the form is not getting the scroll bars.
>>>>>> If I add a preferredHeight attribute to the ScrollPane The form 
>>>>>> is not transparent (undesired behavior) but the scrollbars are 
>>>>>> active.
>>>>>>
>>>>>> Am I doing something wrong? I'd like to have a transparent form 
>>>>>> with the background image and the scroll bars when needed.
>>>>>> Any help is appreciated,
>>>>>> Bojan
>>>>>>
>>>>>>
>>>>>> -- 
>>>>>> *Dr. Bojan Vučinić *
>>>>>> President, Ma-CAD <http://www.ma-cad.com/>
>>>>>> bojan.vucinic@ma-cad.com <ma...@ma-cad.com>
>>>>>> IM: bvucinic (Skype)
>>>>>> *http://fr.linkedin.com/in/bvucinic*
>>>>>>
>>>>>> /Maintenance Concept Adjustment & Design/ 	31, rue Chanzy
>>>>>> Paris, Ile de France 75011 France
>>>>>> Work: +33 (6) 14 15 36 70
>>>>>> Mobile: +33 (6) 14 15 36 70
>>>>>> Fax: +33 (1) 53 01 38 28
>>>>>> See who we know in common 
>>>>>> <http://www.linkedin.com/e/wwk/4839994/> 	Want a signature like 
>>>>>> this? <http://www.linkedin.com/e/sig/4839994/>
>>>>>>
>>>>>
>>>> <scroll1.png><scroll2.png>
>>>
>

Re: Form in a ScrollPane

Posted by Greg Brown <gk...@mac.com>.
Did you try setting the column width to 1*?

On Nov 23, 2010, at 9:57 AM, Bojan Vučinić wrote:

> Works like a charm. Many thanks.
> 
> If you could just tell me how to fill the width by the TableView in the first row, that would be great.
> 
> 
> Greg Brown said the following on 23/11/2010 14:43:
>> 
>> What type of container is the parent of the second scroll pane? Looks like maybe it is a vertical box pane? Try using a TablePane with two rows: the first one should have a height of -1 (the default), and the second should have a height of 1*.
>> 
>> On Nov 23, 2010, at 4:17 AM, Bojan Vučinić wrote:
>> 
>>> Hi Greg,
>>> 
>>> Thanks for your help.
>>> The form transparency issue has been solved by setting  styles="{backgroundColor:null}" on the ScrollPane, as per your instructions.
>>> 
>>> However, the scroll bars issue is still present.
>>> In one form which is closer to the top of the hierarchy (Window - TablePane - TabPane - StackPane - ScrollPane - Form) the scroll bars appear when needed (see scroll1.png).
>>> But in another, where the form is a bit down the hierarchy (Window - TablePane - TabPane - BoxPane - ScrollPane - BoxPane - Form the scroll bars don't appear (see scroll2.png).
>>> 
>>> Any idea why this is happening?
>>> Best regards,
>>> Bojan
>>> 
>>> 
>>> Greg Brown said the following on 23/11/2010 01:05:
>>>> 
>>>> Hi Bojan,
>>>> 
>>>> Does the form actually exceed the size of the scroll pane? If not, then the scroll bars would not appear. If you want scroll bars to always appear, you can set the scroll bar policy to "always".
>>>> 
>>>> By default, scroll panes have a white background - you can set the background color to null to make it transparent.
>>>> 
>>>> Hope this helps,
>>>> Greg
>>>> 
>>>> On Nov 22, 2010, at 3:04 PM, Bojan Vučinić wrote:
>>>> 
>>>>> Hello,
>>>>> 
>>>>> I'm building a Pivot 2.0 application with Scala.
>>>>> I've encountered the following problem:
>>>>> In my bxml file I have:
>>>>> > Stack Pane
>>>>> >> Image
>>>>> >> ScrollPane
>>>>> >>> Form
>>>>> if I define the ScrollPane with no attributes the form is transparent, the image is visible in the background (desired behavior), but the form is not getting the scroll bars.
>>>>> If I add a preferredHeight attribute to the ScrollPane The form is not transparent (undesired behavior) but the scrollbars are active.
>>>>> 
>>>>> Am I doing something wrong? I'd like to have a transparent form with the background image and the scroll bars when needed.
>>>>> Any help is appreciated,
>>>>> Bojan
>>>>> 
>>>>> 
>>>>> -- 
>>>>> Dr. Bojan Vučinić 
>>>>> President, Ma-CAD
>>>>> bojan.vucinic@ma-cad.com
>>>>> IM: bvucinic (Skype)
>>>>> http://fr.linkedin.com/in/bvucinic
>>>>> 
>>>>> Maintenance Concept Adjustment & Design	 31, rue Chanzy
>>>>> Paris, Ile de France 75011 France
>>>>> Work: +33 (6) 14 15 36 70
>>>>> Mobile: +33 (6) 14 15 36 70
>>>>> Fax: +33 (1) 53 01 38 28
>>>>> See who we know in common	Want a signature like this?
>>>> 
>>> <scroll1.png><scroll2.png>
>> 


Re: Form in a ScrollPane

Posted by Bojan Vučinić <bo...@ma-cad.com>.
Works like a charm. Many thanks.

If you could just tell me how to fill the width by the TableView in the 
first row, that would be great.


Greg Brown said the following on 23/11/2010 14:43:
> What type of container is the parent of the second scroll pane? Looks 
> like maybe it is a vertical box pane? Try using a TablePane with two 
> rows: the first one should have a height of -1 (the default), and the 
> second should have a height of 1*.
>
> On Nov 23, 2010, at 4:17 AM, Bojan Vučinić wrote:
>
>> Hi Greg,
>>
>> Thanks for your help.
>> The form transparency issue has been solved by setting  
>> styles="{backgroundColor:null}" on the ScrollPane, as per your 
>> instructions.
>>
>> However, the scroll bars issue is still present.
>> In one form which is closer to the top of the hierarchy (Window - 
>> TablePane - TabPane - StackPane - ScrollPane - Form) the scroll bars 
>> appear when needed (see scroll1.png).
>> But in another, where the form is a bit down the hierarchy (Window - 
>> TablePane - TabPane - BoxPane - ScrollPane - BoxPane - Form the 
>> scroll bars don't appear (see scroll2.png).
>>
>> Any idea why this is happening?
>> Best regards,
>> Bojan
>>
>>
>> Greg Brown said the following on 23/11/2010 01:05:
>>> Hi Bojan,
>>>
>>> Does the form actually exceed the size of the scroll pane? If not, 
>>> then the scroll bars would not appear. If you want scroll bars to 
>>> always appear, you can set the scroll bar policy to "always".
>>>
>>> By default, scroll panes have a white background - you can set the 
>>> background color to null to make it transparent.
>>>
>>> Hope this helps,
>>> Greg
>>>
>>> On Nov 22, 2010, at 3:04 PM, Bojan Vučinić wrote:
>>>
>>>> Hello,
>>>>
>>>> I'm building a Pivot 2.0 application with Scala.
>>>> I've encountered the following problem:
>>>> In my bxml file I have:
>>>> > Stack Pane
>>>> >> Image
>>>> >> ScrollPane
>>>> >>> Form
>>>> if I define the ScrollPane with no attributes the form is 
>>>> transparent, the image is visible in the background (desired 
>>>> behavior), but the form is not getting the scroll bars.
>>>> If I add a preferredHeight attribute to the ScrollPane The form is 
>>>> not transparent (undesired behavior) but the scrollbars are active.
>>>>
>>>> Am I doing something wrong? I'd like to have a transparent form 
>>>> with the background image and the scroll bars when needed.
>>>> Any help is appreciated,
>>>> Bojan
>>>>
>>>>
>>>> -- 
>>>> *Dr. Bojan Vučinić *
>>>> President, Ma-CAD <http://www.ma-cad.com/>
>>>> bojan.vucinic@ma-cad.com <ma...@ma-cad.com>
>>>> IM: bvucinic (Skype)
>>>> *http://fr.linkedin.com/in/bvucinic*
>>>>
>>>> /Maintenance Concept Adjustment & Design/ 	31, rue Chanzy
>>>> Paris, Ile de France 75011 France
>>>> Work: +33 (6) 14 15 36 70
>>>> Mobile: +33 (6) 14 15 36 70
>>>> Fax: +33 (1) 53 01 38 28
>>>> See who we know in common 
>>>> <http://www.linkedin.com/e/wwk/4839994/> 	Want a signature like 
>>>> this? <http://www.linkedin.com/e/sig/4839994/>
>>>>
>>>
>> <scroll1.png><scroll2.png>
>

Re: Form in a ScrollPane

Posted by Greg Brown <gk...@mac.com>.
What type of container is the parent of the second scroll pane? Looks like maybe it is a vertical box pane? Try using a TablePane with two rows: the first one should have a height of -1 (the default), and the second should have a height of 1*.

On Nov 23, 2010, at 4:17 AM, Bojan Vučinić wrote:

> Hi Greg,
> 
> Thanks for your help.
> The form transparency issue has been solved by setting  styles="{backgroundColor:null}" on the ScrollPane, as per your instructions.
> 
> However, the scroll bars issue is still present.
> In one form which is closer to the top of the hierarchy (Window - TablePane - TabPane - StackPane - ScrollPane - Form) the scroll bars appear when needed (see scroll1.png).
> But in another, where the form is a bit down the hierarchy (Window - TablePane - TabPane - BoxPane - ScrollPane - BoxPane - Form the scroll bars don't appear (see scroll2.png).
> 
> Any idea why this is happening?
> Best regards,
> Bojan
> 
> 
> Greg Brown said the following on 23/11/2010 01:05:
>> 
>> Hi Bojan,
>> 
>> Does the form actually exceed the size of the scroll pane? If not, then the scroll bars would not appear. If you want scroll bars to always appear, you can set the scroll bar policy to "always".
>> 
>> By default, scroll panes have a white background - you can set the background color to null to make it transparent.
>> 
>> Hope this helps,
>> Greg
>> 
>> On Nov 22, 2010, at 3:04 PM, Bojan Vučinić wrote:
>> 
>>> Hello,
>>> 
>>> I'm building a Pivot 2.0 application with Scala.
>>> I've encountered the following problem:
>>> In my bxml file I have:
>>> > Stack Pane
>>> >> Image
>>> >> ScrollPane
>>> >>> Form
>>> if I define the ScrollPane with no attributes the form is transparent, the image is visible in the background (desired behavior), but the form is not getting the scroll bars.
>>> If I add a preferredHeight attribute to the ScrollPane The form is not transparent (undesired behavior) but the scrollbars are active.
>>> 
>>> Am I doing something wrong? I'd like to have a transparent form with the background image and the scroll bars when needed.
>>> Any help is appreciated,
>>> Bojan
>>> 
>>> 
>>> -- 
>>> Dr. Bojan Vučinić 
>>> President, Ma-CAD
>>> bojan.vucinic@ma-cad.com
>>> IM: bvucinic (Skype)
>>> http://fr.linkedin.com/in/bvucinic
>>> 
>>> Maintenance Concept Adjustment & Design	 31, rue Chanzy
>>> Paris, Ile de France 75011 France
>>> Work: +33 (6) 14 15 36 70
>>> Mobile: +33 (6) 14 15 36 70
>>> Fax: +33 (1) 53 01 38 28
>>> See who we know in common	Want a signature like this?
>> 
> <scroll1.png><scroll2.png>


Re: Form in a ScrollPane

Posted by Bojan Vučinić <bo...@ma-cad.com>.
Hi Greg,

Thanks for your help.
The form transparency issue has been solved by setting  
styles="{backgroundColor:null}" on the ScrollPane, as per your instructions.

However, the scroll bars issue is still present.
In one form which is closer to the top of the hierarchy (Window - 
TablePane - TabPane - StackPane - ScrollPane - Form) the scroll bars 
appear when needed (see scroll1.png).
But in another, where the form is a bit down the hierarchy (Window - 
TablePane - TabPane - BoxPane - ScrollPane - BoxPane - Form the scroll 
bars don't appear (see scroll2.png).

Any idea why this is happening?
Best regards,
Bojan


Greg Brown said the following on 23/11/2010 01:05:
> Hi Bojan,
>
> Does the form actually exceed the size of the scroll pane? If not, 
> then the scroll bars would not appear. If you want scroll bars to 
> always appear, you can set the scroll bar policy to "always".
>
> By default, scroll panes have a white background - you can set the 
> background color to null to make it transparent.
>
> Hope this helps,
> Greg
>
> On Nov 22, 2010, at 3:04 PM, Bojan Vučinić wrote:
>
>> Hello,
>>
>> I'm building a Pivot 2.0 application with Scala.
>> I've encountered the following problem:
>> In my bxml file I have:
>> > Stack Pane
>> >> Image
>> >> ScrollPane
>> >>> Form
>> if I define the ScrollPane with no attributes the form is 
>> transparent, the image is visible in the background (desired 
>> behavior), but the form is not getting the scroll bars.
>> If I add a preferredHeight attribute to the ScrollPane The form is 
>> not transparent (undesired behavior) but the scrollbars are active.
>>
>> Am I doing something wrong? I'd like to have a transparent form with 
>> the background image and the scroll bars when needed.
>> Any help is appreciated,
>> Bojan
>>
>>
>> -- 
>> *Dr. Bojan Vučinić *
>> President, Ma-CAD <http://www.ma-cad.com/>
>> bojan.vucinic@ma-cad.com <ma...@ma-cad.com>
>> IM: bvucinic (Skype)
>> *http://fr.linkedin.com/in/bvucinic*
>>
>> /Maintenance Concept Adjustment & Design/ 	31, rue Chanzy
>> Paris, Ile de France 75011 France
>> Work: +33 (6) 14 15 36 70
>> Mobile: +33 (6) 14 15 36 70
>> Fax: +33 (1) 53 01 38 28
>> See who we know in common <http://www.linkedin.com/e/wwk/4839994/> 
>> Want a signature like this? <http://www.linkedin.com/e/sig/4839994/>
>>
>

Re: Form in a ScrollPane

Posted by Greg Brown <gk...@mac.com>.
Hi Bojan,

Does the form actually exceed the size of the scroll pane? If not, then the scroll bars would not appear. If you want scroll bars to always appear, you can set the scroll bar policy to "always".

By default, scroll panes have a white background - you can set the background color to null to make it transparent.

Hope this helps,
Greg

On Nov 22, 2010, at 3:04 PM, Bojan Vučinić wrote:

> Hello,
> 
> I'm building a Pivot 2.0 application with Scala.
> I've encountered the following problem:
> In my bxml file I have:
> > Stack Pane
> >> Image
> >> ScrollPane
> >>> Form
> if I define the ScrollPane with no attributes the form is transparent, the image is visible in the background (desired behavior), but the form is not getting the scroll bars.
> If I add a preferredHeight attribute to the ScrollPane The form is not transparent (undesired behavior) but the scrollbars are active.
> 
> Am I doing something wrong? I'd like to have a transparent form with the background image and the scroll bars when needed.
> Any help is appreciated,
> Bojan
> 
> 
> -- 
> Dr. Bojan Vučinić 
> President, Ma-CAD
> bojan.vucinic@ma-cad.com
> IM: bvucinic (Skype)
> http://fr.linkedin.com/in/bvucinic
> 
> Maintenance Concept Adjustment & Design	 31, rue Chanzy
> Paris, Ile de France 75011 France
> Work: +33 (6) 14 15 36 70
> Mobile: +33 (6) 14 15 36 70
> Fax: +33 (1) 53 01 38 28
> See who we know in common	Want a signature like this?