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. QPen: dashPattern to define a continuous line
Forum Updated to NodeBB v4.3 + New Features

QPen: dashPattern to define a continuous line

Scheduled Pinned Locked Moved General and Desktop
3 Posts 2 Posters 900 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.
  • 3 Offline
    3 Offline
    3nids
    wrote on last edited by
    #1

    Hi all,

    I wonder what to do to define a continuous line using QPen::setDashPattern.

    I tried (1,0) without success.

    Is this feasible???

    Thanks a lot!

    1 Reply Last reply
    0
    • sierdzioS Offline
      sierdzioS Offline
      sierdzio
      Moderators
      wrote on last edited by
      #2

      Why use a dash pattern when you want a solid line? Just use QPen(Qt::SolidLine).

      (Z(:^

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

        Hi,
        I agree. But in an API, I want to allow users to use setDashPattern. And I would like to be able to go back to a solid line. Hence, having a combination for this is useful.

        It would avoid me to add another method like setSolid.

        Cheers.

        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