Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. [Solved]Very strong error in QSplitter
QtWS25 Last Chance

[Solved]Very strong error in QSplitter

Scheduled Pinned Locked Moved General and Desktop
6 Posts 3 Posters 4.2k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    Ruzik
    wrote on last edited by
    #1

    Hellow, i have slpitter, i set style sheet to it, add some widgets and when i compile it i see it:
    !http://hostingkartinok.com/image/01201109/d0eddbdce4b2e213722d7aa6f74b6dad.png(first)!
    After it i copy exe file in my desktop, open it and see it
    !http://hostingkartinok.com/image/01201109/bdd7e19ce54941558b698cf271d3eae9.png(second)!
    @QSplitter * splitter;
    splitter = new QSplitter(this);
    splitter->setOrientation(Qt::Horizontal);
    graphicsPlot = new RGraphicsPlot;
    functionList = new RFunctionListWidget(this);

    splitter->addWidget(functionList);
    splitter->addWidget(graphicsPlot);
    horizontalLayout_2->addWidget(splitter);
    //
    splitter->restoreState(settings.value("graphics//splitterSizes").toByteArray());
    //
    //and in global style sheet QWidget{ background: transparent;}
    splitter->setStyleSheet("QSplitter::handle{image: url(:/images/Resources/Images/slpitter.png);}");
    splitter->setFixedWidth(3);@
    I try without styleSheet, try delete ini file with splitter's state before opening, try compile in debug and release, and if i open .exe file in release folder i get second result, i thing: "maybe it is because of differnt dlls", but i use 4.7.3 qt and 4.7.3 dlls
    In advance thank you for your help!

    1 Reply Last reply
    0
    • R Offline
      R Offline
      Ruzik
      wrote on last edited by
      #2

      I use MSVC 2008 compiler and Visual studio for develop

      1 Reply Last reply
      0
      • K Offline
        K Offline
        koahnig
        wrote on last edited by
        #3

        Hi Ruzik

        apparently you have just typed the links into your post. So, the link is only shown in the post.
        If you would use the picture link button, which should be the sixth from the left above your post window, the pictures are shown directly in your post.

        This makes it easier for people to view your post. Actually I have seen it yesterday, but the pure links were my reason not to follow.

        Unfortunately, besides this formatting tip for your post, I cannot really contribute. I am typically fighting myself to get the window sizing in a way I like. :-(

        Vote the answer(s) that helped you to solve your issue(s)

        1 Reply Last reply
        0
        • R Offline
          R Offline
          Ruzik
          wrote on last edited by
          #4

          I change it, sorry for i dont do it before

          1 Reply Last reply
          0
          • G Offline
            G Offline
            giesbert
            wrote on last edited by
            #5

            Hi Ruzik,

            can you comment the line 11 (splitter->restoreState) just to check if it works then?

            Nokia Certified Qt Specialist.
            Programming Is Like Sex: One mistake and you have to support it for the rest of your life. (Michael Sinz)

            1 Reply Last reply
            0
            • R Offline
              R Offline
              Ruzik
              wrote on last edited by
              #6

              If i do it i get second result agter compile, thats why i get first result after compile
              And i find my how i can do it:
              @ splitter->setStyleSheet("QSplitter::handle{image: url(:/images/Resources/Images/slpitter.png);}"
              "QSplitter { width: 5px; }");
              //splitter->setFixedWidth(3);@
              the problem turned so easy :)
              Many thanks for your help!!

              1 Reply Last reply
              0

              • Login

              • Login or register to search.
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • Users
              • Groups
              • Search
              • Get Qt Extensions
              • Unsolved