Eclipse SUMO - Simulation of Urban MObility
GNEPolygonFrame Class Reference

#include <GNEPolygonFrame.h>

Inheritance diagram for GNEPolygonFrame:
Collaboration diagram for GNEPolygonFrame:

Data Structures

class  GEOPOICreator
 

Public Types

enum  AddShapeResult { ADDSHAPE_SUCCESS, ADDSHAPE_UPDATEDTEMPORALSHAPE, ADDSHAPE_INVALID, ADDSHAPE_NOTHING }
 enum with all possible values after try to create an shape using frame More...
 

Public Member Functions

void focusUpperElement ()
 focus upper element of frame More...
 
GNEFrameModuls::DrawingShapegetDrawingShapeModul () 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...
 
GNEViewNetgetViewNet () const
 get view net More...
 
 GNEPolygonFrame (FXHorizontalFrame *horizontalFrameParent, GNEViewNet *viewNet)
 Constructor. More...
 
virtual void hide ()
 hide Frame More...
 
AddShapeResult processClick (const Position &clickedPosition, const GNEViewNetHelper::ObjectsUnderCursor &objectsUnderCursor)
 process click over Viewnet More...
 
void setFrameWidth (int newWidth)
 set width of GNEFrame More...
 
void show ()
 show Frame More...
 
virtual void updateFrameAfterUndoRedo ()
 function called after undo/redo in the current frame (can be reimplemented in frame children) 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...
 
const RGBColorgetEdgeCandidateColor () const
 get edge candidate color More...
 
const RGBColorgetEdgeCandidateSelectedColor () const
 get selected color More...
 
const std::map< int, std::string > & getPredefinedTagsMML () const
 get predefinedTagsMML More...
 
void openHelpAttributesDialog (const GNEAttributeCarrier::TagProperties &tagProperties) const
 Open help attributes dialog. More...
 
bool shapeDrawed ()
 build a shaped element using the drawed shape return true if was sucesfully created More...
 
void tagSelected ()
 Tag selected in TagSelector. More...
 
functions called by moduls that can be reimplemented in frame children
virtual void demandElementSelected ()
 selected demand element in DemandElementSelector More...
 
virtual void edgePathCreated ()
 finish edge path creation More...
 
virtual void attributeUpdated ()
 function called after set a valid attribute in AttributeCreator/AttributeEditor/GenericParametersEditor/... More...
 
virtual void attributesEditorExtendedDialogOpened ()
 open AttributesCreator extended dialog (can be reimplemented in frame children) 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...
 
GNEViewNetmyViewNet
 View Net. More...
 

Private Attributes

GNEFrameModuls::DrawingShapemyDrawingShape
 Drawing shape. More...
 
GEOPOICreatormyGEOPOICreator
 GEOPOICreator. More...
 
GNEFrameAttributesModuls::NeteditAttributesmyNeteditAttributes
 Netedit parameter. More...
 
GNEFrameAttributesModuls::AttributesCreatormyShapeAttributes
 shape internal attributes More...
 
GNEFrameModuls::TagSelectormyShapeTagSelector
 shape tag selector More...
 

Detailed Description

The Widget for setting internal attributes of shape elements

Definition at line 34 of file GNEPolygonFrame.h.

Member Enumeration Documentation

◆ AddShapeResult

enum with all possible values after try to create an shape using frame

Enumerator
ADDSHAPE_SUCCESS 
ADDSHAPE_UPDATEDTEMPORALSHAPE 
ADDSHAPE_INVALID 
ADDSHAPE_NOTHING 

Definition at line 39 of file GNEPolygonFrame.h.

Constructor & Destructor Documentation

◆ GNEPolygonFrame()

GNEPolygonFrame::GNEPolygonFrame ( FXHorizontalFrame *  horizontalFrameParent,
GNEViewNet viewNet 
)

Constructor.

parent FXHorizontalFrame in which this GNEFrame is placed viewNet viewNet that uses this GNEFrame

create GEOPOICreator

Definition at line 215 of file GNEPolygonFrame.cpp.

