Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. CheckBox in TableViewColumn
Forum Updated to NodeBB v4.3 + New Features

CheckBox in TableViewColumn

Scheduled Pinned Locked Moved Unsolved QML and Qt Quick
7 Posts 3 Posters 1.4k Views 1 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.
  • A Offline
    A Offline
    Arkning
    wrote on last edited by Arkning
    #1

    Hi,

    I wanted to make the CehckBox fill the size of the row of the TableViewColumn, I tried but diidn't make it ^^ that's why i'm asking for help.

    Thanks in advance for your answer.

    1 Reply Last reply
    0
    • dheerendraD Offline
      dheerendraD Offline
      dheerendra
      Qt Champions 2022
      wrote on last edited by
      #2

      Can u show me image or sample code u tried ?

      Dheerendra
      @Community Service
      Certified Qt Specialist
      http://www.pthinks.com

      A 1 Reply Last reply
      0
      • dheerendraD dheerendra

        Can u show me image or sample code u tried ?

        A Offline
        A Offline
        Arkning
        wrote on last edited by
        #3

        @dheerendra TableViewColumn {
        width: view.width / 4
        movable: false
        resizable: false
        delegate: CheckBox { }
        }

        But when I do anchors.fill: parent inside CheckBox it doesn't change anything

        1 Reply Last reply
        0
        • P Offline
          P Offline
          Pou Lin Chang
          wrote on last edited by
          #4

          @Arkning you do mean that you want the QCheckbox to take the entire space of the row in the TableViewColumn ?

          A 1 Reply Last reply
          1
          • P Pou Lin Chang

            @Arkning you do mean that you want the QCheckbox to take the entire space of the row in the TableViewColumn ?

            A Offline
            A Offline
            Arkning
            wrote on last edited by
            #5

            @Pou-Lin-Chang exactly

            P 1 Reply Last reply
            1
            • A Arkning

              @Pou-Lin-Chang exactly

              P Offline
              P Offline
              Pou Lin Chang
              wrote on last edited by Pou Lin Chang
              #6

              @Arkning
              I have some more questions.

              1. what kind of Layout are you using to create your TableViewColumn ? QGridLayout ?
              2. you creating a QCheckBox with a label or just the QCheckbox ?

              if it's just the QCheckBox, then i believe you can't increase the size of the checkbox, it got its default size and we cant increase or expand it. But yeah you can create your own customize checkbox but i believe that will be tedious.

              if it's with the label and you are using QGridlayout than you can span your row.

              A 1 Reply Last reply
              1
              • P Pou Lin Chang

                @Arkning
                I have some more questions.

                1. what kind of Layout are you using to create your TableViewColumn ? QGridLayout ?
                2. you creating a QCheckBox with a label or just the QCheckbox ?

                if it's just the QCheckBox, then i believe you can't increase the size of the checkbox, it got its default size and we cant increase or expand it. But yeah you can create your own customize checkbox but i believe that will be tedious.

                if it's with the label and you are using QGridlayout than you can span your row.

                A Offline
                A Offline
                Arkning
                wrote on last edited by
                #7

                @Pou-Lin-Chang I'm using a ColumnLayout, and I guess it just a QCheckbox (There is a sample of my code above)

                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