SUMO - Simulation of Urban MObility
GNEDialog_About.cpp
Go to the documentation of this file.
1 /****************************************************************************/
2 // Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.org/sumo
3 // Copyright (C) 2001-2017 German Aerospace Center (DLR) and others.
4 /****************************************************************************/
5 //
6 // This program and the accompanying materials
7 // are made available under the terms of the Eclipse Public License v2.0
8 // which accompanies this distribution, and is available at
9 // http://www.eclipse.org/legal/epl-v20.html
10 //
11 /****************************************************************************/
17 // The "About" - dialog for NETEDIT, (adapted from GUIDialog_AboutSUMO)
18 /****************************************************************************/
19 
20 
21 // ===========================================================================
22 // included modules
23 // ===========================================================================
24 #ifdef _MSC_VER
25 #include <windows_config.h>
26 #else
27 #include <config.h>
28 #endif
29 
30 #ifdef HAVE_VERSION_H
31 #include <version.h>
32 #endif
33 
34 #include <utils/common/StdDefs.h>
38 #include "GNEDialog_About.h"
39 
40 
41 // ===========================================================================
42 // method definitions
43 // ===========================================================================
45  FXDialogBox(parent, "About NETEDIT", GUIDesignDialogBox) {
46  // set dialog icon
48 
49  // create frame for main info
50  FXHorizontalFrame* mainInfoFrame = new FXHorizontalFrame(this, GUIDesignAuxiliarHorizontalFrame);
51 
52  // DLR Icon
53  new FXLabel(mainInfoFrame, "", GUIIconSubSys::getIcon(ICON_DLR), GUIDesignLabelIcon64x64noSpacing);
54 
55  // "NETEDIT <VERSION>"
56  FXVerticalFrame* descriptionFrame = new FXVerticalFrame(mainInfoFrame, GUIDesignLabelAboutInfo);
57  myHeadlineFont = new FXFont(getApp(), "Arial", 18, FXFont::Bold);
58  FXLabel* neteditLabel = new FXLabel(descriptionFrame, "NETEDIT " VERSION_STRING, 0, GUIDesignLabelAboutInfo);
59  neteditLabel->setFont(myHeadlineFont);
60  new FXLabel(descriptionFrame, "Network editor for SUMO, the Simulation of Urban MObility", 0, GUIDesignLabelAboutInfo);
61  new FXLabel(descriptionFrame, HAVE_ENABLED, 0, GUIDesignLabelAboutInfo);
62 
63  // Netedit icon
65 
66  // copyright notice
67  new FXLabel(this, "Part of SUMO, the Simulation of Urban MObility.", 0, GUIDesignLabelAboutInfo);
68  new FXLabel(this, "Copyright (C) 2001-2017 DLR / Institute of Transportation Systems", 0, GUIDesignLabelAboutInfo);
69 
70  // link to homepage
71  FXLinkLabel* link = new FXLinkLabel(this, "http://sumo.dlr.de", 0, GUIDesignLabelCenter);
72  link->setTipText("http://sumo.dlr.de");
73 
74  // centered ok-button
75  FXHorizontalFrame* buttonFrame = new FXHorizontalFrame(this, GUIDesignHorizontalFrame);
76  new FXHorizontalFrame(buttonFrame, GUIDesignAuxiliarHorizontalFrame);
77  FXButton* OKButton = new FXButton(buttonFrame, "&OK\t\t", GUIIconSubSys::getIcon(ICON_ACCEPT), this, ID_ACCEPT, GUIDesignButtonOK);
78  new FXHorizontalFrame(buttonFrame, GUIDesignAuxiliarHorizontalFrame);
79 
80  // focus OK button
81  OKButton->setFocus();
82 }
83 
84 
85 void
87  FXDialogBox::create();
88 }
89 
90 
92  delete myHeadlineFont;
93 }
94 
95 
96 /****************************************************************************/
#define GUIDesignLabelAboutInfo
label extended over over frame without thickand with text justify to center and withouht vertical spa...
Definition: GUIDesigns.h:167
#define GUIDesignHorizontalFrame
Definition: GUIDesigns.h:206
void create()
Creates the widget.
FXFont * myHeadlineFont
Font for the widget.
GNEDialog_About(FXWindow *parent)
Constructor.
#define HAVE_ENABLED
Definition: config.h:26
#define GUIDesignAuxiliarHorizontalFrame
design for auxiliar (Without borders) horizontal frame used to pack another frames ...
Definition: GUIDesigns.h:246
#define GUIDesignLabelCenter
label extended over frame without thickand with text justify to center and height of 23 ...
Definition: GUIDesigns.h:149
#define VERSION_STRING
Definition: config.h:210
#define GUIDesignLabelIcon64x64noSpacing
design for label with icon of 64x64 px
Definition: GUIDesigns.h:176
#define GUIDesignDialogBox
Definition: GUIDesigns.h:395
#define GUIDesignButtonOK
Definition: GUIDesigns.h:97
~GNEDialog_About()
Destructor.
static FXIcon * getIcon(GUIIcon which)
returns a icon previously defined in the enum GUIIcon