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]Rounded corners of outer most frame
Forum Updated to NodeBB v4.3 + New Features

[Solved]Rounded corners of outer most frame

Scheduled Pinned Locked Moved General and Desktop
qml round radiu
4 Posts 2 Posters 3.9k Views 2 Watching
  • 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.
  • P Offline
    P Offline
    PP99
    wrote on last edited by PP99
    #1

    Is it possible to achieve rounded corners at the outermost frame? I have managed to remove Windows default border, menu bar, title etc.
    I am trying to achieve it using QML, Background image, Rectangle and its property:Radius. I use a rectangle as child of item and get the effect however I want the main container to be curved at corners. Want to achieve this .
    I am just starting out on Qt. Thanks for your time.

    p3c0P 1 Reply Last reply
    0
    • P PP99

      Is it possible to achieve rounded corners at the outermost frame? I have managed to remove Windows default border, menu bar, title etc.
      I am trying to achieve it using QML, Background image, Rectangle and its property:Radius. I use a rectangle as child of item and get the effect however I want the main container to be curved at corners. Want to achieve this .
      I am just starting out on Qt. Thanks for your time.

      p3c0P Offline
      p3c0P Offline
      p3c0
      Moderators
      wrote on last edited by
      #2

      Hi @PP99 and Welcome,
      Try out the following:

      import QtQuick 2.4
      import QtQuick.Window 2.2
      
      Window {
          width: 400
          height: 400
          flags: Qt.FramelessWindowHint
          color: "transparent"
      
          Rectangle {
              x: 10
              y: 10
              width: parent.width-20
              height: parent.height-20
              radius: 15
          }
      }
      

      157

      1 Reply Last reply
      2
      • P Offline
        P Offline
        PP99
        wrote on last edited by
        #3

        Thank you very much. It works.

        p3c0P 1 Reply Last reply
        0
        • P PP99

          Thank you very much. It works.

          p3c0P Offline
          p3c0P Offline
          p3c0
          Moderators
          wrote on last edited by
          #4

          @PP99 You're Welcome :). Please mark the post as solved. You will need to edit the post title and prepend [Solved].

          157

          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