References myDrawingShape, myGEOPOICreator, myNeteditAttributes, myShapeAttributes, myShapeTagSelector, GNEFrameModuls::TagSelector::setCurrentTag(), and SUMO_TAG_POLY.

◆ ~GNEPolygonFrame()

GNEPolygonFrame::~GNEPolygonFrame ( )

Destructor.

Definition at line 238 of file GNEPolygonFrame.cpp.

Member Function Documentation

◆ addPOI()

◆ addPOILane()

◆ addPolygon()

◆ attributesEditorExtendedDialogOpened()

void GNEFrame::attributesEditorExtendedDialogOpened ( )
protectedvirtualinherited

open AttributesCreator extended dialog (can be reimplemented in frame children)

Reimplemented in GNEVehicleTypeFrame.

Definition at line 191 of file GNEFrame.cpp.

Referenced by GNEFrame::GNEFrame(), and GNEFrameAttributesModuls::AttributesEditorExtended::onCmdOpenDialog().

◆ attributeUpdated()

void GNEFrame::attributeUpdated ( )
protectedvirtualinherited

◆ demandElementSelected()

void GNEFrame::demandElementSelected ( )
protectedvirtualinherited

◆ edgePathCreated()

void GNEFrame::edgePathCreated ( )
protectedvirtualinherited

finish edge path creation

Reimplemented in GNEVehicleFrame, and GNEPersonFrame.

Definition at line 172 of file GNEFrame.cpp.

Referenced by GNEFrame::GNEFrame(), and GNEFrameModuls::EdgePathCreator::onCmdFinishRouteCreation().

◆ focusUpperElement()

◆ getDrawingShapeModul()

◆ getEdgeCandidateColor()

◆ getEdgeCandidateSelectedColor()

◆ getFrameHeaderFont()

FXFont * GNEFrame::getFrameHeaderFont ( ) const
inherited

get font of the header's frame

Definition at line 145 of file GNEFrame.cpp.

References GNEFrame::myFrameHeaderFont.

◆ getFrameHeaderLabel()

FXLabel * GNEFrame::getFrameHeaderLabel ( ) const
inherited

get the label for the frame's header

Definition at line 139 of file GNEFrame.cpp.

References GNEFrame::myFrameHeaderLabel.

Referenced by GNEProhibitionFrame::GNEProhibitionFrame(), and GNEInspectorFrame::inspectMultisection().

◆ getIdsSelected()

std::string GNEPolygonFrame::getIdsSelected ( const FXList *  list)
static

get list of selecte id's in string format

Definition at line 326 of file GNEPolygonFrame.cpp.

◆ getPredefinedTagsMML()

◆ getViewNet()

GNEViewNet * GNEFrame::getViewNet ( ) const
inherited

get view net

Definition at line 133 of file GNEFrame.cpp.

References GNEFrame::myViewNet.

