Results 1 to 2 of 2

Thread: QT 4.8 Layout Problem

  1. #1
    Join Date
    Feb 2015
    Posts
    6
    Qt products
    Qt4

    Default QT 4.8 Layout Problem

    Hi,

    I add a widget, and an existing layout into the main layout as follows,

    QHBoxLayout* l = new QHBoxLayout();
    l->setMargin( 2 );
    l->setSpacing( 5 ) );
    l->addWidget( txtLabel ); // seen on the main layout in QT 4.8
    l->addLayout( mLayout, 1 ); // not seen on the main layout in QT 4.8
    layout()->insertLayout(0,l);

    The above code block works OK with 4.1, but it does not work OK with QT4.8. Could you please help about this difference ?

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: QT 4.8 Layout Problem

    What exactly is "not seen"? Layouts do not have any visual appearance. Where exactly is this something "not seen"? What is this "main layout"? Where do you apply it?
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


Similar Threads

  1. Layout problem
    By baluk in forum Newbie
    Replies: 7
    Last Post: 24th October 2010, 06:21
  2. Problem with layout!
    By sang in forum Qt Programming
    Replies: 2
    Last Post: 24th August 2010, 21:01
  3. Problem with layout
    By franco.amato in forum Qt Programming
    Replies: 3
    Last Post: 18th December 2009, 19:32
  4. QT Layout problem
    By bod in forum Qt Programming
    Replies: 1
    Last Post: 1st July 2008, 13:29
  5. Layout Problem
    By Seema Rao in forum Qt Programming
    Replies: 4
    Last Post: 19th April 2006, 11:08

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.