Layout problem: text in VBox with percentHeight

I'm using Flex 3. I have a lot of problems with a text component inside a VBox component with percentHeight to put value. The behavior that I'm trying to get, it's the VBox will be a scroll bar that will allow the text to display. The behavior I get, it's that resizes it VBox on the entire height of the text element and does not take into account its percentHeight. I would use a text box instead of a text nested in a VBox, but I need to put other components inside the VBox so I want the VBox to be able to scroll through all of the items inside.

Here is a sample application showing my problem:

<? XML version = "1.0"? >
" < = xmlns:mx mx:Application ' http://www.Adobe.com/2006/MXML "layout ="vertical"> "
< mx:VBox width = "100%" height = "10%" borderStyle = "solid" backgroundColor = "white" >
< mx:Text width = "100%" >
< mx:text >
<! [CDATA [Lorem ipsum dolor sit amet, adipiscing elit computer. In eleifend mi ultrices.
NEC commodo eros ornare non. Vestibule dapibus placerat magna vel imperdiet. Nullam vel libero eget
metus auctor tempus. Curabitur orci, fermentum odio eleifend eget faucibus pulvinar in. Pellentesque
capita morbi tristique senectus and netus and renowned malesuada ac turpis egestas. Morbi porta
Nunc fitness a ultrices. Aliquam ultricies interdum ullamcorper libero vel eros. Nam nibh felis,
adipiscing ut fitness a, hendrerit eget enim. Suspendisse eleifend nibh EU. Curabitur metus erat,
Semper at ultrices ac, mattis at nulla.
[]] >
< / mx:text >
< / mx:Text >
< / mx:VBox >
< / mx:Application >

When resizing the browser horizontally, the VBox changes depending on its width, but when resizing vertically, the VBox remains always at the height of its contents and ignores the ' height = '10% ' "."

Can anyone suggest a way to get the behavior that I'm trying to achieve?

Just wrap a cloth around the VBox:

skider wrote:

I'm using Flex 3. I have a lot of problems with a text component inside a VBox component with percentHeight to put value. The behavior that I'm trying to get, it's the VBox will be a scroll bar that will allow the text to display. The behavior I get, it's that resizes it VBox on the entire height of the text element and does not take into account its percentHeight. I would use a text box instead of a text nested in a VBox, but I need to put other components inside the VBox so I want the VBox to be able to scroll through all of the items inside.

Here is a sample application showing my problem:


http://www.Adobe.com/2006/mxml"layout ="vertical">
  


       
           
                NEC commodo eros ornare non. Vestibule dapibus placerat magna vel imperdiet. Nullam vel libero eget
metus auctor tempus. Curabitur orci, fermentum odio eleifend eget faucibus pulvinar in. Pellentesque
capita morbi tristique senectus and netus and renowned malesuada ac turpis egestas. Morbi porta
Nunc fitness a ultrices. Aliquam ultricies interdum ullamcorper libero vel eros. Nam nibh felis,
adipiscing ut fitness a, hendrerit eget enim. Suspendisse eleifend nibh EU. Curabitur metus erat,
Semper at ultrices ac, mattis at nulla.
]]>
           

       

   


When resizing the browser horizontally, the VBox changes depending on its width, but when resizing vertically, the VBox remains always at the height of its contents and ignores the ' height = '10% ' "."

Can anyone suggest a way to get the behavior that I'm trying to achieve?

Tags: Flex

