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. How to customize the Qt:BDiagPattern(widen the lines)
QtWS25 Last Chance

How to customize the Qt:BDiagPattern(widen the lines)

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

    Hi All,

    I need implement the style as below link(please ignore the text), but Qt:BDiagPattern can not reach my requirements. Does anyone know how to implement this?

    http://i43.tinypic.com/se4ob8.png

    Thanks in advance,
    Songtao

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi and welcome to devnet,

      IIRC you have to set the pen color and width of painter before applying the pattern and you should be good

      Hope it helps

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

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

        Hi SGaist,

        Thanks for your reply. Unfortunately, it does NOT work. From my current investiagtion, the pattern is not related to Qpen, but related to QBrush.

        Do you have any idea on it?

        Thanks a lot,
        Songtao

        1 Reply Last reply
        0
        • SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #4

          Indeed, I've mixed up two things from memory, sorry.

          What you can do however is create a texture that contains the pattern looking like you want and then use it with the brush

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          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