You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@royale.apache.org by GitBox <gi...@apache.org> on 2022/09/04 17:57:55 UTC
[GitHub] [royale-asjs] yishayw opened a new issue, #1208: Emulaytion - Panel's internal container does not default to Panel's size
yishayw opened a new issue, #1208:
URL: https://github.com/apache/royale-asjs/issues/1208
In below example you can see in Royale the content expanding beyond the panel's height, whereas in Flex there's a scrollbar in the Panel.
```
<?xml version="1.0"?>
<!-- dragdrop\DandDCanvas.mxml -->
<mx:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.apache.org/royale/spark"
xmlns:mx="library://ns.apache.org/royale/mx"
width="100%" height="100%"
backgroundColor="white">
<fx:Script>
<![CDATA[
]]>
</fx:Script>
<mx:Panel width="111" height="111">
<mx:Canvas width="100%" height="200" backgroundColor="red"/>
</mx:Panel>
</mx:Application>
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@royale.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [royale-asjs] yishayw commented on issue #1208: Emulation - Panel's internal container does not default to Panel's size
Posted by GitBox <gi...@apache.org>.
yishayw commented on issue #1208:
URL: https://github.com/apache/royale-asjs/issues/1208#issuecomment-1236976838
This problem may have been introduced in 8af26f74e1e567ac47b936937a4072f2c2b19a53 by @aharui
Specifically, this line
```
if (!isNaN(percentHeight))
_measuredMinHeight = mh;
```
in UIComponent.get__measuredHeight() sets measured min height of panel's internal container to its content measured height. This essentially overrides BoxLayout's flexing algorithm for percentHeight children.
As mentioned above layout is ok with other components, so I did not want to change BoxLayout without understanding this better.
I solved this by creating a custom Panel layout for mx, same as there exists one for spark. Panel is essentially just a titlebar and an internal content container (ignoring unimplemented control bar for now), so a simpler layout makes more sense to me.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@royale.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [royale-asjs] yishayw commented on issue #1208: Emulation - Panel's internal container does not default to Panel's size
Posted by GitBox <gi...@apache.org>.
yishayw commented on issue #1208:
URL: https://github.com/apache/royale-asjs/issues/1208#issuecomment-1236765599
This is in contrast to the following scenario, which works as expected:
```
<?xml version="1.0"?>
<mx:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.apache.org/royale/spark"
xmlns:mx="library://ns.apache.org/royale/mx"
width="100%" height="100%"
backgroundColor="white">
<fx:Script>
<![CDATA[
]]>
</fx:Script>
<mx:VBox width="111" height="111">
<mx:Canvas id="panelTitleBar" width="100%" height="20" backgroundColor="blue"/>
<mx:Canvas id="panelContentContainer" width="100%" height="100%">
<mx:Canvas width="100%" height="200" backgroundColor="red"/>
</mx:Canvas>
</mx:VBox>
</mx:Application>
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@royale.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [royale-asjs] yishayw closed issue #1208: Emulation - Panel's internal container does not default to Panel's size
Posted by GitBox <gi...@apache.org>.
yishayw closed issue #1208: Emulation - Panel's internal container does not default to Panel's size
URL: https://github.com/apache/royale-asjs/issues/1208
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@royale.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [royale-asjs] greg-dove commented on issue #1208: Emulation - Panel's internal container does not default to Panel's size
Posted by GitBox <gi...@apache.org>.
greg-dove commented on issue #1208:
URL: https://github.com/apache/royale-asjs/issues/1208#issuecomment-1236527950
The problem here is the minHeight getter on PanelInternalContainer which is defaulting to measuredMinHeight.
Simply setting
this.minHeight = 0;
in the PanelInternalContainer constructor might be one option to fix this. The way this is set up is quite different to how flex manages the content pane I think, so we might just have to apply some changes to get the behavior to be the same or at least similar. I did not check this in Flex.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@royale.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org