Results 1 to 2 of 2

Thread: Unwanted white border

  1. #1
    Join Date
    Jan 2013
    Location
    England
    Posts
    13
    Thanks
    7
    Qt products
    Qt5
    Platforms
    Windows

    Default Unwanted white border

    Hello,

    I seem to be getting an unwanted white border between my background image and my widget windowframe.

    I have tried different methods of setting the background, Stylesheet, palette etc but with no success

    When i have used the background image before, it has fit perfectly without problem - but with the white border, the text and buttons are out of place in the theme.

    My widget size is the same as the size of my background image, i have tried changing that with no success.

    I am using:

    Qt Code:
    1.  
    2. Appsize(1200,650);
    3.  
    4.  
    5. this -> resize(Appsize);
    6. this -> setFixedSize(Appsize);
    To copy to clipboard, switch view to plain text mode 


    instead of

    Qt Code:
    1. MyWidget -> resize(Appsize);
    2. MyWidget -> setFixedSize(Appsize);
    To copy to clipboard, switch view to plain text mode 

    I dont suppose that this could effect it? I am using 'this' because when I use 'MyWidget' the widget is opened at the bottom right corner of my screen (Is there any way of making it open in the center as it does when I use 'this' - and why is it different?)

    Thanks in advance, i really appreciate the help!

  2. #2
    Join Date
    Mar 2011
    Location
    Hyderabad, India
    Posts
    1,882
    Thanks
    3
    Thanked 452 Times in 435 Posts
    Qt products
    Qt4 Qt5
    Platforms
    MacOS X Unix/X11 Windows
    Wiki edits
    15

    Default Re: Unwanted white border

    I dont suppose that this could effect it?
    Yes they can, unless MyWidget == this.

    Where do you use "this" based code ?
    and
    Where do you use "MyWidget" based code ?
    When you know how to do it then you may do it wrong.
    When you don't know how to do it then it is not that you may do it wrong but you may not do it right.

Similar Threads

  1. Replies: 10
    Last Post: 9th September 2013, 15:29
  2. Replies: 2
    Last Post: 21st March 2012, 14:30
  3. Replies: 1
    Last Post: 12th November 2011, 10:11
  4. QTreeView and unwanted scrollbar
    By theprobe in forum Qt Programming
    Replies: 2
    Last Post: 12th January 2011, 08:19
  5. QGraphicsView unwanted margin
    By hheld in forum Qt Programming
    Replies: 4
    Last Post: 3rd January 2011, 17:16

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.