Results 1 to 2 of 2

Thread: Widget to edit a QGradient

  1. #1
    Join Date
    Jun 2015
    Qt products
    MacOS X Unix/X11 Windows Symbian S60

    Default Widget to edit a QGradient

    Hello all,
    I'm new to PyQt and wondering how I can create a widget to edit a QGradient like in teh picture below

    So far I have been thinking at using a QGraphicView and drawing all items on it, making the markers movable.
    Is there a better (i.e. simpler) way?


  2. #2
    Join Date
    Jan 2006
    Graz, Austria
    Thanked 1,545 Times in 1,495 Posts
    Qt products
    Qt3 Qt4 Qt5
    Unix/X11 Windows

    Default Re: Widget to edit a QGradient

    That's probably the easiest way, given that most of the mouse handling for dragging the markers/handles is already covered by the graphics view framework.


Similar Threads

  1. Widget to edit envelope profile
    By mastupristi in forum Qt Programming
    Replies: 1
    Last Post: 14th October 2014, 21:31
  2. QGradient on triangle
    By oogolov in forum Qt Programming
    Replies: 3
    Last Post: 20th June 2012, 19:34
  3. drawLine with QGradient is slow
    By D.Dupuis in forum Qt Programming
    Replies: 0
    Last Post: 7th December 2011, 12:35
  4. HistogramItem and Qgradient
    By OverTheOCean in forum Qwt
    Replies: 4
    Last Post: 27th August 2010, 02:59
  5. Problems with painting a Qgradient
    By sacrif in forum Newbie
    Replies: 4
    Last Post: 20th January 2010, 16:27


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.