Eclipse SUMO - Simulation of Urban MObility
|
#include <GUIPropertyScheme.h>
Public Member Functions | |
int | addColor (const T &color, const double threshold, const std::string &name="") |
bool | allowsNegativeValues () const |
void | clear () |
const RGBColor & | getBackgroundColor () const |
T | getColor (const double value) const |
const std::vector< T > & | getColors () const |
GUIIcon | getIcon () const |
const std::string & | getName () const |
const std::vector< std::string > & | getNames () const |
std::string | getTagName (std::vector< double >) const |
std::string | getTagName (std::vector< RGBColor >) const |
const std::vector< double > & | getThresholds () const |
const std::string & | getTranslatedName () const |
GUIPropertyScheme (const std::string &name, const std::string &translatedName, const T &baseColor, const std::string &colName="", const bool isFixed=false, double baseValue=0, RGBColor bgColor=RGBColor::WHITE, GUIIcon icon=GUIIcon::EMPTY) | |
Constructor. | |
GUIPropertyScheme (const std::string &name, const T &baseColor, const std::string &colName="", const bool isFixed=false, double baseValue=0, RGBColor bgColor=RGBColor::WHITE, GUIIcon icon=GUIIcon::EMPTY) | |
double | interpolate (const double &min, const double &max, double weight) const |
specializations for GUIScaleScheme | |
RGBColor | interpolate (const RGBColor &min, const RGBColor &max, double weight) const |
specializations for GUIColorScheme | |
bool | isFixed () const |
bool | isInterpolated () const |
bool | operator== (const GUIPropertyScheme &c) const |
void | removeColor (const int pos) |
void | save (OutputDevice &dev, const std::string &prefix="") const |
void | setAllowsNegativeValues (bool value) |
void | setColor (const int pos, const T &color) |
bool | setColor (const std::string &name, const T &color) |
void | setInterpolated (const bool interpolate, double interpolationStart=0.f) |
void | setThreshold (const int pos, const double threshold) |
Private Attributes | |
bool | myAllowNegativeValues |
RGBColor | myBgColor |
std::vector< T > | myColors |
GUIIcon | myIcon |
bool | myIsFixed |
bool | myIsInterpolated |
std::string | myName |
std::vector< std::string > | myNames |
std::vector< double > | myThresholds |
std::string | myTranslatedName |
This class provides a mapping from real values to properties (mainly colors). Each color is stored along with a threshold value. Color values between thresholds are obtained by interpolation
Definition at line 43 of file GUIPropertyScheme.h.
|
inline |
Constructor.
Definition at line 46 of file GUIPropertyScheme.h.
References GUIPropertyScheme< T >::addColor().
|
inline |
Definition at line 60 of file GUIPropertyScheme.h.
References GUIPropertyScheme< T >::addColor().
|
inline |
Definition at line 94 of file GUIPropertyScheme.h.
References GUIPropertyScheme< T >::myColors, GUIPropertyScheme< T >::myNames, and GUIPropertyScheme< T >::myThresholds.
Referenced by GNEViewNet::buildColorRainbow(), GUIViewTraffic::buildColorRainbow(), GUISUMOAbstractView::buildMinMaxRainbow(), GUIOverheadWire::drawGL(), GUIPropertyScheme< T >::GUIPropertyScheme(), GUIPropertyScheme< T >::GUIPropertyScheme(), GUIVisualizationSettings::initNeteditDefaults(), GUIVisualizationSettings::initSumoGuiDefaults(), GUISettingsHandler::myStartElement(), GUIDialog_ViewSettings::updateColorRanges(), and GUIDialog_ViewSettings::updateScaleRanges().
|
inline |
Definition at line 179 of file GUIPropertyScheme.h.
References GUIPropertyScheme< T >::myAllowNegativeValues.
Referenced by GUIDialog_ViewSettings::rebuildColorMatrix(), and GUIDialog_ViewSettings::rebuildScaleMatrix().
|
inline |
Definition at line 118 of file GUIPropertyScheme.h.
References GUIPropertyScheme< T >::myColors, GUIPropertyScheme< T >::myNames, and GUIPropertyScheme< T >::myThresholds.
Referenced by GNEViewNet::buildColorRainbow(), GUIViewTraffic::buildColorRainbow(), GUISUMOAbstractView::buildMinMaxRainbow(), GUIOverheadWire::drawGL(), and GUISettingsHandler::myStartElement().
|
inline |
Definition at line 191 of file GUIPropertyScheme.h.
References GUIPropertyScheme< T >::myBgColor.
|
inline |
Definition at line 124 of file GUIPropertyScheme.h.
References GUIPropertyScheme< T >::interpolate(), GUIPropertyScheme< T >::myColors, GUIPropertyScheme< T >::myIsInterpolated, and GUIPropertyScheme< T >::myThresholds.
Referenced by GUIVehicle::drawAction_drawCarriageClass(), GNEEdge::drawEdgeName(), GUIJunctionWrapper::drawGL(), GUIOverheadWire::drawGL(), GUILane::drawGL(), GNEViewNet::drawTemporalJunction(), GNEViewNet::drawTemporalSplitJunction(), GNEWalkingArea::drawWalkingArea(), GUIDottedGeometry::DottedGeometryColor::getColor(), GNEDemandElement::getColorByScheme(), GUIBaseVehicle::getExaggeration(), GUIBaseVehicle::setColor(), GUIContainer::setColor(), GUIEdge::setColor(), GUILane::setColor(), GUIPerson::setColor(), GNEEdgeData::setColor(), GNEEdgeRelData::setColor(), GNETAZRelData::setColor(), GNEJunction::setColor(), GUIPointOfInterest::setColor(), GUIPolygon::setColor(), GUILane::setFunctionalColor(), GNELane::setLaneColor(), GUIEdge::setMultiColor(), GUILane::setMultiColor(), and GNELane::setMultiColor().
|
inline |
Definition at line 159 of file GUIPropertyScheme.h.
References GUIPropertyScheme< T >::myColors.
Referenced by GUISUMOAbstractView::displayColorLegend(), GUIDialog_ViewSettings::rebuildColorMatrix(), and GUIDialog_ViewSettings::rebuildScaleMatrix().
|
inline |
Definition at line 187 of file GUIPropertyScheme.h.
References GUIPropertyScheme< T >::myIcon.
|
inline |
Definition at line 151 of file GUIPropertyScheme.h.
References GUIPropertyScheme< T >::myName.
Referenced by GNEViewNet::buildColorRainbow(), GUIViewTraffic::buildColorRainbow(), GUISUMOAbstractView::buildMinMaxRainbow(), GUISUMOAbstractView::displayColorLegend(), GUIDialog_ViewSettings::onCmdColorChange(), GNEEdgeData::setColor(), and GNEEdgeRelData::setColor().
|
inline |
Definition at line 171 of file GUIPropertyScheme.h.
References GUIPropertyScheme< T >::myNames.
Referenced by GUISUMOAbstractView::displayColorLegend(), GUIDialog_ViewSettings::rebuildColorMatrix(), and GUIDialog_ViewSettings::rebuildScaleMatrix().
|
inline |
Definition at line 250 of file GUIPropertyScheme.h.
References SUMO_TAG_SCALINGSCHEME, and toString().
|
inline |
Definition at line 240 of file GUIPropertyScheme.h.
References SUMO_TAG_COLORSCHEME, and toString().
Referenced by GUIPropertyScheme< T >::save().
|
inline |
Definition at line 163 of file GUIPropertyScheme.h.
References GUIPropertyScheme< T >::myThresholds.
Referenced by GUISUMOAbstractView::displayColorLegend(), GUIDialog_ViewSettings::rebuildColorMatrix(), and GUIDialog_ViewSettings::rebuildScaleMatrix().
|
inline |
Definition at line 155 of file GUIPropertyScheme.h.
References GUIPropertyScheme< T >::myTranslatedName.
|
inline |
specializations for GUIScaleScheme
Definition at line 246 of file GUIPropertyScheme.h.
|
inline |
specializations for GUIColorScheme
Definition at line 236 of file GUIPropertyScheme.h.
References RGBColor::interpolate().
Referenced by GUIPropertyScheme< T >::getColor(), and GUIPropertyScheme< T >::setInterpolated().
|
inline |
Definition at line 175 of file GUIPropertyScheme.h.
References GUIPropertyScheme< T >::myIsFixed.
Referenced by GNEViewNet::buildColorRainbow(), GUIViewTraffic::buildColorRainbow(), GUISUMOAbstractView::displayColorLegend(), GUISettingsHandler::myStartElement(), GUIDialog_ViewSettings::rebuildColorMatrices(), GUIDialog_ViewSettings::rebuildColorMatrix(), GUIDialog_ViewSettings::rebuildScaleMatrix(), GUIDialog_ViewSettings::updateColorRanges(), and GUIDialog_ViewSettings::updateScaleRanges().
|
inline |
Definition at line 167 of file GUIPropertyScheme.h.
References GUIPropertyScheme< T >::myIsInterpolated.
Referenced by GUIDialog_ViewSettings::rebuildColorMatrix(), and GUIDialog_ViewSettings::rebuildScaleMatrix().
|
inline |
Definition at line 230 of file GUIPropertyScheme.h.
References GUIPropertyScheme< T >::myColors, GUIPropertyScheme< T >::myIsInterpolated, GUIPropertyScheme< T >::myName, and GUIPropertyScheme< T >::myThresholds.
|
inline |
Definition at line 111 of file GUIPropertyScheme.h.
References GUIPropertyScheme< T >::myColors, GUIPropertyScheme< T >::myNames, and GUIPropertyScheme< T >::myThresholds.
Referenced by GUIDialog_ViewSettings::updateColorRanges(), and GUIDialog_ViewSettings::updateScaleRanges().
|
inline |
Definition at line 195 of file GUIPropertyScheme.h.
References OutputDevice::closeTag(), OutputDevice::getPrecision(), GUIPropertyScheme< T >::getTagName(), GUIPropertyScheme< T >::myColors, GUIPropertyScheme< T >::myIsFixed, GUIPropertyScheme< T >::myIsInterpolated, GUIPropertyScheme< T >::myName, GUIPropertyScheme< T >::myNames, GUIPropertyScheme< T >::myThresholds, OutputDevice::openTag(), OutputDevice::setPrecision(), SUMO_ATTR_COLOR, SUMO_ATTR_INTERPOLATED, SUMO_ATTR_NAME, SUMO_ATTR_THRESHOLD, SUMO_TAG_ENTRY, and OutputDevice::writeAttr().
|
inline |
Definition at line 183 of file GUIPropertyScheme.h.
References GUIPropertyScheme< T >::myAllowNegativeValues.
Referenced by GUIVisualizationSettings::initNeteditDefaults(), and GUIVisualizationSettings::initSumoGuiDefaults().
|
inline |
Definition at line 78 of file GUIPropertyScheme.h.
References GUIPropertyScheme< T >::myColors.
Referenced by GUISettingsHandler::myStartElement(), GUIDialog_ViewSettings::updateColorRanges(), and GUIDialog_ViewSettings::updateScaleRanges().
|
inline |
Definition at line 82 of file GUIPropertyScheme.h.
References GUIPropertyScheme< T >::myColors, and GUIPropertyScheme< T >::myNames.
|
inline |
Definition at line 144 of file GUIPropertyScheme.h.
References GUIPropertyScheme< T >::interpolate(), GUIPropertyScheme< T >::myIsInterpolated, and GUIPropertyScheme< T >::myThresholds.
Referenced by GUISettingsHandler::myStartElement(), and GUIDialog_ViewSettings::onCmdColorChange().
|
inline |
Definition at line 74 of file GUIPropertyScheme.h.
References GUIPropertyScheme< T >::myThresholds.
Referenced by GUIDialog_ViewSettings::updateColorRanges(), and GUIDialog_ViewSettings::updateScaleRanges().
|
private |
Definition at line 263 of file GUIPropertyScheme.h.
Referenced by GUIPropertyScheme< T >::allowsNegativeValues(), and GUIPropertyScheme< T >::setAllowsNegativeValues().
|
private |
Definition at line 265 of file GUIPropertyScheme.h.
Referenced by GUIPropertyScheme< T >::getBackgroundColor().
|
private |
Definition at line 258 of file GUIPropertyScheme.h.
Referenced by GUIPropertyScheme< T >::addColor(), GUIPropertyScheme< T >::clear(), GUIPropertyScheme< T >::getColor(), GUIPropertyScheme< T >::getColors(), GUIPropertyScheme< T >::operator==(), GUIPropertyScheme< T >::removeColor(), GUIPropertyScheme< T >::save(), GUIPropertyScheme< T >::setColor(), and GUIPropertyScheme< T >::setColor().
|
private |
Definition at line 264 of file GUIPropertyScheme.h.
Referenced by GUIPropertyScheme< T >::getIcon().
|
private |
Definition at line 262 of file GUIPropertyScheme.h.
Referenced by GUIPropertyScheme< T >::isFixed(), and GUIPropertyScheme< T >::save().
|
private |
Definition at line 260 of file GUIPropertyScheme.h.
Referenced by GUIPropertyScheme< T >::getColor(), GUIPropertyScheme< T >::isInterpolated(), GUIPropertyScheme< T >::operator==(), GUIPropertyScheme< T >::save(), and GUIPropertyScheme< T >::setInterpolated().
|
private |
Definition at line 256 of file GUIPropertyScheme.h.
Referenced by GUIPropertyScheme< T >::getName(), GUIPropertyScheme< T >::operator==(), and GUIPropertyScheme< T >::save().
|
private |
Definition at line 261 of file GUIPropertyScheme.h.
Referenced by GUIPropertyScheme< T >::addColor(), GUIPropertyScheme< T >::clear(), GUIPropertyScheme< T >::getNames(), GUIPropertyScheme< T >::removeColor(), GUIPropertyScheme< T >::save(), and GUIPropertyScheme< T >::setColor().
|
private |
Definition at line 259 of file GUIPropertyScheme.h.
Referenced by GUIPropertyScheme< T >::addColor(), GUIPropertyScheme< T >::clear(), GUIPropertyScheme< T >::getColor(), GUIPropertyScheme< T >::getThresholds(), GUIPropertyScheme< T >::operator==(), GUIPropertyScheme< T >::removeColor(), GUIPropertyScheme< T >::save(), GUIPropertyScheme< T >::setInterpolated(), and GUIPropertyScheme< T >::setThreshold().
|
private |
Definition at line 257 of file GUIPropertyScheme.h.
Referenced by GUIPropertyScheme< T >::getTranslatedName().