Referenced by GNEAdditionalFrame::SelectorLaneParents::abortConsecutiveLaneSelector(), GNEFrameModuls::EdgePathCreator::addEdge(), GNEAdditionalFrame::SelectorLaneParents::addSelectedLane(), GNECrossingFrame::EdgesSelector::enableEdgeSelector(), GNEAdditionalFrame::SelectorEdgeChildren::getEdgeIdsSelected(), GNEAdditionalFrame::SelectorLaneChildren::getLaneIdsSelected(), GNEInspectorFrame::OverlappedInspection::inspectOverlappedAttributeCarrier(), GNERouteFrame::ConsecutiveEdges::onCmdAbortRoute(), GNERouteFrame::NonConsecutiveEdges::onCmdAbortRoute(), GNEConnectorFrame::ConnectionModifications::onCmdCancelModifications(), GNEConnectorFrame::ConnectionOperations::onCmdClearSelectedConnections(), GNEInspectorFrame::TemplateEditor::onCmdCopyTemplate(), GNERouteFrame::ConsecutiveEdges::onCmdCreateRoute(), GNERouteFrame::NonConsecutiveEdges::onCmdCreateRoute(), GNETLSEditorFrame::TLSFile::onCmdLoadTLSProgram(), GNERouteFrame::ConsecutiveEdges::onCmdRemoveLastRouteEdge(), GNEPersonTypeFrame::PersonTypeEditor::onCmdResetPersonType(), GNEConnectorFrame::ConnectionOperations::onCmdResetSelectedConnections(), GNEVehicleTypeFrame::VehicleTypeEditor::onCmdResetVehicleType(), GNEConnectorFrame::ConnectionModifications::onCmdSaveModifications(), GNEConnectorFrame::ConnectionOperations::onCmdSelectConflicts(), GNEConnectorFrame::ConnectionOperations::onCmdSelectDeadEnds(), GNEConnectorFrame::ConnectionOperations::onCmdSelectDeadStarts(), GNEFrameModuls::DemandElementSelector::onCmdSelectDemandElement(), GNEPersonTypeFrame::PersonTypeSelector::onCmdSelectItem(), GNEVehicleTypeFrame::VehicleTypeSelector::onCmdSelectItem(), GNEConnectorFrame::ConnectionOperations::onCmdSelectPass(), GNECrossingFrame::CrossingParameters::onCmdSetAttribute(), GNEInspectorFrame::GEOAttributesEditor::onCmdSetGEOAttribute(), GNEInspectorFrame::NeteditAttributesEditor::onCmdSetNeteditAttribute(), GNEFrameModuls::DemandElementSelector::refreshDemandElementSelector(), GNERouteFrame::ConsecutiveEdges::refreshEdgeCandidates(), GNEPersonTypeFrame::PersonTypeSelector::refreshPersonTypeSelector(), GNEFrameModuls::SelectorParent::refreshSelectorParentModul(), GNEVehicleTypeFrame::VehicleTypeSelector::refreshVehicleTypeSelector(), GNEDeleteFrame::removeAttributeCarrier(), GNECrossingFrame::EdgesSelector::restoreEdgeColors(), GNEInspectorFrame::GEOAttributesEditor::showGEOAttributesEditor(), GNEInspectorFrame::NeteditAttributesEditor::showNeteditAttributesEditor(), GNEAdditionalFrame::SelectorEdgeChildren::showSelectorEdgeChildrenModul(), GNEAdditionalFrame::SelectorLaneChildren::showSelectorLaneChildrenModul(), GNEInspectorFrame::TemplateEditor::showTemplateEditor(), GNEAdditionalFrame::SelectorEdgeChildren::updateUseSelectedEdges(), and GNEAdditionalFrame::SelectorLaneChildren::updateUseSelectedLanes().

◆ hide()

◆ openHelpAttributesDialog()

◆ processClick()

GNEPolygonFrame::AddShapeResult GNEPolygonFrame::processClick ( const Position clickedPosition,
const GNEViewNetHelper::ObjectsUnderCursor objectsUnderCursor 
)

process click over Viewnet

Parameters
[in]clickedPositionclicked position over ViewNet
[in]ObjectsUnderCursorobjects under cursor after click over view
Returns
AddShapeStatus with the result of operation

Definition at line 252 of file GNEPolygonFrame.cpp.

References GNEFrameModuls::DrawingShape::addNewPoint(), addPOI(), addPOILane(), ADDSHAPE_INVALID, ADDSHAPE_NOTHING, ADDSHAPE_SUCCESS, ADDSHAPE_UPDATEDTEMPORALSHAPE, GNEFrameAttributesModuls::AttributesCreator::areValuesValid(), GNENet::generateShapeID(), GNEFrameAttributesModuls::AttributesCreator::getAttributesAndValues(), GNEFrameModuls::TagSelector::getCurrentTagProperties(), GNEFrameModuls::DrawingShape::getDeleteLastCreatedPoint(), GNENetElement::getGeometry(), GNEAttributeCarrier::getID(), GNEViewNetHelper::ObjectsUnderCursor::getLaneFront(), GNEViewNet::getNet(), GNEFrameAttributesModuls::NeteditAttributes::getNeteditAttributesAndValues(), GNEAttributeCarrier::TagProperties::getTag(), GNEFrameModuls::DrawingShape::isDrawing(), myDrawingShape, myNeteditAttributes, myShapeAttributes, myShapeTagSelector, GNEFrame::myViewNet, PositionVector::nearest_offset_to_point2D(), GNEFrameModuls::DrawingShape::removeLastPoint(), GNEViewNet::setStatusBarText(), GNENetElement::NetElementGeometry::shape, GNEFrameAttributesModuls::AttributesCreator::showWarningMessage(), SUMO_ATTR_GEO, 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::processLeftButtonPressNetwork().

