2015-07-11 18:56:02 +08:00
/*
2019-01-12 23:01:55 +08:00
Copyright ( c ) 2008 - 2019 Jan W . Krieger ( < jan @ jkrieger . de > )
2015-07-11 18:56:02 +08:00
2015-07-12 22:34:27 +08:00
2015-07-11 18:56:02 +08:00
This software is free software : you can redistribute it and / or modify
it under the terms of the GNU Lesser General Public License ( LGPL ) as published by
the Free Software Foundation , either version 2 of the License , or
( at your option ) any later version .
This program is distributed in the hope that it will be useful ,
but WITHOUT ANY WARRANTY ; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE . See the
GNU Lesser General Public License ( LGPL ) for more details .
You should have received a copy of the GNU Lesser General Public License ( LGPL )
along with this program . If not , see < http : //www.gnu.org/licenses/>.
*/
# include <QString>
# include <QPainter>
# include <QPair>
2018-11-26 03:25:44 +08:00
# include "jkqtplottertools/jkqtptools.h"
# include "jkqtplottertools/jkqtp_imexport.h"
2018-12-19 00:13:18 +08:00
# include "jkqtplottertools/jkqtpdrawingtools.h"
# include "jkqtplotter/jkqtpgraphsbase.h"
# include "jkqtplottertools/jkqtpenhancedpainter.h"
2015-07-11 18:56:02 +08:00
2018-12-19 00:13:18 +08:00
# ifndef jkqtpgraphs_H
# define jkqtpgraphs_H
2015-07-11 18:56:02 +08:00
// forward declarations
2019-01-20 17:49:29 +08:00
class JKQTBasePlotter ;
2019-01-20 23:15:10 +08:00
class JKQTPlotter ;
2019-01-20 17:49:29 +08:00
class JKQTPCoordinateAxis ;
class JKQTPDatastore ;
2015-07-11 18:56:02 +08:00
//class JKQTPColorPaletteTools;
/*! \brief This implements xy line plots. This also alows to draw symbols at the data points.
2019-02-03 21:04:48 +08:00
\ ingroup jkqtplotter_linesymbolgraphs_simple
2015-07-11 18:56:02 +08:00
\ image html plot_lineplots . png
*/
2019-02-03 21:04:48 +08:00
class JKQTP_LIB_EXPORT JKQTPXYLineGraph : public JKQTPXYGraph {
2015-07-11 18:56:02 +08:00
Q_OBJECT
public :
/** \brief class constructor */
2019-01-20 17:49:29 +08:00
JKQTPXYLineGraph ( JKQTBasePlotter * parent = nullptr ) ;
2015-08-02 19:36:54 +08:00
/** \brief class constructor */
2019-01-20 23:15:10 +08:00
JKQTPXYLineGraph ( JKQTPlotter * parent ) ;
2015-07-11 18:56:02 +08:00
/** \brief plots the graph to the plotter object specified as parent */
2018-12-28 05:52:00 +08:00
virtual void draw ( JKQTPEnhancedPainter & painter ) override ;
2015-07-11 18:56:02 +08:00
/** \brief plots a key marker inside the specified rectangle \a rect */
2018-12-28 05:52:00 +08:00
virtual void drawKeyMarker ( JKQTPEnhancedPainter & painter , QRectF & rect ) override ;
2015-07-11 18:56:02 +08:00
/** \brief returns the color to be used for the key label */
2018-12-28 05:52:00 +08:00
virtual QColor getKeyLabelColor ( ) override ;
2015-07-11 18:56:02 +08:00
2019-01-26 20:00:40 +08:00
/*! \brief sets the property color ( \copybrief color ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter color is : < BLOCKQUOTE > \ copydoc color < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see color for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setColor ( const QColor & __value )
2019-01-10 04:23:24 +08:00
{
this - > color = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property color ( \copybrief color ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter color is : < BLOCKQUOTE > \ copydoc color < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see color for more information */
2019-01-26 20:00:40 +08:00
inline virtual QColor getColor ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > color ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property fillColor ( \copybrief fillColor ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter fillColor is : < BLOCKQUOTE > \ copydoc fillColor < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see fillColor for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setFillColor ( const QColor & __value )
2019-01-10 04:23:24 +08:00
{
this - > fillColor = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property fillColor ( \copybrief fillColor ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter fillColor is : < BLOCKQUOTE > \ copydoc fillColor < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see fillColor for more information */
2019-01-26 20:00:40 +08:00
inline virtual QColor getFillColor ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > fillColor ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property style ( \copybrief style ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter style is : < BLOCKQUOTE > \ copydoc style < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see style for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setStyle ( const Qt : : PenStyle & __value )
2019-01-10 04:23:24 +08:00
{
this - > style = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property style ( \copybrief style ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter style is : < BLOCKQUOTE > \ copydoc style < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see style for more information */
2019-01-26 20:00:40 +08:00
inline virtual Qt : : PenStyle getStyle ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > style ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property lineWidth ( \copybrief lineWidth ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter lineWidth is : < BLOCKQUOTE > \ copydoc lineWidth < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see lineWidth for more information */
2019-01-26 03:16:04 +08:00
inline virtual void setLineWidth ( double __value )
2019-01-10 04:23:24 +08:00
{
this - > lineWidth = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property lineWidth ( \copybrief lineWidth ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter lineWidth is : < BLOCKQUOTE > \ copydoc lineWidth < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see lineWidth for more information */
2019-01-26 03:16:04 +08:00
inline virtual double getLineWidth ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > lineWidth ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property symbol ( \copybrief symbol ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter symbol is : < BLOCKQUOTE > \ copydoc symbol < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see symbol for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setSymbol ( const JKQTPGraphSymbols & __value )
2019-01-10 04:23:24 +08:00
{
this - > symbol = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property symbol ( \copybrief symbol ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter symbol is : < BLOCKQUOTE > \ copydoc symbol < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see symbol for more information */
2019-01-26 20:00:40 +08:00
inline virtual JKQTPGraphSymbols getSymbol ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > symbol ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property symbolWidth ( \copybrief symbolWidth ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter symbolWidth is : < BLOCKQUOTE > \ copydoc symbolWidth < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see symbolWidth for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setSymbolWidth ( double __value )
2019-01-10 04:23:24 +08:00
{
this - > symbolWidth = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property symbolWidth ( \copybrief symbolWidth ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter symbolWidth is : < BLOCKQUOTE > \ copydoc symbolWidth < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see symbolWidth for more information */
2019-01-26 20:00:40 +08:00
inline virtual double getSymbolWidth ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > symbolWidth ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property symbolSize ( \copybrief symbolSize ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter symbolSize is : < BLOCKQUOTE > \ copydoc symbolSize < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see symbolSize for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setSymbolSize ( double __value )
2019-01-10 04:23:24 +08:00
{
this - > symbolSize = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property symbolSize ( \copybrief symbolSize ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter symbolSize is : < BLOCKQUOTE > \ copydoc symbolSize < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see symbolSize for more information */
2019-01-26 20:00:40 +08:00
inline virtual double getSymbolSize ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > symbolSize ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property drawLine ( \copybrief drawLine ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter drawLine is : < BLOCKQUOTE > \ copydoc drawLine < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see drawLine for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setDrawLine ( bool __value )
2019-01-10 04:23:24 +08:00
{
this - > drawLine = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property drawLine ( \copybrief drawLine ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter drawLine is : < BLOCKQUOTE > \ copydoc drawLine < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see drawLine for more information */
2019-01-26 20:00:40 +08:00
inline virtual bool getDrawLine ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > drawLine ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property drawSelectionLine ( \copybrief drawSelectionLine ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter drawSelectionLine is : < BLOCKQUOTE > \ copydoc drawSelectionLine < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see drawSelectionLine for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setDrawSelectionLine ( bool __value )
2019-01-10 04:23:24 +08:00
{
this - > drawSelectionLine = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property drawSelectionLine ( \copybrief drawSelectionLine ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter drawSelectionLine is : < BLOCKQUOTE > \ copydoc drawSelectionLine < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see drawSelectionLine for more information */
2019-01-26 20:00:40 +08:00
inline virtual bool getDrawSelectionLine ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > drawSelectionLine ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property selectionLineColor ( \copybrief selectionLineColor ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter selectionLineColor is : < BLOCKQUOTE > \ copydoc selectionLineColor < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see selectionLineColor for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setSelectionLineColor ( const QColor & __value )
2019-01-10 04:23:24 +08:00
{
this - > selectionLineColor = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property selectionLineColor ( \copybrief selectionLineColor ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter selectionLineColor is : < BLOCKQUOTE > \ copydoc selectionLineColor < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see selectionLineColor for more information */
2019-01-26 20:00:40 +08:00
inline virtual QColor getSelectionLineColor ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > selectionLineColor ;
}
2015-07-11 18:56:02 +08:00
protected :
/** \brief if \c true, draws a thick shadow around the line*/
bool drawSelectionLine ;
/** \brief color for the shadow, or a lighter version of the line color, if transparent (default) */
QColor selectionLineColor ;
2019-01-26 03:16:04 +08:00
/** \brief which plot style to use from the parent plotter (via JKQTBasePlotter::getPlotStyle() and JKQTBasePlotter::getNextStyle() ) */
2015-07-11 18:56:02 +08:00
int parentPlotStyle ;
/** \brief color of the graph */
QColor color ;
/** \brief color of the graph fill */
QColor fillColor ;
/** \brief linestyle of the graph lines */
Qt : : PenStyle style ;
2019-01-20 23:15:10 +08:00
/** \brief width (pixels) of the graph, given in pt */
2015-07-11 18:56:02 +08:00
double lineWidth ;
/** \brief which symbol to use for the datapoints */
2019-01-20 17:49:29 +08:00
JKQTPGraphSymbols symbol ;
2019-01-20 23:15:10 +08:00
/** \brief size (diameter in pt) of the symbol for the data points, given in pt */
2015-07-11 18:56:02 +08:00
double symbolSize ;
2019-01-20 23:15:10 +08:00
/** \brief width (in pt) of the lines used to plot the symbol for the data points, given in pt */
2015-07-11 18:56:02 +08:00
double symbolWidth ;
/** \brief indicates whether to draw a line or not */
bool drawLine ;
QPen getLinePen ( JKQTPEnhancedPainter & painter ) const ;
QPen getSymbolPen ( JKQTPEnhancedPainter & painter ) const ;
QBrush getBrush ( JKQTPEnhancedPainter & painter ) const ;
} ;
2019-01-20 17:49:29 +08:00
/*! \brief This implements xy scatter plots (like JKQTPXYLineGraph), but the color and size of the symbols may be taken from a column.
2019-02-03 21:04:48 +08:00
\ ingroup jkqtplotter_linesymbolgraphs_param
2015-07-11 18:56:02 +08:00
set the properties sizeColumn and / or colorColumn to change the size and / or color of the symbols according to the values in the column .
2019-01-29 05:14:27 +08:00
\ image html jkqtplotter_simpletest_paramscatterplot . png " Different Styles of Parametrized Scatter/Line Graphs "
\ image html jkqtplotter_simpletest_paramscatterplot_image_star . png " JKQTPXYParametrizedScatterGraph with symbols organized in a grid "
\ see JKQTPXYParametrizedErrorScatterGraph , \ ref JKQTPlotterParamScatter , \ ref JKQTPlotterParamScatterImage
*/
2019-02-03 21:04:48 +08:00
class JKQTP_LIB_EXPORT JKQTPXYParametrizedScatterGraph : public JKQTPXYLineGraph , public JKQTPColorPaletteTools {
2015-07-11 18:56:02 +08:00
Q_OBJECT
public :
/** \brief class constructor */
2019-01-20 17:49:29 +08:00
JKQTPXYParametrizedScatterGraph ( JKQTBasePlotter * parent = nullptr ) ;
2015-08-02 19:36:54 +08:00
/** \brief class constructor */
2019-01-20 23:15:10 +08:00
JKQTPXYParametrizedScatterGraph ( JKQTPlotter * parent ) ;
2015-07-11 18:56:02 +08:00
/** \brief plots the graph to the plotter object specified as parent */
2018-12-28 05:52:00 +08:00
virtual void draw ( JKQTPEnhancedPainter & painter ) override ;
2018-12-16 21:59:39 +08:00
/** \brief plots a key marker inside the specified rectangle \a rect */
2018-12-28 05:52:00 +08:00
virtual void drawKeyMarker ( JKQTPEnhancedPainter & painter , QRectF & rect ) override ;
2015-07-11 18:56:02 +08:00
/** \brief returns the color to be used for the key label */
2018-12-28 05:52:00 +08:00
virtual QColor getKeyLabelColor ( ) override ;
2015-07-11 18:56:02 +08:00
2019-01-26 20:00:40 +08:00
/*! \brief sets the property sizeColumn ( \copybrief sizeColumn ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter sizeColumn is : < BLOCKQUOTE > \ copydoc sizeColumn < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see sizeColumn for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setSizeColumn ( int __value )
2019-01-10 04:23:24 +08:00
{
this - > sizeColumn = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property sizeColumn ( \copybrief sizeColumn ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter sizeColumn is : < BLOCKQUOTE > \ copydoc sizeColumn < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see sizeColumn for more information */
2019-01-26 20:00:40 +08:00
inline virtual int getSizeColumn ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > sizeColumn ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property sizeColumn ( \copybrief sizeColumn ) to the specified \a __value, where __value is static_cast'ed from size_t to int.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter sizeColumn is : < BLOCKQUOTE > \ copydoc sizeColumn < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see sizeColumn for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setSizeColumn ( size_t __value ) { this - > sizeColumn = static_cast < int > ( __value ) ; }
/*! \brief sets the property colorColumn ( \copybrief colorColumn ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter colorColumn is : < BLOCKQUOTE > \ copydoc colorColumn < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see colorColumn for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setColorColumn ( int __value )
2019-01-10 04:23:24 +08:00
{
this - > colorColumn = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property colorColumn ( \copybrief colorColumn ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter colorColumn is : < BLOCKQUOTE > \ copydoc colorColumn < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see colorColumn for more information */
2019-01-26 20:00:40 +08:00
inline virtual int getColorColumn ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > colorColumn ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property colorColumn ( \copybrief colorColumn ) to the specified \a __value, where __value is static_cast'ed from size_t to int.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter colorColumn is : < BLOCKQUOTE > \ copydoc colorColumn < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see colorColumn for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setColorColumn ( size_t __value ) { this - > colorColumn = static_cast < int > ( __value ) ; }
/*! \brief sets the property symbolColumn ( \copybrief symbolColumn ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter symbolColumn is : < BLOCKQUOTE > \ copydoc symbolColumn < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see symbolColumn for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setSymbolColumn ( int __value )
2019-01-10 04:23:24 +08:00
{
this - > symbolColumn = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property symbolColumn ( \copybrief symbolColumn ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter symbolColumn is : < BLOCKQUOTE > \ copydoc symbolColumn < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see symbolColumn for more information */
2019-01-26 20:00:40 +08:00
inline virtual int getSymbolColumn ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > symbolColumn ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property symbolColumn ( \copybrief symbolColumn ) to the specified \a __value, where __value is static_cast'ed from size_t to int.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter symbolColumn is : < BLOCKQUOTE > \ copydoc symbolColumn < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see symbolColumn for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setSymbolColumn ( size_t __value ) { this - > symbolColumn = static_cast < int > ( __value ) ; }
/*! \brief sets the property linewidthColumn ( \copybrief linewidthColumn ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter linewidthColumn is : < BLOCKQUOTE > \ copydoc linewidthColumn < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see linewidthColumn for more information */
2019-01-26 03:16:04 +08:00
inline virtual void setLinewidthColumn ( int __value )
2019-01-10 04:23:24 +08:00
{
this - > linewidthColumn = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property linewidthColumn ( \copybrief linewidthColumn ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter linewidthColumn is : < BLOCKQUOTE > \ copydoc linewidthColumn < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see linewidthColumn for more information */
2019-01-26 03:16:04 +08:00
inline virtual int getLinewidthColumn ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > linewidthColumn ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property linewidthColumn ( \copybrief linewidthColumn ) to the specified \a __value, where __value is static_cast'ed from size_t to int.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter linewidthColumn is : < BLOCKQUOTE > \ copydoc linewidthColumn < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see linewidthColumn for more information */
2019-01-26 03:16:04 +08:00
inline virtual void setLinewidthColumn ( size_t __value ) { this - > linewidthColumn = static_cast < int > ( __value ) ; }
2019-01-26 20:00:40 +08:00
/*! \brief sets the property colorColumnContainsRGB ( \copybrief colorColumnContainsRGB ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter colorColumnContainsRGB is : < BLOCKQUOTE > \ copydoc colorColumnContainsRGB < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see colorColumnContainsRGB for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setColorColumnContainsRGB ( bool __value )
2019-01-10 04:23:24 +08:00
{
this - > colorColumnContainsRGB = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property colorColumnContainsRGB ( \copybrief colorColumnContainsRGB ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter colorColumnContainsRGB is : < BLOCKQUOTE > \ copydoc colorColumnContainsRGB < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see colorColumnContainsRGB for more information */
2019-01-26 20:00:40 +08:00
inline virtual bool getColorColumnContainsRGB ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > colorColumnContainsRGB ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property gridModeForSymbolSize ( \copybrief gridModeForSymbolSize ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter gridModeForSymbolSize is : < BLOCKQUOTE > \ copydoc gridModeForSymbolSize < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see gridModeForSymbolSize for more information */
2019-01-26 03:16:04 +08:00
inline virtual void setGridModeForSymbolSize ( bool __value )
2019-01-10 04:23:24 +08:00
{
this - > gridModeForSymbolSize = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property gridModeForSymbolSize ( \copybrief gridModeForSymbolSize ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter gridModeForSymbolSize is : < BLOCKQUOTE > \ copydoc gridModeForSymbolSize < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see gridModeForSymbolSize for more information */
2019-01-26 03:16:04 +08:00
inline virtual bool getGridModeForSymbolSize ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > gridModeForSymbolSize ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property gridDeltaX ( \copybrief gridDeltaX ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter gridDeltaX is : < BLOCKQUOTE > \ copydoc gridDeltaX < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see gridDeltaX for more information */
2019-01-26 03:16:04 +08:00
inline virtual void setGridDeltaX ( double __value )
2019-01-10 04:23:24 +08:00
{
this - > gridDeltaX = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property gridDeltaX ( \copybrief gridDeltaX ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter gridDeltaX is : < BLOCKQUOTE > \ copydoc gridDeltaX < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see gridDeltaX for more information */
2019-01-26 03:16:04 +08:00
inline virtual double getGridDeltaX ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > gridDeltaX ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property gridDeltaY ( \copybrief gridDeltaY ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter gridDeltaY is : < BLOCKQUOTE > \ copydoc gridDeltaY < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see gridDeltaY for more information */
2019-01-26 03:16:04 +08:00
inline virtual void setGridDeltaY ( double __value )
2019-01-10 04:23:24 +08:00
{
this - > gridDeltaY = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property gridDeltaY ( \copybrief gridDeltaY ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter gridDeltaY is : < BLOCKQUOTE > \ copydoc gridDeltaY < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see gridDeltaY for more information */
2019-01-26 03:16:04 +08:00
inline virtual double getGridDeltaY ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > gridDeltaY ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property gridSymbolFractionSize ( \copybrief gridSymbolFractionSize ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter gridSymbolFractionSize is : < BLOCKQUOTE > \ copydoc gridSymbolFractionSize < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see gridSymbolFractionSize for more information */
2019-01-26 03:16:04 +08:00
inline virtual void setGridSymbolFractionSize ( double __value )
2019-01-10 04:23:24 +08:00
{
this - > gridSymbolFractionSize = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property gridSymbolFractionSize ( \copybrief gridSymbolFractionSize ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter gridSymbolFractionSize is : < BLOCKQUOTE > \ copydoc gridSymbolFractionSize < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see gridSymbolFractionSize for more information */
2019-01-26 03:16:04 +08:00
inline virtual double getGridSymbolFractionSize ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > gridSymbolFractionSize ;
}
2015-07-11 18:56:02 +08:00
2019-01-20 17:49:29 +08:00
virtual void setParent ( JKQTBasePlotter * parent ) override ;
2015-07-11 18:56:02 +08:00
/*! \brief if the graph plots outside the actual plot field of view (e.g. color bars, scale bars, ...)
\ note If you want to draw outside , then you ' ll also have to implement drawOutside ( )
*/
2018-12-28 05:52:00 +08:00
virtual void getOutsideSize ( JKQTPEnhancedPainter & painter , int & leftSpace , int & rightSpace , int & topSpace , int & bottomSpace ) override ;
2015-07-11 18:56:02 +08:00
/*! \brief plots outside the actual plot field of view (e.g. color bars, scale bars, ...)
\ note If you want to draw outside , then you ' ll also have to implement getOutsideSize ( ) , so enough space is reserved
The four value supplied tell the method where to draw ( inside one of the rectangles ) .
*/
2018-12-28 05:52:00 +08:00
virtual void drawOutside ( JKQTPEnhancedPainter & painter , QRect leftSpace , QRect rightSpace , QRect topSpace , QRect bottomSpace ) override ;
2015-07-11 18:56:02 +08:00
/** \brief determine min/max data value of the image */
2018-12-28 05:52:00 +08:00
virtual void cbGetDataMinMax ( double & imin , double & imax ) override ;
2019-01-20 17:49:29 +08:00
/** \copydoc JKQTPGraph::usesColumn() */
2018-12-28 05:52:00 +08:00
virtual bool usesColumn ( int c ) const override ;
2015-07-11 18:56:02 +08:00
2018-12-28 05:52:00 +08:00
virtual double getInternalDataMin ( ) const override ;
virtual double getInternalDataMax ( ) const override ;
2015-07-11 18:56:02 +08:00
protected :
/** \brief this column contains the symbol size in pt */
int sizeColumn ;
/** \brief this column contains the symbol color */
int colorColumn ;
/** \brief this column contains the symbol type */
int symbolColumn ;
2018-12-16 21:59:39 +08:00
/** \brief this column contains the line width */
int linewidthColumn ;
2015-07-11 18:56:02 +08:00
2018-12-25 04:39:37 +08:00
/** \brief if the gridModeForSymbolSize mode is actiavted (true), the plot assumes that the scatter symbols are ordered in a grid. It the uses the given griDeltaX and gridDeltaY to calculate the symbol size, so they fill the available space to a fraction gridSymbolFractionSize. */
2015-07-11 18:56:02 +08:00
bool gridModeForSymbolSize ;
2018-12-25 04:39:37 +08:00
/** \brief if the gridModeForSymbolSize mode is actiavted (true), the plot assumes that the scatter symbols are ordered in a grid. It the uses the given griDeltaX and gridDeltaY to calculate the symbol size, so they fill the available space to a fraction gridSymbolFractionSize. */
2015-07-11 18:56:02 +08:00
double gridDeltaX ;
2018-12-25 04:39:37 +08:00
/** \brief if the gridModeForSymbolSize mode is actiavted (true), the plot assumes that the scatter symbols are ordered in a grid. It the uses the given griDeltaX and gridDeltaY to calculate the symbol size, so they fill the available space to a fraction gridSymbolFractionSize. */
2015-07-11 18:56:02 +08:00
double gridDeltaY ;
2018-12-25 04:39:37 +08:00
/** \brief if the gridModeForSymbolSize mode is actiavted (true), the plot assumes that the scatter symbols are ordered in a grid. It the uses the given griDeltaX and gridDeltaY to calculate the symbol size, so they fill the available space to a fraction gridSymbolFractionSize. */
2015-07-11 18:56:02 +08:00
double gridSymbolFractionSize ;
/** \brief if this is true, the value in the colorColumn is converted to an integer, representing a color in ARGB format (as in QRgb) */
bool colorColumnContainsRGB ;
2018-12-16 21:59:39 +08:00
double getLocalLineWidth ( int i ) ;
2015-07-11 18:56:02 +08:00
double getLocalSymbolSize ( int i ) ;
QColor getLocalColor ( int i ) ;
2019-01-20 17:49:29 +08:00
JKQTPGraphSymbols getLocalSymbolType ( int i ) ;
2015-07-11 18:56:02 +08:00
/** \brief internally used to store the range of the color column */
double intColMin ;
/** \brief internally used to store the range of the color column */
double intColMax ;
} ;
/*! \brief This implements xy line plots with x and y error indicators.
2019-02-03 21:04:48 +08:00
\ ingroup jkqtplotter_linesymbolgraphs_simple
2015-07-11 18:56:02 +08:00
\ image html plot_errorbarlineplots . png
\ image html plot_errorlinelineplots . png
\ image html plot_errorpolygonlineplots . png
*/
2019-02-03 21:04:48 +08:00
class JKQTP_LIB_EXPORT JKQTPXYLineErrorGraph : public JKQTPXYLineGraph , public JKQTPXYGraphErrors {
2015-07-11 18:56:02 +08:00
Q_OBJECT
public :
/** \brief class constructor */
2019-01-20 17:49:29 +08:00
JKQTPXYLineErrorGraph ( JKQTBasePlotter * parent = nullptr ) ;
2015-08-02 19:36:54 +08:00
/** \brief class constructor */
2019-01-20 23:15:10 +08:00
JKQTPXYLineErrorGraph ( JKQTPlotter * parent ) ;
2015-07-11 18:56:02 +08:00
/** \brief get the maximum and minimum x-value of the graph
*
* The result is given in the two parameters which are call - by - reference parameters !
*/
2018-12-28 05:52:00 +08:00
virtual bool getXMinMax ( double & minx , double & maxx , double & smallestGreaterZero ) override ;
2015-07-11 18:56:02 +08:00
/** \brief get the maximum and minimum y-value of the graph
*
* The result is given in the two parameters which are call - by - reference parameters !
*/
2018-12-28 05:52:00 +08:00
virtual bool getYMinMax ( double & miny , double & maxy , double & smallestGreaterZero ) override ;
2019-01-20 17:49:29 +08:00
/** \copydoc JKQTPGraph::usesColumn() */
2018-12-28 05:52:00 +08:00
virtual bool usesColumn ( int c ) const override ;
2015-07-11 18:56:02 +08:00
protected :
/** \brief this function is used to plot error inidcators before plotting the graphs. */
2018-12-28 05:52:00 +08:00
virtual void drawErrorsBefore ( JKQTPEnhancedPainter & painter ) override ;
2015-07-11 18:56:02 +08:00
} ;
2019-01-20 17:49:29 +08:00
/*! \brief This implements xy scatter plots (like JKQTPXYLineGraph), but the color and size of the symbols may be taken from a column. with errorbars
2019-02-03 21:04:48 +08:00
\ ingroup jkqtplotter_linesymbolgraphs_param
2015-07-11 18:56:02 +08:00
set the properties sizeColumn and / or colorColumn to change the size and / or color of the symbols according to the values in the column .
2019-01-29 05:14:27 +08:00
\ image html screen_parmetrizedplots_datatable . png
\ see JKQTPXYParametrizedScatterGraph , \ ref JKQTPlotterParamScatter
2015-07-11 18:56:02 +08:00
*/
2019-02-03 21:04:48 +08:00
class JKQTP_LIB_EXPORT JKQTPXYParametrizedErrorScatterGraph : public JKQTPXYParametrizedScatterGraph , public JKQTPXYGraphErrors {
2015-07-11 18:56:02 +08:00
Q_OBJECT
public :
2019-01-20 17:49:29 +08:00
JKQTPXYParametrizedErrorScatterGraph ( JKQTBasePlotter * parent = nullptr ) ;
2019-01-20 23:15:10 +08:00
JKQTPXYParametrizedErrorScatterGraph ( JKQTPlotter * parent ) ;
2015-07-11 18:56:02 +08:00
/** \brief get the maximum and minimum x-value of the graph
*
* The result is given in the two parameters which are call - by - reference parameters !
*/
2018-12-28 05:52:00 +08:00
virtual bool getXMinMax ( double & minx , double & maxx , double & smallestGreaterZero ) override ;
2015-07-11 18:56:02 +08:00
/** \brief get the maximum and minimum y-value of the graph
*
* The result is given in the two parameters which are call - by - reference parameters !
*/
2018-12-28 05:52:00 +08:00
virtual bool getYMinMax ( double & miny , double & maxy , double & smallestGreaterZero ) override ;
2019-01-20 17:49:29 +08:00
/** \copydoc JKQTPGraph::usesColumn() */
2018-12-28 05:52:00 +08:00
virtual bool usesColumn ( int c ) const override ;
2015-07-11 18:56:02 +08:00
protected :
/** \brief this function is used to plot error inidcators before plotting the graphs. */
2018-12-28 05:52:00 +08:00
virtual void drawErrorsBefore ( JKQTPEnhancedPainter & painter ) override ;
2015-07-11 18:56:02 +08:00
/** \brief this function can be used to set the color of the error indicators automatically
*
* return \ c true and the colors to use , if applicable , the default implementation returns false */
2019-01-20 17:49:29 +08:00
virtual bool intPlotXYErrorIndicatorsGetColor ( JKQTPEnhancedPainter & painter , JKQTBasePlotter * parent , JKQTPGraph * parentGraph , int xColumn , int yColumn , int xErrorColumn , int yErrorColumn , JKQTPErrorPlotstyle xErrorStyle , JKQTPErrorPlotstyle yErrorStyle , int index , QColor & errorColor , QColor & errorFillColor ) override ;
2015-07-11 18:56:02 +08:00
} ;
2018-12-01 23:02:04 +08:00
2018-11-25 21:53:26 +08:00
/*! \brief This implements a step plot with values \f$ \left(x, f(x) \right) \f$
2019-02-03 21:04:48 +08:00
\ ingroup jkqtplotter_linesymbolgraphs_simple
2015-07-11 18:56:02 +08:00
2019-01-29 05:14:27 +08:00
\ image html jkqtplotter_simpletest_stepplots . png
2015-07-11 18:56:02 +08:00
2019-01-29 05:14:27 +08:00
\ see JKQTPStepVerticalGraph , \ ref JKQTPlotterStepPlot
2018-11-25 21:53:26 +08:00
*/
2019-02-03 21:04:48 +08:00
class JKQTP_LIB_EXPORT JKQTPStepHorizontalGraph : public JKQTPXYGraph {
2018-11-25 21:53:26 +08:00
Q_OBJECT
public :
2015-07-11 18:56:02 +08:00
/** \brief class constructor */
2019-01-20 17:49:29 +08:00
JKQTPStepHorizontalGraph ( JKQTBasePlotter * parent = nullptr ) ;
2015-08-02 19:36:54 +08:00
/** \brief class constructor */
2019-01-20 23:15:10 +08:00
JKQTPStepHorizontalGraph ( JKQTPlotter * parent ) ;
2015-07-11 18:56:02 +08:00
/** \brief plots the graph to the plotter object specified as parent */
2018-12-28 05:52:00 +08:00
virtual void draw ( JKQTPEnhancedPainter & painter ) override ;
2015-07-11 18:56:02 +08:00
/** \brief plots a key marker inside the specified rectangle \a rect */
2018-12-28 05:52:00 +08:00
virtual void drawKeyMarker ( JKQTPEnhancedPainter & painter , QRectF & rect ) override ;
2015-07-11 18:56:02 +08:00
/** \brief returns the color to be used for the key label */
2018-12-28 05:52:00 +08:00
virtual QColor getKeyLabelColor ( ) override ;
2015-07-11 18:56:02 +08:00
2019-01-26 20:00:40 +08:00
/*! \brief sets the property color ( \copybrief color ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter color is : < BLOCKQUOTE > \ copydoc color < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see color for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setColor ( const QColor & __value )
2019-01-10 04:23:24 +08:00
{
this - > color = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property color ( \copybrief color ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter color is : < BLOCKQUOTE > \ copydoc color < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see color for more information */
2019-01-26 20:00:40 +08:00
inline virtual QColor getColor ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > color ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property fillColor ( \copybrief fillColor ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter fillColor is : < BLOCKQUOTE > \ copydoc fillColor < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see fillColor for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setFillColor ( const QColor & __value )
2019-01-10 04:23:24 +08:00
{
this - > fillColor = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property fillColor ( \copybrief fillColor ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter fillColor is : < BLOCKQUOTE > \ copydoc fillColor < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see fillColor for more information */
2019-01-26 20:00:40 +08:00
inline virtual QColor getFillColor ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > fillColor ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property fillStyle ( \copybrief fillStyle ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter fillStyle is : < BLOCKQUOTE > \ copydoc fillStyle < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see fillStyle for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setFillStyle ( const Qt : : BrushStyle & __value )
2019-01-10 04:23:24 +08:00
{
this - > fillStyle = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property fillStyle ( \copybrief fillStyle ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter fillStyle is : < BLOCKQUOTE > \ copydoc fillStyle < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see fillStyle for more information */
2019-01-26 20:00:40 +08:00
inline virtual Qt : : BrushStyle getFillStyle ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > fillStyle ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property style ( \copybrief style ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter style is : < BLOCKQUOTE > \ copydoc style < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see style for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setStyle ( const Qt : : PenStyle & __value )
2019-01-10 04:23:24 +08:00
{
this - > style = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property style ( \copybrief style ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter style is : < BLOCKQUOTE > \ copydoc style < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see style for more information */
2019-01-26 20:00:40 +08:00
inline virtual Qt : : PenStyle getStyle ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > style ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property lineWidth ( \copybrief lineWidth ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter lineWidth is : < BLOCKQUOTE > \ copydoc lineWidth < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see lineWidth for more information */
2019-01-26 03:16:04 +08:00
inline virtual void setLineWidth ( double __value )
2019-01-10 04:23:24 +08:00
{
this - > lineWidth = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property lineWidth ( \copybrief lineWidth ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter lineWidth is : < BLOCKQUOTE > \ copydoc lineWidth < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see lineWidth for more information */
2019-01-26 03:16:04 +08:00
inline virtual double getLineWidth ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > lineWidth ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property drawLine ( \copybrief drawLine ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter drawLine is : < BLOCKQUOTE > \ copydoc drawLine < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see drawLine for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setDrawLine ( bool __value )
2019-01-10 04:23:24 +08:00
{
this - > drawLine = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property drawLine ( \copybrief drawLine ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter drawLine is : < BLOCKQUOTE > \ copydoc drawLine < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see drawLine for more information */
2019-01-26 20:00:40 +08:00
inline virtual bool getDrawLine ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > drawLine ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property fillCurve ( \copybrief fillCurve ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter fillCurve is : < BLOCKQUOTE > \ copydoc fillCurve < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see fillCurve for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setFillCurve ( bool __value )
2019-01-10 04:23:24 +08:00
{
this - > fillCurve = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property fillCurve ( \copybrief fillCurve ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter fillCurve is : < BLOCKQUOTE > \ copydoc fillCurve < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see fillCurve for more information */
2019-01-26 20:00:40 +08:00
inline virtual bool getFillCurve ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > fillCurve ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property stepType ( \copybrief stepType ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter stepType is : < BLOCKQUOTE > \ copydoc stepType < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see stepType for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setStepType ( const JKQTPStepType & __value )
2019-01-10 04:23:24 +08:00
{
this - > stepType = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property stepType ( \copybrief stepType ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter stepType is : < BLOCKQUOTE > \ copydoc stepType < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see stepType for more information */
2019-01-26 20:00:40 +08:00
inline virtual JKQTPStepType getStepType ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > stepType ;
}
2015-07-11 18:56:02 +08:00
protected :
/** \brief color of the graph */
QColor color ;
/** \brief color of the graph fill */
QColor fillColor ;
/** \brief linestyle of the graph lines */
Qt : : PenStyle style ;
2019-01-20 23:15:10 +08:00
/** \brief width (pixels) of the graph, given in pt */
2015-07-11 18:56:02 +08:00
double lineWidth ;
/** \brief fill style, if the curve should be filled */
Qt : : BrushStyle fillStyle ;
/** \brief indicates whether to draw a line or not */
bool drawLine ;
/** \brief indicates whether to fill the space between the curve and the x-axis */
bool fillCurve ;
2018-12-07 04:41:35 +08:00
/** \brief specifies whether the steps elongate to the left, the right, or are centered around the \f$ x_i \f$ values. */
2019-01-20 17:49:29 +08:00
JKQTPStepType stepType ;
2015-07-11 18:56:02 +08:00
2019-01-26 03:16:04 +08:00
/** \brief which plot style to use from the parent plotter (via JKQTBasePlotter::getPlotStyle() and JKQTBasePlotter::getNextStyle() ) */
2015-07-11 18:56:02 +08:00
int parentPlotStyle ;
QBrush getBrush ( JKQTPEnhancedPainter & painter ) const ;
QPen getLinePen ( JKQTPEnhancedPainter & painter ) const ;
} ;
/*! \brief This implements a step plot with values \f$ \left(f(y), y \right) \f$
2019-02-03 21:04:48 +08:00
\ ingroup jkqtplotter_linesymbolgraphs_simple
2015-07-11 18:56:02 +08:00
\ image html plot_stepverplot1 . png
2019-01-29 05:14:27 +08:00
\ see JKQTPStepHorizontalGraph , \ ref JKQTPlotterStepPlot
2015-07-11 18:56:02 +08:00
*/
2019-02-03 21:04:48 +08:00
class JKQTP_LIB_EXPORT JKQTPStepVerticalGraph : public JKQTPStepHorizontalGraph {
2015-07-11 18:56:02 +08:00
Q_OBJECT
public :
/** \brief class constructor */
2019-01-20 17:49:29 +08:00
JKQTPStepVerticalGraph ( JKQTBasePlotter * parent = nullptr ) ;
2015-08-02 19:36:54 +08:00
/** \brief class constructor */
2019-01-20 23:15:10 +08:00
JKQTPStepVerticalGraph ( JKQTPlotter * parent ) ;
2015-07-11 18:56:02 +08:00
/** \brief plots the graph to the plotter object specified as parent */
2018-12-28 05:52:00 +08:00
virtual void draw ( JKQTPEnhancedPainter & painter ) override ;
2015-07-11 18:56:02 +08:00
} ;
/*! \brief simply marks a range (and possibly a centerline) in a plot. This may be used to display e.g. mean +/- stddev
or a range of interest , or the range of good values , . . .
2019-01-13 01:53:16 +08:00
\ ingroup jkqtplotter_diverse
2015-07-11 18:56:02 +08:00
*/
2019-02-03 21:04:48 +08:00
class JKQTP_LIB_EXPORT JKQTPHorizontalRange : public JKQTPGraph {
2015-07-11 18:56:02 +08:00
Q_OBJECT
public :
/** \brief class constructor */
2019-01-20 17:49:29 +08:00
JKQTPHorizontalRange ( JKQTBasePlotter * parent = nullptr ) ;
2015-08-02 19:36:54 +08:00
/** \brief class constructor */
2019-01-20 23:15:10 +08:00
JKQTPHorizontalRange ( JKQTPlotter * parent ) ;
2015-07-11 18:56:02 +08:00
/** \brief plots the graph to the plotter object specified as parent */
2018-12-28 05:52:00 +08:00
virtual void draw ( JKQTPEnhancedPainter & painter ) override ;
2015-07-11 18:56:02 +08:00
/** \brief plots a key marker inside the specified rectangle \a rect */
2018-12-28 05:52:00 +08:00
virtual void drawKeyMarker ( JKQTPEnhancedPainter & painter , QRectF & rect ) override ;
2015-07-11 18:56:02 +08:00
/** \brief get the maximum and minimum x-value of the graph
*
* The result is given in the two parameters which are call - by - reference parameters !
*/
2018-12-28 05:52:00 +08:00
virtual bool getXMinMax ( double & minx , double & maxx , double & smallestGreaterZero ) override ;
2015-07-11 18:56:02 +08:00
/** \brief get the maximum and minimum y-value of the graph
*
* The result is given in the two parameters which are call - by - reference parameters !
*/
2018-12-28 05:52:00 +08:00
virtual bool getYMinMax ( double & miny , double & maxy , double & smallestGreaterZero ) override ;
2015-07-11 18:56:02 +08:00
/** \brief returns the color to be used for the key label */
2018-12-28 05:52:00 +08:00
virtual QColor getKeyLabelColor ( ) override ;
2015-07-11 18:56:02 +08:00
void setDrawCenterLineOnly ( ) ;
2019-01-26 20:00:40 +08:00
/*! \brief sets the property color ( \copybrief color ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter color is : < BLOCKQUOTE > \ copydoc color < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see color for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setColor ( const QColor & __value )
2019-01-10 04:23:24 +08:00
{
this - > color = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property color ( \copybrief color ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter color is : < BLOCKQUOTE > \ copydoc color < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see color for more information */
2019-01-26 20:00:40 +08:00
inline virtual QColor getColor ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > color ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property fillColor ( \copybrief fillColor ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter fillColor is : < BLOCKQUOTE > \ copydoc fillColor < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see fillColor for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setFillColor ( const QColor & __value )
2019-01-10 04:23:24 +08:00
{
this - > fillColor = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property fillColor ( \copybrief fillColor ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter fillColor is : < BLOCKQUOTE > \ copydoc fillColor < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see fillColor for more information */
2019-01-26 20:00:40 +08:00
inline virtual QColor getFillColor ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > fillColor ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property fillStyle ( \copybrief fillStyle ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter fillStyle is : < BLOCKQUOTE > \ copydoc fillStyle < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see fillStyle for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setFillStyle ( const Qt : : BrushStyle & __value )
2019-01-10 04:23:24 +08:00
{
this - > fillStyle = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property fillStyle ( \copybrief fillStyle ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter fillStyle is : < BLOCKQUOTE > \ copydoc fillStyle < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see fillStyle for more information */
2019-01-26 20:00:40 +08:00
inline virtual Qt : : BrushStyle getFillStyle ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > fillStyle ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property style ( \copybrief style ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter style is : < BLOCKQUOTE > \ copydoc style < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see style for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setStyle ( const Qt : : PenStyle & __value )
2019-01-10 04:23:24 +08:00
{
this - > style = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property style ( \copybrief style ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter style is : < BLOCKQUOTE > \ copydoc style < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see style for more information */
2019-01-26 20:00:40 +08:00
inline virtual Qt : : PenStyle getStyle ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > style ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property lineWidth ( \copybrief lineWidth ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter lineWidth is : < BLOCKQUOTE > \ copydoc lineWidth < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see lineWidth for more information */
2019-01-26 03:16:04 +08:00
inline virtual void setLineWidth ( double __value )
2019-01-10 04:23:24 +08:00
{
this - > lineWidth = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property lineWidth ( \copybrief lineWidth ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter lineWidth is : < BLOCKQUOTE > \ copydoc lineWidth < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see lineWidth for more information */
2019-01-26 03:16:04 +08:00
inline virtual double getLineWidth ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > lineWidth ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property centerColor ( \copybrief centerColor ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter centerColor is : < BLOCKQUOTE > \ copydoc centerColor < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see centerColor for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setCenterColor ( const QColor & __value )
2019-01-10 04:23:24 +08:00
{
this - > centerColor = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property centerColor ( \copybrief centerColor ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter centerColor is : < BLOCKQUOTE > \ copydoc centerColor < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see centerColor for more information */
2019-01-26 20:00:40 +08:00
inline virtual QColor getCenterColor ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > centerColor ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property centerStyle ( \copybrief centerStyle ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter centerStyle is : < BLOCKQUOTE > \ copydoc centerStyle < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see centerStyle for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setCenterStyle ( const Qt : : PenStyle & __value )
2019-01-10 04:23:24 +08:00
{
this - > centerStyle = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property centerStyle ( \copybrief centerStyle ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter centerStyle is : < BLOCKQUOTE > \ copydoc centerStyle < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see centerStyle for more information */
2019-01-26 20:00:40 +08:00
inline virtual Qt : : PenStyle getCenterStyle ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > centerStyle ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property centerLineWidth ( \copybrief centerLineWidth ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter centerLineWidth is : < BLOCKQUOTE > \ copydoc centerLineWidth < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see centerLineWidth for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setCenterLineWidth ( double __value )
2019-01-10 04:23:24 +08:00
{
this - > centerLineWidth = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property centerLineWidth ( \copybrief centerLineWidth ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter centerLineWidth is : < BLOCKQUOTE > \ copydoc centerLineWidth < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see centerLineWidth for more information */
2019-01-26 20:00:40 +08:00
inline virtual double getCenterLineWidth ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > centerLineWidth ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property rangeMin ( \copybrief rangeMin ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter rangeMin is : < BLOCKQUOTE > \ copydoc rangeMin < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see rangeMin for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setRangeMin ( double __value )
2019-01-10 04:23:24 +08:00
{
this - > rangeMin = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property rangeMin ( \copybrief rangeMin ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter rangeMin is : < BLOCKQUOTE > \ copydoc rangeMin < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see rangeMin for more information */
2019-01-26 20:00:40 +08:00
inline virtual double getRangeMin ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > rangeMin ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property rangeMax ( \copybrief rangeMax ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter rangeMax is : < BLOCKQUOTE > \ copydoc rangeMax < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see rangeMax for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setRangeMax ( double __value )
2019-01-10 04:23:24 +08:00
{
this - > rangeMax = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property rangeMax ( \copybrief rangeMax ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter rangeMax is : < BLOCKQUOTE > \ copydoc rangeMax < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see rangeMax for more information */
2019-01-26 20:00:40 +08:00
inline virtual double getRangeMax ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > rangeMax ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property sizeMin ( \copybrief sizeMin ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter sizeMin is : < BLOCKQUOTE > \ copydoc sizeMin < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see sizeMin for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setSizeMin ( double __value )
2019-01-10 04:23:24 +08:00
{
this - > sizeMin = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property sizeMin ( \copybrief sizeMin ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter sizeMin is : < BLOCKQUOTE > \ copydoc sizeMin < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see sizeMin for more information */
2019-01-26 20:00:40 +08:00
inline virtual double getSizeMin ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > sizeMin ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property sizeMax ( \copybrief sizeMax ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter sizeMax is : < BLOCKQUOTE > \ copydoc sizeMax < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see sizeMax for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setSizeMax ( double __value )
2019-01-10 04:23:24 +08:00
{
this - > sizeMax = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property sizeMax ( \copybrief sizeMax ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter sizeMax is : < BLOCKQUOTE > \ copydoc sizeMax < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see sizeMax for more information */
2019-01-26 20:00:40 +08:00
inline virtual double getSizeMax ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > sizeMax ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property unlimitedSizeMin ( \copybrief unlimitedSizeMin ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter unlimitedSizeMin is : < BLOCKQUOTE > \ copydoc unlimitedSizeMin < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see unlimitedSizeMin for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setUnlimitedSizeMin ( bool __value )
2019-01-10 04:23:24 +08:00
{
this - > unlimitedSizeMin = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property unlimitedSizeMin ( \copybrief unlimitedSizeMin ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter unlimitedSizeMin is : < BLOCKQUOTE > \ copydoc unlimitedSizeMin < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see unlimitedSizeMin for more information */
2019-01-26 20:00:40 +08:00
inline virtual bool getUnlimitedSizeMin ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > unlimitedSizeMin ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property unlimitedSizeMax ( \copybrief unlimitedSizeMax ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter unlimitedSizeMax is : < BLOCKQUOTE > \ copydoc unlimitedSizeMax < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see unlimitedSizeMax for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setUnlimitedSizeMax ( bool __value )
2019-01-10 04:23:24 +08:00
{
this - > unlimitedSizeMax = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property unlimitedSizeMax ( \copybrief unlimitedSizeMax ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter unlimitedSizeMax is : < BLOCKQUOTE > \ copydoc unlimitedSizeMax < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see unlimitedSizeMax for more information */
2019-01-26 20:00:40 +08:00
inline virtual bool getUnlimitedSizeMax ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > unlimitedSizeMax ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property rangeCenter ( \copybrief rangeCenter ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter rangeCenter is : < BLOCKQUOTE > \ copydoc rangeCenter < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see rangeCenter for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setRangeCenter ( double __value )
2019-01-10 04:23:24 +08:00
{
this - > rangeCenter = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property rangeCenter ( \copybrief rangeCenter ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter rangeCenter is : < BLOCKQUOTE > \ copydoc rangeCenter < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see rangeCenter for more information */
2019-01-26 20:00:40 +08:00
inline virtual double getRangeCenter ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > rangeCenter ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property plotCenterLine ( \copybrief plotCenterLine ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter plotCenterLine is : < BLOCKQUOTE > \ copydoc plotCenterLine < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see plotCenterLine for more information */
2019-01-26 03:16:04 +08:00
inline virtual void setPlotCenterLine ( bool __value )
2019-01-10 04:23:24 +08:00
{
this - > plotCenterLine = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property plotCenterLine ( \copybrief plotCenterLine ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter plotCenterLine is : < BLOCKQUOTE > \ copydoc plotCenterLine < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see plotCenterLine for more information */
2019-01-26 03:16:04 +08:00
inline virtual bool getPlotCenterLine ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > plotCenterLine ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property invertedRange ( \copybrief invertedRange ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter invertedRange is : < BLOCKQUOTE > \ copydoc invertedRange < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see invertedRange for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setInvertedRange ( bool __value )
2019-01-10 04:23:24 +08:00
{
this - > invertedRange = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property invertedRange ( \copybrief invertedRange ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter invertedRange is : < BLOCKQUOTE > \ copydoc invertedRange < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see invertedRange for more information */
2019-01-26 20:00:40 +08:00
inline virtual bool getInvertedRange ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > invertedRange ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property plotRange ( \copybrief plotRange ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter plotRange is : < BLOCKQUOTE > \ copydoc plotRange < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see plotRange for more information */
2019-01-26 03:16:04 +08:00
inline virtual void setPlotRange ( bool __value )
2019-01-10 04:23:24 +08:00
{
this - > plotRange = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property plotRange ( \copybrief plotRange ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter plotRange is : < BLOCKQUOTE > \ copydoc plotRange < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see plotRange for more information */
2019-01-26 03:16:04 +08:00
inline virtual bool getPlotRange ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > plotRange ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property fillRange ( \copybrief fillRange ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter fillRange is : < BLOCKQUOTE > \ copydoc fillRange < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see fillRange for more information */
2019-01-26 20:00:40 +08:00
inline virtual void setFillRange ( bool __value )
2019-01-10 04:23:24 +08:00
{
this - > fillRange = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property fillRange ( \copybrief fillRange ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter fillRange is : < BLOCKQUOTE > \ copydoc fillRange < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see fillRange for more information */
2019-01-26 20:00:40 +08:00
inline virtual bool getFillRange ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > fillRange ;
}
2019-01-26 20:00:40 +08:00
/*! \brief sets the property plotRangeLines ( \copybrief plotRangeLines ) to the specified \a __value.
2019-01-25 05:49:10 +08:00
\ details Description of the parameter plotRangeLines is : < BLOCKQUOTE > \ copydoc plotRangeLines < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see plotRangeLines for more information */
2019-01-26 03:16:04 +08:00
inline virtual void setPlotRangeLines ( bool __value )
2019-01-10 04:23:24 +08:00
{
this - > plotRangeLines = __value ;
}
2019-01-26 20:00:40 +08:00
/*! \brief returns the property plotRangeLines ( \copybrief plotRangeLines ).
2019-01-25 05:49:10 +08:00
\ details Description of the parameter plotRangeLines is : < BLOCKQUOTE > \ copydoc plotRangeLines < / BLOCKQUOTE >
2019-01-10 04:23:24 +08:00
\ see plotRangeLines for more information */
2019-01-26 03:16:04 +08:00
inline virtual bool getPlotRangeLines ( ) const
2019-01-10 04:23:24 +08:00
{
return this - > plotRangeLines ;
}
2015-07-11 18:56:02 +08:00
protected :
/** \brief min-value of range */
double rangeMin ;
/** \brief max-value of range */
double rangeMax ;
/** \brief where to plot the center line */
double rangeCenter ;
double sizeMin ;
double sizeMax ;
bool unlimitedSizeMin ;
bool unlimitedSizeMax ;
/** \brief indicates whether to plot a center line */
bool plotCenterLine ;
/** \brief if \c true, fills the parts outside the given range */
bool invertedRange ;
/** \brief if \c true, the range is plotted, if \c false, only the center line is plotted (if \a plotCenterLine is \c true ) */
bool plotRange ;
/** \brief if \c true, draws lines at the range borders \a color */
bool plotRangeLines ;
2019-01-08 04:00:56 +08:00
/** \brief if \c true, this fills the range with \a fillColor */
2015-07-11 18:56:02 +08:00
bool fillRange ;
/** \brief color of the graph */
QColor color ;
/** \brief color of the center line graph */
QColor centerColor ;
/** \brief color of the graph fill */
QColor fillColor ;
/** \brief linestyle of the graph lines */
Qt : : PenStyle style ;
/** \brief linestyle of the center line graph lines */
Qt : : PenStyle centerStyle ;
2019-01-20 23:15:10 +08:00
/** \brief width (pt) of the graph, given in pt */
2015-07-11 18:56:02 +08:00
double lineWidth ;
2019-01-20 23:15:10 +08:00
/** \brief width (pt) of the center line graph, given in pt */
2015-07-11 18:56:02 +08:00
double centerLineWidth ;
/** \brief fill style, if the curve should be filled */
Qt : : BrushStyle fillStyle ;
2019-01-26 03:16:04 +08:00
/** \brief which plot style to use from the parent plotter (via JKQTBasePlotter::getPlotStyle() and JKQTBasePlotter::getNextStyle() ) */
2015-07-11 18:56:02 +08:00
int parentPlotStyle ;
QBrush getBrush ( JKQTPEnhancedPainter & painter ) const ;
QPen getLinePen ( JKQTPEnhancedPainter & painter ) const ;
} ;
/*! \brief simply marks a range (and possibly a centerline) in a plot. This may be used to display e.g. mean +/- stddev
or a range of interest , or the range of good values , . . .
2019-01-13 01:53:16 +08:00
\ ingroup jkqtplotter_diverse
2015-07-11 18:56:02 +08:00
*/
2019-02-03 21:04:48 +08:00
class JKQTP_LIB_EXPORT JKQTPVerticalRange : public JKQTPHorizontalRange {
2015-07-11 18:56:02 +08:00
Q_OBJECT
public :
/** \brief class constructor */
2019-01-20 17:49:29 +08:00
JKQTPVerticalRange ( JKQTBasePlotter * parent = nullptr ) ;
2015-08-02 19:36:54 +08:00
/** \brief class constructor */
2019-01-20 23:15:10 +08:00
JKQTPVerticalRange ( JKQTPlotter * parent ) ;
2015-07-11 18:56:02 +08:00
/** \brief plots the graph to the plotter object specified as parent */
2018-12-28 05:52:00 +08:00
virtual void draw ( JKQTPEnhancedPainter & painter ) override ;
2015-07-11 18:56:02 +08:00
/** \brief plots a key marker inside the specified rectangle \a rect */
2018-12-28 05:52:00 +08:00
virtual void drawKeyMarker ( JKQTPEnhancedPainter & painter , QRectF & rect ) override ;
2015-07-11 18:56:02 +08:00
/** \brief get the maximum and minimum x-value of the graph
*
* The result is given in the two parameters which are call - by - reference parameters !
*/
2018-12-28 05:52:00 +08:00
virtual bool getXMinMax ( double & minx , double & maxx , double & smallestGreaterZero ) override ;
2015-07-11 18:56:02 +08:00
/** \brief get the maximum and minimum y-value of the graph
*
* The result is given in the two parameters which are call - by - reference parameters !
*/
2018-12-28 05:52:00 +08:00
virtual bool getYMinMax ( double & miny , double & maxy , double & smallestGreaterZero ) override ;
2015-07-11 18:56:02 +08:00
} ;
2018-12-19 00:13:18 +08:00
# endif // jkqtpgraphs_H