![]() |
SUMO - Simulation of Urban MObility
|
#include <GNEPolygonFrame.h>


Data Structures | |
| class | DrawingMode |
| class | NeteditAttributes |
| class | ShapeAttributes |
| class | ShapeAttributeSingle |
| class | ShapeSelector |
Public Types | |
| enum | AddShapeResult { ADDSHAPE_SUCCESS, ADDSHAPE_NEWPOINT, ADDSHAPE_INVALID, ADDSHAPE_NOTHING } |
| enum with all possible values after try to create an shape using frame More... | |
Public Member Functions | |
| bool | buildPoly (const PositionVector &drawedShape) |
| build Polygon using values of Fields and drawed shape return true if was sucesfully created More... | |
| void | focusUpperElement () |
| focus upper element of frame More... | |
| DrawingMode * | getDrawingMode () const |
| get drawing mode editor More... | |
| FXFont * | getFrameHeaderFont () const |
| get font of the header's frame More... | |
| FXLabel * | getFrameHeaderLabel () const |
| get the label for the frame's header More... | |
| NeteditAttributes * | getNeteditAttributes () const |
| get netedit attributes editor More... | |
| ShapeAttributes * | getShapeAttributes () const |
| get shape attributes More... | |
| ShapeSelector * | getShapeSelector () const |
| get shape selector More... | |
| GNEViewNet * | getViewNet () const |
| get view net More... | |
| GNEPolygonFrame (FXHorizontalFrame *horizontalFrameParent, GNEViewNet *viewNet) | |
| Constructor. More... | |
| virtual void | hide () |
| hide Frame More... | |
| AddShapeResult | processClick (const Position &clickedPosition, GNELane *lane) |
| process click over Viewnet More... | |
| void | setFrameWidth (int newWidth) |
| set width of GNEFrame More... | |
| void | show () |
| show shape frame and update use selected edges/lanes More... | |
| ~GNEPolygonFrame () | |
| Destructor. More... | |
Static Public Member Functions | |
| static std::string | getIdsSelected (const FXList *list) |
| get list of selecte id's in string format More... | |
Protected Member Functions | |
| bool | addPOI (const std::map< SumoXMLAttr, std::string > &POIValues) |
| add POI More... | |
| bool | addPOILane (const std::map< SumoXMLAttr, std::string > &POIValues) |
| add POILane More... | |
| bool | addPolygon (const std::map< SumoXMLAttr, std::string > &POIValues) |
| add Polygon More... | |
| void | openHelpAttributesDialog (SumoXMLTag tag) const |
| Open help attributes dialog. More... | |
Protected Attributes | |
| FXVerticalFrame * | myContentFrame |
| Vertical frame that holds all widgets of frame. More... | |
| FXHorizontalFrame * | myHeaderFrame |
| fame for header elements More... | |
| FXHorizontalFrame * | myHeaderLeftFrame |
| fame for left header elements More... | |
| FXHorizontalFrame * | myHeaderRightFrame |
| fame for right header elements More... | |
| GNEViewNet * | myViewNet |
| View Net for changes. More... | |
Private Attributes | |
| DrawingMode * | myDrawingMode |
| drawing mode More... | |
| NeteditAttributes * | myNeteditAttributes |
| Netedit parameter. More... | |
| ShapeAttributes * | myShapeAttributes |
| shape internal attributes More... | |
| ShapeSelector * | myShapeSelector |
| additional selector More... | |
The Widget for setting internal attributes of shape elements
Definition at line 42 of file GNEPolygonFrame.h.
enum with all possible values after try to create an shape using frame
| Enumerator | |
|---|---|
| ADDSHAPE_SUCCESS | |
| ADDSHAPE_NEWPOINT | |
| ADDSHAPE_INVALID | |
| ADDSHAPE_NOTHING | |
Definition at line 47 of file GNEPolygonFrame.h.
| GNEPolygonFrame::GNEPolygonFrame | ( | FXHorizontalFrame * | horizontalFrameParent, |
| GNEViewNet * | viewNet | ||
| ) |
Constructor.
parent FXHorizontalFrame in which this GNEFrame is placed viewNet viewNet that uses this GNEFrame
Definition at line 810 of file GNEPolygonFrame.cpp.
References myDrawingMode, myNeteditAttributes, myShapeAttributes, myShapeSelector, GNEPolygonFrame::ShapeSelector::setCurrentShape(), and SUMO_TAG_POLY.
| GNEPolygonFrame::~GNEPolygonFrame | ( | ) |
Destructor.
Definition at line 830 of file GNEPolygonFrame.cpp.
|
protected |
add POI
Definition at line 1013 of file GNEPolygonFrame.cpp.
References GNENet::addPOI(), Shape::DEFAULT_LAYER_POI, GNEViewNet::getNet(), GNEViewNet::getUndoList(), GNE_ATTR_BLOCK_MOVEMENT, GNEFrame::myViewNet, GNEUndoList::p_abort(), GNEUndoList::p_begin(), GNEUndoList::p_end(), RGBColor::parseColor(), GeomConvHelper::parseShapeReporting(), GNENet::retrievePOI(), GNEPOI::setAttribute(), SUMO_ATTR_ANGLE, SUMO_ATTR_COLOR, SUMO_ATTR_HEIGHT, SUMO_ATTR_ID, SUMO_ATTR_IMGFILE, SUMO_ATTR_LAYER, SUMO_ATTR_POSITION, SUMO_ATTR_RELATIVEPATH, SUMO_ATTR_TYPE, SUMO_ATTR_WIDTH, SUMO_TAG_POI, and toString().
Referenced by processClick().
|
protected |
add POILane
Definition at line 1045 of file GNEPolygonFrame.cpp.
References GNENet::addPOI(), Shape::DEFAULT_LAYER_POI, GNEViewNet::getNet(), GNEViewNet::getUndoList(), GNE_ATTR_BLOCK_MOVEMENT, GNEFrame::myViewNet, GNEUndoList::p_abort(), GNEUndoList::p_begin(), GNEUndoList::p_end(), RGBColor::parseColor(), GNENet::retrieveLane(), GNENet::retrievePOI(), GNEPOI::setAttribute(), SUMO_ATTR_ANGLE, SUMO_ATTR_COLOR, SUMO_ATTR_HEIGHT, SUMO_ATTR_ID, SUMO_ATTR_IMGFILE, SUMO_ATTR_LANE, SUMO_ATTR_LAYER, SUMO_ATTR_POSITION, SUMO_ATTR_POSITION_LAT, SUMO_ATTR_RELATIVEPATH, SUMO_ATTR_TYPE, SUMO_ATTR_WIDTH, SUMO_TAG_POILANE, and toString().
Referenced by processClick().
|
protected |
add Polygon
Definition at line 981 of file GNEPolygonFrame.cpp.
References GNENet::addPolygon(), Shape::DEFAULT_LAYER, GNEViewNet::getNet(), GNEViewNet::getUndoList(), GNE_ATTR_BLOCK_MOVEMENT, GNE_ATTR_BLOCK_SHAPE, GNEFrame::myViewNet, GNEUndoList::p_abort(), GNEUndoList::p_begin(), GNEUndoList::p_end(), RGBColor::parseColor(), GeomConvHelper::parseShapeReporting(), GNENet::retrievePolygon(), GNEPoly::setAttribute(), SUMO_ATTR_ANGLE, SUMO_ATTR_COLOR, SUMO_ATTR_FILL, SUMO_ATTR_ID, SUMO_ATTR_IMGFILE, SUMO_ATTR_LAYER, SUMO_ATTR_RELATIVEPATH, SUMO_ATTR_SHAPE, SUMO_ATTR_TYPE, SUMO_TAG_POLY, and toString().
Referenced by buildPoly().
| bool GNEPolygonFrame::buildPoly | ( | const PositionVector & | drawedShape | ) |
build Polygon using values of Fields and drawed shape return true if was sucesfully created
Definition at line 904 of file GNEPolygonFrame.cpp.
References addPolygon(), GNEPolygonFrame::ShapeAttributes::areValuesValid(), GNENet::generateShapeID(), GNEPolygonFrame::ShapeAttributes::getAttributesAndValues(), GNEViewNet::getNet(), GNE_ATTR_BLOCK_MOVEMENT, GNE_ATTR_BLOCK_SHAPE, GNEPolygonFrame::NeteditAttributes::isBlockMovementEnabled(), GNEPolygonFrame::NeteditAttributes::isBlockShapeEnabled(), myNeteditAttributes, myShapeAttributes, GNEFrame::myViewNet, GNEPolygonFrame::ShapeAttributes::showWarningMessage(), SUMO_ATTR_GEO, SUMO_ATTR_ID, SUMO_ATTR_SHAPE, SUMO_TAG_POLY, and toString().
Referenced by GNEPolygonFrame::DrawingMode::stopDrawing().
|
inherited |
focus upper element of frame
Definition at line 735 of file GNEFrame.cpp.
References GNEFrame::myFrameHeaderLabel.
Referenced by GNEViewNet::hotkeyFocusFrame(), GNEViewNet::onLeftBtnPress(), GNEViewNet::setEditMode(), and GNEViewNet::updateModeSpecificControls().
| GNEPolygonFrame::DrawingMode * GNEPolygonFrame::getDrawingMode | ( | ) | const |
get drawing mode editor
Definition at line 976 of file GNEPolygonFrame.cpp.
References myDrawingMode.
Referenced by GNEViewNet::abortOperation(), GNEViewNet::doPaintGL(), GNEViewNet::hotkeyEnter(), GNEViewNet::onRightBtnPress(), GNEViewNet::onRightBtnRelease(), and GNEPolygonFrame::ShapeSelector::setCurrentShape().
|
inherited |
get font of the header's frame
Definition at line 778 of file GNEFrame.cpp.
References GNEFrame::myFrameHeaderFont.
|
inherited |
get the label for the frame's header
Definition at line 772 of file GNEFrame.cpp.
References GNEFrame::myFrameHeaderLabel.
Referenced by GNEProhibitionFrame::GNEProhibitionFrame(), and GNEInspectorFrame::inspectMultisection().
|
static |
get list of selecte id's in string format
Definition at line 942 of file GNEPolygonFrame.cpp.
| GNEPolygonFrame::NeteditAttributes * GNEPolygonFrame::getNeteditAttributes | ( | ) | const |
get netedit attributes editor
Definition at line 970 of file GNEPolygonFrame.cpp.
References myNeteditAttributes.
Referenced by GNEPolygonFrame::ShapeSelector::setCurrentShape(), and GNEPolygonFrame::DrawingMode::stopDrawing().
| GNEPolygonFrame::ShapeAttributes * GNEPolygonFrame::getShapeAttributes | ( | ) | const |
get shape attributes
Definition at line 964 of file GNEPolygonFrame.cpp.
References myShapeAttributes.
Referenced by GNEPolygonFrame::ShapeSelector::setCurrentShape().
| GNEPolygonFrame::ShapeSelector * GNEPolygonFrame::getShapeSelector | ( | ) | const |
get shape selector
Definition at line 958 of file GNEPolygonFrame.cpp.
References myShapeSelector.
Referenced by GNEPolygonFrame::ShapeAttributes::addAttribute(), GNEPolygonFrame::ShapeAttributeSingle::getValue(), GNEPolygonFrame::ShapeAttributes::onCmdHelp(), GNEPolygonFrame::ShapeAttributeSingle::onCmdSetAttribute(), GNEPolygonFrame::ShapeAttributeSingle::onCmdSetColorAttribute(), and GNEPolygonFrame::ShapeAttributes::showWarningMessage().
|
inherited |
get view net
Definition at line 766 of file GNEFrame.cpp.
References GNEFrame::myViewNet.
Referenced by GNEPolygonFrame::DrawingMode::abortDrawing(), GNETLSEditorFrame::TLSFile::checkTLSValids(), GNEFrame::ACHierarchy::createPopUpMenu(), GNECrossingFrame::edgesSelector::enableEdgeSelector(), GNETLSEditorFrame::TLSFile::myStartElement(), GNEFrame::ACHierarchy::onCmdCenterItem(), GNEInspectorFrame::TemplateEditor::onCmdCopyTemplate(), GNEFrame::ACHierarchy::onCmdDeleteItem(), GNEFrame::GenericParametersEditor::onCmdEditGenericParameter(), GNEFrame::ACHierarchy::onCmdInspectItem(), GNESelectorFrame::SelectionOperation::onCmdInvert(), GNESelectorFrame::SelectionOperation::onCmdLoad(), GNEInspectorFrame::AttributesEditor::AttributeInput::onCmdOpenAttributeDialog(), GNESelectorFrame::VisualScaling::onCmdScaleSelection(), GNEInspectorFrame::AttributesEditor::AttributeInput::onCmdSetAttribute(), GNECrossingFrame::crossingParameters::onCmdSetAttribute(), GNEFrame::GenericParametersEditor::onCmdSetGenericParameter(), GNEInspectorFrame::GEOAttributesEditor::onCmdSetGEOAttribute(), GNEInspectorFrame::NeteditAttributesEditor::onCmdSetNeteditAttribute(), GNEAdditionalFrame::SelectorParentAdditional::refreshListOfAdditionalParents(), GNEDeleteFrame::removeAttributeCarrier(), GNECrossingFrame::edgesSelector::restoreEdgeColors(), GNEFrame::ACHierarchy::showAttributeCarrierChilds(), GNEFrame::ACHierarchy::showAttributeCarrierParents(), GNEAdditionalFrame::SelectorParentEdges::showList(), GNEAdditionalFrame::SelectorParentLanes::showList(), GNEInspectorFrame::NeteditAttributesEditor::showNeteditAttributesEditor(), GNEAdditionalFrame::AdditionalAttributes::showWarningMessage(), GNEPolygonFrame::ShapeAttributes::showWarningMessage(), GNEPolygonFrame::DrawingMode::stopDrawing(), GNESelectorFrame::LockGLObjectTypes::updateLockGLObjectTypes(), GNEAdditionalFrame::SelectorParentEdges::updateUseSelectedEdges(), and GNEAdditionalFrame::SelectorParentLanes::updateUseSelectedLanes().
|
virtualinherited |
hide Frame
Reimplemented in GNEInspectorFrame, GNESelectorFrame, GNECrossingFrame, GNEDeleteFrame, and GNEProhibitionFrame.
Definition at line 750 of file GNEFrame.cpp.
References GNEViewNet::getViewParent(), GNEViewParent::hideFramesArea(), and GNEFrame::myViewNet.
Referenced by GNEProhibitionFrame::hide(), GNEDeleteFrame::hide(), GNECrossingFrame::hide(), GNESelectorFrame::hide(), GNEInspectorFrame::hide(), GNEFrame::ACHierarchy::hideACHierarchy(), GNEAdditionalFrame::AdditionalAttributes::hideAdditionalParameters(), GNEFrame::GenericParametersEditor::hideGenericParametersEditor(), GNEAdditionalFrame::SelectorParentLanes::hideList(), GNEAdditionalFrame::SelectorParentAdditional::hideListOfAdditionalParents(), GNEAdditionalFrame::NeteditAttributes::hideNeteditAttributes(), GNEAdditionalFrame::AdditionalAttributeSingle::hideParameter(), GNEPolygonFrame::ShapeAttributeSingle::hideParameter(), and GNEPolygonFrame::ShapeAttributes::hideShapeParameters().
|
protectedinherited |
Open help attributes dialog.
Definition at line 784 of file GNEFrame.cpp.
References GUIIconSubSys::getIcon(), GNEAttributeCarrier::getTagProperties(), GUIDesignAuxiliarHorizontalFrame, GUIDesignButtonOK, GUIDesignDialogBoxResizable, GUIDesignHorizontalSeparator, GUIDesignTableNotEditable, ICON_ACCEPT, ICON_MODEINSPECT, MAX2(), MID_TABLE, GNEFrame::myScrollWindowsContents, toString(), and WRITE_DEBUG.
Referenced by GNEFrame::GNEFrame(), GNEInspectorFrame::AttributesEditor::onCmdAttributeHelp(), GNECrossingFrame::crossingParameters::onCmdHelp(), GNEAdditionalFrame::AdditionalAttributes::onCmdHelp(), and GNEPolygonFrame::ShapeAttributes::onCmdHelp().
| GNEPolygonFrame::AddShapeResult GNEPolygonFrame::processClick | ( | const Position & | clickedPosition, |
| GNELane * | lane | ||
| ) |
process click over Viewnet
| [in] | clickedPosition | clicked position over ViewNet |
| [in] | lane | clicked lane |
Definition at line 835 of file GNEPolygonFrame.cpp.
References GNEPolygonFrame::DrawingMode::addNewPoint(), addPOI(), addPOILane(), ADDSHAPE_INVALID, ADDSHAPE_NEWPOINT, ADDSHAPE_NOTHING, ADDSHAPE_SUCCESS, GNEPolygonFrame::ShapeAttributes::areValuesValid(), GNENet::generateShapeID(), GNEPolygonFrame::ShapeAttributes::getAttributesAndValues(), GNEPolygonFrame::ShapeSelector::getCurrentShapeType(), GNEAttributeCarrier::getID(), GNEViewNet::getNet(), GNELane::getShape(), GNE_ATTR_BLOCK_MOVEMENT, GNEPolygonFrame::NeteditAttributes::isBlockMovementEnabled(), GNEPolygonFrame::DrawingMode::isDrawing(), myDrawingMode, myNeteditAttributes, myShapeAttributes, myShapeSelector, GNEFrame::myViewNet, PositionVector::nearest_offset_to_point2D(), GNEViewNet::setStatusBarText(), GNEPolygonFrame::ShapeAttributes::showWarningMessage(), SUMO_ATTR_ID, SUMO_ATTR_LANE, SUMO_ATTR_POSITION, SUMO_TAG_POI, SUMO_TAG_POILANE, SUMO_TAG_POLY, toString(), and WRITE_WARNING.
Referenced by GNEViewNet::onLeftBtnPress().
|
inherited |
set width of GNEFrame
Definition at line 759 of file GNEFrame.cpp.
References GNEFrame::myScrollWindowsContents.
|
virtual |
show shape frame and update use selected edges/lanes
Reimplemented from GNEFrame.
Definition at line 935 of file GNEPolygonFrame.cpp.
References GNEFrame::show().
Referenced by GNEPolygonFrame::ShapeAttributeSingle::showParameter(), GNEPolygonFrame::ShapeAttributes::showShapeParameters(), and GNEViewNet::updateModeSpecificControls().
|
protectedinherited |
Vertical frame that holds all widgets of frame.
Definition at line 235 of file GNEFrame.h.
Referenced by GNEConnectorFrame::GNEConnectorFrame(), GNECrossingFrame::GNECrossingFrame(), GNEFrame::GNEFrame(), GNEProhibitionFrame::GNEProhibitionFrame(), and GNEInspectorFrame::inspectMultisection().
|
private |
drawing mode
Definition at line 445 of file GNEPolygonFrame.h.
Referenced by getDrawingMode(), GNEPolygonFrame(), and processClick().
|
protectedinherited |
fame for header elements
Definition at line 238 of file GNEFrame.h.
Referenced by GNEFrame::GNEFrame().
|
protectedinherited |
fame for left header elements
Definition at line 241 of file GNEFrame.h.
Referenced by GNEFrame::GNEFrame(), GNEInspectorFrame::inspectChild(), GNEInspectorFrame::inspectFromDeleteFrame(), and GNEInspectorFrame::inspectMultisection().
|
protectedinherited |
fame for right header elements
Definition at line 244 of file GNEFrame.h.
Referenced by GNEFrame::GNEFrame().
|
private |
Netedit parameter.
Definition at line 442 of file GNEPolygonFrame.h.
Referenced by buildPoly(), getNeteditAttributes(), GNEPolygonFrame(), and processClick().
|
private |
shape internal attributes
Definition at line 439 of file GNEPolygonFrame.h.
Referenced by buildPoly(), getShapeAttributes(), GNEPolygonFrame(), and processClick().
|
private |
additional selector
Definition at line 436 of file GNEPolygonFrame.h.
Referenced by GNEPolygonFrame::ShapeAttributes::areValuesValid(), getShapeSelector(), GNEPolygonFrame(), processClick(), GNEPolygonFrame::ShapeAttributeSingle::showParameter(), and GNEPolygonFrame::ShapeAttributes::showWarningMessage().
|
protectedinherited |
View Net for changes.
Definition at line 232 of file GNEFrame.h.
Referenced by GNEAdditionalFrame::addAdditional(), addPOI(), addPOILane(), addPolygon(), GNETLSEditorFrame::buildIinternalLanes(), buildPoly(), GNESelectorFrame::clearCurrentSelection(), GNEInspectorFrame::clearInspectedAC(), GNETLSEditorFrame::editJunction(), GNEAdditionalFrame::generateID(), GNESelectorFrame::getMatches(), GNEFrame::getViewNet(), GNETLSEditorFrame::handleChange(), GNESelectorFrame::handleIDs(), GNEConnectorFrame::handleLaneClick(), GNETLSEditorFrame::handleMultiChange(), GNEFrame::hide(), GNEInspectorFrame::hide(), GNEConnectorFrame::initTargets(), GNEInspectorFrame::inspectElement(), GNEConnectorFrame::onCmdCancel(), GNEProhibitionFrame::onCmdCancel(), GNETLSEditorFrame::onCmdCancel(), GNEConnectorFrame::onCmdClearSelectedConnections(), GNECrossingFrame::onCmdCreateCrossing(), GNETLSEditorFrame::onCmdDefCreate(), GNETLSEditorFrame::onCmdDefDelete(), GNETLSEditorFrame::onCmdDefSwitch(), GNEInspectorFrame::onCmdGoBack(), GNEConnectorFrame::onCmdOK(), GNETLSEditorFrame::onCmdOK(), GNETLSEditorFrame::onCmdPhaseSwitch(), GNEConnectorFrame::onCmdResetSelectedConnections(), GNESelectorFrame::SelectionOperation::onCmdSave(), GNEConnectorFrame::onCmdSelectConflicts(), GNEConnectorFrame::onCmdSelectDeadEnds(), GNEConnectorFrame::onCmdSelectDeadStarts(), GNEConnectorFrame::onCmdSelectPass(), GNETLSEditorFrame::parseTLSPrograms(), processClick(), GNEAdditionalFrame::removeAdditional(), GNEDeleteFrame::removeAttributeCarrier(), GNEDeleteFrame::removeSelectedAttributeCarriers(), GNEDeleteFrame::show(), and GNEFrame::show().