 |
Eclipse SUMO - Simulation of Urban MObility
|
Go to the documentation of this file.
45 myEdgeCandidateColor(
RGBColor(0, 64, 0, 255)),
46 myEdgeCandidateSelectedColor(
RGBColor::GREEN) {
88 FXVerticalFrame::hide();
110 FXVerticalFrame::show();
119 FXVerticalFrame::hide();
198 FXDialogBox* attributesHelpDialog =
new FXDialogBox(
myScrollWindowsContents, (
"Parameters of " + tagProperties.
getTagStr()).c_str(),
GUIDesignDialogBoxResizable, 0, 0, 0, 0, 10, 10, 10, 38, 4, 4);
202 int sizeColumnDescription = 0;
203 int sizeColumnDefinitions = 0;
205 myTable->setVisibleColumns(3);
207 myTable->setBackColor(FXRGB(255, 255, 255));
208 myTable->setColumnText(0,
"Attribute");
209 myTable->setColumnText(1,
"Description");
210 myTable->setColumnText(2,
"Definition");
211 myTable->getRowHeader()->setWidth(0);
214 for (
const auto& i : tagProperties) {
216 FXTableItem* attribute =
new FXTableItem(i.getAttrStr().c_str());
217 attribute->setJustify(FXTableItem::CENTER_X);
218 myTable->setItem(itemIndex, 0, attribute);
220 FXTableItem* type =
new FXTableItem(
"");
221 type->setText(i.getDescription().c_str());
222 sizeColumnDescription =
MAX2(sizeColumnDescription, (
int)i.getDescription().size());
223 type->setJustify(FXTableItem::CENTER_X);
224 myTable->setItem(itemIndex, 1, type);
226 FXTableItem* definition =
new FXTableItem(i.getDefinition().c_str());
227 definition->setJustify(FXTableItem::LEFT);
228 myTable->setItem(itemIndex, 2, definition);
229 sizeColumnDefinitions =
MAX2(sizeColumnDefinitions, (
int)i.getDefinition().size());
233 FXHeader* header = myTable->getColumnHeader();
234 header->setItemJustify(0, JUSTIFY_CENTER_X);
235 header->setItemSize(0, 120);
236 header->setItemJustify(1, JUSTIFY_CENTER_X);
237 header->setItemSize(1, sizeColumnDescription * 7);
238 header->setItemJustify(2, JUSTIFY_CENTER_X);
239 header->setItemSize(2, sizeColumnDefinitions * 6);
249 WRITE_DEBUG(
"Opening HelpAttributes dialog for tag '" + tagProperties.getTagStr() +
"' showing " +
toString(tagProperties.getNumberOfAttributes()) +
" attributes");
251 attributesHelpDialog->create();
253 attributesHelpDialog->show(PLACEMENT_CURSOR);
257 getApp()->runModalFor(attributesHelpDialog);
259 WRITE_DEBUG(
"Closing HelpAttributes dialog for tag '" + tagProperties.getTagStr() +
"'");
275 const std::map<int, std::string>&
#define GUIDesignAuxiliarHorizontalFrame
design for auxiliar (Without borders) horizontal frame used to pack another frames
static FXFont * myFrameHeaderFont
static Font for the Header (it's common for all headers, then create only one time)
FXScrollWindow * myScrollWindowsContents
scroll windows that holds the content frame
virtual void attributeUpdated()
function called after set a valid attribute in AttributeCreator/AttributeEditor/GenericParametersEdit...
FXFont * getFrameHeaderFont() const
get font of the header's frame
struct with the attribute Properties
virtual void updateFrameAfterUndoRedo()
function called after undo/redo in the current frame (can be reimplemented in frame children)
const std::string & getTagStr() const
get Tag vinculated with this attribute Property in String Format (used to avoid multiple calls to toS...
virtual void edgePathCreated()
finish edge path creation
virtual void demandElementSelected()
selected demand element in DemandElementSelector
virtual void tagSelected()
Tag selected in TagSelector.
FXHorizontalFrame * myHeaderLeftFrame
fame for left header elements
GNEViewNet * getViewNet() const
get view net
#define GUIDesignButtonOK
#define GUIDesignTableNotEditable
design for table extended over frame that cannot be edited
void hideFramesArea()
hide frames area if all GNEFrames are hidden
static FXIcon * getIcon(GUIIcon which)
returns a icon previously defined in the enum GUIIcon
FXVerticalFrame * myContentFrame
Vertical frame that holds all widgets of frame.
#define GUIDesignContentsScrollWindow
design for the content frame of every frame
FXHorizontalFrame * myHeaderRightFrame
fame for right header elements
virtual void attributesEditorExtendedDialogOpened()
open AttributesCreator extended dialog (can be reimplemented in frame children)
FXLabel * myFrameHeaderLabel
the label for the frame's header
void showFramesArea()
show frames area if at least a GNEFrame is showed
#define GUIDesignLabelFrameInformation
label extended over frame without thick and with text justify to left, used to show information in fr...
const RGBColor & getEdgeCandidateSelectedColor() const
get selected color
#define GUIDesignContentsFrame
design for the main content frame of every frame/dialog
static StringBijection< int >::Entry attrs[]
The names of SUMO-XML attributes (for passing to GenericSAXHandler)
void focusUpperElement()
focus upper element of frame
#define GUIDesignHorizontalSeparator
RGBColor myEdgeCandidateColor
edge candidate color (used by some modulds to mark edges)
FXHorizontalFrame * myHeaderFrame
fame for header elements
RGBColor myEdgeCandidateSelectedColor
selected edge candidate color (used by some modulds to selected mark edges)
GNEViewNet * myViewNet
View Net.
const std::map< int, std::string > & getPredefinedTagsMML() const
get predefinedTagsMML
void openHelpAttributesDialog(const GNEAttributeCarrier::TagProperties &tagProperties) const
Open help attributes dialog.
std::string toString(const T &t, std::streamsize accuracy=gPrecision)
#define GUIDesignDialogBoxResizable
design for standard dialog box (for example, about dialog)
void setFrameWidth(int newWidth)
set width of GNEFrame
#define GUIDesignAuxiliarFrame
design for auxiliar (Without borders) frames used to pack another frames extended in all directions
GNEFrame()
FOX needs this.
virtual bool shapeDrawed()
build a shaped element using the drawed shape (can be reimplemented in frame children)
const RGBColor & getEdgeCandidateColor() const
get edge candidate color
std::map< int, std::string > myPredefinedTagsMML
Map of attribute ids to their (readable) string-representation (needed for SUMOSAXAttributesImpl_Cach...
virtual void show()
show Frame
FXLabel * getFrameHeaderLabel() const
get the label for the frame's header
virtual void hide()
hide Frame
GNEViewParent * getViewParent() const
get the net object
int getNumberOfAttributes() const
get number of attributes