Results 1 to 3 of 3

Thread: Selecting and changing QwtColumnSymbol in a QwtPlotBarChart

  1. #1
    Join Date
    Apr 2014
    Posts
    13
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default Selecting and changing QwtColumnSymbol in a QwtPlotBarChart

    Hi,

    I wonder if it is possible to use QwtColumnSymbol/QwtPlotBarChart to not only show a bar chart, but to manipulate it. I want to select one or more QwtColumnSymbols with the mouse and change their heights. Is this possible with these classes or should I better change to QwtPlotItems?

    Thanks,
    Carsten

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

    Default Re: Selecting and changing QwtColumnSymbol in a QwtPlotBarChart

    Well, for such an editor you need to know the geometry of the bars. The code for calculating them can be found in QwtPlotBarChart::drawSample - guess I should make a QwtPlotBarChart::columnRect() method - the maps you need for this calculation are available using QwtPlot::canvasMap().

    When implementing your own type of bar chart somehow based on QwtColumnSymbol wouldn't IMHO change the situation.

    Uwe

  3. #3
    Join Date
    Apr 2014
    Posts
    13
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default Re: Selecting and changing QwtColumnSymbol in a QwtPlotBarChart

    Thanks Uwe, this works. And indeed, a funktion like QwtPlotBarChart::columnRect(int index) would really be helpful for this case

    Best regards,
    Carsten

Similar Threads

  1. Replies: 1
    Last Post: 26th May 2015, 08:34
  2. Replies: 2
    Last Post: 2nd September 2013, 17:03
  3. QSlider: changing the groove without changing the handle
    By Olivier Berten in forum Qt Programming
    Replies: 3
    Last Post: 30th April 2013, 11:02
  4. Selecting QGraphicsItems
    By SixDegrees in forum Qt Programming
    Replies: 3
    Last Post: 20th September 2010, 13:55
  5. Replies: 2
    Last Post: 10th August 2009, 10:45

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.