◆ setFrameWidth()

void GNEFrame::setFrameWidth ( int  newWidth)
inherited

set width of GNEFrame

Definition at line 126 of file GNEFrame.cpp.

References GNEFrame::myScrollWindowsContents.

Referenced by GNEViewParent::Frames::setWidth().

◆ shapeDrawed()

◆ show()

◆ tagSelected()

◆ updateFrameAfterUndoRedo()

void GNEFrame::updateFrameAfterUndoRedo ( )
virtualinherited

function called after undo/redo in the current frame (can be reimplemented in frame children)

Reimplemented in GNEInspectorFrame.

Definition at line 151 of file GNEFrame.cpp.

Referenced by GNEApplicationWindow::onCmdRedo(), and GNEApplicationWindow::onCmdUndo().

Field Documentation

◆ myContentFrame

FXVerticalFrame* GNEFrame::myContentFrame
protectedinherited

Vertical frame that holds all widgets of frame.

Definition at line 123 of file GNEFrame.h.

Referenced by GNECrossingFrame::GNECrossingFrame(), GNEFrame::GNEFrame(), and GNEInspectorFrame::inspectMultisection().

◆ myDrawingShape

GNEFrameModuls::DrawingShape* GNEPolygonFrame::myDrawingShape
private

Drawing shape.

Definition at line 161 of file GNEPolygonFrame.h.

Referenced by getDrawingShapeModul(), GNEPolygonFrame(), processClick(), shapeDrawed(), and tagSelected().

◆ myGEOPOICreator

GEOPOICreator* GNEPolygonFrame::myGEOPOICreator
private

GEOPOICreator.

Definition at line 164 of file GNEPolygonFrame.h.

Referenced by GNEPolygonFrame(), and tagSelected().

◆ myHeaderFrame

FXHorizontalFrame* GNEFrame::myHeaderFrame
protectedinherited

fame for header elements

Definition at line 126 of file GNEFrame.h.

Referenced by GNEFrame::GNEFrame().

◆ myHeaderLeftFrame

FXHorizontalFrame* GNEFrame::myHeaderLeftFrame
protectedinherited

◆ myHeaderRightFrame

FXHorizontalFrame* GNEFrame::myHeaderRightFrame
protectedinherited

fame for right header elements

Definition at line 132 of file GNEFrame.h.

Referenced by GNEFrame::GNEFrame().

◆ myNeteditAttributes

GNEFrameAttributesModuls::NeteditAttributes* GNEPolygonFrame::myNeteditAttributes
private

◆ myShapeAttributes

GNEFrameAttributesModuls::AttributesCreator* GNEPolygonFrame::myShapeAttributes
private

◆ myShapeTagSelector

GNEFrameModuls::TagSelector* GNEPolygonFrame::myShapeTagSelector
private

◆ myViewNet

GNEViewNet* GNEFrame::myViewNet
protectedinherited

View Net.

Definition at line 120 of file GNEFrame.h.

