Changeset 8127 in ntrip for trunk/BNC/qwt/qwt_plot_dict.cpp


Ignore:
Timestamp:
May 10, 2017, 3:20:54 PM (7 years ago)
Author:
stoecker
Message:

update qwt and qwtpolar, many QT5 fixes (unfinished)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/BNC/qwt/qwt_plot_dict.cpp

    r4271 r8127  
    6464
    6565   Auto deletion is enabled.
    66    \sa setAutoDelete(), attachItem()
     66   \sa setAutoDelete(), QwtPlotItem::attach()
    6767*/
    6868QwtPlotDict::QwtPlotDict()
     
    7575   Destructor
    7676
    77    If autoDelete is on, all attached items will be deleted
    78    \sa setAutoDelete(), autoDelete(), attachItem()
     77   If autoDelete() is on, all attached items will be deleted
     78   \sa setAutoDelete(), autoDelete(), QwtPlotItem::attach()
    7979*/
    8080QwtPlotDict::~QwtPlotDict()
     
    9090   in the destructor of QwtPlotDict. The default value is on.
    9191
    92    \sa autoDelete(), attachItem()
     92   \sa autoDelete(), insertItem()
    9393*/
    9494void QwtPlotDict::setAutoDelete( bool autoDelete )
     
    9999/*!
    100100   \return true if auto deletion is enabled
    101    \sa setAutoDelete(), attachItem()
     101   \sa setAutoDelete(), insertItem()
    102102*/
    103103bool QwtPlotDict::autoDelete() const
     
    107107
    108108/*!
    109    Attach/Detach a plot item
     109  Insert a plot item
    110110
    111    Attached items will be deleted in the destructor,
    112    if auto deletion is enabled (default). Manually detached
    113    items are not deleted.
     111  \param item PlotItem
     112  \sa removeItem()
     113 */
     114void QwtPlotDict::insertItem( QwtPlotItem *item )
     115{
     116    d_data->itemList.insertItem( item );
     117}
    114118
    115    \param item Plot item to attach/detach
    116    \ on If true attach, else detach the item
     119/*!
     120  Remove a plot item
    117121
    118    \sa setAutoDelete(), ~QwtPlotDict()
    119 */
    120 void QwtPlotDict::attachItem( QwtPlotItem *item, bool on )
     122  \param item PlotItem
     123  \sa insertItem()
     124 */
     125void QwtPlotDict::removeItem( QwtPlotItem *item )
    121126{
    122     if ( on )
    123         d_data->itemList.insertItem( item );
    124     else
    125         d_data->itemList.removeItem( item );
     127    d_data->itemList.removeItem( item );
    126128}
    127129
     
    168170/*!
    169171  \return List of all attached plot items of a specific type.
     172  \param rtti See QwtPlotItem::RttiValues
    170173  \sa QwtPlotItem::rtti()
    171174*/
Note: See TracChangeset for help on using the changeset viewer.