51 #ifdef CHECK_MEMORY_LEAKS
53 #endif // CHECK_MEMORY_LEAKS
92 FXDialogBox(parent, "View Settings", DECOR_TITLE | DECOR_BORDER | DECOR_RESIZE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0),
93 myParent(parent), mySettings(settings),
94 myDecals(decals), myDecalsLock(decalsLock),
96 myBackup = (*mySettings);
98 FXVerticalFrame* contentFrame =
99 new FXVerticalFrame(
this, LAYOUT_SIDE_TOP | LAYOUT_FILL_X | LAYOUT_FILL_Y,
100 0, 0, 0, 0, 0, 0, 0, 0, 2, 2);
104 new FXHorizontalFrame(contentFrame, FRAME_THICK, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2);
105 mySchemeName =
new FXComboBox(frame0, 20,
this,
MID_SIMPLE_VIEW_NAMECHANGE, COMBOBOX_INSERT_LAST | FRAME_SUNKEN | LAYOUT_LEFT | LAYOUT_CENTER_Y | COMBOBOX_STATIC);
107 for (std::vector<std::string>::const_iterator i = names.begin(); i != names.end(); ++i) {
108 size_t index = mySchemeName->appendItem((*i).c_str());
109 if ((*i) == mySettings->name) {
110 mySchemeName->setCurrentItem((FXint) index);
113 mySchemeName->setNumVisible(5);
115 new FXButton(frame0,
"\t\tSave the setting to registry",
117 ICON_ABOVE_TEXT | BUTTON_TOOLBAR | FRAME_RAISED | LAYOUT_TOP | LAYOUT_LEFT);
118 new FXButton(frame0,
"\t\tRemove the setting from registry",
120 ICON_ABOVE_TEXT | BUTTON_TOOLBAR | FRAME_RAISED | LAYOUT_TOP | LAYOUT_LEFT);
121 new FXButton(frame0,
"\t\tExport setting to file",
123 ICON_ABOVE_TEXT | BUTTON_TOOLBAR | FRAME_RAISED | LAYOUT_TOP | LAYOUT_LEFT);
124 new FXButton(frame0,
"\t\tLoad setting from file",
126 ICON_ABOVE_TEXT | BUTTON_TOOLBAR | FRAME_RAISED | LAYOUT_TOP | LAYOUT_LEFT);
131 new FXTabBook(contentFrame, 0, 0, TABBOOK_LEFTTABS | PACK_UNIFORM_WIDTH | PACK_UNIFORM_HEIGHT | LAYOUT_FILL_X | LAYOUT_FILL_Y | LAYOUT_RIGHT,
132 0, 0, 0, 0, 0, 0, 0, 0);
135 new FXTabItem(tabbook,
"Background", NULL, TAB_LEFT_NORMAL, 0, 0, 0, 0, 4, 8, 4, 4);
136 FXScrollWindow* genScroll =
new FXScrollWindow(tabbook);
137 FXVerticalFrame* frame1 =
138 new FXVerticalFrame(genScroll, FRAME_THICK | FRAME_RAISED | LAYOUT_FILL_X | LAYOUT_FILL_Y, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2);
141 new FXMatrix(frame1, 2, LAYOUT_FILL_X | LAYOUT_TOP | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
142 0, 0, 0, 0, 10, 10, 10, 10, 5, 5);
143 new FXLabel(m11,
"Color", 0, LAYOUT_CENTER_Y);
146 LAYOUT_FIX_WIDTH | LAYOUT_CENTER_Y | LAYOUT_SIDE_TOP | FRAME_SUNKEN | FRAME_THICK | ICON_AFTER_TEXT,
147 0, 0, 100, 0, 0, 0, 0, 0);
149 new FXHorizontalSeparator(frame1, SEPARATOR_GROOVE | LAYOUT_FILL_X);
151 FXVerticalFrame* frame11 =
152 new FXVerticalFrame(frame1, LAYOUT_FILL_Y, 0, 0, 0, 0, 10, 10, 10, 10, 5, 5);
153 new FXLabel(frame11,
"Decals:");
154 myDecalsFrame =
new FXVerticalFrame(frame11);
156 new FXButton(frame111,
"&Load Decals", NULL,
this,
MID_SIMPLE_VIEW_LOAD_DECALS, BUTTON_DEFAULT | FRAME_RAISED | FRAME_THICK | LAYOUT_TOP | LAYOUT_LEFT | LAYOUT_CENTER_X, 0, 0, 0, 0, 20, 20, 4, 4);
157 new FXButton(frame111,
"&Save Decals", NULL,
this,
MID_SIMPLE_VIEW_SAVE_DECALS, BUTTON_DEFAULT | FRAME_RAISED | FRAME_THICK | LAYOUT_TOP | LAYOUT_LEFT | LAYOUT_CENTER_X, 0, 0, 0, 0, 20, 20, 4, 4);
159 new FXHorizontalSeparator(frame1, SEPARATOR_GROOVE | LAYOUT_FILL_X);
162 new FXMatrix(frame1, 2, LAYOUT_FILL_X | LAYOUT_BOTTOM | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
163 0, 0, 0, 0, 10, 10, 10, 10, 5, 5);
166 myShowGrid->setCheck(mySettings->showGrid);
169 new FXMatrix(m12, 2, LAYOUT_CENTER_Y | LAYOUT_FILL_X | LAYOUT_BOTTOM | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
170 0, 0, 0, 0, 10, 10, 0, 0, 5, 5);
171 new FXLabel(m121,
"x-spacing", 0, LAYOUT_CENTER_Y);
174 LAYOUT_CENTER_Y | LAYOUT_TOP | FRAME_SUNKEN | FRAME_THICK);
175 myGridXSizeDialer->setRange(1, 10000);
176 myGridXSizeDialer->setValue(mySettings->gridXSize);
178 new FXMatrix(m12, 2, LAYOUT_CENTER_Y | LAYOUT_FILL_X | LAYOUT_BOTTOM | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
179 0, 0, 0, 0, 10, 10, 0, 0, 5, 5);
180 new FXLabel(m122,
"y-spacing", 0, LAYOUT_CENTER_Y);
183 LAYOUT_CENTER_Y | LAYOUT_TOP | FRAME_SUNKEN | FRAME_THICK);
184 myGridYSizeDialer->setRange(1, 10000);
185 myGridYSizeDialer->setValue(mySettings->gridXSize);
189 new FXTabItem(tabbook,
"Streets", NULL, TAB_LEFT_NORMAL, 0, 0, 0, 0, 4, 8, 4, 4);
190 FXScrollWindow* genScroll =
new FXScrollWindow(tabbook);
191 FXVerticalFrame* frame2 =
192 new FXVerticalFrame(genScroll, FRAME_THICK | FRAME_RAISED | LAYOUT_FILL_X | LAYOUT_FILL_Y, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2);
194 FXVerticalFrame* frame22 =
195 new FXVerticalFrame(frame2, LAYOUT_FILL_X | LAYOUT_FILL_Y, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2);
197 new FXMatrix(frame22, 3, LAYOUT_FILL_X | LAYOUT_TOP | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
198 0, 0, 0, 0, 10, 10, 10, 2, 5, 5);
199 new FXLabel(m21,
"Color", 0, LAYOUT_CENTER_Y);
200 myLaneEdgeColorMode =
new FXComboBox(m21, 30,
this,
MID_SIMPLE_VIEW_COLORCHANGE, FRAME_SUNKEN | LAYOUT_LEFT | LAYOUT_TOP | COMBOBOX_STATIC);
201 myLaneEdgeColorMode->setNumVisible(21);
202 myLaneColorInterpolation =
new FXCheckButton(m21,
"Interpolate",
this,
MID_SIMPLE_VIEW_COLORCHANGE, LAYOUT_CENTER_Y | CHECKBUTTON_NORMAL);
203 myLaneColorSettingFrame =
new FXVerticalFrame(frame22, LAYOUT_FILL_X | LAYOUT_FILL_Y, 0, 0, 0, 0, 10, 10, 2, 8, 5, 2);
205 new FXHorizontalSeparator(frame2, SEPARATOR_GROOVE | LAYOUT_FILL_X);
207 FXVerticalFrame* frame23 =
208 new FXVerticalFrame(frame2, LAYOUT_FILL_X | LAYOUT_FILL_Y, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2);
210 new FXMatrix(frame23, 3, LAYOUT_FILL_X | LAYOUT_TOP | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
211 0, 0, 0, 0, 10, 10, 10, 2, 5, 5);
212 new FXLabel(m23,
"Scale width", 0, LAYOUT_CENTER_Y);
213 myLaneEdgeScaleMode =
new FXComboBox(m23, 30,
this,
MID_SIMPLE_VIEW_COLORCHANGE, FRAME_SUNKEN | LAYOUT_LEFT | LAYOUT_TOP | COMBOBOX_STATIC);
214 myLaneEdgeScaleMode->setNumVisible(21);
215 myLaneScaleInterpolation =
new FXCheckButton(m23,
"Interpolate",
this,
MID_SIMPLE_VIEW_COLORCHANGE, LAYOUT_CENTER_Y | CHECKBUTTON_NORMAL);
216 myLaneScaleSettingFrame =
new FXVerticalFrame(frame23, LAYOUT_FILL_X | LAYOUT_FILL_Y, 0, 0, 0, 0, 10, 10, 2, 8, 5, 2);
219 if (GUIVisualizationSettings::UseMesoSim) {
220 mySettings->edgeColorer.fill(*myLaneEdgeColorMode);
221 mySettings->edgeScaler.fill(*myLaneEdgeScaleMode);
224 mySettings->laneColorer.fill(*myLaneEdgeColorMode);
225 mySettings->laneScaler.fill(*myLaneEdgeScaleMode);
230 new FXHorizontalSeparator(frame2, SEPARATOR_GROOVE | LAYOUT_FILL_X);
232 new FXMatrix(frame2, 2, LAYOUT_FILL_X | LAYOUT_BOTTOM | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
233 0, 0, 0, 0, 10, 10, 10, 10, 5, 5);
235 myShowLaneBorders->setCheck(mySettings->laneShowBorders);
236 new FXLabel(m22,
" ", 0, LAYOUT_CENTER_Y);
238 myShowLaneDecals->setCheck(mySettings->showLinkDecals);
239 new FXLabel(m22,
" ", 0, LAYOUT_CENTER_Y);
241 myShowRails->setCheck(mySettings->showRails);
242 new FXLabel(m22,
" ", 0, LAYOUT_CENTER_Y);
244 myHideMacroConnectors->setCheck(mySettings->hideConnectors);
245 new FXLabel(m22,
" ", 0, LAYOUT_CENTER_Y);
246 new FXLabel(m22,
"Exaggerate width by", 0, LAYOUT_CENTER_Y);
247 myLaneWidthUpscaleDialer =
249 LAYOUT_TOP | FRAME_SUNKEN | FRAME_THICK);
250 myLaneWidthUpscaleDialer->setRange(0, 10000);
251 myLaneWidthUpscaleDialer->setValue(mySettings->laneWidthExaggeration);
254 myEdgeNamePanel =
new NamePanel(m22,
this,
"Show edge name", mySettings->edgeName);
255 myStreetNamePanel =
new NamePanel(m22,
this,
"Show street name", mySettings->streetName);
256 myInternalEdgeNamePanel =
new NamePanel(m22,
this,
"Show internal edge name", mySettings->internalEdgeName);
257 myCwaEdgeNamePanel =
new NamePanel(m22,
this,
"Show crossing and walkingarea name", mySettings->cwaEdgeName);
261 new FXTabItem(tabbook,
"Vehicles", NULL, TAB_LEFT_NORMAL, 0, 0, 0, 0, 4, 8, 4, 4);
262 FXScrollWindow* genScroll =
new FXScrollWindow(tabbook);
263 FXVerticalFrame* frame3 =
264 new FXVerticalFrame(genScroll, FRAME_THICK | FRAME_RAISED | LAYOUT_FILL_X | LAYOUT_FILL_Y, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2);
267 new FXMatrix(frame3, 2, LAYOUT_FILL_X | LAYOUT_TOP | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
268 0, 0, 0, 0, 10, 10, 10, 2, 5, 5);
269 new FXLabel(m31,
"Show As", 0, LAYOUT_CENTER_Y);
270 myVehicleShapeDetail =
new FXComboBox(m31, 20,
this,
MID_SIMPLE_VIEW_COLORCHANGE, FRAME_SUNKEN | LAYOUT_LEFT | LAYOUT_TOP | COMBOBOX_STATIC);
271 myVehicleShapeDetail->appendItem(
"'triangles'");
272 myVehicleShapeDetail->appendItem(
"'boxes'");
273 myVehicleShapeDetail->appendItem(
"'simple shapes'");
274 myVehicleShapeDetail->appendItem(
"'raster images'");
275 myVehicleShapeDetail->setNumVisible(4);
276 myVehicleShapeDetail->setCurrentItem(settings->vehicleQuality);
278 new FXHorizontalSeparator(frame3, SEPARATOR_GROOVE | LAYOUT_FILL_X);
281 new FXMatrix(frame3, 3, LAYOUT_FILL_X | LAYOUT_TOP | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
282 0, 0, 0, 0, 10, 10, 10, 2, 5, 5);
283 new FXLabel(m32,
"Color", 0, LAYOUT_CENTER_Y);
284 myVehicleColorMode =
new FXComboBox(m32, 20,
this,
MID_SIMPLE_VIEW_COLORCHANGE, FRAME_SUNKEN | LAYOUT_LEFT | LAYOUT_TOP | COMBOBOX_STATIC);
285 mySettings->vehicleColorer.fill(*myVehicleColorMode);
286 myVehicleColorMode->setNumVisible(24);
287 myVehicleColorInterpolation =
new FXCheckButton(m32,
"Interpolate",
this,
MID_SIMPLE_VIEW_COLORCHANGE, LAYOUT_CENTER_Y | CHECKBUTTON_NORMAL);
289 myVehicleColorSettingFrame =
290 new FXVerticalFrame(frame3, LAYOUT_FILL_X | LAYOUT_FILL_Y, 0, 0, 0, 0, 10, 10, 2, 8, 5, 2);
292 new FXHorizontalSeparator(frame3, SEPARATOR_GROOVE | LAYOUT_FILL_X);
295 new FXMatrix(frame3, 2, LAYOUT_FILL_X | LAYOUT_TOP | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
296 0, 0, 0, 0, 10, 10, 10, 10, 5, 5);
298 myShowBlinker->setCheck(mySettings->showBlinker);
299 new FXLabel(m33,
" ", 0, LAYOUT_CENTER_Y);
301 myShowMinGap->setCheck(mySettings->drawMinGap);
302 new FXLabel(m33,
" ", 0, LAYOUT_CENTER_Y);
304 myShowBTRange->setCheck(mySettings->showBTRange);
305 new FXLabel(m33,
" ", 0, LAYOUT_CENTER_Y);
311 myVehicleNamePanel =
new NamePanel(m33,
this,
"Show vehicle name", mySettings->vehicleName);
319 new FXHorizontalSeparator(frame3, SEPARATOR_GROOVE | LAYOUT_FILL_X);
322 new FXMatrix(frame3, 2, LAYOUT_FILL_X | LAYOUT_BOTTOM | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
323 0, 0, 0, 0, 10, 10, 10, 10, 5, 5);
324 myVehicleSizePanel =
new SizePanel(m34,
this, mySettings->vehicleSize);
329 new FXTabItem(tabbook,
"Persons", NULL, TAB_LEFT_NORMAL, 0, 0, 0, 0, 4, 8, 4, 4);
330 FXScrollWindow* genScroll =
new FXScrollWindow(tabbook);
331 FXVerticalFrame* frame3 =
332 new FXVerticalFrame(genScroll, FRAME_THICK | FRAME_RAISED | LAYOUT_FILL_X | LAYOUT_FILL_Y, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2);
335 new FXMatrix(frame3, 2, LAYOUT_FILL_X | LAYOUT_TOP | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
336 0, 0, 0, 0, 10, 10, 10, 2, 5, 5);
337 new FXLabel(m101,
"Show As", 0, LAYOUT_CENTER_Y);
338 myPersonShapeDetail =
new FXComboBox(m101, 20,
this,
MID_SIMPLE_VIEW_COLORCHANGE, FRAME_SUNKEN | LAYOUT_LEFT | LAYOUT_TOP | COMBOBOX_STATIC);
339 myPersonShapeDetail->appendItem(
"'triangles'");
340 myPersonShapeDetail->appendItem(
"'boxes'");
341 myPersonShapeDetail->appendItem(
"'simple shapes'");
342 myPersonShapeDetail->appendItem(
"'raster images'");
343 myPersonShapeDetail->setNumVisible(4);
344 myPersonShapeDetail->setCurrentItem(settings->personQuality);
346 new FXHorizontalSeparator(frame3, SEPARATOR_GROOVE | LAYOUT_FILL_X);
349 new FXMatrix(frame3, 3, LAYOUT_FILL_X | LAYOUT_TOP | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
350 0, 0, 0, 0, 10, 10, 10, 2, 5, 5);
351 new FXLabel(m102,
"Color", 0, LAYOUT_CENTER_Y);
352 myPersonColorMode =
new FXComboBox(m102, 20,
this,
MID_SIMPLE_VIEW_COLORCHANGE, FRAME_SUNKEN | LAYOUT_LEFT | LAYOUT_TOP | COMBOBOX_STATIC);
353 mySettings->personColorer.fill(*myPersonColorMode);
354 myPersonColorMode->setNumVisible(9);
355 myPersonColorInterpolation =
new FXCheckButton(m102,
"Interpolate",
this,
MID_SIMPLE_VIEW_COLORCHANGE, LAYOUT_CENTER_Y | CHECKBUTTON_NORMAL);
357 myPersonColorSettingFrame =
358 new FXVerticalFrame(frame3, LAYOUT_FILL_X | LAYOUT_FILL_Y, 0, 0, 0, 0, 10, 10, 2, 8, 5, 2);
360 new FXHorizontalSeparator(frame3, SEPARATOR_GROOVE | LAYOUT_FILL_X);
363 new FXMatrix(frame3, 2, LAYOUT_FILL_X | LAYOUT_TOP | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
364 0, 0, 0, 0, 10, 10, 10, 10, 5, 5);
365 myPersonNamePanel =
new NamePanel(m103,
this,
"Show person name", mySettings->personName);
367 new FXHorizontalSeparator(frame3, SEPARATOR_GROOVE | LAYOUT_FILL_X);
370 new FXMatrix(frame3, 2, LAYOUT_FILL_X | LAYOUT_BOTTOM | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
371 0, 0, 0, 0, 10, 10, 10, 10, 5, 5);
372 myPersonSizePanel =
new SizePanel(m104,
this, mySettings->personSize);
376 new FXTabItem(tabbook,
"Junctions", NULL, TAB_LEFT_NORMAL, 0, 0, 0, 0, 4, 8, 4, 4);
377 FXScrollWindow* genScroll =
new FXScrollWindow(tabbook);
378 FXVerticalFrame* frame4 =
379 new FXVerticalFrame(genScroll, FRAME_THICK | FRAME_RAISED | LAYOUT_FILL_X | LAYOUT_FILL_Y, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2);
381 new FXMatrix(frame4, 3, LAYOUT_FILL_X | LAYOUT_TOP | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
382 0, 0, 0, 0, 10, 10, 10, 2, 5, 5);
383 new FXLabel(m41,
"Color", 0, LAYOUT_CENTER_Y);
384 myJunctionColorMode =
new FXComboBox(m41, 20,
this,
MID_SIMPLE_VIEW_COLORCHANGE, FRAME_SUNKEN | LAYOUT_LEFT | LAYOUT_TOP | COMBOBOX_STATIC);
385 mySettings->junctionColorer.fill(*myJunctionColorMode);
386 myJunctionColorMode->setNumVisible(3);
387 myJunctionColorInterpolation =
new FXCheckButton(m41,
"Interpolate",
this,
MID_SIMPLE_VIEW_COLORCHANGE, LAYOUT_CENTER_Y | CHECKBUTTON_NORMAL);
389 myJunctionColorSettingFrame =
390 new FXVerticalFrame(frame4, LAYOUT_FILL_X | LAYOUT_FILL_Y, 0, 0, 0, 0, 10, 10, 2, 8, 5, 2);
392 new FXHorizontalSeparator(frame4, SEPARATOR_GROOVE | LAYOUT_FILL_X);
394 new FXMatrix(frame4, 2, LAYOUT_FILL_X | LAYOUT_TOP | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
395 0, 0, 0, 0, 10, 10, 10, 10, 5, 5);
397 myShowTLIndex->setCheck(mySettings->drawLinkTLIndex);
398 new FXLabel(m42,
" ", 0, LAYOUT_CENTER_Y);
400 myShowJunctionIndex->setCheck(mySettings->drawLinkJunctionIndex);
401 new FXLabel(m42,
" ", 0, LAYOUT_CENTER_Y);
403 myShowLane2Lane->setCheck(mySettings->showLane2Lane);
404 new FXLabel(m42,
" ", 0, LAYOUT_CENTER_Y);
405 myJunctionNamePanel =
new NamePanel(m42,
this,
"Show junction name", mySettings->junctionName);
406 myInternalJunctionNamePanel =
new NamePanel(m42,
this,
"Show internal junction name", mySettings->internalJunctionName);
408 myDrawJunctionShape->setCheck(mySettings->drawJunctionShape);
411 new FXTabItem(tabbook,
"Detectors/Trigger", NULL, TAB_LEFT_NORMAL, 0, 0, 0, 0, 4, 8, 4, 4);
412 FXScrollWindow* genScroll =
new FXScrollWindow(tabbook);
413 FXVerticalFrame* frame5 =
414 new FXVerticalFrame(genScroll, FRAME_THICK | FRAME_RAISED | LAYOUT_FILL_X | LAYOUT_FILL_Y, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2);
417 new FXMatrix(frame5, 2, LAYOUT_FILL_X | LAYOUT_TOP | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
418 0, 0, 0, 0, 10, 10, 10, 10, 5, 5);
419 myAddNamePanel =
new NamePanel(m51,
this,
"Show detector name", mySettings->addName);
420 new FXHorizontalSeparator(frame5 , SEPARATOR_GROOVE | LAYOUT_FILL_X);
423 new FXMatrix(frame5, 2, LAYOUT_FILL_X | LAYOUT_TOP | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
424 0, 0, 0, 0, 10, 10, 10, 10, 5, 5);
425 myAddSizePanel =
new SizePanel(m52,
this, mySettings->addSize);
436 new FXTabItem(tabbook,
"POIs", NULL, TAB_LEFT_NORMAL, 0, 0, 0, 0, 4, 8, 4, 4);
437 FXScrollWindow* genScroll =
new FXScrollWindow(tabbook);
438 FXVerticalFrame* frame6 =
439 new FXVerticalFrame(genScroll, FRAME_THICK | FRAME_RAISED | LAYOUT_FILL_X | LAYOUT_FILL_Y, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2);
442 new FXMatrix(frame6, 2, LAYOUT_FILL_X | LAYOUT_TOP | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
443 0, 0, 0, 0, 10, 10, 10, 10, 5, 5);
444 myPOINamePanel =
new NamePanel(m61,
this,
"Show poi names", mySettings->poiName);
445 new FXHorizontalSeparator(frame6 , SEPARATOR_GROOVE | LAYOUT_FILL_X);
448 new FXMatrix(frame6, 2, LAYOUT_FILL_X | LAYOUT_TOP | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
449 0, 0, 0, 0, 10, 10, 10, 10, 5, 5);
450 myPOISizePanel =
new SizePanel(m62,
this, mySettings->poiSize);
454 new FXTabItem(tabbook,
"Polygons", NULL, TAB_LEFT_NORMAL, 0, 0, 0, 0, 4, 8, 4, 4);
455 FXScrollWindow* genScroll =
new FXScrollWindow(tabbook);
456 FXVerticalFrame* frame9 =
457 new FXVerticalFrame(genScroll, FRAME_THICK | FRAME_RAISED | LAYOUT_FILL_X | LAYOUT_FILL_Y, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2);
460 new FXMatrix(frame9, 2, LAYOUT_FILL_X | LAYOUT_TOP | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
461 0, 0, 0, 0, 10, 10, 10, 10, 5, 5);
462 myPolyNamePanel =
new NamePanel(m91,
this,
"Show polygon names", mySettings->polyName);
463 new FXHorizontalSeparator(frame9 , SEPARATOR_GROOVE | LAYOUT_FILL_X);
465 myPolySizePanel =
new SizePanel(m91,
this, mySettings->polySize);
469 new FXTabItem(tabbook,
"Legend", NULL, TAB_LEFT_NORMAL, 0, 0, 0, 0, 4, 8, 4, 4);
470 FXScrollWindow* genScroll =
new FXScrollWindow(tabbook);
471 FXVerticalFrame* frame7 =
472 new FXVerticalFrame(genScroll, FRAME_THICK | FRAME_RAISED | LAYOUT_FILL_X | LAYOUT_FILL_Y, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2);
475 new FXMatrix(frame7, 2, LAYOUT_FILL_X | LAYOUT_TOP | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
476 0, 0, 0, 0, 10, 10, 10, 10, 5, 5);
478 myShowSizeLegend->setCheck(mySettings->showSizeLegend);
482 new FXTabItem(tabbook,
"openGL", NULL, TAB_LEFT_NORMAL, 0, 0, 0, 0, 4, 8, 4, 4);
483 FXScrollWindow* genScroll =
new FXScrollWindow(tabbook);
484 FXVerticalFrame* frame8 =
485 new FXVerticalFrame(genScroll, FRAME_THICK | FRAME_RAISED | LAYOUT_FILL_X | LAYOUT_FILL_Y, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2);
488 new FXMatrix(frame8, 1, LAYOUT_FILL_X | LAYOUT_TOP | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
489 0, 0, 0, 0, 10, 10, 10, 10, 5, 5);
491 myAntialiase->setCheck(mySettings->antialiase);
493 myDither->setCheck(mySettings->dither);
496 FXButton* initial =
new FXButton(f2,
"&Use", NULL,
this,
MID_SETTINGS_OK, BUTTON_INITIAL | BUTTON_DEFAULT | FRAME_RAISED | FRAME_THICK | LAYOUT_TOP | LAYOUT_LEFT | LAYOUT_CENTER_X, 0, 0, 0, 0, 30, 30, 4, 4);
497 new FXButton(f2,
"&Discard", NULL,
this,
MID_SETTINGS_CANCEL, BUTTON_DEFAULT | FRAME_RAISED | FRAME_THICK | LAYOUT_TOP | LAYOUT_LEFT | LAYOUT_CENTER_X, 0, 0, 0, 0, 30, 30, 4, 4);
500 rebuildColorMatrices(
false);
503 setX(getApp()->reg().readIntEntry(
"VIEWSETTINGS",
"x", 150));
504 setY(getApp()->reg().readIntEntry(
"VIEWSETTINGS",
"y", 150));
505 setWidth(getApp()->reg().readIntEntry(
"VIEWSETTINGS",
"width", 700));
506 setHeight(getApp()->reg().readIntEntry(
"VIEWSETTINGS",
"height", 500));
560 FXString dataS = (
char*) data;
563 for (
int i = 0; i <
mySchemeName->getNumItems() - 1; ++i) {
634 std::vector<FXColorWell*>::const_iterator colEnd,
635 std::vector<FXRealSpinDial*>::const_iterator threshIt,
636 std::vector<FXRealSpinDial*>::const_iterator threshEnd,
637 std::vector<FXButton*>::const_iterator buttonIt,
640 while (colIt != colEnd) {
642 if (sender == *colIt) {
646 if (sender == *threshIt) {
647 const SUMOReal val = (*threshIt)->getValue();
651 (*threshIt)->getRange(lo, hi);
652 (*threshIt)->setRange(lo, val);
656 if (threshIt != threshEnd) {
657 (*threshIt)->getRange(lo, hi);
658 (*threshIt)->setRange(val, hi);
663 if (sender == *colIt) {
667 if (sender == *buttonIt) {
687 std::vector<FXRealSpinDial*>::const_iterator scaleEnd,
688 std::vector<FXRealSpinDial*>::const_iterator threshIt,
689 std::vector<FXRealSpinDial*>::const_iterator threshEnd,
690 std::vector<FXButton*>::const_iterator buttonIt,
693 while (scaleIt != scaleEnd) {
695 if (sender == *scaleIt) {
696 scheme.
setColor(pos, (*scaleIt)->getValue());
699 if (sender == *threshIt) {
700 const SUMOReal val = (*threshIt)->getValue();
704 (*threshIt)->getRange(lo, hi);
705 (*threshIt)->setRange(lo, val);
709 if (threshIt != threshEnd) {
710 (*threshIt)->getRange(lo, hi);
711 (*threshIt)->setRange(val, hi);
716 if (sender == *scaleIt) {
717 scheme.
setColor(pos, (*scaleIt)->getValue());
720 if (sender == *buttonIt) {
722 scheme.
addColor((*scaleIt)->getValue(), (*threshIt)->getValue());
746 bool doRebuildColorMatrices =
false;
755 if (GUIVisualizationSettings::UseMesoSim) {
817 doRebuildColorMatrices =
true;
821 doRebuildColorMatrices =
true;
824 doRebuildColorMatrices =
true;
831 doRebuildColorMatrices =
true;
835 doRebuildColorMatrices =
true;
838 doRebuildColorMatrices =
true;
845 doRebuildColorMatrices =
true;
849 doRebuildColorMatrices =
true;
852 doRebuildColorMatrices =
true;
859 doRebuildColorMatrices =
true;
863 doRebuildColorMatrices =
true;
866 doRebuildColorMatrices =
true;
873 doRebuildColorMatrices =
true;
877 doRebuildColorMatrices =
true;
880 doRebuildColorMatrices =
true;
910 if (doRebuildColorMatrices) {
914 getApp()->forceRefresh();
923 if (settingsName !=
"") {
924 FXint index =
mySchemeName->appendItem(settingsName.c_str());
937 std::vector<GUISUMOAbstractView::Decal>::iterator j;
940 dev <<
" <decal filename=\"" << d.
filename
941 <<
"\" centerX=\"" << d.
centerX
942 <<
"\" centerY=\"" << d.
centerY
943 <<
"\" centerZ=\"" << d.
centerZ
944 <<
"\" width=\"" << d.
width
945 <<
"\" height=\"" << d.
height
947 <<
"\" rotation=\"" << d.
rot
948 <<
"\" tilt=\"" << d.
tilt
949 <<
"\" roll=\"" << d.
roll
950 <<
"\" layer=\"" << d.
layer
953 dev <<
"</decals>\n";
956 FXMessageBox::error(
myParent, MBOX_OK,
"Storing failed!",
"%s", e.what());
981 std::string name =
"";
982 while (name.length() == 0) {
983 FXDialogBox dialog(
this,
"Enter a name", DECOR_TITLE | DECOR_BORDER);
984 FXVerticalFrame* content =
new FXVerticalFrame(&dialog, LAYOUT_FILL_X | LAYOUT_FILL_Y, 0, 0, 0, 0, 10, 10, 10, 10, 10, 10);
985 new FXLabel(content,
"Please enter an alphanumeric name: ", NULL, LAYOUT_FILL_X | JUSTIFY_LEFT);
986 FXTextField*
text =
new FXTextField(content, 40, &dialog, FXDialogBox::ID_ACCEPT, TEXTFIELD_ENTER_ONLY | FRAME_SUNKEN | FRAME_THICK | LAYOUT_FILL_X);
987 new FXHorizontalSeparator(content, SEPARATOR_GROOVE | LAYOUT_FILL_X);
989 new FXButton(buttons,
"&OK", NULL, &dialog, FXDialogBox::ID_ACCEPT, BUTTON_INITIAL | BUTTON_DEFAULT | FRAME_RAISED | FRAME_THICK | LAYOUT_RIGHT);
990 new FXButton(buttons,
"&Cancel", NULL, &dialog, FXDialogBox::ID_CANCEL, BUTTON_DEFAULT | FRAME_RAISED | FRAME_THICK | LAYOUT_RIGHT, 0, 0, 0, 0, 20, 20);
993 if (!dialog.execute()) {
996 name = text->getText().text();
997 for (
size_t i = 0; i < name.length(); ++i) {
998 if (name[i] !=
'_' && (name[i] <
'a' || name[i] >
'z') && (name[i] <
'A' || name[i] >
'Z') && (name[i] <
'0' || name[i] >
'9')) {
1006 tmpSettings.
name = name;
1020 sender->handle(
this,
1022 ? FXSEL(SEL_COMMAND, ID_DISABLE) : FXSEL(SEL_COMMAND, ID_ENABLE),
1034 std::string name =
mySchemeName->getItem(index).text();
1045 sender->handle(
this,
1047 ? FXSEL(SEL_COMMAND, ID_DISABLE) : FXSEL(SEL_COMMAND, ID_ENABLE),
1064 FXMessageBox::error(
this, MBOX_OK,
"Storing failed!",
"%s", e.what());
1072 sender->handle(
this,
1074 ? FXSEL(SEL_COMMAND, ID_DISABLE) : FXSEL(SEL_COMMAND, ID_ENABLE),
1082 FXFileDialog opendialog(
this,
"Import view settings");
1084 opendialog.setSelectMode(SELECTFILE_ANY);
1085 opendialog.setPatternList(
"*.xml");
1089 if (opendialog.execute()) {
1099 FXFileDialog opendialog(
this,
"Load Decals");
1101 opendialog.setSelectMode(SELECTFILE_ANY);
1102 opendialog.setPatternList(
"*.xml");
1106 if (opendialog.execute()) {
1129 sender->handle(
this, FXSEL(SEL_COMMAND, ID_ENABLE), ptr);
1147 header->setHeight(getApp()->getNormalFont()->getFontHeight() + getApp()->getNormalFont()->getFontAscent());
1149 for (k = 0; k < 7; k++) {
1150 header->setItemJustify(k, JUSTIFY_CENTER_X | JUSTIFY_TOP);
1151 header->setItemSize(k, 60);
1153 header->setItemSize(0, 150);
1156 std::vector<GUISUMOAbstractView::Decal>::iterator j;
1169 for (k = 0; k < 7; k++) {
1177 std::vector<FXColorWell*>& colors,
1178 std::vector<FXRealSpinDial*>& thresholds,
1179 std::vector<FXButton*>& buttons,
1180 FXCheckButton* interpolation,
1183 FXMatrix* m =
new FXMatrix(frame, 3,
1184 LAYOUT_FILL_X | MATRIX_BY_COLUMNS,
1185 0, 0, 0, 0, 10, 10, 0, 0, 5, 3);
1189 const bool fixed = scheme.
isFixed();
1190 std::vector<RGBColor>::const_iterator colIt = scheme.
getColors().begin();
1191 std::vector<SUMOReal>::const_iterator threshIt = scheme.
getThresholds().begin();
1192 std::vector<std::string>::const_iterator nameIt = scheme.
getNames().begin();
1193 FX::FXString buttonText =
"Add";
1194 while (colIt != scheme.
getColors().end()) {
1197 LAYOUT_FIX_WIDTH | LAYOUT_CENTER_Y | FRAME_SUNKEN | FRAME_THICK | ICON_AFTER_TEXT,
1198 0, 0, 100, 0, 0, 0, 0, 0));
1200 new FXLabel(m, nameIt->c_str());
1205 threshDialer->setValue(*threshIt);
1206 thresholds.push_back(threshDialer);
1207 buttons.push_back(
new FXButton(m, buttonText, NULL,
this,
MID_SIMPLE_VIEW_COLORCHANGE, BUTTON_DEFAULT | FRAME_RAISED | FRAME_THICK | LAYOUT_TOP | LAYOUT_LEFT | LAYOUT_CENTER_X, 0, 0, 0, 0, 20, 20, 4, 4));
1208 buttonText =
"Remove";
1216 interpolation->disable();
1218 if (colors.size() > 1) {
1219 interpolation->enable();
1220 if (interpolation->getCheck() != FALSE) {
1221 thresholds.front()->enable();
1223 thresholds.front()->disable();
1226 interpolation->disable();
1227 thresholds.front()->disable();
1236 std::vector<FXRealSpinDial*>& scales,
1237 std::vector<FXRealSpinDial*>& thresholds,
1238 std::vector<FXButton*>& buttons,
1239 FXCheckButton* interpolation,
1242 FXMatrix* m =
new FXMatrix(frame, 3,
1243 LAYOUT_FILL_X | MATRIX_BY_COLUMNS,
1244 0, 0, 0, 0, 10, 10, 0, 0, 5, 3);
1248 const bool fixed = scheme.
isFixed();
1249 std::vector<SUMOReal>::const_iterator scaleIt = scheme.
getColors().begin();
1250 std::vector<SUMOReal>::const_iterator threshIt = scheme.
getThresholds().begin();
1251 std::vector<std::string>::const_iterator nameIt = scheme.
getNames().begin();
1252 FX::FXString buttonText =
"Add";
1253 while (scaleIt != scheme.
getColors().end()) {
1255 scaleDialer->setValue(*scaleIt);
1256 scales.push_back(scaleDialer);
1258 new FXLabel(m, nameIt->c_str());
1263 threshDialer->setValue(*threshIt);
1264 thresholds.push_back(threshDialer);
1265 buttons.push_back(
new FXButton(m, buttonText, NULL,
this,
MID_SIMPLE_VIEW_COLORCHANGE, BUTTON_DEFAULT | FRAME_RAISED | FRAME_THICK | LAYOUT_TOP | LAYOUT_LEFT | LAYOUT_CENTER_X, 0, 0, 0, 0, 20, 20, 4, 4));
1266 buttonText =
"Remove";
1274 interpolation->disable();
1276 if (scales.size() > 1) {
1277 interpolation->enable();
1278 if (interpolation->getCheck() != FALSE) {
1279 thresholds.front()->enable();
1281 thresholds.front()->disable();
1284 interpolation->disable();
1285 thresholds.front()->disable();
1297 LAYOUT_FILL_Y | LAYOUT_FIX_WIDTH, 0, 0, 470, 0);
1303 for (
int i = 1; i <= 5; ++i) {
1349 std::string value = i->
item->getText().text();
1351 if (value.find_first_not_of(
" ") == std::string::npos) {
1357 if (row == static_cast<int>(
myDecals->size())) {
1369 }
else if (row > static_cast<int>(
myDecals->size())) {
1373 d = (*myDecals)[row];
1387 std::string msg =
"The value must be a float, is:" + value;
1388 FXMessageBox::error(
this, MBOX_OK,
"Number format error",
"%s", msg.c_str());
1395 std::string msg =
"The value must be a float, is:" + value;
1396 FXMessageBox::error(
this, MBOX_OK,
"Number format error",
"%s", msg.c_str());
1403 std::string msg =
"The value must be a float, is:" + value;
1404 FXMessageBox::error(
this, MBOX_OK,
"Number format error",
"%s", msg.c_str());
1411 std::string msg =
"The value must be a float, is:" + value;
1412 FXMessageBox::error(
this, MBOX_OK,
"Number format error",
"%s", msg.c_str());
1419 std::string msg =
"The value must be a float, is:" + value;
1420 FXMessageBox::error(
this, MBOX_OK,
"Number format error",
"%s", msg.c_str());
1427 std::string msg =
"The value must be a float, is:" + value;
1428 FXMessageBox::error(
this, MBOX_OK,
"Number format error",
"%s", msg.c_str());
1434 (*myDecals)[row] = d;
1454 for (
int i = 0; i <
mySchemeName->getNumItems(); ++i) {
1466 const std::string& title,
1471 FXMatrix* m1 =
new FXMatrix(parent, 2, LAYOUT_FILL_X | LAYOUT_BOTTOM | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
1472 0, 0, 0, 0, 10, 10, 0, 0, 5, 5);
1473 new FXLabel(m1,
"Size", 0, LAYOUT_CENTER_Y);
1474 mySizeDial =
new FXRealSpinDial(m1, 10, target, MID_SIMPLE_VIEW_COLORCHANGE,
1475 LAYOUT_CENTER_Y | LAYOUT_TOP | FRAME_SUNKEN | FRAME_THICK);
1478 FXMatrix* m2 =
new FXMatrix(parent, 2, LAYOUT_FILL_X | LAYOUT_BOTTOM | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
1479 0, 0, 0, 0, 10, 10, 0, 0, 5, 5);
1480 new FXLabel(m2,
"Color", 0, LAYOUT_CENTER_Y);
1482 target, MID_SIMPLE_VIEW_COLORCHANGE,
1483 LAYOUT_FIX_WIDTH | LAYOUT_CENTER_Y | LAYOUT_SIDE_TOP | FRAME_SUNKEN | FRAME_THICK | ICON_AFTER_TEXT,
1484 0, 0, 100, 0, 0, 0, 0, 0);
1497 myCheck->setCheck(settings.
show);
1498 mySizeDial->setValue(settings.
size);
1507 myCheck =
new FXCheckButton(parent,
"Draw with constant size when zoomed out", target,
MID_SIMPLE_VIEW_COLORCHANGE, LAYOUT_CENTER_Y | CHECKBUTTON_NORMAL);
1510 FXMatrix* m1 =
new FXMatrix(parent, 2, LAYOUT_FILL_X | LAYOUT_BOTTOM | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
1511 0, 0, 0, 0, 10, 10, 0, 0, 5, 5);
1512 new FXLabel(m1,
"Minimum Size", 0, LAYOUT_CENTER_Y);
1514 LAYOUT_CENTER_Y | LAYOUT_TOP | FRAME_SUNKEN | FRAME_THICK);
1515 myMinSizeDial->setValue(settings.
minSize);
1516 FXMatrix* m2 =
new FXMatrix(parent, 2, LAYOUT_FILL_X | LAYOUT_BOTTOM | LAYOUT_LEFT | MATRIX_BY_COLUMNS,
1517 0, 0, 0, 0, 10, 10, 0, 0, 5, 5);
1518 new FXLabel(m2,
"Exaggerate by", 0, LAYOUT_CENTER_Y);
1520 LAYOUT_TOP | FRAME_SUNKEN | FRAME_THICK);
1521 myExaggerateDial->setRange(0, 10000);
1529 myMinSizeDial->getValue(), myExaggerateDial->getValue(), myCheck->getCheck() != FALSE);
1536 myMinSizeDial->setValue(settings.
minSize);
1543 getApp()->reg().writeIntEntry(
"VIEWSETTINGS",
"x", getX());
1544 getApp()->reg().writeIntEntry(
"VIEWSETTINGS",
"y", getY());
1545 getApp()->reg().writeIntEntry(
"VIEWSETTINGS",
"width", getWidth());
1546 getApp()->reg().writeIntEntry(
"VIEWSETTINGS",
"height", getHeight());
void rebuildColorMatrices(bool doCreate=false)
Rebuilds color changing dialogs after choosing another coloring scheme.
GUIVisualizationTextSettings junctionName
A decal (an image) that can be shown.
FXVerticalFrame * myVehicleColorSettingFrame
long onUpdSaveSetting(FXObject *, FXSelector, void *data)
Called when updating the button that allows to save the settings into the registry.
FXCheckButton * myLaneColorInterpolation
FXComboBox * myJunctionColorMode
void close()
Closes the device and removes it from the dictionary.
FXVerticalFrame * myDecalsFrame
const std::vector< T > & getColors() const
GUICompleteSchemeStorage gSchemeStorage
bool showSizeLegend
Information whether the size legend shall be drawn.
FXCheckButton * myJunctionColorInterpolation
FXCheckButton * myShowBlinker
bool isInterpolated() const
Cancel-button was pushed.
FXVerticalFrame * myLaneScaleSettingFrame
FXCheckButton * myShowBTRange
GUIVisualizationTextSettings streetName
float laneWidthExaggeration
The lane exaggeration (upscale thickness)
size_t getLaneEdgeMode() const
Returns the number of the active lane (edge) coloring schme.
SUMOReal roll
The roll of the image to the ground plane (in degrees)
std::string addSettings(GUISUMOAbstractView *view=0) const
Adds the parsed settings to the global list of settings.
Informs the dialog about switching to another scheme.
For the export-to-file - button.
bool showBlinker
Information whether vehicle blinkers shall be drawn.
GUIVisualizationTextSettings addName
FXComboBox * myVehicleColorMode
void removeColor(const size_t pos)
GUIVisualizationTextSettings personName
std::vector< FXButton * > myLaneButtons
bool drawLinkTLIndex
Information whether a link's tls index shall be drawn.
static SUMOReal _2SUMOReal(const E *const data)
SizePanel * myPOISizePanel
GUIVisualizationTextSettings poiName
GUIColorScheme & getLaneEdgeScheme()
Returns the current lane (edge) coloring schme.
bool showBTRange
Information whether the communication range shall be drawn.
GUIColorer laneColorer
The lane colorer.
Stores the information about how to visualize structures.
The dialog to change the view (gui) settings.
SizePanel(FXMatrix *parent, GUIDialog_ViewSettings *target, const GUIVisualizationSizeSettings &settings)
static RGBColor getRGBColor(FXColor col)
converts FXColor to RGBColor
void remove(GUIDialog_EditViewport *)
std::vector< FXRealSpinDial * > myLaneScaleThresholds
std::vector< GUISUMOAbstractView::Decal > * myDecals
The parent's decals.
NamePanel * myPOINamePanel
void setColor(const size_t pos, const T &color)
bool showRails
Information whether rails shall be drawn.
void loadDecals(const std::string &file)
Loads decals from a file.
std::vector< FXButton * > myPersonButtons
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.
std::vector< FXColorWell * > myJunctionColors
GUIVisualizationTextSettings vehicleName
FXComboBox * myVehicleShapeDetail
void loadSettings(const std::string &file)
Loads a scheme from a file.
bool hasDecals() const
Returns whether any decals have been parsed.
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.
void setActive(size_t scheme)
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.
SUMOReal getGridHeight() const
SUMOReal centerZ
The center of the image in z-direction (net coordinates, in m)
long onCmdExportSetting(FXObject *, FXSelector, void *data)
Called if the settings shall be exported into a file.
SUMOReal width
The width of the image (net coordinates in x-direction, in m)
long onCmdEditTable(FXObject *, FXSelector, void *data)
Called if the decals-table was changed.
static FXString getFilename2Write(FXWindow *parent, const FXString &header, const FXString &extension, FXIcon *icon, FXString ¤tFolder)
Returns the file name to write.
bool dither
Information whether dithering shall be enabled.
std::vector< FXRealSpinDial * > myPersonThresholds
const std::vector< GUISUMOAbstractView::Decal > & getDecals() const
Returns the parsed decals.
FXColorWell * myColorWell
FXDEFMAP(GUIDialog_AppSettings) GUIDialog_AppSettingsMap[]
long onCmdNameChange(FXObject *, FXSelector, void *)
Called if the name of the scheme was changed.
SizePanel * myPolySizePanel
void setThreshold(const size_t pos, const SUMOReal threshold)
void saveDecals(const std::string &file) const
Writes the currently used decals into a file.
GUIVisualizationSizeSettings polySize
GUIColorer vehicleColorer
The vehicle colorer.
GUIVisualizationTextSettings edgeName
void setInterpolated(const bool interpolate, SUMOReal interpolationStart=0.f)
FXCheckButton * myVehicleColorInterpolation
GUIVisualizationSizeSettings addSize
const std::vector< std::string > & getNames() const
Returns a list of stored settings names.
For the load-decals - button.
NamePanel * myInternalEdgeNamePanel
FXCheckButton * myShowMinGap
NamePanel * myEdgeNamePanel
FXCheckButton * myShowGrid
std::string name
The name of this setting.
void setCurrentScheme(const std::string &)
Sets the named scheme as the current.
FXCheckButton * myShowLane2Lane
void rebuildList()
Rebuilds the decals table.
void update(const GUIVisualizationSizeSettings &settings)
SUMOReal altitude
The altitude of the image (net coordinates in z-direction, in m)
GUIVisualizationSettings * mySettings
The current settings.
GUIVisualizationTextSettings internalEdgeName
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.
std::vector< FXRealSpinDial * > myLaneScales
NamePanel * myStreetNamePanel
SUMOReal centerY
The center of the image in y-direction (net coordinates, in m)
bool drawMinGap
Information whether the minimum gap shall be drawn.
NamePanel * myInternalJunctionNamePanel
std::vector< FXColorWell * > myVehicleColors
bool contains(const std::string &name) const
Returns the information whether a setting with the given name is stored.
FXRealSpinDial * myLaneWidthUpscaleDialer
void remove(const std::string &name)
Removes the setting with the given name.
unsigned int getNumInitialSettings() const
Returns the number of initial settings.
void saveWindowSize()
save window position and size to the registry
FXCheckButton * myShowSizeLegend
GUIVisualizationSettings & get(const std::string &name)
Returns the named scheme.
bool allowsNegativeValues() const
FXVerticalFrame * myLaneColorSettingFrame
FXComboBox & getColoringSchemesCombo()
bool initialised
Whether this image was initialised (inserted as a texture)
GUIColorer personColorer
The person colorer.
GUIVisualizationTextSettings internalJunctionName
const std::vector< std::string > & getNames() const
float minSize
The minimum size to draw this object.
GUIColorer junctionColorer
The junction colorer.
std::string getCurrentScheme() const
Returns the name of the currently chosen scheme.
std::string filename
The path to the file the image is located at.
For the save-to-db - button.
SUMOReal gridXSize
Information about the grid spacings.
long onUpdDeleteSetting(FXObject *, FXSelector, void *data)
Called when updating the button that allows to delete settings.
FXVerticalFrame * myJunctionColorSettingFrame
std::string toString(const T &t, std::streamsize accuracy=OUTPUT_ACCURACY)
FXCheckButton * myLaneScaleInterpolation
FXCheckButton * myShowLaneBorders
SizePanel * myAddSizePanel
NamePanel * myAddNamePanel
unsigned int addColor(const T &color, const SUMOReal threshold, const std::string &name="")
GUIScaleScheme & getLaneEdgeScaleScheme()
Returns the current lane (edge) scaling schme.
std::vector< FXColorWell * > myPersonColors
FXRealSpinDial * myGridYSizeDialer
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
long onCmdOk(FXObject *, FXSelector, void *)
Called if the OK-button was pressed.
NamePanel * myCwaEdgeNamePanel
For the save-decals - button.
void unlock()
release mutex lock
SUMOReal height
The height of the image (net coordinates in y-direction, in m)
GUIVisualizationSizeSettings poiSize
~GUIDialog_ViewSettings()
Destructor.
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)
SUMOReal centerX
The center of the image in x-direction (net coordinates, in m)
NamePanel * myVehicleNamePanel
FXCheckButton * myShowJunctionIndex
MFXAddEditTypedTable * myDecalsTable
FXCheckButton * myDrawJunctionShape
float exaggeration
The size exaggeration (upscale)
bool showLinkDecals
Information whether link textures (arrows) shall be drawn.
FXRealSpinDial * mySizeDial
NamePanel(FXMatrix *parent, GUIDialog_ViewSettings *target, const std::string &title, const GUIVisualizationTextSettings &settings)
FXComboBox * myLaneEdgeScaleMode
... lane scaler
static OutputDevice & getDevice(const std::string &name)
Returns the described OutputDevice.
GUIVisualizationTextSettings getSettings()
FXComboBox * myPersonShapeDetail
NamePanel * myJunctionNamePanel
void writeSettings(FXApp *app)
Writes the current scheme into the registry.
FXComboBox * myLaneEdgeColorMode
... lane colorer
void setCurrent(GUIVisualizationSettings *settings)
Sets current settings (called if reopened)
FXCheckButton * myHideMacroConnectors
bool drawLinkJunctionIndex
Information whether a link's junction index shall be drawn.
SUMOReal getGridWidth() const
FXCheckButton * myShowRails
GUIVisualizationSizeSettings personSize
virtual bool setColorScheme(const std::string &)
int personQuality
The quality of person drawing.
FXCheckButton * myShowTLIndex
bool showGrid
Information whether a grid shall be shown.
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
SUMOReal layer
The layer of the image.
long onCmdColorChange(FXObject *, FXSelector, void *)
Called if something (color, width, etc.) has been changed.
bool showLane2Lane
Information whether lane-to-lane arrows shall be drawn.
SizePanel * myPersonSizePanel
Static storage of an output device and its base (abstract) implementation.
void setCellType(size_t pos, CellType t)
FXRealSpinDial * myGridXSizeDialer
An XML-handler for visualisation schemes.
void save(OutputDevice &dev) const
Writes the settings into an output device.
FXCheckButton * myPersonColorInterpolation
GUIVisualizationSizeSettings vehicleSize
SizePanel * myVehicleSizePanel
bool drawJunctionShape
whether the shape of the junction should be drawn
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
SUMOReal tilt
The tilt of the image to the ground plane (in degrees)
GUIVisualizationSizeSettings getSettings()
int vehicleQuality
The quality of vehicle drawing.
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)
MFXMutex * myDecalsLock
Lock used when changing the decals.
void setNumberCellParams(size_t pos, double min, double max, double steps1, double steps2, double steps3, const std::string &format)
std::vector< FXRealSpinDial * > myJunctionThresholds
GUIScaler laneScaler
The lane scaler.
For the import-from-file - button.
FXCheckButton * myAntialiase
const std::vector< SUMOReal > & getThresholds() const
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
static FXIcon * getIcon(GUIIcon which)
std::vector< FXButton * > myJunctionButtons
NamePanel * myPersonNamePanel
GUIVisualizationSettings myBackup
A backup of the settings (used if the "Cancel" button is pressed)
size_t getLaneEdgeScaleMode() const
Returns the number of the active lane (edge) scaling schme.
std::vector< FXColorWell * > myLaneColors
FXComboBox * mySchemeName
std::vector< FXRealSpinDial * > myLaneThresholds
Informs the dialog about a value's change.
std::vector< FXButton * > myVehicleButtons
SUMOReal rot
The rotation of the image in the ground plane (in degrees)
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
FXCheckButton * myShowLaneDecals