Results 1 to 3 of 3

Thread: Stacked Curves - QwtPlotMultiBarChart

  1. #1
    Join Date
    May 2013
    Location
    Melbourne
    Posts
    36
    Thanks
    2
    Thanked 3 Times in 3 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Stacked Curves - QwtPlotMultiBarChart

    Hallo,
    I wanted to plot multiple curves in stacked form. Using QwtPlotMultiBarChart (& following qwt example code) I have achieved as shown in Screenshot.png. But I would like to have continuous curves as in StackedCurvedSurface.png. I was thinking of using sample width of bars to a very small value can do the job but couldn't figure out the code. Or, is there any other way to do that?

    Any help would be greatly appreciated.

    StackedCurveSurface.pngScreenshot.jpg

  2. #2
    Join Date
    Feb 2006
    Location
    Munich, Germany
    Posts
    3,291
    Thanked 876 Times in 824 Posts
    Qt products
    Qt3 Qt4 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: Stacked Curves - QwtPlotMultiBarChart

    Use 3 QwtPlotCurves with a brush to fill the area below the curve. Do the stacking by summing up the y coordinates. Use QwtPlotItem::setZ() to control the drawing order of the curves ( blue -> green -> red ).

    Uwe

  3. #3
    Join Date
    May 2013
    Location
    Melbourne
    Posts
    36
    Thanks
    2
    Thanked 3 Times in 3 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: Stacked Curves - QwtPlotMultiBarChart

    That's fantastic Uwe! It didn't come in my mind! It's working fine now.

Similar Threads

  1. problem in stacked widget
    By wagmare in forum Qt Programming
    Replies: 4
    Last Post: 24th February 2009, 08:28
  2. Stacked widget mouse propagation
    By bunjee in forum Qt Programming
    Replies: 3
    Last Post: 14th November 2008, 17:54
  3. Stacked Widget Scroll
    By csvivek in forum Qt Programming
    Replies: 6
    Last Post: 27th May 2008, 11:36
  4. Stacked Layout. & Widget.
    By csvivek in forum Qt Programming
    Replies: 1
    Last Post: 13th May 2008, 08:56
  5. Acces a stacked widget...?
    By ucomesdag in forum Qt Programming
    Replies: 5
    Last Post: 25th November 2006, 14:05

Bookmarks

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.