Similar Questions

  • Height of a VBox with label and wrapped text

    Hello

    I have a VBox with label and text wrapped inside. The sentence in the text are from an external location and load in the text. I want to know the height of the VBox after that the text was being wrapped and place inside the VBox.

    I used all the properties for VBox as getHeight(), getPrefHeight(), getMinHeight() and getMaxHeight(), but these properties give me what I want.

    Is there another property I am missing or is a short coming of VBox?

    If this is a shortcoming of VBox, what other solution do I?

    Thank you

    AA

    You can register a listener with heightProperty() of the vbox and get it when it changes.

  • Question of layout on VBox with different content (bug or not?)

    I don't know if the following behavior is a bug, or scheduled. At least the behavior has changed since 2.2 to the last beta 8.

    I have VBox container. Inside is a ListView and a BorderPane. The content in the center of the BorderPane can be changed between a text box and a WebView. When that happens, the height of the ListView changes. (No additional constraints have been put on one of the nodes).

    I'm not enough of an expert layout of course what happens here. The desired behavior would be that ListView (or across the top of the VBox) has a constant size, does not matter what is in the rest of the VBox. If the observed behavior is intended, how can I get the desired behavior?

    Complete code below.

    package jbugs;
    
    import javafx.application.Application;
    import javafx.stage.Stage;
    import javafx.scene.layout.BorderPane;
    import javafx.scene.control.Button;
    import javafx.event.EventHandler;
    import javafx.event.ActionEvent;
    import javafx.scene.control.ToolBar;
    import javafx.scene.layout.VBox;
    import javafx.scene.control.ListView;
    import javafx.scene.control.TextArea;
    import javafx.scene.web.WebView;
    import javafx.scene.Scene;
    
    public class WebViewLayoutBug extends Application {
    
      public void start(Stage stage) {
    
        BorderPane root = new BorderPane();
    
        Button text = new Button("TextArea");
    
        Button web = new Button("WebView");
        ToolBar toolbar = new ToolBar(text, web);
    
        VBox vb = new VBox();
    
        ListView<String> lv = new ListView<String>();
       
        lv.getItems().addAll("foo", "bar");
    
        final BorderPane bp = new BorderPane();
    
        vb.getChildren().addAll(lv, bp);
    
        final TextArea textArea = new TextArea();
        final WebView webView = new WebView();
    
        text.setOnAction(new EventHandler<ActionEvent>() {
          public void handle(ActionEvent e) {
            bp.setCenter(textArea);
          }
        });
    
        web.setOnAction(new EventHandler<ActionEvent>() {
          public void handle(ActionEvent e) {
            bp.setCenter(webView);
          }
        });
    
        root.setTop(toolbar);
    
        root.setCenter(vb);
       
        stage.setScene(new Scene(root, 800, 600));
        stage.show();
      }
    
    }
    
    

    This has exactly the same for me in 1.7.0_40 JDK and JDK 1.8.0 b109.

    The desired behavior would be that ListView (or across the top of the VBox) has a constant size, does not matter what is in the rest of the VBox. If the observed behavior is intended, how can I get the desired behavior?

        lv.setMinHeight(Control.USE_PREF_SIZE);
        lv.setMaxHeight(Control.USE_PREF_SIZE);
    
  • Layout problem

    I am facing a lot of problems with the layout system which I think is terrible compared to the cascades QtQuick anchoring system. Now, I have this problem: I'm working with a listview that is filled by a remote xml file, I create the listitem for use with.

    It's the source of the listitem:

    Container {
                                    layout: StackLayout {
                                        orientation: LayoutOrientation.LeftToRight
    
                                    }
                                    Container {
                                        }
                                        Label {
                                        }
                                        Label {
                                        }
                                    }
                                    ImageView {
                                        id: imageView
                                    }
                                }
    

    Now in vertical mode, it look like this:

    But horizontal is like this:

    because the text is too short, but I want image will always be on the right. If I use docklayout text is placed over the image and I could not find a way to prevent this.

    Thank you for your help.

    Hello

    To force the outside container take all available space horizontally, set preferredWidth is at infinity.

    A value not zero in his StackLayoutProperties left spaceQuota value of the container.

    Substantive definition of the container to a solid color allows the debug configuration.

  • Div layout problem

    HI - stuck on what I think should be a pretty basic layout problem:

    I have 2 divs, equal widths but different heights, a floating to the left and the other to the right so that they appear next to each other on the page.  The left one contains varying amounts of text, the right one contains a flash player so never varies.

    Where the text of the left div is long, I want that he start next to the player, but then sink under it, rather than continue down to the same width as the div.  If I remove the width of the left div, while it is up to the width of the container, the player div is positioned underneath, so I can't work out how to get the effect.

    Can anyone help?

    Not quite sure what you're trying to accomplish.

    Do you want the green text to wrap around the player, as demonstrated with the Magi here?

    http://ALT-Web.com/demos/CSS2-captions-on-floated-images.shtml

    Nancy O.
    ALT-Web Design & Publishing
    Web | Graphics | Print | Media specialists
    http://ALT-Web.com/
    http://Twitter.com/ALTWEB
    http://ALT-Web.blogspot.com

  • Design layout of text in After Effects or...?

    I need to produce a motion, it displays the menu items and prices (similar to a takeout menu).

    I don't know what the best way to address the issue. Should I create the page layout in After Effects or not?

    If I don't need animate the text, is it more efficient only design in Indesign and exporting as a pdf or image file?

    We greatly appreciate any recommendations or advice?

    I almost always put in page complex text in Illustrator or Photoshop with the text in its final position. It is easier and faster, and there is better alignment tools. If I intend to use animations to text so usually I'll layout of the text in Photoshop, because you can convert text from Photoshop to editable text layers, and, unfortunately, this is not a feature yet implemented in it HAVE - AE workflow. You can get complex projects of text created in Illustrator into Photoshop with editable text layers, if you use the export function in artificial intelligence, but you may need some rearranging layers in Photoshop to get the project to work directly in AE as a model.

    If I was doing something like takeout menu of the restaurant and I wanted to use animations of text I would create the Photoshop document in the aspect ratio of the width of your finished AE comp menu so let's say that the menu real life was 9 X 12 inches, then the Photoshop document would be 1920 X 2560. Layout of your menu with each item of text you want to animate on a separate layer, give up the layer effects, and then import the Photoshop file as a model while the dimensions of the layer, create your text animations using text animations, then nest the menu layout in a standard HD model and animate the position and scale of the menu. I do a lot of this sort of thing and this workflow is much more effective than to try to create a layout of complex text in AE with the limited text tools available.

    I also have a good amount of work in In Design for use in After Effects. That's where you get some really amazing text tools. In the design of Illustrator to PDF, then Illustrator Photoshop via export, then Photoshop for AE as a model.

  • Fields on several Internet sites have been changed in another language. The browser is set to English, and this problem does not occur with Chrome.

    Fields on several Internet sites have been changed in another language. The browser is set to English, and this problem does not occur with Chrome. Specifically, a large part of Tumblr and Facebook menu has been changed in another language (Russian, I think). I tried reinstall Firefox, clear the cache and reset firefox to its default state. None of them helped. Any suggestions on how to fix this?

    Hey again,

    Sometimes a problem with Firefox can be a result of malware installed on your computer, you may not be aware of.

    You can try these free programs to search for malicious software that work with your existing anti-virus software:

    Microsoft Security Essentials is a good permanent antivirus for Windows 7/Vista/XP, if you do not already have one.

    More information can be found in the article troubleshooting Firefox problems caused by malware .

    I hope this helps!

    Curtis

  • Up to version 6.22 of entry and other components HTML texts have been with a width. Now, after installing version 7. The entries have increased in size not more about before defined sizes... You can fix this?

    Up to version 6.22 of entry and other components HTML texts have been with a width. Now, after installing version 7. The entries have increased in size not more about before defined sizes... You can fix this?

    I think it's about the size, just differently than before. See the discussion in:
    https://Bugzilla.Mozilla.org/show_bug.cgi?id=691157

  • I found the solution for the problem of sound-acpi with Satellite P100-219

    Hello

    I found the solution for the problem of sound-acpi with Toshiba P100 (it works with P100-219 at least). I can provide the source modified and compiled table DSDT, but I would like to know if it is possible to get these changes in the next update of the BIOS?

    See you soon,.
    MIK

    Hi Mik

    As you know that it is not possible to find info on the next BIOS, especially if you want to have some information about the Linux operating system. Just wait and see if some forum users pointed out something on the subject.

  • text messages sent with an email address from a touch ipod duplicated on a second ipod touch using a different email address, but the two ipods are controlled by a parent with the same apple ID and password.

    Text messages sent with an email address from a touch ipod duplicated on a second ipod touch using a different email address, but the two ipods are controlled by a parent with the same apple ID and password.  This has happened recently.  My two girls have used their respective ipods and texting, without their messages of duplication for each of the other ipods for more than a year.  Somehow recently, both addresses seem to be synced with them or something, so that both see each and other messages.  I've recently updated two ipods, iTunes on my computer--not the cloud and added music for two ipods, but has not changed anything by email email settings or message I know.  Help, please!

    Welcome to the Apple community.

    I can't fully follow how you have everything set up, but a glance at the settings > messages > send & receive

  • problem of sudden wifi with iphone 4S

    Hello

    a few days ago, my iPhone 4S does not receive more an IP address from a DHCP server, even for all the WIFI networks, with that I use for work.

    WIFI authentication is OK, but is never received from IP (or other information received from the DHCP server).

    Someone at - he already experienced this?

    Any idea?

    Already used the 'forgotten network?' and enter the parameters for connection a couple of times, same result.

    Thank you very much

    Dominique

    Hi dofas,.

    Here are a few troubleshooting steps for the problem you are having with your Wi - Fi connection.  I've highlighted some key information.  Click on the link for more details.

    If your iPhone, iPad or iPod touch connects to a Wi - Fi network
    https://support.Apple.com/en-us/HT204051

    Still not connect?

    Reset your network settings. Tap Settings > General > reset > reset network settings. This resets also Wi - Fi networks and passwords, cell parameters and VPN, and APN settings you used before

    • If you are connected to a Wi - Fi network, but you can't get online, try to use your Wi - Fi network on other devices. If you can't get online using your other devices, there could be an interruption of the service. Call your internet provider cable or the assistance company.
    • Try to connect to a Wi - Fi network in a different location. If your device can connect, you will need to get help with your Wi - Fi network. If it cannot connect to Wi - Fi networks, contact Apple.
    • Update your Wi - Fi router with the latest firmware and check that the router supports your Apple product. For more information, contact the manufacturer of your router.

    Recommended settings for the WiFi routers and access points
    https://support.Apple.com/en-us/HT202068

    DHCP

    The DHCP Dynamic Host Configuration Protocol () assigns addresses that identify devices on your network. Once awarded, devices use these addresses to communicate with each other and with computers on the Internet. The functionality of a DHCP server can be considered similar to a telephone company distributing phone numbers, that clients then use to call other people.

    Value: a single DHCP server by network

    Details: There is only one DHCP server on your network. This DHCP server can be integrated into your modem cable or DSL, a stand-alone, or integrated into your router Wi - Fi router. In all cases, only one device should act as a DHCP server on your network. If several devices has activated, you will probably see to address conflicts and issues of access to the Internet or other resources on your network.

    Take care

  • problems of xbox 360 with windows xp sp3 wireless receiver

    problems of xbox 360 with windows xp sp3 wireless receiver

    Hi Frank Lucas.

    (1) if it works well before?

    (2) remember to make changes?

    (3) you get an error message?

    You can see the steps outlined in the article below

    Troubleshooting your Xbox 360 Controller for Windows

    http://support.Microsoft.com/kb/908888

    You can also post your query on Xbox Forum

    http://forums.Xbox.com/

  • Problem of automatic downloading with a security update? (KB2538242 repeatedly offered)

    original title: problem of automatic downloading with a security update?
    I'm having some trouble with the following security update?

    a security update for Microsoft Visual C++ 2005 Service Pack 1 Redistributable Package (KB2538242)...

    A security issue has been identified in leading to vulnerability MFC application into DLL planting due to not specify the full path to the location/DLL MFC system.  You can protect your computer by installing this update from Microsoft.
    This update repeatedly wants to be downloaded on my computer... and I did it more than once... but again... It is said several times to download. Is this a HACK download or what?

    Thank you for your time...
    Ken Frank

    Hi Ken,

    Check if the update is installed the update history...

    a. open Windows Update by clicking on the button start. In the search box, type Update, and then in the list of results, click Windows Update.

    (b) in the left pane, click view update history.

    I wish that you follow the steps mentioned in the article to resolve the problem.

    Troubleshooting Windows Update or Microsoft Update when you are repeatedly offered an update

  • Problems of internet connectivity with Dell Inspiron 7520 (1703 of Dell Wireless 802.11b/g/n 2.4 ghz)

    Hello

    I bought a Dell Inspiron 7520 for a week now, and I had a strange problem with internet connectivity since then. First, wifi takes a lot of time to connect. After, I'm online, every 10 minutes my network access stops working completely. But if I click on the network icon in the toolbar, it starts working again, but it stops in the next 10 minutes, once again, and so on. If I try to fix connectivity problems, he always find and solve some in the network card or wireless, but then point again, after 10 minutes, or so, it happens again.

    My network card is a Wireless Dell 1703 802.11b/g/n 2.4 ghz and I tried to update and to re - download the firmware, but nothing seems to fix.

    What should I do to fix this?

    Hello friends. Recently I came across the same problem identified by many with a Dell Inspiron 15R laptop 7520 with the Dell Wireless 1703 (Atheros chipset). After losing an entire afternoon and looking at forums and their complaints, I think that I found the solution to the problem (at least, here is running).

    The laptop is connected to a router TP-Link TL-WR740N. The router is configured to run with a frequency of 20 or 40 MHz, making the switch automatically in the factory. The mobile card wireless driver is configured to work only with 20 MHz at the factory. But can be configured to work with two frequencies is adapted automatically. To do this, change the configuration (in Windows 7):

    Start > Control Panel > Device Manager > network adapters > Dell Wireless 1703 802.11b/g/n (2,4 GHz) > click the Advanced tab > select 802.11n bandwidth. Change the value of Auto 20 MHz / 40 MHz.

    Press OK and wait for to reconnect you.

    I hope this helps.

    Jeferson Vasconcellos

  • Problems of huge performance with the list of scrolling on the Playbook (especially Air applications)

    Hello

    It is more of a general question but also for the development of Air for the Playbook and other devices BB10.

    My Playbook has huge performance problems when it comes to scrolling lists.

    And this problem exists with almost all applications (not the ones that I have developed).

    For example, take a look at the app NTV - such its bad, its almost unusable because it's so late when scrolling lists.

    I don't know how this app was developed, but I guess it's Webworks or Air.

    You can see this delay also in the official app of Facebook: it's the same poor performance when it comes to scrolling.

    I guess this Facebook app is also WebWorks or Air.

    So Air or usable at all WebWorks?

    This performance is not fun, and it has no sense to develop applications with this platforms if these performance issues are of type platform.

    Now, my question is - is it true that the only platform that "really works at all" (about performance) is the native "platform"?

    Or is it a problem in the current version of the Playbook OS?

    Else you have noticed that this operation met during the scrolling of lists?

    Thank you

    Bullety

    It's a question AIR, specifically made software. All of the applications you listed are AIR. Try something like Scrapbook, and you see things how smooth can be (waterfalls).

    I saw not the same problems when using WebWorks with Sencha Touch. It is also quite possible to make things smooth in the NDK with waterfalls, but it's only for BB10 (for developers non - RIM). So cannot use it PB BB10 release (end of 2012).

    I also note that the new fuse QNX user interface components are much smoother than conventional QNX UI components. If you use make sure you air that you use.

Maybe you are looking for