80 FXIMPLEMENT(
GUIDialog_ViewSettings, FXDialogBox, GUIDialog_ViewSettingsMap, ARRAYNUMBER(GUIDialog_ViewSettingsMap))
88 myParent(parent), mySettings(settings),
89 myDecals(decals), myDecalsLock(decalsLock),
91 myBackup = (*mySettings);
99 for (std::vector<std::string>::const_iterator i = names.begin(); i != names.end(); ++i) {
100 int index = mySchemeName->appendItem((*i).c_str());
101 if ((*i) == mySettings->name) {
102 mySchemeName->setCurrentItem((FXint) index);
105 mySchemeName->setNumVisible(5);
112 new FXVerticalSeparator(frame0);
114 mySaveViewPort =
new FXCheckButton(frame0,
"Viewport");
115 mySaveDelay =
new FXCheckButton(frame0,
"Delay");
116 mySaveDecals =
new FXCheckButton(frame0,
"Decals");
124 FXScrollWindow* genScroll =
new FXScrollWindow(tabbook);
134 new FXLabel(frame11,
"Decals:");
135 myDecalsFrame =
new FXVerticalFrame(frame11);
144 myShowGrid->setCheck(mySettings->showGrid);
145 new FXLabel(m12,
"");
149 myGridXSizeDialer->setRange(1, 10000);
150 myGridXSizeDialer->setValue(mySettings->gridXSize);
154 myGridYSizeDialer->setRange(1, 10000);
155 myGridYSizeDialer->setValue(mySettings->gridXSize);
160 FXScrollWindow* genScroll =
new FXScrollWindow(tabbook);
180 mySettings->edgeColorer.fill(*myLaneEdgeColorMode);
181 mySettings->edgeScaler.fill(*myLaneEdgeScaleMode);
182 myLaneEdgeColorMode->setNumVisible((
int)mySettings->edgeColorer.size());
183 myLaneEdgeScaleMode->setNumVisible((
int)mySettings->edgeScaler.size());
185 mySettings->laneColorer.fill(*myLaneEdgeColorMode);
186 mySettings->laneScaler.fill(*myLaneEdgeScaleMode);
187 myLaneEdgeColorMode->setNumVisible((
int)mySettings->laneColorer.size());
188 myLaneEdgeScaleMode->setNumVisible((
int)mySettings->laneScaler.size());
194 myShowLaneBorders->setCheck(mySettings->laneShowBorders);
197 myShowLaneDecals->setCheck(mySettings->showLinkDecals);
200 myShowLinkRules->setCheck(mySettings->showLinkRules);
203 myShowRails->setCheck(mySettings->showRails);
206 myHideMacroConnectors->setCheck(mySettings->hideConnectors);
209 myShowLaneDirection->setCheck(mySettings->showLaneDirection);
212 myShowSublanes->setCheck(mySettings->showSublanes);
216 myLaneWidthUpscaleDialer->setRange(0, 10000);
217 myLaneWidthUpscaleDialer->setValue(mySettings->laneWidthExaggeration);
221 myLaneMinWidthDialer->setRange(0, 10000);
222 myLaneMinWidthDialer->setValue(mySettings->laneMinSize);
225 myEdgeNamePanel =
new NamePanel(m22,
this,
"Show edge name", mySettings->edgeName);
226 myStreetNamePanel =
new NamePanel(m22,
this,
"Show street name", mySettings->streetName);
231 FXScrollWindow* genScroll =
new FXScrollWindow(tabbook);
237 myVehicleShapeDetail->appendItem(
"'triangles'");
238 myVehicleShapeDetail->appendItem(
"'boxes'");
239 myVehicleShapeDetail->appendItem(
"'simple shapes'");
240 myVehicleShapeDetail->appendItem(
"'raster images'");
241 myVehicleShapeDetail->setNumVisible(4);
242 myVehicleShapeDetail->setCurrentItem(settings->vehicleQuality);
249 mySettings->vehicleColorer.fill(*myVehicleColorMode);
250 myVehicleColorMode->setNumVisible((
int)mySettings->vehicleColorer.size());
259 myShowBlinker->setCheck(mySettings->showBlinker);
262 myShowMinGap->setCheck(mySettings->drawMinGap);
265 myShowBTRange->setCheck(mySettings->showBTRange);
272 myVehicleNamePanel =
new NamePanel(m33,
this,
"Show vehicle name", mySettings->vehicleName);
283 myVehicleSizePanel =
new SizePanel(m34,
this, mySettings->vehicleSize);
288 FXScrollWindow* genScroll =
new FXScrollWindow(tabbook);
294 myPersonShapeDetail->appendItem(
"'triangles'");
295 myPersonShapeDetail->appendItem(
"'boxes'");
296 myPersonShapeDetail->appendItem(
"'simple shapes'");
297 myPersonShapeDetail->appendItem(
"'raster images'");
298 myPersonShapeDetail->setNumVisible(4);
299 myPersonShapeDetail->setCurrentItem(settings->personQuality);
306 mySettings->personColorer.fill(*myPersonColorMode);
307 myPersonColorMode->setNumVisible(10);
315 myPersonNamePanel =
new NamePanel(m103,
this,
"Show person name", mySettings->personName);
320 myPersonSizePanel =
new SizePanel(m104,
this, mySettings->personSize);
325 FXScrollWindow* genScroll =
new FXScrollWindow(tabbook);
331 myContainerShapeDetail->appendItem(
"'triangles'");
332 myContainerShapeDetail->appendItem(
"'boxes'");
333 myContainerShapeDetail->appendItem(
"'simple shapes'");
334 myContainerShapeDetail->appendItem(
"'raster images'");
335 myContainerShapeDetail->setNumVisible(4);
336 myContainerShapeDetail->setCurrentItem(settings->containerQuality);
343 mySettings->containerColorer.fill(*myContainerColorMode);
344 myContainerColorMode->setNumVisible(9);
352 myContainerNamePanel =
new NamePanel(m103,
this,
"Show container name", mySettings->containerName);
357 myContainerSizePanel =
new SizePanel(m104,
this, mySettings->containerSize);
362 FXScrollWindow* genScroll =
new FXScrollWindow(tabbook);
367 mySettings->junctionColorer.fill(*myJunctionColorMode);
368 myJunctionColorMode->setNumVisible(3);
375 myTLIndexPanel =
new NamePanel(m42,
this,
"Show link tls index", mySettings->drawLinkTLIndex);
376 myJunctionIndexPanel =
new NamePanel(m42,
this,
"Show link junction index", mySettings->drawLinkJunctionIndex);
378 myShowLane2Lane->setCheck(mySettings->showLane2Lane);
380 myJunctionNamePanel =
new NamePanel(m42,
this,
"Show junction name", mySettings->junctionName);
381 myInternalJunctionNamePanel =
new NamePanel(m42,
this,
"Show internal junction name", mySettings->internalJunctionName);
382 myInternalEdgeNamePanel =
new NamePanel(m42,
this,
"Show internal edge name", mySettings->internalEdgeName);
383 myCwaEdgeNamePanel =
new NamePanel(m42,
this,
"Show crossing and walkingarea name", mySettings->cwaEdgeName);
385 myDrawJunctionShape->setCheck(mySettings->drawJunctionShape);
387 myDrawCrossingsAndWalkingAreas->setCheck(mySettings->drawCrossingsAndWalkingareas);
392 myJunctionSizePanel =
new SizePanel(m43,
this, mySettings->junctionSize);
397 FXScrollWindow* genScroll =
new FXScrollWindow(tabbook);
401 myAddNamePanel =
new NamePanel(m51,
this,
"Show detector name", mySettings->addName);
405 myAddSizePanel =
new SizePanel(m52,
this, mySettings->addSize);
415 FXScrollWindow* genScroll =
new FXScrollWindow(tabbook);
419 myPOINamePanel =
new NamePanel(m61,
this,
"Show poi names", mySettings->poiName);
420 myPOITypePanel =
new NamePanel(m61,
this,
"Show poi types", mySettings->poiType);
424 myPOISizePanel =
new SizePanel(m62,
this, mySettings->poiSize);
430 FXScrollWindow* genScroll =
new FXScrollWindow(tabbook);
434 myPolyNamePanel =
new NamePanel(m91,
this,
"Show polygon names", mySettings->polyName);
435 myPolyTypePanel =
new NamePanel(m91,
this,
"Show polygon types", mySettings->polyType);
438 myPolySizePanel =
new SizePanel(m91,
this, mySettings->polySize);
443 FXScrollWindow* genScroll =
new FXScrollWindow(tabbook);
448 myShowSizeLegend->setCheck(mySettings->showSizeLegend);
449 new FXLabel(m72,
"");
454 FXScrollWindow* genScroll =
new FXScrollWindow(tabbook);
459 myAntialiase->setCheck(mySettings->antialiase);
461 myDither->setCheck(mySettings->dither);
468 rebuildColorMatrices(
false);
471 const FXint minSize = 400;
472 setX(
MIN2(getApp()->reg().readIntEntry(
"VIEWSETTINGS",
"x", 150), getApp()->getRootWindow()->getWidth() - minSize));
473 setY(
MIN2(getApp()->reg().readIntEntry(
"VIEWSETTINGS",
"y", 150), getApp()->getRootWindow()->getHeight() - minSize));
474 setWidth(
MAX2(getApp()->reg().readIntEntry(
"VIEWSETTINGS",
"width", 700), minSize));
475 setHeight(
MAX2(getApp()->reg().readIntEntry(
"VIEWSETTINGS",
"height", 500), minSize));
542 FXString dataS = (
char*) data;
545 for (
int i = 0; i <
mySchemeName->getNumItems() - 1; ++i) {
629 std::vector<FXColorWell*>::const_iterator colEnd,
630 std::vector<FXRealSpinDial*>::const_iterator threshIt,
631 std::vector<FXRealSpinDial*>::const_iterator threshEnd,
632 std::vector<FXButton*>::const_iterator buttonIt,
635 while (colIt != colEnd) {
637 if (sender == *colIt) {
641 if (sender == *threshIt) {
642 const double val = (*threshIt)->getValue();
646 (*threshIt)->getRange(lo, hi);
647 (*threshIt)->setRange(lo, val);
651 if (threshIt != threshEnd) {
652 (*threshIt)->getRange(lo, hi);
653 (*threshIt)->setRange(val, hi);
658 if (sender == *colIt) {
662 if (sender == *buttonIt) {
682 std::vector<FXRealSpinDial*>::const_iterator scaleEnd,
683 std::vector<FXRealSpinDial*>::const_iterator threshIt,
684 std::vector<FXRealSpinDial*>::const_iterator threshEnd,
685 std::vector<FXButton*>::const_iterator buttonIt,
688 while (scaleIt != scaleEnd) {
690 if (sender == *scaleIt) {
691 scheme.
setColor(pos, (*scaleIt)->getValue());
694 if (sender == *threshIt) {
695 const double val = (*threshIt)->getValue();
699 (*threshIt)->getRange(lo, hi);
700 (*threshIt)->setRange(lo, val);
704 if (threshIt != threshEnd) {
705 (*threshIt)->getRange(lo, hi);
706 (*threshIt)->setRange(val, hi);
711 if (sender == *scaleIt) {
712 scheme.
setColor(pos, (*scaleIt)->getValue());
715 if (sender == *buttonIt) {
717 scheme.
addColor((*scaleIt)->getValue(), (*threshIt)->getValue());
742 bool doRebuildColorMatrices =
false;
822 doRebuildColorMatrices =
true;
826 doRebuildColorMatrices =
true;
829 doRebuildColorMatrices =
true;
836 doRebuildColorMatrices =
true;
840 doRebuildColorMatrices =
true;
843 doRebuildColorMatrices =
true;
850 doRebuildColorMatrices =
true;
854 doRebuildColorMatrices =
true;
857 doRebuildColorMatrices =
true;
864 doRebuildColorMatrices =
true;
868 doRebuildColorMatrices =
true;
871 doRebuildColorMatrices =
true;
878 doRebuildColorMatrices =
true;
882 doRebuildColorMatrices =
true;
885 doRebuildColorMatrices =
true;
892 doRebuildColorMatrices =
true;
896 doRebuildColorMatrices =
true;
899 doRebuildColorMatrices =
true;
929 if (doRebuildColorMatrices) {
933 getApp()->forceRefresh();
942 if (settingsName !=
"") {
943 FXint index =
mySchemeName->appendItem(settingsName.c_str());
964 std::vector<GUISUMOAbstractView::Decal>::iterator j;
1005 std::string name =
"";
1006 while (name.length() == 0) {
1017 if (!dialog.execute()) {
1020 name = text->getText().text();
1021 for (
int i = 0; i < (int)name.length(); ++i) {
1022 if (name[i] !=
'_' && (name[i] <
'a' || name[i] >
'z') && (name[i] <
'A' || name[i] >
'Z') && (name[i] <
'0' || name[i] >
'9')) {
1030 tmpSettings.
name = name;
1044 sender->handle(
this,
1046 ? FXSEL(SEL_COMMAND, ID_DISABLE) : FXSEL(SEL_COMMAND, ID_ENABLE),
1058 std::string name =
mySchemeName->getItem(index).text();
1069 sender->handle(
this,
1071 ? FXSEL(SEL_COMMAND, ID_DISABLE) : FXSEL(SEL_COMMAND, ID_ENABLE),
1101 FXMessageBox::error(
this, MBOX_OK,
"Storing failed!",
"%s", e.what());
1109 sender->handle(
this,
1112 FXSEL(SEL_COMMAND, ID_DISABLE) : FXSEL(SEL_COMMAND, ID_ENABLE),
1120 FXFileDialog opendialog(
this,
"Import view settings");
1122 opendialog.setSelectMode(SELECTFILE_ANY);
1123 opendialog.setPatternList(
"*.xml");
1127 if (opendialog.execute()) {
1137 FXFileDialog opendialog(
this,
"Load Decals");
1139 opendialog.setSelectMode(SELECTFILE_ANY);
1140 opendialog.setPatternList(
"*.xml");
1144 if (opendialog.execute()) {
1165 FXMessageBox::error(
myParent, MBOX_OK,
"Storing failed!",
"%s", e.what());
1175 sender->handle(
this, FXSEL(SEL_COMMAND, ID_ENABLE), ptr);
1185 const int numRows =
MAX2((
int)10, (
int)
myDecals->size() + 1);
1196 header->setHeight(getApp()->getNormalFont()->getFontHeight() + getApp()->getNormalFont()->getFontAscent());
1198 for (k = 0; k < cols; k++) {
1200 header->setItemSize(k, 60);
1202 header->setItemSize(0, 150);
1205 std::vector<GUISUMOAbstractView::Decal>::iterator j;
1219 for (k = 0; k < 7; k++) {
1227 std::vector<FXColorWell*>& colors,
1228 std::vector<FXRealSpinDial*>& thresholds,
1229 std::vector<FXButton*>& buttons,
1230 FXCheckButton* interpolation,
1237 const bool fixed = scheme.
isFixed();
1238 std::vector<RGBColor>::const_iterator colIt = scheme.
getColors().begin();
1239 std::vector<double>::const_iterator threshIt = scheme.
getThresholds().begin();
1240 std::vector<std::string>::const_iterator nameIt = scheme.
getNames().begin();
1241 FX::FXString buttonText =
"Add";
1242 while (colIt != scheme.
getColors().end()) {
1245 new FXLabel(m, nameIt->c_str());
1250 threshDialer->setValue(*threshIt);
1251 thresholds.push_back(threshDialer);
1253 buttonText =
"Remove";
1261 interpolation->disable();
1263 if (colors.size() > 1) {
1264 interpolation->enable();
1265 if (interpolation->getCheck() != FALSE) {
1266 thresholds.front()->enable();
1268 thresholds.front()->disable();
1271 interpolation->disable();
1272 thresholds.front()->disable();
1281 std::vector<FXRealSpinDial*>& scales,
1282 std::vector<FXRealSpinDial*>& thresholds,
1283 std::vector<FXButton*>& buttons,
1284 FXCheckButton* interpolation,
1291 const bool fixed = scheme.
isFixed();
1292 std::vector<double>::const_iterator scaleIt = scheme.
getColors().begin();
1293 std::vector<double>::const_iterator threshIt = scheme.
getThresholds().begin();
1294 std::vector<std::string>::const_iterator nameIt = scheme.
getNames().begin();
1295 FX::FXString buttonText =
"Add";
1296 while (scaleIt != scheme.
getColors().end()) {
1298 scaleDialer->setValue(*scaleIt);
1299 scales.push_back(scaleDialer);
1301 new FXLabel(m, nameIt->c_str());
1306 threshDialer->setValue(*threshIt);
1307 thresholds.push_back(threshDialer);
1309 buttonText =
"Remove";
1317 interpolation->disable();
1319 if (scales.size() > 1) {
1320 interpolation->enable();
1321 if (interpolation->getCheck() != FALSE) {
1322 thresholds.front()->enable();
1324 thresholds.front()->disable();
1327 interpolation->disable();
1328 thresholds.front()->disable();
1345 for (
int i = 1; i <= 5; ++i) {
1395 std::string value = i->
item->getText().text();
1397 if (value.find_first_not_of(
" ") == std::string::npos) {
1403 if (row == static_cast<int>(
myDecals->size())) {
1416 }
else if (row > static_cast<int>(
myDecals->size())) {
1420 d = (*myDecals)[row];
1434 std::string msg =
"The value must be a float, is:" + value;
1435 FXMessageBox::error(
this, MBOX_OK,
"Number format error",
"%s", msg.c_str());
1442 std::string msg =
"The value must be a float, is:" + value;
1443 FXMessageBox::error(
this, MBOX_OK,
"Number format error",
"%s", msg.c_str());
1450 std::string msg =
"The value must be a float, is:" + value;
1451 FXMessageBox::error(
this, MBOX_OK,
"Number format error",
"%s", msg.c_str());
1458 std::string msg =
"The value must be a float, is:" + value;
1459 FXMessageBox::error(
this, MBOX_OK,
"Number format error",
"%s", msg.c_str());
1466 std::string msg =
"The value must be a float, is:" + value;
1467 FXMessageBox::error(
this, MBOX_OK,
"Number format error",
"%s", msg.c_str());
1474 std::string msg =
"The value must be a float, is:" + value;
1475 FXMessageBox::error(
this, MBOX_OK,
"Number format error",
"%s", msg.c_str());
1482 std::string msg =
"The value must be a bool, is:" + value;
1483 FXMessageBox::error(
this, MBOX_OK,
"Number format error",
"%s", msg.c_str());
1489 (*myDecals)[row] = d;
1509 for (
int i = 0; i <
mySchemeName->getNumItems(); ++i) {
1521 const std::string& title,
1524 myCheck->setCheck(settings.
show);
1525 new FXLabel(parent,
"");
1529 mySizeDial->setRange(10, 1000);
1530 mySizeDial->setValue(settings.
size);
1545 myCheck->setCheck(settings.
show);
1546 mySizeDial->setValue(settings.
size);
1557 new FXLabel(parent,
"");
1561 myMinSizeDial->setValue(settings.
minSize);
1565 myExaggerateDial->setRange(0, 10000);
1573 myMinSizeDial->getValue(), myExaggerateDial->getValue(), myCheck->getCheck() != FALSE);
1580 myMinSizeDial->setValue(settings.
minSize);
1587 getApp()->reg().writeIntEntry(
"VIEWSETTINGS",
"x", getX());
1588 getApp()->reg().writeIntEntry(
"VIEWSETTINGS",
"y", getY());
1589 getApp()->reg().writeIntEntry(
"VIEWSETTINGS",
"width", getWidth());
1590 getApp()->reg().writeIntEntry(
"VIEWSETTINGS",
"height", getHeight());
void rebuildColorMatrices(bool doCreate=false)
Rebuilds color changing dialogs after choosing another coloring scheme.
GUIVisualizationSizeSettings junctionSize
FXMatrix * rebuildScaleMatrix(FXVerticalFrame *frame, std::vector< FXRealSpinDial *> &scales, std::vector< FXRealSpinDial *> &thresholds, std::vector< FXButton *> &buttons, FXCheckButton *interpolation, GUIScaleScheme &scheme)
Rebuilds manipulators for the current scaling scheme.
GUIDialog_EditViewport * getViewportEditor()
get the viewport and create it on first access
const std::vector< GUISUMOAbstractView::Decal > & getDecals() const
Returns the parsed decals.
GUIVisualizationTextSettings junctionName
A decal (an image) that can be shown.
FXCheckButton * mySaveViewPort
FXVerticalFrame * myVehicleColorSettingFrame
long onUpdSaveSetting(FXObject *, FXSelector, void *data)
Called when updating the button that allows to save the settings into the registry.
FXCheckButton * myLaneColorInterpolation
double altitude
The altitude of the image (net coordinates in z-direction, in m)
OutputDevice & writeAttr(const SumoXMLAttr attr, const T &val)
writes a named attribute
FXComboBox * myJunctionColorMode
void close()
Closes the device and removes it from the dictionary.
FXVerticalFrame * myDecalsFrame
GUICompleteSchemeStorage gSchemeStorage
bool showSizeLegend
Information whether the size legend shall be drawn.
FXCheckButton * myJunctionColorInterpolation
FXCheckButton * myShowBlinker
#define GUIDesignViewSettingsMatrix5
GUIVisualizationTextSettings poiType
FXVerticalFrame * myLaneScaleSettingFrame
FXCheckButton * myShowBTRange
GUIVisualizationTextSettings streetName
double laneWidthExaggeration
The lane exaggeration (upscale thickness)
#define GUIDesignViewSettingsMatrix3
bool showBlinker
Information whether vehicle blinkers shall be drawn.
GUIVisualizationTextSettings addName
FXComboBox * myVehicleColorMode
GUIVisualizationTextSettings personName
#define GUIDesignViewSettingsButton5
std::vector< FXButton * > myLaneButtons
SizePanel * myPOISizePanel
FXDEFMAP(GUIDialog_ViewSettings) GUIDialog_ViewSettingsMap[]
#define GUIDesignViewSettingsColorWell2
const std::vector< std::string > & getNames() const
Returns a list of stored settings names.
GUIVisualizationTextSettings poiName
static bool _2bool(const E *const data)
converts a 0-terminated char-type array into the boolean value described by it
FXCheckButton * myShowLinkRules
#define GUIDesignViewSettingsMFXTableJustify
GUIColorScheme & getLaneEdgeScheme()
Returns the current lane (edge) coloring schme.
For the import-from-file - button.
bool showBTRange
Information whether the communication range shall be drawn.
#define GUIDesignButtonToolbar
little button with icon placed in navigation toolbar
double exaggeration
The size exaggeration (upscale)
void saveDecals(OutputDevice &dev) const
Writes the currently used decals into a file.
GUIColorer laneColorer
The lane colorer.
GUIColorer containerColorer
The container colorer.
Stores the information about how to visualize structures.
The dialog to change the view (gui) settings.
void setDelay(double delay)
Sets the delay of the parent application.
SizePanel(FXMatrix *parent, GUIDialog_ViewSettings *target, const GUIVisualizationSizeSettings &settings)
NamePanel * myPolyTypePanel
GUIColorer edgeColorer
The mesoscopic edge colorer.
static RGBColor getRGBColor(FXColor col)
converts FXColor to RGBColor
void remove(GUIDialog_EditViewport *)
remove viewport
const std::vector< std::string > & getNames() const
std::vector< FXRealSpinDial * > myLaneScaleThresholds
#define GUIDesignViewSettingsVerticalFrame4
std::vector< GUISUMOAbstractView::Decal > * myDecals
The parent's decals.
NamePanel * myPOINamePanel
For the load-decals - button.
For the save-decals - button.
bool showRails
Information whether rails shall be drawn.
void loadDecals(const std::string &file)
Loads decals from a file.
std::vector< FXButton * > myPersonButtons
std::vector< FXColorWell * > myJunctionColors
GUIVisualizationTextSettings vehicleName
FXComboBox * myVehicleShapeDetail
FXCheckButton * myShowSublanes
double centerX
The center of the image in x-direction (net coordinates, in m)
bool screenRelative
Whether this image should be skipped in 2D-views.
void loadSettings(const std::string &file)
Loads a scheme from a file.
#define GUIDesignViewSettingsVerticalFrame5
bool allowsNegativeValues() const
static void deleteChildren(FXWindow *w)
Deletes all children of the given window.
long onCmdSaveDecals(FXObject *, FXSelector, void *data)
Called if the decals shall be saved to a file.
bool showLaneDirection
Whether to show direction indicators for lanes.
void writeXML(OutputDevice &dev)
write the settings to the given device
GUIVisualizationTextSettings cwaEdgeName
FXString gCurrentFolder
The folder used as last.
long onCmdSaveSetting(FXObject *, FXSelector, void *data)
Called if the settings shall be saved into the registry.
bool laneShowBorders
Information whether lane borders shall be drawn.
long onCmdExportSetting(FXObject *, FXSelector, void *data)
Called if the settings shall be exported into a file.
SizePanel * myJunctionSizePanel
bool isInterpolated() const
bool hasDecals() const
Returns whether any decals have been parsed.
#define GUIDesignViewSettingsTextField1
textFields
bool showLinkRules
Information whether link rules (colored bars) shall be drawn.
long onCmdEditTable(FXObject *, FXSelector, void *data)
Called if the decals-table was changed.
FXCheckButton * mySaveDelay
#define GUIDesignViewSettingsSpinDial1
static FXString getFilename2Write(FXWindow *parent, const FXString &header, const FXString &extension, FXIcon *icon, FXString ¤tFolder)
Returns the file name to write.
double getGridHeight() const
get grid Height
bool dither
Information whether dithering shall be enabled.
double height
The height of the image (net coordinates in y-direction, in m)
FXVerticalFrame * myContainerColorSettingFrame
std::vector< FXRealSpinDial * > myPersonThresholds
double getDelay() const
Returns the delay of the parent application.
#define GUIDesignMatrixViewSettings
FXMatrix used to pack values in Viewsettings.
long onCmdNameChange(FXObject *, FXSelector, void *)
Called if the name of the scheme was changed.
SizePanel * myPolySizePanel
double getDelay() const
Returns the parsed delay.
void setActive(int scheme)
double layer
The layer of the image.
bool updateColorRanges(FXObject *sender, std::vector< FXColorWell *>::const_iterator colIt, std::vector< FXColorWell *>::const_iterator colEnd, std::vector< FXRealSpinDial *>::const_iterator threshIt, std::vector< FXRealSpinDial *>::const_iterator threshEnd, std::vector< FXButton *>::const_iterator buttonIt, GUIColorScheme &scheme)
#define GUIDesignViewSettingsVerticalFrame1
vertical frames
#define GUIDesignViewSettingsMatrix2
GUIVisualizationSizeSettings polySize
For the export-to-file - button.
GUIColorer vehicleColorer
The vehicle colorer.
FXCheckButton * myShowLaneDirection
double roll
The roll of the image to the ground plane (in degrees)
#define GUIDesignViewSettingsButton2
GUIVisualizationTextSettings edgeName
std::vector< FXButton * > myContainerButtons
FXCheckButton * myVehicleColorInterpolation
GUIVisualizationSizeSettings addSize
double getGridWidth() const
get grid width
int getLaneEdgeMode() const
Returns the number of the active lane (edge) coloring schme.
#define GUIDesignViewSettingsVerticalFrame2
void setNumberCellParams(int pos, double min, double max, double steps1, double steps2, double steps3, const std::string &format)
NamePanel * myInternalEdgeNamePanel
FXCheckButton * myShowMinGap
void save(OutputDevice &dev) const
Writes the settings into an output device.
NamePanel * myEdgeNamePanel
void setCellType(int pos, CellType t)
FXCheckButton * myShowGrid
int addColor(const T &color, const double threshold, const std::string &name="")
std::string name
The name of this setting.
double gridXSize
Information about the grid spacings.
#define GUIDesignHorizontalSeparator
#define GUIDesignViewSettingsButton3
void setCurrentScheme(const std::string &)
Sets the named scheme as the current.
FXCheckButton * myShowLane2Lane
std::string toString(const T &t, std::streamsize accuracy=gPrecision)
void rebuildList()
Rebuilds the decals table.
#define GUIDesignViewSettingsHorizontalFrame2
void update(const GUIVisualizationSizeSettings &settings)
double minSize
The minimum size to draw this object.
FXCheckButton * myDrawCrossingsAndWalkingAreas
void show()
show view settings dialog
GUIVisualizationSettings * mySettings
The current settings.
GUIVisualizationTextSettings internalEdgeName
std::vector< FXRealSpinDial * > myLaneScales
#define GUIDesignViewSettingsLabel2
NamePanel * myStreetNamePanel
#define GUIDesignCheckButton
bool drawMinGap
Information whether the minimum gap shall be drawn.
NamePanel * myInternalJunctionNamePanel
std::vector< FXColorWell * > myVehicleColors
#define GUIDesignViewSettingsMatrix4
FXRealSpinDial * myLaneWidthUpscaleDialer
double rot
The rotation of the image in the ground plane (in degrees)
void remove(const std::string &name)
Removes the setting with the given name.
#define GUIDesignViewSettingsMatrix1
Matrix.
GUIVisualizationTextSettings polyType
bool showSublanes
Whether to show sublane boundaries.
void saveWindowSize()
save window position and size to the registry
#define GUIDesignViewSettingsColorWell1
Color wells.
FXCheckButton * myShowSizeLegend
GUIVisualizationSettings & get(const std::string &name)
Returns the named scheme.
FXCheckButton * mySaveDecals
FXVerticalFrame * myLaneColorSettingFrame
FXComboBox & getColoringSchemesCombo()
get coloring schemes combo
FXRealSpinDial * myLaneMinWidthDialer
bool initialised
Whether this image was initialised (inserted as a texture)
GUIVisualizationTextSettings drawLinkTLIndex
#define GUIDesignViewSettingsColorWell
ColorWell.
GUIColorer personColorer
The person colorer.
void setThreshold(const int pos, const double threshold)
GUIVisualizationTextSettings internalJunctionName
int getNumInitialSettings() const
Returns the number of initial settings.
#define GUIDesignComboBoxStatic
Combo box static (not editable)
double centerY
The center of the image in y-direction (net coordinates, in m)
GUIColorer junctionColorer
The junction colorer.
bool updateScaleRanges(FXObject *sender, std::vector< FXRealSpinDial *>::const_iterator colIt, std::vector< FXRealSpinDial *>::const_iterator colEnd, std::vector< FXRealSpinDial *>::const_iterator threshIt, std::vector< FXRealSpinDial *>::const_iterator threshEnd, std::vector< FXButton *>::const_iterator buttonIt, GUIScaleScheme &scheme)
#define GUIDesignViewSettingsButton4
std::string filename
The path to the file the image is located at.
long onUpdDeleteSetting(FXObject *, FXSelector, void *data)
Called when updating the button that allows to delete settings.
FXVerticalFrame * myJunctionColorSettingFrame
FXCheckButton * myLaneScaleInterpolation
double laneMinSize
The minimum visual lane width for drawing.
GUIScaler edgeScaler
The mesoscopic edge scaler.
FXCheckButton * myShowLaneBorders
SizePanel * myAddSizePanel
NamePanel * myAddNamePanel
GUIScaleScheme & getLaneEdgeScaleScheme()
Returns the current lane (edge) scaling schme.
std::vector< FXColorWell * > myPersonColors
Informs the dialog about a value's change.
FXRealSpinDial * myGridYSizeDialer
int containerQuality
The quality of container drawing.
long onCmdCancel(FXObject *, FXSelector, void *)
Called if the Cancel-button was pressed.
RGBColor backgroundColor
The background color to use.
bool antialiase
Information whether antialiase shall be enabled.
std::vector< FXButton * > myLaneScaleButtons
std::string addSettings(GUISUMOAbstractView *view=0) const
Adds the parsed settings to the global list of settings.
long onCmdOk(FXObject *, FXSelector, void *)
Called if the OK-button was pressed.
NamePanel * myCwaEdgeNamePanel
double width
The width of the image (net coordinates in x-direction, in m)
#define GUIDesignViewSettingsDialog
void setColor(const int pos, const T &color)
virtual bool setColorScheme(const std::string &)
set color scheme
void unlock()
release mutex lock
FXComboBox * myContainerColorMode
GUIVisualizationSizeSettings poiSize
~GUIDialog_ViewSettings()
Destructor.
NamePanel * myTLIndexPanel
Cancel-button was pushed.
#define GUIDesignViewSettingsHorizontalFrame1
Horizontal frames.
NamePanel * myVehicleNamePanel
NamePanel * myContainerNamePanel
MFXAddEditTypedTable * myDecalsTable
FXCheckButton * myDrawJunctionShape
bool showLinkDecals
Information whether link textures (arrows) shall be drawn.
#define GUIDesignViewSettingsTabBook1
Tab books.
#define GUIDesignViewSettingsComboBox1
Combo boxs.
NamePanel(FXMatrix *parent, GUIDialog_ViewSettings *target, const std::string &title, const GUIVisualizationTextSettings &settings)
GUIVisualizationSizeSettings containerSize
FXComboBox * myLaneEdgeScaleMode
... lane scaler
void applyViewport(GUISUMOAbstractView *view) const
Sets the viewport which has been parsed.
void removeColor(const int pos)
static OutputDevice & getDevice(const std::string &name)
Returns the described OutputDevice.
bool contains(const std::string &name) const
Returns the information whether a setting with the given name is stored.
GUIVisualizationTextSettings getSettings()
FXComboBox * myPersonShapeDetail
NamePanel * myJunctionNamePanel
const std::vector< T > & getColors() const
void writeSettings(FXApp *app)
Writes the current scheme into the registry.
#define GUIDesignViewSettingsHorizontalFrame3
FXComboBox * myLaneEdgeColorMode
... lane colorer
void setCurrent(GUIVisualizationSettings *settings)
Sets current settings (called if reopened)
FXCheckButton * myHideMacroConnectors
double centerZ
The center of the image in z-direction (net coordinates, in m)
static double _2double(const E *const data)
converts a char-type array into the double value described by it
#define GUIDesignViewSettingsTabItemBook1
For the save-to-db - button.
FXCheckButton * myShowRails
GUIVisualizationSizeSettings personSize
int personQuality
The quality of person drawing.
std::string getCurrentScheme() const
Returns the name of the currently chosen scheme.
bool showGrid
Information whether a grid shall be shown.
bool drawCrossingsAndWalkingareas
whether crosings and walkingareas shall be drawn
long onUpdExportSetting(FXObject *, FXSelector, void *data)
Called when updating the button that allows to export settings into a file.
static FXColor getFXColor(const RGBColor &col)
converts FXColor to RGBColor
double tilt
The tilt of the image to the ground plane (in degrees)
NamePanel * myPOITypePanel
long onCmdColorChange(FXObject *, FXSelector, void *)
Called if something (color, width, etc.) has been changed.
#define GUIDesignViewSettingsVerticalFrame3
bool showLane2Lane
Information whether lane-to-lane arrows shall be drawn.
SizePanel * myPersonSizePanel
Static storage of an output device and its base (abstract) implementation.
bool closeTag()
Closes the most recently opened tag.
FXRealSpinDial * myGridXSizeDialer
An XML-handler for visualisation schemes.
NamePanel * myJunctionIndexPanel
FXCheckButton * myPersonColorInterpolation
#define GUIDesignViewSettingsVerticalFrame6
#define GUIDesignViewSettingsButton1
Buttons.
#define GUIDesignSpinDial
GUIVisualizationSizeSettings vehicleSize
SizePanel * myVehicleSizePanel
bool drawJunctionShape
whether the shape of the junction should be drawn
std::vector< FXRealSpinDial * > myContainerThresholds
long onCmdLoadDecals(FXObject *, FXSelector, void *data)
Called if the decals shall be loaded from a file.
void update(const GUIVisualizationTextSettings &settings)
FXColorWell * myBackgroundColor
std::vector< FXRealSpinDial * > myVehicleThresholds
FXMatrix * rebuildColorMatrix(FXVerticalFrame *frame, std::vector< FXColorWell *> &colors, std::vector< FXRealSpinDial *> &thresholds, std::vector< FXButton *> &buttons, FXCheckButton *interpolation, GUIColorScheme &scheme)
Rebuilds manipulators for the current coloring scheme.
int getLaneEdgeScaleMode() const
Returns the number of the active lane (edge) scaling schme.
GUIVisualizationSizeSettings getSettings()
int vehicleQuality
The quality of vehicle drawing.
const std::vector< double > & getThresholds() const
static bool UseMesoSim
this should be set at the same time as MSGlobals::gUseMesoSim
MFXMutex * myDecalsLock
Lock used when changing the decals.
SizePanel * myContainerSizePanel
std::vector< FXRealSpinDial * > myJunctionThresholds
FXCheckButton * myContainerColorInterpolation
GUIScaler laneScaler
The lane scaler.
#define GUIDesignViewSettingsSpinDial2
FXCheckButton * myAntialiase
FXComboBox * myContainerShapeDetail
long onCmdDeleteSetting(FXObject *, FXSelector, void *data)
Called if the settings shall be deleted.
GUISUMOAbstractView * myParent
The parent view (which settings are changed)
FXVerticalFrame * myPersonColorSettingFrame
NamePanel * myPolyNamePanel
std::vector< FXColorWell * > myContainerColors
static FXIcon * getIcon(GUIIcon which)
returns a icon previously defined in the enum GUIIcon
Informs the dialog about switching to another scheme.
std::vector< FXButton * > myJunctionButtons
GUIVisualizationTextSettings drawLinkJunctionIndex
#define GUIDesignViewSettingsMFXTable
MFX Add/Edit Typed Table.
NamePanel * myPersonNamePanel
GUIVisualizationSettings myBackup
A backup of the settings (used if the "Cancel" button is pressed)
std::vector< FXColorWell * > myLaneColors
OutputDevice & openTag(const std::string &xmlElement)
Opens an XML tag.
FXComboBox * mySchemeName
std::vector< FXRealSpinDial * > myLaneThresholds
std::vector< FXButton * > myVehicleButtons
void setInterpolated(const bool interpolate, double interpolationStart=0.f)
long onCmdImportSetting(FXObject *, FXSelector, void *data)
Called if the settings shall be read from a file.
void add(const GUIVisualizationSettings &scheme)
Adds a visualization scheme.
FXComboBox * myPersonColorMode
long onUpdImportSetting(FXObject *, FXSelector, void *data)
Called when updating the button that allows to read settings from a file.
GUIVisualizationTextSettings polyName
GUIVisualizationTextSettings containerName
#define GUIDesignViewSettingsLabel1
Label.
#define GUIDesignViewSettingsMainDialog
FXCheckButton * myShowLaneDecals