Referenced by GNEFrameModuls::DrawingShape::abortDrawing(), GNEFrameAttributesModuls::DrawingShape::abortDrawing(), GNEDeleteFrame::ACsToDelete(), GNESelectorFrame::ACsToSelected(), GNEAdditionalFrame::addAdditional(), GNECrossingFrame::addCrossing(), GNEPersonPlanFrame::PersonPlanCreator::addEdge(), GNERouteFrame::ConsecutiveEdges::addEdge(), GNERouteFrame::NonConsecutiveEdges::addEdge(), GNEFrameModuls::EdgePathCreator::addEdge(), GNETAZFrame::addOrRemoveTAZMember(), GNEPersonFrame::addPerson(), GNEPersonPlanFrame::addPersonPlan(), addPOI(), addPOILane(), addPolygon(), GNEStopFrame::addStop(), GNETAZFrame::TAZCurrent::addTAZChild(), GNEVehicleFrame::addVehicle(), GNEFrameAttributesModuls::AttributesEditorRow::AttributesEditorRow(), GNEAdditionalFrame::buildAdditionalOverEdge(), GNEAdditionalFrame::buildAdditionalOverLane(), GNEAdditionalFrame::buildAdditionalOverLanes(), GNEAdditionalFrame::buildAdditionalOverView(), GNEConnectorFrame::buildConnection(), GNETLSEditorFrame::buildIinternalLanes(), GNEPersonFrame::buildPerson(), GNEPersonFrame::buildPersonOverRoute(), GNEPersonFrame::buildPersonOverStop(), GNEProhibitionFrame::buildProhibition(), GNETLSEditorFrame::cleanup(), GNESelectorFrame::clearCurrentSelection(), GNEFrameModuls::EdgePathCreator::clearEdges(), GNEInspectorFrame::clearInspectedAC(), GNEFrameModuls::AttributeCarrierHierarchy::createPopUpMenu(), GNETAZFrame::dropTAZMembers(), GNEPersonFrame::edgePathCreated(), GNEVehicleFrame::edgePathCreated(), GNETLSEditorFrame::editJunction(), GNETAZFrame::TAZSaveChanges::enableButtonsAndBeginUndoList(), GNEAdditionalFrame::generateID(), GNESelectorFrame::getMatches(), GNEFrameAttributesModuls::NeteditAttributes::getNeteditAttributesAndValues(), GNEFrame::getViewNet(), GNEPersonTypeFrame::GNEPersonTypeFrame(), GNEVehicleTypeFrame::GNEVehicleTypeFrame(), GNETLSEditorFrame::handleChange(), GNERouteFrame::handleEdgeClick(), GNESelectorFrame::handleIDs(), GNEConnectorFrame::handleLaneClick(), GNETLSEditorFrame::handleMultiChange(), GNEProhibitionFrame::handleProhibitionClick(), GNEFrame::hide(), GNEInspectorFrame::hide(), GNERouteFrame::hotkeyBackSpace(), GNERouteFrame::hotkeyEnter(), GNERouteFrame::hotkeyEsc(), GNEConnectorFrame::initTargets(), GNEInspectorFrame::inspectSingleElement(), GNEPersonPlanFrame::PersonPlanCreator::onCmdAbortPersonPlanCreation(), GNERouteFrame::ConsecutiveEdges::onCmdAbortRoute(), GNERouteFrame::NonConsecutiveEdges::onCmdAbortRoute(), GNEProhibitionFrame::onCmdCancel(), GNETLSEditorFrame::onCmdCancel(), GNETAZFrame::TAZSaveChanges::onCmdCancelChanges(), GNEFrameModuls::AttributeCarrierHierarchy::onCmdCenterItem(), GNEPersonTypeFrame::PersonTypeEditor::onCmdCopyPersonType(), GNEVehicleTypeFrame::VehicleTypeEditor::onCmdCopyVehicleType(), GNECrossingFrame::CreateCrossing::onCmdCreateCrossing(), GNEPolygonFrame::GEOPOICreator::onCmdCreateGEOPOI(), GNEPersonTypeFrame::PersonTypeEditor::onCmdCreatePersonType(), GNERouteFrame::NonConsecutiveEdges::onCmdCreateRoute(), GNEVehicleTypeFrame::VehicleTypeEditor::onCmdCreateVehicleType(), GNETLSEditorFrame::onCmdDefCreate(), GNETLSEditorFrame::onCmdDefDelete(), GNETLSEditorFrame::onCmdDefSwitch(), GNEFrameModuls::AttributeCarrierHierarchy::onCmdDeleteItem(), GNEPersonTypeFrame::PersonTypeEditor::onCmdDeletePersonType(), GNEVehicleTypeFrame::VehicleTypeEditor::onCmdDeleteVehicleType(), GNEFrameAttributesModuls::GenericParametersEditor::onCmdEditGenericParameter(), GNEPersonPlanFrame::PersonPlanCreator::onCmdFinishPersonPlanCreation(), GNEFrameModuls::EdgePathCreator::onCmdFinishRouteCreation(), GNEInspectorFrame::onCmdGoBack(), GNEFrameModuls::AttributeCarrierHierarchy::onCmdInspectItem(), GNESelectorFrame::SelectionOperation::onCmdInvert(), GNESelectorFrame::SelectionOperation::onCmdLoad(), GNETLSEditorFrame::TLSFile::onCmdLoadTLSProgram(), GNEFrameModuls::AttributeCarrierHierarchy::onCmdMoveItemDown(), GNEFrameModuls::AttributeCarrierHierarchy::onCmdMoveItemUp(), GNETLSEditorFrame::onCmdOK(), GNEFrameAttributesModuls::AttributesEditorRow::onCmdOpenAttributeDialog(), GNETLSEditorFrame::onCmdPhaseSwitch(), GNEFrameModuls::EdgePathCreator::onCmdRemoveLastInsertedElement(), GNERouteFrame::NonConsecutiveEdges::onCmdRemoveLastRouteEdge(), GNEPersonTypeFrame::PersonTypeEditor::onCmdResetPersonType(), GNEVehicleTypeFrame::VehicleTypeEditor::onCmdResetVehicleType(), GNESelectorFrame::SelectionOperation::onCmdSave(), GNETAZFrame::TAZSaveChanges::onCmdSaveChanges(), GNESelectorFrame::VisualScaling::onCmdScaleSelection(), GNETAZFrame::TAZSelectionStatistics::onCmdSelectEdges(), GNESelectorFrame::ElementSet::onCmdSelectElementSet(), GNEFrameAttributesModuls::AttributesEditorRow::onCmdSelectRadioButton(), GNEFrameAttributesModuls::AttributesEditorRow::onCmdSetAttribute(), GNEFrameAttributesModuls::GenericParametersEditor::onCmdSetGenericParameter(), GNETAZFrame::TAZSelectionStatistics::onCmdSetNewValues(), GNETAZFrame::TAZChildDefaultParameters::onCmdUseSelectedEdges(), GNETLSEditorFrame::parseTLSPrograms(), GNEPersonPlanFrame::personPlanCreated(), GNECreateEdgeFrame::processClick(), processClick(), GNEInspectorFrame::processDemandSupermodeClick(), GNEInspectorFrame::processNetworkSupermodeClick(), GNEProhibitionFrame::ProhibitionLegend::ProhibitionLegend(), GNEFrameAttributesModuls::AttributesEditorRow::refreshAttributesEditorRow(), GNESelectorFrame::ElementSet::refreshElementSet(), GNEFrameAttributesModuls::GenericParametersEditor::refreshGenericParametersEditor(), GNEDeleteFrame::removeAttributeCarrier(), GNEDeleteFrame::removeSelectedAttributeCarriers(), GNETAZFrame::TAZCurrent::setTAZ(), shapeDrawed(), GNETAZFrame::shapeDrawed(), GNEFrame::show(), GNEStopFrame::show(), GNEDeleteFrame::show(), GNEPersonPlanFrame::show(), GNEFrameModuls::AttributeCarrierHierarchy::showAttributeCarrierChildren(), GNEFrameModuls::AttributeCarrierHierarchy::showAttributeCarrierParents(), GNESelectorFrame::LockGLObjectTypes::showTypeEntries(), GNEFrameAttributesModuls::AttributesCreator::showWarningMessage(), GNEAdditionalFrame::SelectorLaneParents::stopConsecutiveLaneSelector(), GNEFrameModuls::DrawingShape::stopDrawing(), GNEFrameAttributesModuls::DrawingShape::stopDrawing(), and GNETAZFrame::TAZEdgesGraphic::updateEdgeColors().


The documentation for this class was generated from the following files: