Import Geant4 0.0.0 source tree
@@ -0,0 +1,35 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: GUI.h,v 2.1 1998/07/12 02:39:01 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/*
|
||||
* GUI.h
|
||||
*/
|
||||
|
||||
#ifndef DSP_TEMPLATE_RELEASE
|
||||
#define DSP_TEMPLATE_RELEASE 04500
|
||||
#endif
|
||||
|
||||
#include "factory.h"
|
||||
#ifndef DSP_RELEASE
|
||||
#include FactoryDefines_i
|
||||
#endif
|
||||
//
|
||||
// Uncomment the following #include directive to define
|
||||
// Power++ 4.5 retired class include file symbols
|
||||
// (e.g., CIcon_i).
|
||||
// Note that makefiles must also be updated to reference
|
||||
// the retired class include directory -
|
||||
// %{XVT_DSP_DIR}/src/pwr/retired
|
||||
// and retired class libraries (platform dependent) e.g.-
|
||||
// xvtxmpwrrt -or- xvtwmrtd, and
|
||||
// xvtxmtbl -or- xvtwmtbl
|
||||
//
|
||||
//#include "PwrRtrd.h"
|
||||
//
|
||||
@@ -0,0 +1,120 @@
|
||||
/*
|
||||
GUI.url: Example Universal Resource Language File for XVT-Power++
|
||||
applications. You may add any application specific resources.
|
||||
*/
|
||||
|
||||
#ifndef PAFACTORY_QBASE_NAME
|
||||
#define PAFACTORY_QBASE_NAME "GUI"
|
||||
#define PAFACTORY_BASE_NAME GUI
|
||||
#endif
|
||||
|
||||
#define APPNAME PAFACTORY_BASE_NAME
|
||||
#define QAPPNAME PAFACTORY_QBASE_NAME
|
||||
|
||||
#define XVT_PREFERRED_MEM_SIZE 4 * 1024 * 1024
|
||||
#define XVT_MINIMUM_MEM_SIZE 1 * 1024 * 1024
|
||||
|
||||
#include "url.h"
|
||||
#include "PwrURL.h"
|
||||
|
||||
#if XVTWS == MACWS
|
||||
#include "faccmd.h"
|
||||
#include "factory.url"
|
||||
#else
|
||||
#include "factory/faccmd.h"
|
||||
#include "factory/factory.url"
|
||||
#endif
|
||||
|
||||
/*
|
||||
Definition of NULLicon
|
||||
*/
|
||||
|
||||
#if XVTWS == WINWS || XVTWS == NTWS
|
||||
|
||||
#transparent $$$
|
||||
20001 ICON DISCARDABLE null.ico
|
||||
$$$
|
||||
|
||||
#endif /* WINWS & NTWS */
|
||||
|
||||
#if XVTWS == PMWS
|
||||
|
||||
#transparent $$$
|
||||
BITMAP 20001 null.bmp
|
||||
ICON 20001 null.ico
|
||||
$$$
|
||||
|
||||
#endif /* PMWS */
|
||||
|
||||
#if XVTWS == MACWS
|
||||
|
||||
#transparent $$$
|
||||
resource 'ICON' (20001) {
|
||||
$"0000 0000 001E 0000 001E 0000 001E 0000" /* ................ */
|
||||
$"001E 0000 001E 0000 001E 0000 0008 0000" /* ................ */
|
||||
$"003F 0000 003F 0000 003F 0000 003F 0000" /* .?...?...?...?.. */
|
||||
$"007F 8000 0069 8000 00E1 C000 00C8 C000" /* ....i..áÀ..ÈÀ. */
|
||||
$"01C8 E000 0FFF FC00 0FFF FC00 0308 3000" /* .Èà..ÿü..ÿü...0. */
|
||||
$"0708 3800 0600 1800 0E00 1C00 0C00 0C00" /* ..8............. */
|
||||
$"1C00 0E00 5800 0680 F800 07C0 7000 0380" /* ....X..ø..Àp.. */
|
||||
$"3000 0300 1000 0200 1000 0200 0000 0000" /* 0............... */
|
||||
};
|
||||
$$$
|
||||
|
||||
#endif /* MACWS */
|
||||
|
||||
#if XVTWS == MTFWS
|
||||
|
||||
#transparent $$$
|
||||
|
||||
value black: color('black', foreground);
|
||||
value blue: color('blue', foreground);
|
||||
value green: color('green2', foreground);
|
||||
value pink: color('magenta2', foreground);
|
||||
value fill: color('lightblue', foreground);
|
||||
|
||||
value gammaColorTable: color_table(
|
||||
black='X',
|
||||
blue='B',
|
||||
green='G',
|
||||
pink='P',
|
||||
fill='.',
|
||||
background color=' ');
|
||||
|
||||
value icon_20001: exported
|
||||
icon(color_table=gammaColorTable,
|
||||
' X ',
|
||||
' X.X ',
|
||||
' X...X B ',
|
||||
' X.....X B B ',
|
||||
' X......XX B B ',
|
||||
' X......X..X BBBBB B ',
|
||||
' X..X...X....X B BBB B',
|
||||
' X..XX..X......B B BB B ',
|
||||
' X..XX..X......B B BB ',
|
||||
' X..XX..X......B B B ',
|
||||
' X..XX..X......B B ',
|
||||
' X..XX..X......B B ',
|
||||
' X..XX..X......B B B.X ',
|
||||
' X......X......BB B B...X ',
|
||||
' X......X......B BB B B.....X ',
|
||||
'X......X......B BBB B.......X ',
|
||||
' X....X........B BBBBB.........X',
|
||||
' X..X..........B B.........X ',
|
||||
' XX............B B.........X ',
|
||||
' X..GGGGGGGG...B.........X ',
|
||||
' X.GG GG............X ',
|
||||
' XG G G G...........X ',
|
||||
' G GG G.....PPPPPPPPPP ',
|
||||
' G GG G....P P ',
|
||||
' G G G G...P PP P P P',
|
||||
' GG GG...P P P P P P',
|
||||
' GGGGGGGG...P P P PPP P',
|
||||
' X.....P PP P P P',
|
||||
' X.....P P ',
|
||||
' X...X PPPPPPPPPP ',
|
||||
' X.X ',
|
||||
' X ');
|
||||
$$$
|
||||
|
||||
#endif /* MTFWS */
|
||||
@@ -0,0 +1,68 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: XResMgr.cxx,v 2.1 1998/07/12 02:39:01 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/********************************************************************
|
||||
|
||||
Copyright (c) 1995-96 XVT Software, Inc.
|
||||
|
||||
File Name: ResMgr.cxx
|
||||
|
||||
Usage:
|
||||
|
||||
If you plan to use Motif-specific icons or cursors in your application,
|
||||
you must edit this file and add the appropriate definitions. Using
|
||||
XVT-Architect's Drafting Board module, you can lay out CIcon objects
|
||||
in a project's windows. However, the resources corresponding to CIcon
|
||||
objects cannot be specified via XVT's Universal Resource Language
|
||||
(URL). You must instead define them in this file with a small amount
|
||||
of C code.
|
||||
|
||||
For more information on the purpose and contents of this file, see
|
||||
the "Cursors and Drawn Icons" section in the XVT Platform-Specific
|
||||
Book for Motif.
|
||||
|
||||
********************************************************************/
|
||||
|
||||
#include "XVTPwr.h"
|
||||
#include "xvt_xres.h"
|
||||
#include Global_i // for NULLicon
|
||||
|
||||
#define pwr_width 32
|
||||
#define pwr_height 30
|
||||
static unsigned char pwr_bits[] =
|
||||
{
|
||||
0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x80,
|
||||
0xf9, 0x03, 0x07, 0x87, 0x09, 0x04, 0x05, 0x85, 0x09, 0x08, 0x05, 0x85,
|
||||
0x09, 0xe8, 0xfd, 0xbd, 0x09, 0x28, 0x20, 0xa0, 0x09, 0xe8, 0xfd, 0xbd,
|
||||
0x09, 0x08, 0x05, 0x85, 0x09, 0x08, 0x05, 0x85, 0x09, 0x08, 0x07, 0x87,
|
||||
0x09, 0x04, 0x00, 0x80, 0xf9, 0x03, 0x00, 0x80, 0x09, 0x00, 0x00, 0x80,
|
||||
0x09, 0x4e, 0xf4, 0x9e, 0x09, 0x51, 0x14, 0xa2, 0x09, 0x51, 0x14, 0xa2,
|
||||
0x09, 0x51, 0x14, 0xa2, 0x09, 0x51, 0x14, 0xa2, 0x09, 0x51, 0x74, 0x9e,
|
||||
0x09, 0x51, 0x15, 0x8a, 0x09, 0x51, 0x15, 0x92, 0x09, 0x51, 0x15, 0x92,
|
||||
0x09, 0x91, 0x12, 0xa2, 0x09, 0x8e, 0xf2, 0xa2, 0x01, 0x00, 0x00, 0x80,
|
||||
0x01, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff
|
||||
};
|
||||
|
||||
// Define an icon or cursor resource type variable:
|
||||
static ICON_RESOURCE PwrIcon;
|
||||
|
||||
// Place resouce into XVT's resource information table:
|
||||
RESOURCE_INFO rtable[] =
|
||||
{
|
||||
{ "ICON", NULLicon, (char *)&PwrIcon },
|
||||
{ 0 }
|
||||
};
|
||||
|
||||
// Build the resource:
|
||||
RESOURCE_INFO* xvt_xres_create_table()
|
||||
{
|
||||
xvt_xres_build_icon( &PwrIcon, NULLheight, NULLwidth, (DATA_PTR)pwr_bits );
|
||||
return rtable;
|
||||
}
|
||||
|
After Width: | Height: | Size: 378 B |
|
After Width: | Height: | Size: 350 B |
|
After Width: | Height: | Size: 158 B |
|
After Width: | Height: | Size: 466 B |
|
After Width: | Height: | Size: 354 B |
|
After Width: | Height: | Size: 466 B |
|
After Width: | Height: | Size: 466 B |
|
After Width: | Height: | Size: 578 B |
|
After Width: | Height: | Size: 198 B |
|
After Width: | Height: | Size: 202 B |
|
After Width: | Height: | Size: 202 B |
|
After Width: | Height: | Size: 198 B |
|
After Width: | Height: | Size: 194 B |
|
After Width: | Height: | Size: 202 B |
|
After Width: | Height: | Size: 194 B |
|
After Width: | Height: | Size: 194 B |
|
After Width: | Height: | Size: 194 B |
|
After Width: | Height: | Size: 202 B |
|
After Width: | Height: | Size: 194 B |
|
After Width: | Height: | Size: 194 B |
|
After Width: | Height: | Size: 202 B |
|
After Width: | Height: | Size: 466 B |
|
After Width: | Height: | Size: 466 B |
|
After Width: | Height: | Size: 254 B |
@@ -0,0 +1,60 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: cstartup.cxx,v 2.1 1998/07/12 02:39:02 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/*********************************************************************
|
||||
*
|
||||
Copyright (c) 1996
|
||||
|
||||
File Name: CStartup.cxx
|
||||
|
||||
Implements main()
|
||||
*
|
||||
*********************************************************************/
|
||||
|
||||
#include "XVTPwr.h"
|
||||
#include "AppDef.h"
|
||||
|
||||
#include GUI_i
|
||||
#include G4XvtGUI_i
|
||||
|
||||
#ifdef DSP_RELEASE
|
||||
#include FactoryCommands_i
|
||||
#endif
|
||||
|
||||
#ifndef PAFACTORY_QBASE_NAME
|
||||
#define PAFACTORY_QBASE_NAME "GUI"
|
||||
#endif
|
||||
|
||||
int main( int argc, char** argv )
|
||||
{
|
||||
// Instantiate an application object, then invoke its Go()
|
||||
// method to begin life as a GUI application. On some platforms
|
||||
// Go() will never return control to main(), so do not place
|
||||
// any meaningful code after Go().
|
||||
//
|
||||
// Add any GUI initialization code to the application class
|
||||
// constructor, rather than doing it here.
|
||||
|
||||
G4XvtGUI theApplication;
|
||||
|
||||
theApplication.Go(
|
||||
argc,
|
||||
argv,
|
||||
PAFACTORY_APP_MENU,
|
||||
PAFACTORY_APP_ABOUT_BOX,
|
||||
PAFACTORY_QBASE_NAME,
|
||||
PAFACTORY_APP_NAME,
|
||||
PAFACTORY_APP_TITLE );
|
||||
|
||||
// In case Go() returns and/or to avoid compiler warnings
|
||||
|
||||
return( 0 );
|
||||
}
|
||||
|
||||
@@ -0,0 +1,24 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: AppDef.h,v 2.1 1998/07/12 02:39:08 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
//
|
||||
// AppDef.h
|
||||
//
|
||||
|
||||
#ifndef GUI_AppDef_H
|
||||
#define GUI_AppDef_H
|
||||
|
||||
#include "facdef.h"
|
||||
|
||||
#define GUI_i "GUI.h"
|
||||
#define G4XvtGUI_i "g4xvtgui.h"
|
||||
#define G4XvtDoc_i "g4xvtdoc.h"
|
||||
#define G4XvtWin_i "g4xvtwin.h"
|
||||
#endif /* AppDef_H */
|
||||
@@ -0,0 +1,44 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: _ctskdoc.h,v 2.1 1998/07/12 02:39:08 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/*
|
||||
This is version 4.5 of XVT-Architect.
|
||||
This file was automatically generated by XVT-Architect,
|
||||
Do not modify its contents.
|
||||
*/
|
||||
|
||||
#ifndef _ctskdoc_factory_h
|
||||
#define _ctskdoc_factory_h
|
||||
|
||||
#include "facdec.h"
|
||||
|
||||
|
||||
// Factory IDs:
|
||||
|
||||
#ifndef CTaskDoc1003
|
||||
#define CTaskDoc1003 1003
|
||||
#endif
|
||||
|
||||
// Object Data Members:
|
||||
|
||||
|
||||
class CTaskDoc1003Data : public CDataMembers
|
||||
{
|
||||
PWRClassInfo
|
||||
virtual void Initialize(PAFactory* theFactory);
|
||||
|
||||
public:
|
||||
|
||||
CTaskWin* itsCTaskWin1004;
|
||||
};
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
@@ -0,0 +1,43 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: _ctskwin.h,v 2.1 1998/07/12 02:39:09 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/*
|
||||
This is version 4.5 of XVT-Architect.
|
||||
This file was automatically generated by XVT-Architect,
|
||||
Do not modify its contents.
|
||||
*/
|
||||
|
||||
#ifndef _ctskwin_factory_h
|
||||
#define _ctskwin_factory_h
|
||||
|
||||
#include "facdec.h"
|
||||
|
||||
|
||||
// Factory IDs:
|
||||
|
||||
#ifndef CTaskWin1004
|
||||
#define CTaskWin1004 1004
|
||||
#endif
|
||||
|
||||
// Object Data Members:
|
||||
|
||||
|
||||
class CTaskWin1004Data : public CDataMembers
|
||||
{
|
||||
PWRClassInfo
|
||||
virtual void Initialize(PAFactory* theFactory);
|
||||
|
||||
public:
|
||||
|
||||
};
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
@@ -0,0 +1,44 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: _g4xvtdc.h,v 2.1 1998/07/12 02:39:09 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/*
|
||||
This is version 4.5 of XVT-Architect.
|
||||
This file was automatically generated by XVT-Architect,
|
||||
Do not modify its contents.
|
||||
*/
|
||||
|
||||
#ifndef _g4xvtdc_factory_h
|
||||
#define _g4xvtdc_factory_h
|
||||
|
||||
#include "facdec.h"
|
||||
|
||||
|
||||
// Factory IDs:
|
||||
|
||||
#ifndef G4Doc
|
||||
#define G4Doc 1009
|
||||
#endif
|
||||
|
||||
// Object Data Members:
|
||||
|
||||
|
||||
class G4DocData : public CDataMembers
|
||||
{
|
||||
PWRClassInfo
|
||||
virtual void Initialize(PAFactory* theFactory);
|
||||
|
||||
public:
|
||||
|
||||
G4XvtWin* itsG4Win;
|
||||
};
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
@@ -0,0 +1,50 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: _g4xvtgu.h,v 2.1 1998/07/12 02:39:10 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/*
|
||||
This is version 4.5 of XVT-Architect.
|
||||
This file was automatically generated by XVT-Architect,
|
||||
Do not modify its contents.
|
||||
*/
|
||||
|
||||
#ifndef _g4xvtgu_factory_h
|
||||
#define _g4xvtgu_factory_h
|
||||
|
||||
#include "facdec.h"
|
||||
|
||||
|
||||
// Factory IDs:
|
||||
|
||||
#ifndef G4XvtGUI1002
|
||||
#define G4XvtGUI1002 1002
|
||||
#endif
|
||||
|
||||
// Object Data Members:
|
||||
|
||||
|
||||
class G4XvtGUI1002Data : public CDataMembers
|
||||
{
|
||||
PWRClassInfo
|
||||
virtual void Initialize(PAFactory* theFactory);
|
||||
|
||||
public:
|
||||
|
||||
CTaskDoc* itsCTaskDoc1003;
|
||||
G4XvtDoc* itsG4Doc;
|
||||
};
|
||||
|
||||
#define PAFACTORY_APP_ABOUT_BOX 0
|
||||
#define PAFACTORY_APP_BASE_NAME "PwrApp"
|
||||
#define PAFACTORY_APP_NAME "XVT - Geant 4"
|
||||
#define PAFACTORY_APP_MENU MENU_BAR_RID
|
||||
#define PAFACTORY_APP_TITLE "PwrApp"
|
||||
|
||||
#endif
|
||||
|
||||
@@ -0,0 +1,138 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: _g4xvtwn.h,v 2.1 1998/07/12 02:39:10 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/*
|
||||
This is version 4.5 of XVT-Architect.
|
||||
This file was automatically generated by XVT-Architect,
|
||||
Do not modify its contents.
|
||||
*/
|
||||
|
||||
#ifndef _g4xvtwn_factory_h
|
||||
#define _g4xvtwn_factory_h
|
||||
|
||||
#include "facdec.h"
|
||||
|
||||
|
||||
// Factory IDs:
|
||||
|
||||
#ifndef G4Win
|
||||
#define G4Win 1010
|
||||
#endif
|
||||
#ifndef progStatus
|
||||
#define progStatus 1017
|
||||
#endif
|
||||
#ifndef LogBar
|
||||
#define LogBar 1062
|
||||
#endif
|
||||
#ifndef CMenuButton1063
|
||||
#define CMenuButton1063 1063
|
||||
#endif
|
||||
#ifndef CMenuButton1064
|
||||
#define CMenuButton1064 1064
|
||||
#endif
|
||||
#ifndef CMenuButton1065
|
||||
#define CMenuButton1065 1065
|
||||
#endif
|
||||
#ifndef CMenuButton1076
|
||||
#define CMenuButton1076 1076
|
||||
#endif
|
||||
#ifndef CMenuButton1077
|
||||
#define CMenuButton1077 1077
|
||||
#endif
|
||||
#ifndef CMenuButton1078
|
||||
#define CMenuButton1078 1078
|
||||
#endif
|
||||
#ifndef CMenuButton1079
|
||||
#define CMenuButton1079 1079
|
||||
#endif
|
||||
#ifndef CMenuButton1080
|
||||
#define CMenuButton1080 1080
|
||||
#endif
|
||||
#ifndef getComButton
|
||||
#define getComButton 1083
|
||||
#endif
|
||||
#ifndef commandBox
|
||||
#define commandBox 1087
|
||||
#endif
|
||||
#ifndef execButton
|
||||
#define execButton 1088
|
||||
#endif
|
||||
#ifndef textExecButton
|
||||
#define textExecButton 1096
|
||||
#endif
|
||||
#ifndef helpButton
|
||||
#define helpButton 1097
|
||||
#endif
|
||||
#ifndef mainTextArea
|
||||
#define mainTextArea 1068
|
||||
#endif
|
||||
#ifndef CommandLog
|
||||
#define CommandLog 1073
|
||||
#endif
|
||||
#ifndef DropArea
|
||||
#define DropArea 1093
|
||||
#endif
|
||||
|
||||
// Object Data Members:
|
||||
|
||||
|
||||
class G4WinData : public CDataMembers
|
||||
{
|
||||
PWRClassInfo
|
||||
virtual void Initialize(PAFactory* theFactory);
|
||||
|
||||
public:
|
||||
|
||||
CStatusBar* itsprogStatus;
|
||||
CToolBar* itsLogBar;
|
||||
CMenuButton* itsCMenuButton1063;
|
||||
CMenuButton* itsCMenuButton1064;
|
||||
CMenuButton* itsCMenuButton1065;
|
||||
CMenuButton* itsCMenuButton1076;
|
||||
CMenuButton* itsCMenuButton1077;
|
||||
CMenuButton* itsCMenuButton1078;
|
||||
CMenuButton* itsCMenuButton1079;
|
||||
CMenuButton* itsCMenuButton1080;
|
||||
CMenuButton* itsgetComButton;
|
||||
NLineText* itscommandBox;
|
||||
CMenuButton* itsexecButton;
|
||||
CMenuButton* itstextExecButton;
|
||||
CMenuButton* itshelpButton;
|
||||
NScrollText* itsmainTextArea;
|
||||
NScrollText* itsCommandLog;
|
||||
CScroller* itsDropArea;
|
||||
};
|
||||
|
||||
|
||||
class LogBarData : public CDataMembers
|
||||
{
|
||||
PWRClassInfo
|
||||
virtual void Initialize(PAFactory* theFactory);
|
||||
|
||||
public:
|
||||
|
||||
CMenuButton* itsCMenuButton1063;
|
||||
CMenuButton* itsCMenuButton1064;
|
||||
CMenuButton* itsCMenuButton1065;
|
||||
CMenuButton* itsCMenuButton1076;
|
||||
CMenuButton* itsCMenuButton1077;
|
||||
CMenuButton* itsCMenuButton1078;
|
||||
CMenuButton* itsCMenuButton1079;
|
||||
CMenuButton* itsCMenuButton1080;
|
||||
CMenuButton* itsgetComButton;
|
||||
NLineText* itscommandBox;
|
||||
CMenuButton* itsexecButton;
|
||||
CMenuButton* itstextExecButton;
|
||||
CMenuButton* itshelpButton;
|
||||
};
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
@@ -0,0 +1,110 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: classes.cxx,v 2.1 1998/07/12 02:39:10 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/*
|
||||
This is version 4.5 of XVT-Architect.
|
||||
This file was automatically generated by XVT-Architect,
|
||||
Do not modify its contents.
|
||||
*/
|
||||
|
||||
#include "XVTPwr.h"
|
||||
#include "AppDef.h"
|
||||
#include PAFactory_i
|
||||
|
||||
#define _PA_REF(x) x=x
|
||||
|
||||
#include G4XvtGUI_f
|
||||
|
||||
PWRRegisterClass1( G4XvtGUI1002Data, G4XvtGUI1002, "G4XvtGUI1002Data", CDataMembers)
|
||||
|
||||
void G4XvtGUI1002Data::Initialize(PAFactory* theFactory)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
itsCTaskDoc1003 = (CTaskDoc*) theFactory->GetInstance(1003);
|
||||
itsG4Doc = (G4XvtDoc*) theFactory->GetInstance(1009);
|
||||
}
|
||||
|
||||
#include CTaskDoc_f
|
||||
|
||||
PWRRegisterClass1( CTaskDoc1003Data, CTaskDoc1003, "CTaskDoc1003Data", CDataMembers)
|
||||
|
||||
void CTaskDoc1003Data::Initialize(PAFactory* theFactory)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
itsCTaskWin1004 = (CTaskWin*) theFactory->GetInstance(1004);
|
||||
}
|
||||
|
||||
#include CTaskWin_f
|
||||
|
||||
PWRRegisterClass1( CTaskWin1004Data, CTaskWin1004, "CTaskWin1004Data", CDataMembers)
|
||||
|
||||
void CTaskWin1004Data::Initialize(PAFactory* theFactory)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
}
|
||||
|
||||
#include G4XvtDoc_f
|
||||
|
||||
PWRRegisterClass1( G4DocData, G4Doc, "G4DocData", CDataMembers)
|
||||
|
||||
void G4DocData::Initialize(PAFactory* theFactory)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
itsG4Win = (G4XvtWin*) theFactory->GetInstance(1010);
|
||||
}
|
||||
|
||||
#include G4XvtWin_f
|
||||
|
||||
PWRRegisterClass1( G4WinData, G4Win, "G4WinData", CDataMembers)
|
||||
|
||||
void G4WinData::Initialize(PAFactory* theFactory)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
itsprogStatus = (CStatusBar*) theFactory->GetInstance(1017);
|
||||
itsLogBar = (CToolBar*) theFactory->GetInstance(1062);
|
||||
itsCMenuButton1063 = (CMenuButton*) theFactory->GetInstance(1063);
|
||||
itsCMenuButton1064 = (CMenuButton*) theFactory->GetInstance(1064);
|
||||
itsCMenuButton1065 = (CMenuButton*) theFactory->GetInstance(1065);
|
||||
itsCMenuButton1076 = (CMenuButton*) theFactory->GetInstance(1076);
|
||||
itsCMenuButton1077 = (CMenuButton*) theFactory->GetInstance(1077);
|
||||
itsCMenuButton1078 = (CMenuButton*) theFactory->GetInstance(1078);
|
||||
itsCMenuButton1079 = (CMenuButton*) theFactory->GetInstance(1079);
|
||||
itsCMenuButton1080 = (CMenuButton*) theFactory->GetInstance(1080);
|
||||
itsgetComButton = (CMenuButton*) theFactory->GetInstance(1083);
|
||||
itscommandBox = (NLineText*) theFactory->GetInstance(1087);
|
||||
itsexecButton = (CMenuButton*) theFactory->GetInstance(1088);
|
||||
itstextExecButton = (CMenuButton*) theFactory->GetInstance(1096);
|
||||
itshelpButton = (CMenuButton*) theFactory->GetInstance(1097);
|
||||
itsmainTextArea = (NScrollText*) theFactory->GetInstance(1068);
|
||||
itsCommandLog = (NScrollText*) theFactory->GetInstance(1073);
|
||||
itsDropArea = (CScroller*) theFactory->GetInstance(1093);
|
||||
}
|
||||
|
||||
|
||||
PWRRegisterClass1( LogBarData, LogBar, "LogBarData", CDataMembers)
|
||||
|
||||
void LogBarData::Initialize(PAFactory* theFactory)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
itsCMenuButton1063 = (CMenuButton*) theFactory->GetInstance(1063);
|
||||
itsCMenuButton1064 = (CMenuButton*) theFactory->GetInstance(1064);
|
||||
itsCMenuButton1065 = (CMenuButton*) theFactory->GetInstance(1065);
|
||||
itsCMenuButton1076 = (CMenuButton*) theFactory->GetInstance(1076);
|
||||
itsCMenuButton1077 = (CMenuButton*) theFactory->GetInstance(1077);
|
||||
itsCMenuButton1078 = (CMenuButton*) theFactory->GetInstance(1078);
|
||||
itsCMenuButton1079 = (CMenuButton*) theFactory->GetInstance(1079);
|
||||
itsCMenuButton1080 = (CMenuButton*) theFactory->GetInstance(1080);
|
||||
itsgetComButton = (CMenuButton*) theFactory->GetInstance(1083);
|
||||
itscommandBox = (NLineText*) theFactory->GetInstance(1087);
|
||||
itsexecButton = (CMenuButton*) theFactory->GetInstance(1088);
|
||||
itstextExecButton = (CMenuButton*) theFactory->GetInstance(1096);
|
||||
itshelpButton = (CMenuButton*) theFactory->GetInstance(1097);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,37 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: classes.h,v 2.1 1998/07/12 02:39:11 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/*
|
||||
This is version 4.5 of XVT-Architect.
|
||||
This file was automatically generated by XVT-Architect,
|
||||
Do not modify its contents.
|
||||
*/
|
||||
|
||||
// Include all class definitions:
|
||||
#include "XVTPwr.h"
|
||||
#include CEnvironment_i
|
||||
#include CButton_i
|
||||
#include CText_i
|
||||
#include CPicture_i
|
||||
#include CMenuButton_i
|
||||
#include CScroller_i
|
||||
#include CToolBar_i
|
||||
#include CWindow_i
|
||||
#include NTextEdit_i
|
||||
#include NScrollText_i
|
||||
#include CStatusBar_i
|
||||
#include NLineText_i
|
||||
#include "rw/regexp.h"
|
||||
|
||||
#include G4XvtGUI_i
|
||||
#include CTaskDoc_i
|
||||
#include CTaskWin_i
|
||||
#include G4XvtDoc_i
|
||||
#include G4XvtWin_i
|
||||
@@ -0,0 +1,30 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: defines.h,v 2.1 1998/07/12 02:39:11 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/*
|
||||
This is version 4.5 of XVT-Architect.
|
||||
This file was automatically generated by XVT-Architect,
|
||||
Do not modify its contents.
|
||||
*/
|
||||
|
||||
#ifndef GUI_FactoryDefines_h
|
||||
#define GUI_FactoryDefines_h
|
||||
|
||||
#include "facdef.h"
|
||||
#include "facstr.h"
|
||||
#include "faccmd.h"
|
||||
|
||||
#include G4XvtGUI_f
|
||||
#include CTaskDoc_f
|
||||
#include CTaskWin_f
|
||||
#include G4XvtDoc_f
|
||||
#include G4XvtWin_f
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,35 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: faccb.h,v 2.1 1998/07/12 02:39:12 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/*
|
||||
This is version 4.5 of XVT-Architect.
|
||||
This file was automatically generated by XVT-Architect,
|
||||
Do not modify its contents.
|
||||
*/
|
||||
|
||||
// Static Factory Initializer
|
||||
|
||||
#if (XVT_CC == XVT_CC_SYMCPLUS || defined XVT_PREDEF_PLACEMENT_NEW)
|
||||
#include "new.h"
|
||||
#else
|
||||
inline void* operator new(size_t, void* m) { return m; }
|
||||
#endif
|
||||
|
||||
class CGUIFactoryInit
|
||||
{
|
||||
public:
|
||||
CGUIFactoryInit() {
|
||||
if (!CGUIFactory::itIsInitialized)
|
||||
new (&GUIFactory) CGUIFactory;
|
||||
}
|
||||
};
|
||||
|
||||
static CGUIFactoryInit _FACTORYInit;
|
||||
|
||||
@@ -0,0 +1,171 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: faccb0.cxx,v 2.1 1998/07/12 02:39:12 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/*
|
||||
This is version 4.5 of XVT-Architect.
|
||||
This file was automatically generated by XVT-Architect,
|
||||
Do not modify its contents.
|
||||
*/
|
||||
|
||||
#include "factory.h"
|
||||
#include "XVTPwr.h"
|
||||
#include "AppDef.h"
|
||||
#include PwrGen_i
|
||||
#include "facdec.h"
|
||||
#include "classes.h"
|
||||
#include "defines.h"
|
||||
#include "faccb.h"
|
||||
#define _PA_REF(x) x=x
|
||||
|
||||
void _Init_GUI_faccb0() { }
|
||||
|
||||
void* C_G4Win_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
CDocument* anEnclosure = PtrCast( CDocument, theData );
|
||||
G4XvtWin* anInstance = new G4XvtWin(anEnclosure, CRect((UNITS)50, (UNITS)50, (UNITS)1017, (UNITS)782), NULLString, WSF_SIZE|WSF_CLOSE|WSF_ICONIZABLE|0, W_DOC, G4WinMB+DEFAULT_BASE
|
||||
#if (DSP_TEMPLATE_RELEASE > 03220)
|
||||
, TASK_WIN);
|
||||
#else
|
||||
);
|
||||
#endif
|
||||
return anInstance;
|
||||
}
|
||||
|
||||
void I_G4Win_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData, CDataMembers* theDataMembers)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
_PA_REF(theDataMembers);
|
||||
G4XvtWin* anInstance = PtrCast(G4XvtWin, theData);
|
||||
if (!anInstance) return;
|
||||
|
||||
{
|
||||
CFont aFont;
|
||||
aFont.Deserialize("01\\system\\0\\12\\");
|
||||
CEnvironment anEnv(0xc0c0c0, 0x7000000, 0xc0c0c0, PAT_SOLID , 0x7000000, PAT_SOLID,1, aFont, M_COPY, P_SOLID, FALSE);
|
||||
|
||||
anInstance->SetEnvironment(anEnv);
|
||||
}
|
||||
|
||||
|
||||
IPAFactoryView(anInstance, STRING1, NULLcmd, NULLcmd, TRUE, TRUE, FALSE, TOPSTICKY|LEFTSTICKY, FALSE, FALSE);
|
||||
|
||||
{
|
||||
CView* aView = (CView*) theFactory->GetInstance(1062);
|
||||
if (aView) anInstance->SetKeyFocus(aView);
|
||||
}
|
||||
|
||||
anInstance->SetBackgroundDrawing(FALSE);
|
||||
|
||||
}
|
||||
|
||||
CFactoryElement _G4WinDEFAULT(&GUIFactory, G4Win, 20024, 2, C_G4Win_GUI_DEFAULT, I_G4Win_GUI_DEFAULT, G4Doc, 0, 1, 1, 0);
|
||||
|
||||
void* C_CMenuButton1065_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
CSubview* anEnclosure = PtrCast( CSubview, theData );
|
||||
CMenuButton *anInstance = new CMenuButton( anEnclosure, CRect((UNITS)54, (UNITS)3, (UNITS)77, (UNITS)26), M_FILE_PRINT );
|
||||
return anInstance;
|
||||
}
|
||||
|
||||
void I_CMenuButton1065_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData, CDataMembers* theDataMembers)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
_PA_REF(theDataMembers);
|
||||
CMenuButton* anInstance = PtrCast(CMenuButton, theData);
|
||||
if (!anInstance) return;
|
||||
|
||||
|
||||
IPAFactoryView(anInstance, "", NULLcmd, NULLcmd, TRUE, TRUE, FALSE, TOPSTICKY|LEFTSTICKY, FALSE, FALSE);
|
||||
|
||||
|
||||
anInstance->SetTogglable( FALSE );
|
||||
CImage anImage(1002);
|
||||
CPicture* aPicture = new CPicture( anInstance, CPoint((UNITS)0, (UNITS)0), anImage );
|
||||
_PA_REF(aPicture);
|
||||
anInstance->SetCommands( NULLcmd, NULLcmd, PRINT_INcmd, PRINT_OUTcmd );
|
||||
anInstance->SizeToFit();
|
||||
|
||||
|
||||
}
|
||||
|
||||
CFactoryElement _CMenuButton1065DEFAULT(&GUIFactory, CMenuButton1065, 20126, 3, C_CMenuButton1065_GUI_DEFAULT, I_CMenuButton1065_GUI_DEFAULT, LogBar, 0, 1, 13, 2);
|
||||
|
||||
void* C_CMenuButton1080_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
CSubview* anEnclosure = PtrCast( CSubview, theData );
|
||||
CMenuButton *anInstance = new CMenuButton( anEnclosure, CRect((UNITS)174, (UNITS)3, (UNITS)197, (UNITS)26), QUITcmd );
|
||||
return anInstance;
|
||||
}
|
||||
|
||||
void I_CMenuButton1080_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData, CDataMembers* theDataMembers)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
_PA_REF(theDataMembers);
|
||||
CMenuButton* anInstance = PtrCast(CMenuButton, theData);
|
||||
if (!anInstance) return;
|
||||
|
||||
|
||||
IPAFactoryView(anInstance, "", NULLcmd, NULLcmd, TRUE, TRUE, FALSE, TOPSTICKY|LEFTSTICKY, FALSE, FALSE);
|
||||
|
||||
|
||||
anInstance->SetTogglable( FALSE );
|
||||
CImage anImage(1007);
|
||||
CPicture* aPicture = new CPicture( anInstance, CPoint((UNITS)0, (UNITS)0), anImage );
|
||||
_PA_REF(aPicture);
|
||||
anInstance->SetCommands( NULLcmd, NULLcmd, QUIT_INcmd, QUIT_OUTcmd );
|
||||
anInstance->SizeToFit();
|
||||
|
||||
|
||||
}
|
||||
|
||||
CFactoryElement _CMenuButton1080DEFAULT(&GUIFactory, CMenuButton1080, 20126, 3, C_CMenuButton1080_GUI_DEFAULT, I_CMenuButton1080_GUI_DEFAULT, LogBar, 0, 1, 13, 7);
|
||||
|
||||
void* C_helpButton_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
CSubview* anEnclosure = PtrCast( CSubview, theData );
|
||||
CMenuButton *anInstance = new CMenuButton( anEnclosure, CRect((UNITS)711, (UNITS)3, (UNITS)734, (UNITS)26), HELPcmd );
|
||||
return anInstance;
|
||||
}
|
||||
|
||||
void I_helpButton_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData, CDataMembers* theDataMembers)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
_PA_REF(theDataMembers);
|
||||
CMenuButton* anInstance = PtrCast(CMenuButton, theData);
|
||||
if (!anInstance) return;
|
||||
|
||||
|
||||
IPAFactoryView(anInstance, "", NULLcmd, NULLcmd, TRUE, FALSE, FALSE, TOPSTICKY|LEFTSTICKY, FALSE, FALSE);
|
||||
|
||||
|
||||
anInstance->SetTogglable( FALSE );
|
||||
CImage anImage(1011);
|
||||
CPicture* aPicture = new CPicture( anInstance, CPoint((UNITS)0, (UNITS)0), anImage );
|
||||
_PA_REF(aPicture);
|
||||
anInstance->SetCommands( NULLcmd, NULLcmd, HELP_INcmd, HELP_OUTcmd );
|
||||
anInstance->SizeToFit();
|
||||
|
||||
|
||||
}
|
||||
|
||||
CFactoryElement _helpButtonDEFAULT(&GUIFactory, helpButton, 20126, 3, C_helpButton_GUI_DEFAULT, I_helpButton_GUI_DEFAULT, LogBar, 0, 1, 13, 12);
|
||||
|
||||
@@ -0,0 +1,186 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: faccb1.cxx,v 2.1 1998/07/12 02:39:12 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/*
|
||||
This is version 4.5 of XVT-Architect.
|
||||
This file was automatically generated by XVT-Architect,
|
||||
Do not modify its contents.
|
||||
*/
|
||||
|
||||
#include "factory.h"
|
||||
#include "XVTPwr.h"
|
||||
#include "AppDef.h"
|
||||
#include PwrGen_i
|
||||
#include "facdec.h"
|
||||
#include "classes.h"
|
||||
#include "defines.h"
|
||||
#include "faccb.h"
|
||||
#define _PA_REF(x) x=x
|
||||
|
||||
void _Init_GUI_faccb1() { }
|
||||
|
||||
void* C_G4XvtGUI1002_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
CApplication* anInstance = NULL;
|
||||
return anInstance;
|
||||
}
|
||||
|
||||
void I_G4XvtGUI1002_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData, CDataMembers* theDataMembers)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
_PA_REF(theDataMembers);
|
||||
G4XvtGUI* anInstance = PtrCast(G4XvtGUI, theData);
|
||||
if (!anInstance) return;
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
CFactoryElement _G4XvtGUI1002DEFAULT(&GUIFactory, G4XvtGUI1002, 20000, 4, C_G4XvtGUI1002_GUI_DEFAULT, I_G4XvtGUI1002_GUI_DEFAULT, 0, 0, 1, 1, 0);
|
||||
|
||||
void* C_progStatus_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
CSubview* anEnclosure = PtrCast( CSubview, theData );
|
||||
CStatusBar *anInstance = new CStatusBar( anEnclosure );
|
||||
return anInstance;
|
||||
}
|
||||
|
||||
void I_progStatus_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData, CDataMembers* theDataMembers)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
_PA_REF(theDataMembers);
|
||||
CStatusBar* anInstance = PtrCast(CStatusBar, theData);
|
||||
if (!anInstance) return;
|
||||
|
||||
|
||||
IPAFactoryView(anInstance, "", NULLcmd, NULLcmd, TRUE, TRUE, FALSE, RIGHTSTICKY, FALSE, FALSE);
|
||||
|
||||
|
||||
anInstance->IStatusBar(2, 2, 5, 3, 0);
|
||||
|
||||
}
|
||||
|
||||
CFactoryElement _progStatusDEFAULT(&GUIFactory, progStatus, 20124, 3, C_progStatus_GUI_DEFAULT, I_progStatus_GUI_DEFAULT, G4Win, 0, 1, 5, 0);
|
||||
|
||||
void* C_CMenuButton1076_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
CSubview* anEnclosure = PtrCast( CSubview, theData );
|
||||
CMenuButton *anInstance = new CMenuButton( anEnclosure, CRect((UNITS)82, (UNITS)3, (UNITS)105, (UNITS)26), STARTcmd );
|
||||
return anInstance;
|
||||
}
|
||||
|
||||
void I_CMenuButton1076_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData, CDataMembers* theDataMembers)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
_PA_REF(theDataMembers);
|
||||
CMenuButton* anInstance = PtrCast(CMenuButton, theData);
|
||||
if (!anInstance) return;
|
||||
|
||||
|
||||
IPAFactoryView(anInstance, "", NULLcmd, NULLcmd, TRUE, TRUE, FALSE, TOPSTICKY|LEFTSTICKY, FALSE, FALSE);
|
||||
|
||||
|
||||
anInstance->SetTogglable( FALSE );
|
||||
CImage anImage(1003);
|
||||
CPicture* aPicture = new CPicture( anInstance, CPoint((UNITS)0, (UNITS)0), anImage );
|
||||
_PA_REF(aPicture);
|
||||
anInstance->SetCommands( NULLcmd, NULLcmd, START_INcmd, START_OUTcmd );
|
||||
anInstance->SizeToFit();
|
||||
|
||||
|
||||
}
|
||||
|
||||
CFactoryElement _CMenuButton1076DEFAULT(&GUIFactory, CMenuButton1076, 20126, 3, C_CMenuButton1076_GUI_DEFAULT, I_CMenuButton1076_GUI_DEFAULT, LogBar, 0, 1, 13, 3);
|
||||
|
||||
void* C_getComButton_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
CSubview* anEnclosure = PtrCast( CSubview, theData );
|
||||
CMenuButton *anInstance = new CMenuButton( anEnclosure, CRect((UNITS)202, (UNITS)3, (UNITS)225, (UNITS)26), M_Retrieve_Commands );
|
||||
return anInstance;
|
||||
}
|
||||
|
||||
void I_getComButton_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData, CDataMembers* theDataMembers)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
_PA_REF(theDataMembers);
|
||||
CMenuButton* anInstance = PtrCast(CMenuButton, theData);
|
||||
if (!anInstance) return;
|
||||
|
||||
|
||||
IPAFactoryView(anInstance, "", NULLcmd, NULLcmd, TRUE, TRUE, FALSE, TOPSTICKY|LEFTSTICKY, FALSE, FALSE);
|
||||
|
||||
|
||||
anInstance->SetTogglable( FALSE );
|
||||
CImage anImage(1008);
|
||||
CPicture* aPicture = new CPicture( anInstance, CPoint((UNITS)0, (UNITS)0), anImage );
|
||||
_PA_REF(aPicture);
|
||||
anInstance->SetCommands( NULLcmd, NULLcmd, GET_COMMANDS_INcmd, GET_COMMANDS_OUTcmd );
|
||||
anInstance->SizeToFit();
|
||||
|
||||
|
||||
}
|
||||
|
||||
CFactoryElement _getComButtonDEFAULT(&GUIFactory, getComButton, 20126, 3, C_getComButton_GUI_DEFAULT, I_getComButton_GUI_DEFAULT, LogBar, 0, 1, 13, 8);
|
||||
|
||||
void* C_mainTextArea_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
CSubview* anEnclosure = PtrCast( CSubview, theData );
|
||||
NScrollText* anInstance = new NScrollText(anEnclosure, CRect((UNITS)0, (UNITS)30, (UNITS)484, (UNITS)255), TRUE, TRUE);
|
||||
|
||||
return anInstance;
|
||||
}
|
||||
|
||||
void I_mainTextArea_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData, CDataMembers* theDataMembers)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
_PA_REF(theDataMembers);
|
||||
NScrollText* anInstance = PtrCast(NScrollText, theData);
|
||||
if (!anInstance) return;
|
||||
|
||||
{
|
||||
CFont aFont;
|
||||
aFont.Deserialize("01\\system\\0\\12\\");
|
||||
CEnvironment anEnv(0xbffffff, 0x7000000, 0xbffffff, PAT_SOLID , 0x7000000, PAT_SOLID,1, aFont, M_COPY, P_SOLID, FALSE);
|
||||
|
||||
anInstance->SetEnvironment(anEnv);
|
||||
}
|
||||
|
||||
|
||||
IPAFactoryView(anInstance, "", NULLcmd, NULLcmd, TRUE, TRUE, FALSE, TOPSTICKY|RIGHTSTICKY|LEFTSTICKY|BOTTOMSTICKY, FALSE, FALSE);
|
||||
|
||||
unsigned anAttribute = TX_BORDER|TX_WRAP|0;
|
||||
if ((anInstance->GetCWindow()->GetAttributes() & WSF_NO_MENUBAR) != 0)
|
||||
anAttribute |= TX_NOMENU;
|
||||
anInstance->INativeTextEdit(anAttribute, (UNITS)1000 ,1000, STRING2, FALSE,anInstance->IsVisible(), anInstance->GetGlue());
|
||||
anInstance->SetTabSize(4);
|
||||
|
||||
|
||||
anInstance->SetVIncrements((UNITS)1 , (UNITS)10);
|
||||
anInstance->SetHIncrements((UNITS)10 , (UNITS)50);
|
||||
|
||||
}
|
||||
|
||||
CFactoryElement _mainTextAreaDEFAULT(&GUIFactory, mainTextArea, 20041, 3, C_mainTextArea_GUI_DEFAULT, I_mainTextArea_GUI_DEFAULT, G4Win, 0, 1, 5, 2);
|
||||
|
||||
@@ -0,0 +1,201 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: faccb2.cxx,v 2.1 1998/07/12 02:39:13 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/*
|
||||
This is version 4.5 of XVT-Architect.
|
||||
This file was automatically generated by XVT-Architect,
|
||||
Do not modify its contents.
|
||||
*/
|
||||
|
||||
#include "factory.h"
|
||||
#include "XVTPwr.h"
|
||||
#include "AppDef.h"
|
||||
#include PwrGen_i
|
||||
#include "facdec.h"
|
||||
#include "classes.h"
|
||||
#include "defines.h"
|
||||
#include "faccb.h"
|
||||
#define _PA_REF(x) x=x
|
||||
|
||||
void _Init_GUI_faccb2() { }
|
||||
|
||||
void* C_CTaskDoc1003_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
CTaskDoc* anInstance = NULL;
|
||||
return anInstance;
|
||||
}
|
||||
|
||||
void I_CTaskDoc1003_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData, CDataMembers* theDataMembers)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
_PA_REF(theDataMembers);
|
||||
CTaskDoc* anInstance = PtrCast(CTaskDoc, theData);
|
||||
if (!anInstance) return;
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
CFactoryElement _CTaskDoc1003DEFAULT(&GUIFactory, CTaskDoc1003, 20043, 1, C_CTaskDoc1003_GUI_DEFAULT, I_CTaskDoc1003_GUI_DEFAULT, G4XvtGUI1002, 0, 1, 2, 0);
|
||||
|
||||
void* C_LogBar_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
CSubview* anEnclosure = PtrCast( CSubview, theData );
|
||||
CToolBar *anInstance = new CToolBar( anEnclosure, CToolBar::AL_TOP );
|
||||
return anInstance;
|
||||
}
|
||||
|
||||
void I_LogBar_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData, CDataMembers* theDataMembers)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
_PA_REF(theDataMembers);
|
||||
CToolBar* anInstance = PtrCast(CToolBar, theData);
|
||||
if (!anInstance) return;
|
||||
|
||||
|
||||
IPAFactoryView(anInstance, "", NULLcCMenuButton1095md, NULLcmd, TRUE, TRUE, TRUE, LEFTSTICKY, FALSE, FALSE);
|
||||
|
||||
|
||||
anInstance->IToolBar(2, 5);
|
||||
anInstance->InsertSeparator( 0 );
|
||||
anInstance->InsertSeparator( 2 );
|
||||
anInstance->InsertSeparator( 3 );
|
||||
anInstance->InsertSeparator( 8 );
|
||||
anInstance->InsertSeparator( 9 );
|
||||
anInstance->InsertSeparator( 10 );
|
||||
anInstance->InsertSeparator( 12 );
|
||||
anInstance->DoSize( anInstance->GetFrame() );
|
||||
|
||||
}
|
||||
|
||||
CFactoryElement _LogBarDEFAULT(&GUIFactory, LogBar, 20123, 3, C_LogBar_GUI_DEFAULT, I_LogBar_GUI_DEFAULT, G4Win, 0, 1, 5, 1);
|
||||
|
||||
void* C_CMenuButton1077_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
CSubview* anEnclosure = PtrCast( CSubview, theData );
|
||||
CMenuButton *anInstance = new CMenuButton( anEnclosure, CRect((UNITS)105, (UNITS)3, (UNITS)128, (UNITS)26), STOPcmd );
|
||||
return anInstance;
|
||||
}
|
||||
|
||||
void I_CMenuButton1077_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData, CDataMembers* theDataMembers)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
_PA_REF(theDataMembers);
|
||||
CMenuButton* anInstance = PtrCast(CMenuButton, theData);
|
||||
if (!anInstance) return;
|
||||
|
||||
|
||||
IPAFactoryView(anInstance, "", NULLcmd, NULLcmd, TRUE, TRUE, FALSE, TOPSTICKY|LEFTSTICKY, FALSE, FALSE);
|
||||
|
||||
|
||||
anInstance->SetTogglable( FALSE );
|
||||
CImage anImage(1004);
|
||||
CPicture* aPicture = new CPicture( anInstance, CPoint((UNITS)0, (UNITS)0), anImage );
|
||||
_PA_REF(aPicture);
|
||||
anInstance->SetCommands( NULLcmd, NULLcmd, STOP_INcmd, STOP_OUTcmd );
|
||||
anInstance->SizeToFit();
|
||||
|
||||
|
||||
}
|
||||
|
||||
CFactoryElement _CMenuButton1077DEFAULT(&GUIFactory, CMenuButton1077, 20126, 3, C_CMenuButton1077_GUI_DEFAULT, I_CMenuButton1077_GUI_DEFAULT, LogBar, 0, 1, 13, 4);
|
||||
|
||||
void* C_commandBox_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
CSubview* anEnclosure = PtrCast( CSubview, theData );
|
||||
NLineText* anInstance = new NLineText(anEnclosure, CPoint((UNITS)230, (UNITS)3), (UNITS)425);
|
||||
return anInstance;
|
||||
}
|
||||
|
||||
void I_commandBox_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData, CDataMembers* theDataMembers)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
_PA_REF(theDataMembers);
|
||||
NLineText* anInstance = PtrCast(NLineText, theData);
|
||||
if (!anInstance) return;
|
||||
|
||||
{
|
||||
CFont aFont;
|
||||
aFont.Deserialize("01\\system\\0\\12\\");
|
||||
CEnvironment anEnv(0xaaaa, 0xffffff, 0xbffffff, PAT_SOLID , 0x7000000, PAT_SOLID,1, aFont, M_COPY, P_SOLID, FALSE);
|
||||
|
||||
anInstance->SetEnvironment(anEnv);
|
||||
}
|
||||
|
||||
|
||||
IPAFactoryView(anInstance, "", NULLcmd, NULLcmd, TRUE, TRUE, FALSE, TOPSTICKY|LEFTSTICKY, FALSE, FALSE);
|
||||
|
||||
unsigned anAttribute = TX_AUTOHSCROLL|TX_AUTOVSCROLL|TX_BORDER|TX_WRAP|0;
|
||||
if ((anInstance->GetCWindow()->GetAttributes() & WSF_NO_MENUBAR) != 0)
|
||||
anAttribute |= TX_NOMENU;
|
||||
anInstance->INativeTextEdit(anAttribute, (UNITS)1000 ,1000, STRING5, FALSE,anInstance->IsVisible(), anInstance->GetGlue());
|
||||
anInstance->SetTabSize(4);
|
||||
|
||||
|
||||
}
|
||||
|
||||
CFactoryElement _commandBoxDEFAULT(&GUIFactory, commandBox, 20040, 3, C_commandBox_GUI_DEFAULT, I_commandBox_GUI_DEFAULT, LogBar, 0, 1, 13, 9);
|
||||
|
||||
void* C_CommandLog_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
CSubview* anEnclosure = PtrCast( CSubview, theData );
|
||||
NScrollText* anInstance = new NScrollText(anEnclosure, CRect((UNITS)485, (UNITS)30, (UNITS)966, (UNITS)255), TRUE, TRUE);
|
||||
|
||||
return anInstance;
|
||||
}
|
||||
|
||||
void I_CommandLog_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData, CDataMembers* theDataMembers)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
_PA_REF(theDataMembers);
|
||||
NScrollText* anInstance = PtrCast(NScrollText, theData);
|
||||
if (!anInstance) return;
|
||||
|
||||
{
|
||||
CFont aFont;
|
||||
aFont.Deserialize("01\\system\\0\\12\\");
|
||||
CEnvironment anEnv(0xffffff, 0x7000000, 0xffffff, PAT_SOLID , 0x7000000, PAT_SOLID,1, aFont, M_COPY, P_SOLID, FALSE);
|
||||
|
||||
anInstance->SetEnvironment(anEnv);
|
||||
}
|
||||
|
||||
|
||||
IPAFactoryView(anInstance, "", NULLcmd, NULLcmd, TRUE, TRUE, FALSE, TOPSTICKY|RIGHTSTICKY|LEFTSTICKY|BOTTOMSTICKY, FALSE, FALSE);
|
||||
|
||||
unsigned anAttribute = TX_BORDER|TX_WRAP|0;
|
||||
if ((anInstance->GetCWindow()->GetAttributes() & WSF_NO_MENUBAR) != 0)
|
||||
anAttribute |= TX_NOMENU;
|
||||
anInstance->INativeTextEdit(anAttribute, (UNITS)1000 ,1000, STRING4, FALSE,anInstance->IsVisible(), anInstance->GetGlue());
|
||||
anInstance->SetTabSize(4);
|
||||
|
||||
|
||||
anInstance->SetVIncrements((UNITS)1 , (UNITS)10);
|
||||
anInstance->SetHIncrements((UNITS)10 , (UNITS)50);
|
||||
|
||||
}
|
||||
|
||||
CFactoryElement _CommandLogDEFAULT(&GUIFactory, CommandLog, 20041, 3, C_CommandLog_GUI_DEFAULT, I_CommandLog_GUI_DEFAULT, G4Win, 0, 1, 5, 3);
|
||||
|
||||
@@ -0,0 +1,185 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: faccb3.cxx,v 2.1 1998/07/12 02:39:13 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/*
|
||||
This is version 4.5 of XVT-Architect.
|
||||
This file was automatically generated by XVT-Architect,
|
||||
Do not modify its contents.
|
||||
*/
|
||||
|
||||
#include "factory.h"
|
||||
#include "XVTPwr.h"
|
||||
#include "AppDef.h"
|
||||
#include PwrGen_i
|
||||
#include "facdec.h"
|
||||
#include "classes.h"
|
||||
#include "defines.h"
|
||||
#include "faccb.h"
|
||||
#define _PA_REF(x) x=x
|
||||
|
||||
void _Init_GUI_faccb3() { }
|
||||
|
||||
void* C_CTaskWin1004_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
CTaskWin* anInstance = NULL;
|
||||
return anInstance;
|
||||
}
|
||||
|
||||
void I_CTaskWin1004_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData, CDataMembers* theDataMembers)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
_PA_REF(theDataMembers);
|
||||
CTaskWin* anInstance = PtrCast(CTaskWin, theData);
|
||||
if (!anInstance) return;
|
||||
|
||||
|
||||
IPAFactoryView(anInstance, "", NULLcmd, NULLcmd, TRUE, TRUE, FALSE, TOPSTICKY|LEFTSTICKY, FALSE, FALSE);
|
||||
|
||||
|
||||
anInstance->SetBackgroundDrawing(FALSE);
|
||||
|
||||
|
||||
}
|
||||
|
||||
CFactoryElement _CTaskWin1004DEFAULT(&GUIFactory, CTaskWin1004, 20044, 2, C_CTaskWin1004_GUI_DEFAULT, I_CTaskWin1004_GUI_DEFAULT, CTaskDoc1003, 0, 1, 1, 0);
|
||||
|
||||
void* C_CMenuButton1063_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
CSubview* anEnclosure = PtrCast( CSubview, theData );
|
||||
CMenuButton *anInstance = new CMenuButton( anEnclosure, CRect((UNITS)3, (UNITS)3, (UNITS)26, (UNITS)26), M_FILE_SAVE );
|
||||
return anInstance;
|
||||
}
|
||||
|
||||
void I_CMenuButton1063_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData, CDataMembers* theDataMembers)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
_PA_REF(theDataMembers);
|
||||
CMenuButton* anInstance = PtrCast(CMenuButton, theData);
|
||||
if (!anInstance) return;
|
||||
|
||||
|
||||
IPAFactoryView(anInstance, "", NULLcmd, NULLcmd, TRUE, TRUE, FALSE, TOPSTICKY|LEFTSTICKY, FALSE, FALSE);
|
||||
|
||||
|
||||
anInstance->SetTogglable( FALSE );
|
||||
CImage anImage(1000);
|
||||
CPicture* aPicture = new CPicture( anInstance, CPoint((UNITS)0, (UNITS)0), anImage );
|
||||
_PA_REF(aPicture);
|
||||
anInstance->SetCommands( NULLcmd, NULLcmd, SAVE_LOG_INcmd, SAVE_LOG_OUTcmd );
|
||||
anInstance->SizeToFit();
|
||||
|
||||
|
||||
}
|
||||
|
||||
CFactoryElement _CMenuButton1063DEFAULT(&GUIFactory, CMenuButton1063, 20126, 3, C_CMenuButton1063_GUI_DEFAULT, I_CMenuButton1063_GUI_DEFAULT, LogBar, 0, 1, 13, 0);
|
||||
|
||||
void* C_CMenuButton1078_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
CSubview* anEnclosure = PtrCast( CSubview, theData );
|
||||
CMenuButton *anInstance = new CMenuButton( anEnclosure, CRect((UNITS)128, (UNITS)3, (UNITS)151, (UNITS)26), PAUSEcmd );
|
||||
return anInstance;
|
||||
}
|
||||
|
||||
void I_CMenuButton1078_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData, CDataMembers* theDataMembers)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
_PA_REF(theDataMembers);
|
||||
CMenuButton* anInstance = PtrCast(CMenuButton, theData);
|
||||
if (!anInstance) return;
|
||||
|
||||
|
||||
IPAFactoryView(anInstance, "", NULLcmd, NULLcmd, TRUE, TRUE, FALSE, TOPSTICKY|LEFTSTICKY, FALSE, FALSE);
|
||||
|
||||
|
||||
anInstance->SetTogglable( FALSE );
|
||||
CImage anImage(1005);
|
||||
CPicture* aPicture = new CPicture( anInstance, CPoint((UNITS)0, (UNITS)0), anImage );
|
||||
_PA_REF(aPicture);
|
||||
anInstance->SetCommands( NULLcmd, NULLcmd, PAUSE_INcmd, PAUSE_OUTcmd );
|
||||
anInstance->SizeToFit();
|
||||
|
||||
|
||||
}
|
||||
|
||||
CFactoryElement _CMenuButton1078DEFAULT(&GUIFactory, CMenuButton1078, 20126, 3, C_CMenuButton1078_GUI_DEFAULT, I_CMenuButton1078_GUI_DEFAULT, LogBar, 0, 1, 13, 5);
|
||||
|
||||
void* C_execButton_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
CSubview* anEnclosure = PtrCast( CSubview, theData );
|
||||
CMenuButton *anInstance = new CMenuButton( anEnclosure, CRect((UNITS)660, (UNITS)3, (UNITS)683, (UNITS)26), EXECUTEcmd );
|
||||
return anInstance;
|
||||
}
|
||||
|
||||
void I_execButton_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData, CDataMembers* theDataMembers)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
_PA_REF(theDataMembers);
|
||||
CMenuButton* anInstance = PtrCast(CMenuButton, theData);
|
||||
if (!anInstance) return;
|
||||
|
||||
|
||||
IPAFactoryView(anInstance, "", NULLcmd, NULLcmd, TRUE, FALSE, FALSE, TOPSTICKY|LEFTSTICKY, FALSE, FALSE);
|
||||
|
||||
|
||||
anInstance->SetTogglable( FALSE );
|
||||
CImage anImage(1009);
|
||||
CPicture* aPicture = new CPicture( anInstance, CPoint((UNITS)0, (UNITS)0), anImage );
|
||||
_PA_REF(aPicture);
|
||||
anInstance->SetCommands( NULLcmd, NULLcmd, EXECUTE_INcmd, EXECUTE_OUTcmd );
|
||||
anInstance->SizeToFit();
|
||||
|
||||
|
||||
}
|
||||
|
||||
CFactoryElement _execButtonDEFAULT(&GUIFactory, execButton, 20126, 3, C_execButton_GUI_DEFAULT, I_execButton_GUI_DEFAULT, LogBar, 0, 1, 13, 10);
|
||||
|
||||
void* C_DropArea_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
CSubview* anEnclosure = PtrCast( CSubview, theData );
|
||||
CScroller* anInstance = new CScroller(anEnclosure, CRect((UNITS)0, (UNITS)255, (UNITS)966, (UNITS)710));
|
||||
|
||||
return anInstance;
|
||||
}
|
||||
|
||||
void I_DropArea_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData, CDataMembers* theDataMembers)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
_PA_REF(theDataMembers);
|
||||
CScroller* anInstance = PtrCast(CScroller, theData);
|
||||
if (!anInstance) return;
|
||||
|
||||
|
||||
IPAFactoryView(anInstance, "", NULLcmd, NULLcmd, TRUE, TRUE, FALSE, TOPSTICKY|RIGHTSTICKY|LEFTSTICKY|BOTTOMSTICKY, FALSE, FALSE);
|
||||
|
||||
|
||||
anInstance->SetScrollingOrigin( CPoint((UNITS)0, (UNITS)0));
|
||||
anInstance->SetVirtualFrame((UNITS)0, (UNITS)0);
|
||||
|
||||
anInstance->IScroller(FALSE,FALSE,TRUE, (UNITS)8, (UNITS)80,anInstance->IsVisible(), anInstance->GetGlue());
|
||||
|
||||
}
|
||||
|
||||
CFactoryElement _DropAreaDEFAULT(&GUIFactory, DropArea, 20017, 3, C_DropArea_GUI_DEFAULT, I_DropArea_GUI_DEFAULT, G4Win, 0, 1, 5, 4);
|
||||
|
||||
@@ -0,0 +1,151 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: faccb4.cxx,v 2.1 1998/07/12 02:39:13 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/*
|
||||
This is version 4.5 of XVT-Architect.
|
||||
This file was automatically generated by XVT-Architect,
|
||||
Do not modify its contents.
|
||||
*/
|
||||
|
||||
#include "factory.h"
|
||||
#include "XVTPwr.h"
|
||||
#include "AppDef.h"
|
||||
#include PwrGen_i
|
||||
#include "facdec.h"
|
||||
#include "classes.h"
|
||||
#include "defines.h"
|
||||
#include "faccb.h"
|
||||
#define _PA_REF(x) x=x
|
||||
|
||||
void _Init_GUI_faccb4() { }
|
||||
|
||||
void* C_G4Doc_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
CApplication* anEnclosure = PtrCast( CApplication, theData );
|
||||
G4XvtDoc* anInstance = new G4XvtDoc(anEnclosure, 1009);
|
||||
|
||||
return anInstance;
|
||||
}
|
||||
|
||||
void I_G4Doc_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData, CDataMembers* theDataMembers)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
_PA_REF(theDataMembers);
|
||||
G4XvtDoc* anInstance = PtrCast(G4XvtDoc, theData);
|
||||
if (!anInstance) return;
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
CFactoryElement _G4DocDEFAULT(&GUIFactory, G4Doc, 20004, 1, C_G4Doc_GUI_DEFAULT, I_G4Doc_GUI_DEFAULT, G4XvtGUI1002, 0, 1, 2, 1);
|
||||
|
||||
void* C_CMenuButton1064_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
CSubview* anEnclosure = PtrCast( CSubview, theData );
|
||||
CMenuButton *anInstance = new CMenuButton( anEnclosure, CRect((UNITS)26, (UNITS)3, (UNITS)49, (UNITS)26), M_FILE_SAVE_AS );
|
||||
return anInstance;
|
||||
}
|
||||
|
||||
void I_CMenuButton1064_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData, CDataMembers* theDataMembers)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
_PA_REF(theDataMembers);
|
||||
CMenuButton* anInstance = PtrCast(CMenuButton, theData);
|
||||
if (!anInstance) return;
|
||||
|
||||
|
||||
IPAFactoryView(anInstance, "", NULLcmd, NULLcmd, TRUE, TRUE, FALSE, TOPSTICKY|LEFTSTICKY, FALSE, FALSE);
|
||||
|
||||
|
||||
anInstance->SetTogglable( FALSE );
|
||||
CImage anImage(1001);
|
||||
CPicture* aPicture = new CPicture( anInstance, CPoint((UNITS)0, (UNITS)0), anImage );
|
||||
_PA_REF(aPicture);
|
||||
anInstance->SetCommands( NULLcmd, NULLcmd, SAVE_AS_INcmd, SAVE_AS_OUTcmd );
|
||||
anInstance->SizeToFit();
|
||||
|
||||
|
||||
}
|
||||
|
||||
CFactoryElement _CMenuButton1064DEFAULT(&GUIFactory, CMenuButton1064, 20126, 3, C_CMenuButton1064_GUI_DEFAULT, I_CMenuButton1064_GUI_DEFAULT, LogBar, 0, 1, 13, 1);
|
||||
|
||||
void* C_CMenuButton1079_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
CSubview* anEnclosure = PtrCast( CSubview, theData );
|
||||
CMenuButton *anInstance = new CMenuButton( anEnclosure, CRect((UNITS)151, (UNITS)3, (UNITS)174, (UNITS)26), RESUMEcmd );
|
||||
return anInstance;
|
||||
}
|
||||
|
||||
void I_CMenuButton1079_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData, CDataMembers* theDataMembers)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
_PA_REF(theDataMembers);
|
||||
CMenuButton* anInstance = PtrCast(CMenuButton, theData);
|
||||
if (!anInstance) return;
|
||||
|
||||
|
||||
IPAFactoryView(anInstance, "", NULLcmd, NULLcmd, TRUE, TRUE, FALSE, TOPSTICKY|LEFTSTICKY, FALSE, FALSE);
|
||||
|
||||
|
||||
anInstance->SetTogglable( FALSE );
|
||||
CImage anImage(1006);
|
||||
CPicture* aPicture = new CPicture( anInstance, CPoint((UNITS)0, (UNITS)0), anImage );
|
||||
_PA_REF(aPicture);
|
||||
anInstance->SetCommands( NULLcmd, NULLcmd, RESUME_INcmd, RESUME_OUTcmd );
|
||||
anInstance->SizeToFit();
|
||||
|
||||
|
||||
}
|
||||
|
||||
CFactoryElement _CMenuButton1079DEFAULT(&GUIFactory, CMenuButton1079, 20126, 3, C_CMenuButton1079_GUI_DEFAULT, I_CMenuButton1079_GUI_DEFAULT, LogBar, 0, 1, 13, 6);
|
||||
|
||||
void* C_textExecButton_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
CSubview* anEnclosure = PtrCast( CSubview, theData );
|
||||
CMenuButton *anInstance = new CMenuButton( anEnclosure, CRect((UNITS)683, (UNITS)3, (UNITS)706, (UNITS)26), COMcmd );
|
||||
return anInstance;
|
||||
}
|
||||
|
||||
void I_textExecButton_GUI_DEFAULT(const PAFactory* theFactory, CObjectRWC* theData, CDataMembers* theDataMembers)
|
||||
{
|
||||
_PA_REF(theFactory);
|
||||
_PA_REF(theData);
|
||||
_PA_REF(theDataMembers);
|
||||
CMenuButton* anInstance = PtrCast(CMenuButton, theData);
|
||||
if (!anInstance) return;
|
||||
|
||||
|
||||
IPAFactoryView(anInstance, "", NULLcmd, NULLcmd, TRUE, FALSE, FALSE, TOPSTICKY|LEFTSTICKY, FALSE, FALSE);
|
||||
|
||||
|
||||
anInstance->SetTogglable( FALSE );
|
||||
CImage anImage(1010);
|
||||
CPicture* aPicture = new CPicture( anInstance, CPoint((UNITS)0, (UNITS)0), anImage );
|
||||
_PA_REF(aPicture);
|
||||
anInstance->SetCommands( NULLcmd, NULLcmd, COM_INcmd, COM_OUTcmd );
|
||||
anInstance->SizeToFit();
|
||||
|
||||
|
||||
}
|
||||
|
||||
CFactoryElement _textExecButtonDEFAULT(&GUIFactory, textExecButton, 20126, 3, C_textExecButton_GUI_DEFAULT, I_textExecButton_GUI_DEFAULT, LogBar, 0, 1, 13, 11);
|
||||
|
||||
@@ -0,0 +1,206 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: faccmd.h,v 2.1 1998/07/12 02:39:14 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/*
|
||||
This is version 4.5 of XVT-Architect.
|
||||
This file was automatically generated by XVT-Architect,
|
||||
Do not modify its contents.
|
||||
*/
|
||||
|
||||
#ifndef GUI_FactoryCommands_h
|
||||
#define GUI_FactoryCommands_h
|
||||
|
||||
// Command ID Bases:
|
||||
/*
|
||||
Default base
|
||||
*/
|
||||
#ifndef PA_NULLBase
|
||||
#define PA_NULLBase 0
|
||||
#endif
|
||||
#ifndef G4Control_Commands
|
||||
#define G4Control_Commands 1000
|
||||
#endif
|
||||
|
||||
// Command IDs:
|
||||
#ifndef NULLcCMenuButton1095md
|
||||
#define NULLcCMenuButton1095md (PA_NULLBase + 20)
|
||||
#endif
|
||||
#ifndef COM_INcmd
|
||||
#define COM_INcmd (G4Control_Commands + 34)
|
||||
#endif
|
||||
#ifndef COM_OUTcmd
|
||||
#define COM_OUTcmd (G4Control_Commands + 35)
|
||||
#endif
|
||||
#ifndef STOP_INcmd
|
||||
#define STOP_INcmd (G4Control_Commands + 5)
|
||||
#endif
|
||||
#ifndef START_OUTcmd
|
||||
#define START_OUTcmd (G4Control_Commands + 3)
|
||||
#endif
|
||||
#ifndef RESUMEcmd
|
||||
#define RESUMEcmd (G4Control_Commands + 10)
|
||||
#endif
|
||||
#ifndef RESUME_INcmd
|
||||
#define RESUME_INcmd (G4Control_Commands + 11)
|
||||
#endif
|
||||
#ifndef M_Pause_Geant
|
||||
#define M_Pause_Geant (PA_NULLBase + 13)
|
||||
#endif
|
||||
#ifndef QUIT_INcmd
|
||||
#define QUIT_INcmd (G4Control_Commands + 14)
|
||||
#endif
|
||||
#ifndef M_Retrieve_Commands
|
||||
#define M_Retrieve_Commands (PA_NULLBase + 7)
|
||||
#endif
|
||||
#ifndef M_Palettes
|
||||
#define M_Palettes (PA_NULLBase + 16)
|
||||
#endif
|
||||
#ifndef M_Commands
|
||||
#define M_Commands (PA_NULLBase + 17)
|
||||
#endif
|
||||
#ifndef COMcmd
|
||||
#define COMcmd (G4Control_Commands + 31)
|
||||
#endif
|
||||
#ifndef PAUSE_OUTcmd
|
||||
#define PAUSE_OUTcmd (G4Control_Commands + 9)
|
||||
#endif
|
||||
#ifndef PAUSEcmd
|
||||
#define PAUSEcmd (G4Control_Commands + 7)
|
||||
#endif
|
||||
#ifndef HELP_OUTcmd
|
||||
#define HELP_OUTcmd (G4Control_Commands + 23)
|
||||
#endif
|
||||
#ifndef PRINT_OUTcmd
|
||||
#define PRINT_OUTcmd (G4Control_Commands + 21)
|
||||
#endif
|
||||
#ifndef SAVE_AS_INcmd
|
||||
#define SAVE_AS_INcmd (G4Control_Commands + 18)
|
||||
#endif
|
||||
#ifndef SAVE_AS_OUTcmd
|
||||
#define SAVE_AS_OUTcmd (G4Control_Commands + 19)
|
||||
#endif
|
||||
#ifndef OutputWinMB
|
||||
#define OutputWinMB (PA_NULLBase + 3)
|
||||
#endif
|
||||
#ifndef SAVE_LOG_INcmd
|
||||
#define SAVE_LOG_INcmd (G4Control_Commands + 16)
|
||||
#endif
|
||||
#ifndef M_Start_Geant
|
||||
#define M_Start_Geant (PA_NULLBase + 11)
|
||||
#endif
|
||||
#ifndef GET_COMMANDS_OUTcmd
|
||||
#define GET_COMMANDS_OUTcmd (G4Control_Commands + 30)
|
||||
#endif
|
||||
#ifndef RESUME_OUTcmd
|
||||
#define RESUME_OUTcmd (G4Control_Commands + 12)
|
||||
#endif
|
||||
#ifndef M_Setup
|
||||
#define M_Setup (PA_NULLBase + 6)
|
||||
#endif
|
||||
#ifndef EXECUTEcmd
|
||||
#define EXECUTEcmd (G4Control_Commands + 26)
|
||||
#endif
|
||||
#ifndef HELP_MENU_1015
|
||||
#define HELP_MENU_1015 (PA_NULLBase + 18)
|
||||
#endif
|
||||
#ifndef HELP_MENU_1044
|
||||
#define HELP_MENU_1044 (PA_NULLBase + 5)
|
||||
#endif
|
||||
#ifndef STOP_OUTcmd
|
||||
#define STOP_OUTcmd (G4Control_Commands + 6)
|
||||
#endif
|
||||
#ifndef START_INcmd
|
||||
#define START_INcmd (G4Control_Commands + 2)
|
||||
#endif
|
||||
#ifndef GET_COMMANDScmd
|
||||
#define GET_COMMANDScmd (G4Control_Commands + 28)
|
||||
#endif
|
||||
#ifndef FILE_MENU_1015
|
||||
#define FILE_MENU_1015 (PA_NULLBase + 2)
|
||||
#endif
|
||||
#ifndef FILE_MENU_1044
|
||||
#define FILE_MENU_1044 (PA_NULLBase + 4)
|
||||
#endif
|
||||
#ifndef G4WinMB
|
||||
#define G4WinMB (PA_NULLBase + 1)
|
||||
#endif
|
||||
#ifndef QUIT_OUTcmd
|
||||
#define QUIT_OUTcmd (G4Control_Commands + 15)
|
||||
#endif
|
||||
#ifndef M_Stop_Geant
|
||||
#define M_Stop_Geant (PA_NULLBase + 12)
|
||||
#endif
|
||||
#ifndef M_Quit_Geant
|
||||
#define M_Quit_Geant (PA_NULLBase + 15)
|
||||
#endif
|
||||
#ifndef PAUSE_INcmd
|
||||
#define PAUSE_INcmd (G4Control_Commands + 8)
|
||||
#endif
|
||||
#ifndef HELPcmd
|
||||
#define HELPcmd (G4Control_Commands + 27)
|
||||
#endif
|
||||
#ifndef STARTcmd
|
||||
#define STARTcmd (G4Control_Commands + 1)
|
||||
#endif
|
||||
#ifndef STOPcmd
|
||||
#define STOPcmd (G4Control_Commands + 4)
|
||||
#endif
|
||||
#ifndef QUITcmd
|
||||
#define QUITcmd (G4Control_Commands + 13)
|
||||
#endif
|
||||
#ifndef HELP_INcmd
|
||||
#define HELP_INcmd (G4Control_Commands + 22)
|
||||
#endif
|
||||
#ifndef PRINT_INcmd
|
||||
#define PRINT_INcmd (G4Control_Commands + 20)
|
||||
#endif
|
||||
#ifndef SAVE_LOG_OUTcmd
|
||||
#define SAVE_LOG_OUTcmd (G4Control_Commands + 17)
|
||||
#endif
|
||||
#ifndef EXECUTE_INcmd
|
||||
#define EXECUTE_INcmd (G4Control_Commands + 24)
|
||||
#endif
|
||||
#ifndef EXECUTE_OUTcmd
|
||||
#define EXECUTE_OUTcmd (G4Control_Commands + 25)
|
||||
#endif
|
||||
#ifndef M_Control
|
||||
#define M_Control (PA_NULLBase + 10)
|
||||
#endif
|
||||
#ifndef GET_COMMANDS_INcmd
|
||||
#define GET_COMMANDS_INcmd (G4Control_Commands + 29)
|
||||
#endif
|
||||
#ifndef M_Enter_Parameters_for_selected_command
|
||||
#define M_Enter_Parameters_for_selected_command (PA_NULLBase + 8)
|
||||
#endif
|
||||
#ifndef M_On_command
|
||||
#define M_On_command (PA_NULLBase + 19)
|
||||
#endif
|
||||
#ifndef M_Resume_Geant
|
||||
#define M_Resume_Geant (PA_NULLBase + 14)
|
||||
#endif
|
||||
#ifndef M_Execute_Selected_Command
|
||||
#define M_Execute_Selected_Command (PA_NULLBase + 9)
|
||||
#endif
|
||||
|
||||
#ifndef PAFACTORY_BASE_NAME
|
||||
#define PAFACTORY_BASE_NAMEGUI
|
||||
#endif
|
||||
#ifndef PAFACTORY_QBASE_NAME
|
||||
#define PAFACTORY_QBASE_NAME "GUI"
|
||||
#endif
|
||||
|
||||
// Layer ID Bases
|
||||
#ifndef DEFAULT_BASE
|
||||
#define DEFAULT_BASE 0
|
||||
#endif
|
||||
|
||||
// Accelerator Tags:
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,40 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: facdec.h,v 2.1 1998/07/12 02:39:14 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/*
|
||||
This is version 4.5 of XVT-Architect.
|
||||
This file was automatically generated by XVT-Architect,
|
||||
Do not modify its contents.
|
||||
*/
|
||||
|
||||
#ifndef GUI_FacDec_h
|
||||
#define GUI_FacDec_h
|
||||
|
||||
// Forward Declarations
|
||||
|
||||
#define CUserView PWR_CRectangle
|
||||
#define CUserSubview PWR_CRectangle
|
||||
#define CUserView_i CRectangle_i
|
||||
#define CUserSubview_i CRectangle_i
|
||||
|
||||
class CMenuButton;
|
||||
class CScroller;
|
||||
class CMenuBar;
|
||||
class CToolBar;
|
||||
class G4XvtGUI;
|
||||
class CTaskDoc;
|
||||
class CTaskWin;
|
||||
class NScrollText;
|
||||
class G4XvtDoc;
|
||||
class G4XvtWin;
|
||||
class CStatusBar;
|
||||
class NLineText;
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,40 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: facdef.h,v 2.1 1998/07/12 02:39:15 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
|
||||
/*
|
||||
This is version 4.5 of XVT-Architect.
|
||||
This file was automatically generated by XVT-Architect,
|
||||
Do not modify its contents.
|
||||
*/
|
||||
|
||||
#ifndef GUI_FacDef_h
|
||||
#define GUI_FacDef_h
|
||||
|
||||
// Factory class includes:
|
||||
#define G4XvtGUI_f "_g4xvtgu.h"
|
||||
#define CTaskDoc_f "_ctskdoc.h"
|
||||
#define CTaskWin_f "_ctskwin.h"
|
||||
#define G4XvtDoc_f "_g4xvtdc.h"
|
||||
#define G4XvtWin_f "_g4xvtwn.h"
|
||||
#define FactoryCommands_i "faccmd.h"
|
||||
#define FactoryStrings_i "facstr.h"
|
||||
#define FactoryDefines_i "defines.h"
|
||||
#define CGUIFactory_i "factory.h"
|
||||
#ifndef PA_FACTORY_INSTANCE
|
||||
#define PA_FACTORY_INSTANCE GUIFactory
|
||||
#endif
|
||||
|
||||
#ifndef DSP_RELEASE
|
||||
#define DSP_RELEASE 450
|
||||
#endif
|
||||
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,39 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: facstr.h,v 2.1 1998/07/12 02:39:15 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/*
|
||||
This is version 4.5 of XVT-Architect.
|
||||
This file was automatically generated by XVT-Architect,
|
||||
Do not modify its contents.
|
||||
*/
|
||||
|
||||
#ifndef GUI_FactoryStrings_h
|
||||
#define GUI_FactoryStrings_h
|
||||
|
||||
// String IDs:
|
||||
|
||||
#ifndef GUIStringIDBase
|
||||
#define GUIStringIDBase 0
|
||||
#endif
|
||||
|
||||
|
||||
// Defines for DEFAULT layer
|
||||
#define STRING5 ""
|
||||
#define STRING3 ""
|
||||
#define STRING6 ""
|
||||
#define STRING7 ""
|
||||
#define STRING8 ""
|
||||
#define STRING9 ""
|
||||
#define STRING2 ""
|
||||
#define STRING4 ""
|
||||
#define STRING1 (1016+GUIStringIDBase)
|
||||
|
||||
|
||||
#endif
|
||||
|
After Width: | Height: | Size: 632 B |
@@ -0,0 +1,65 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: factory.cxx,v 2.1 1998/07/12 02:39:15 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/*
|
||||
This is version 4.5 of XVT-Architect.
|
||||
This file was automatically generated by XVT-Architect,
|
||||
Do not modify its contents.
|
||||
*/
|
||||
|
||||
#include "factory.h"
|
||||
#include "faccmd.h"
|
||||
|
||||
|
||||
CGUIFactory GUIFactory;
|
||||
|
||||
int CGUIFactory::itIsInitialized = 0;
|
||||
|
||||
extern void _Init_GUI_faccb0();
|
||||
extern void _Init_GUI_faccb1();
|
||||
extern void _Init_GUI_faccb2();
|
||||
extern void _Init_GUI_faccb3();
|
||||
extern void _Init_GUI_faccb4();
|
||||
|
||||
CGUIFactory::CGUIFactory(void)
|
||||
: PAFactory(itIsInitialized)
|
||||
{
|
||||
itIsInitialized = 1;
|
||||
_Init_GUI_faccb0();
|
||||
_Init_GUI_faccb1();
|
||||
_Init_GUI_faccb2();
|
||||
_Init_GUI_faccb3();
|
||||
_Init_GUI_faccb4();
|
||||
}
|
||||
|
||||
CGUIFactory& CGUIFactory::operator[](CGUIFactory::LayerID theLayer)
|
||||
{
|
||||
PAFactory::operator[]((long) theLayer);
|
||||
return *this;
|
||||
}
|
||||
|
||||
void CGUIFactory::SetDefaultLayer(CGUIFactory::LayerID theLayer)
|
||||
{
|
||||
PAFactory::SetDefaultLayer((long) theLayer);
|
||||
}
|
||||
|
||||
CGUIFactory::LayerID CGUIFactory::GetDefaultLayer(void) const
|
||||
{
|
||||
return (CGUIFactory::LayerID) PAFactory::GetDefaultLayer();
|
||||
}
|
||||
|
||||
long CGUIFactory::GetLayerBase(CGUIFactory::LayerID theLayerID)
|
||||
{
|
||||
switch(theLayerID) {
|
||||
case DEFAULT: return DEFAULT_BASE;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,50 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: factory.h,v 2.1 1998/07/12 02:39:16 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/*
|
||||
This is version 4.5 of XVT-Architect.
|
||||
This file was automatically generated by XVT-Architect,
|
||||
Do not modify its contents.
|
||||
*/
|
||||
|
||||
#ifndef GUIFactory_h
|
||||
#define GUIFactory_h
|
||||
|
||||
#include "XVTPwr.h"
|
||||
#include "AppDef.h"
|
||||
#include PAFactory_i
|
||||
|
||||
// Project factory class definition:
|
||||
|
||||
class CGUIFactory : public PAFactory
|
||||
{
|
||||
public:
|
||||
|
||||
enum LayerID {
|
||||
DEFAULT=0
|
||||
};
|
||||
|
||||
CGUIFactory(void);
|
||||
|
||||
CGUIFactory& operator[](LayerID theLayer);
|
||||
void SetDefaultLayer(LayerID theLayer);
|
||||
LayerID GetDefaultLayer(void) const;
|
||||
long GetLayerBase(LayerID theLayer);
|
||||
|
||||
protected:
|
||||
|
||||
friend class CGUIFactoryInit;
|
||||
|
||||
static int itIsInitialized;
|
||||
|
||||
};
|
||||
|
||||
extern CGUIFactory GUIFactory;
|
||||
#endif
|
||||
@@ -0,0 +1,74 @@
|
||||
/*
|
||||
This is version 4.5 of XVT-Architect.
|
||||
This file was automatically generated by XVT-Architect,
|
||||
Do not modify its contents.
|
||||
*/
|
||||
|
||||
#ifndef URL_RECT
|
||||
#define URL_RECT(a,b,c,d) a, b, c, d
|
||||
#endif
|
||||
#include "faccmd.h"
|
||||
#include "images.url"
|
||||
#include "strings.url"
|
||||
|
||||
|
||||
|
||||
/* Definition of menubar G4WinMB for DEFAULT layer */
|
||||
|
||||
menubar G4WinMB+DEFAULT_BASE
|
||||
menu G4WinMB+DEFAULT_BASE
|
||||
submenu FILE_MENU_1015+DEFAULT_BASE "File"
|
||||
submenu M_Setup+DEFAULT_BASE "Commands"
|
||||
submenu M_Control+DEFAULT_BASE "Control"
|
||||
submenu M_Palettes+DEFAULT_BASE "Palettes"
|
||||
submenu HELP_MENU_1015+DEFAULT_BASE "Help"
|
||||
|
||||
menu FILE_MENU_1015+DEFAULT_BASE
|
||||
item M_FILE_SAVE "Save Log"
|
||||
item M_FILE_SAVE_AS "Save Log As..."
|
||||
item M_FILE_PRINT "Print Log..."
|
||||
separator
|
||||
item M_FILE_QUIT "Exit"
|
||||
|
||||
menu M_Setup+DEFAULT_BASE
|
||||
item M_Retrieve_Commands "Retrieve Commands"
|
||||
separator
|
||||
item M_Enter_Parameters_for_selected_command "Enter Parameters for selected command"
|
||||
item M_Execute_Selected_Command "Execute Selected Command"
|
||||
|
||||
menu M_Control+DEFAULT_BASE
|
||||
item M_Start_Geant "Start Geant"
|
||||
item M_Stop_Geant "Stop Geant"
|
||||
separator
|
||||
item M_Pause_Geant "Pause Geant"
|
||||
item M_Resume_Geant "Resume_Geant"
|
||||
separator
|
||||
item M_Quit_Geant "Quit Geant"
|
||||
|
||||
menu M_Palettes+DEFAULT_BASE
|
||||
item M_Commands "Commands"
|
||||
|
||||
menu HELP_MENU_1015+DEFAULT_BASE
|
||||
item M_HELP_ONWINDOW "This Window"
|
||||
separator
|
||||
item M_On_command "On command"
|
||||
separator
|
||||
item M_HELP_VERSION "About..."
|
||||
|
||||
/* Definition of menubar OutputWinMB for DEFAULT layer */
|
||||
|
||||
menubar OutputWinMB+DEFAULT_BASE
|
||||
menu OutputWinMB+DEFAULT_BASE
|
||||
submenu FILE_MENU_1044+DEFAULT_BASE "File"
|
||||
submenu HELP_MENU_1044+DEFAULT_BASE "Help"
|
||||
|
||||
menu FILE_MENU_1044+DEFAULT_BASE
|
||||
item M_FILE_SAVE "Save Log"
|
||||
item M_FILE_SAVE_AS "Save Log As"
|
||||
separator
|
||||
item M_FILE_PRINT "Print Log"
|
||||
|
||||
menu HELP_MENU_1044+DEFAULT_BASE
|
||||
item M_HELP_ONWINDOW "This Window"
|
||||
separator
|
||||
item M_HELP_VERSION "About"
|
||||
@@ -0,0 +1,18 @@
|
||||
/*
|
||||
This is version 4.5 of XVT-Architect.
|
||||
This file was automatically generated by XVT-Architect,
|
||||
Do not modify its contents.
|
||||
*/
|
||||
|
||||
IMAGE 1000 "/afs/cern.ch/user/s/sprior/geant4_current_code/geant4alpha/prototype/interfaces/xvt_standalone_test/HP_GUI/bitmaps/small/smallsave.bmp"
|
||||
IMAGE 1001 "/afs/cern.ch/user/s/sprior/geant4_current_code/geant4alpha/prototype/interfaces/xvt_standalone_test/HP_GUI/bitmaps/small/smallsaveas.bmp"
|
||||
IMAGE 1002 "/afs/cern.ch/user/s/sprior/geant4_current_code/geant4alpha/prototype/interfaces/xvt_standalone_test/HP_GUI/bitmaps/small/smallprint.bmp"
|
||||
IMAGE 1003 "/afs/cern.ch/user/s/sprior/geant4_current_code/geant4alpha/prototype/interfaces/xvt_standalone_test/HP_GUI/bitmaps/small/smallstart3d.bmp"
|
||||
IMAGE 1004 "/afs/cern.ch/user/s/sprior/geant4_current_code/geant4alpha/prototype/interfaces/xvt_standalone_test/HP_GUI/bitmaps/small/smallstop3d.bmp"
|
||||
IMAGE 1005 "/afs/cern.ch/user/s/sprior/geant4_current_code/geant4alpha/prototype/interfaces/xvt_standalone_test/HP_GUI/bitmaps/small/smallpause3d.bmp"
|
||||
IMAGE 1006 "/afs/cern.ch/user/s/sprior/geant4_current_code/geant4alpha/prototype/interfaces/xvt_standalone_test/HP_GUI/bitmaps/small/smallresume3d.bmp"
|
||||
IMAGE 1007 "/afs/cern.ch/user/s/sprior/geant4_current_code/geant4alpha/prototype/interfaces/xvt_standalone_test/HP_GUI/bitmaps/small/smallquit3d.bmp"
|
||||
IMAGE 1008 "/afs/cern.ch/user/s/sprior/geant4_current_code/geant4alpha/prototype/interfaces/xvt_standalone_test/HP_GUI/bitmaps/small/gtox.bmp"
|
||||
IMAGE 1009 "/afs/cern.ch/user/s/sprior/geant4_current_code/geant4alpha/prototype/interfaces/xvt_standalone_test/HP_GUI/bitmaps/small/xtog.bmp"
|
||||
IMAGE 1010 "/afs/cern.ch/user/s/sprior/geant4_current_code/geant4alpha/prototype/interfaces/xvt_standalone_test/HP_GUI/bitmaps/small/command.bmp"
|
||||
IMAGE 1011 "/afs/cern.ch/user/s/sprior/geant4_current_code/geant4alpha/prototype/interfaces/xvt_standalone_test/HP_GUI/bitmaps/small/helpcom.bmp"
|
||||
@@ -0,0 +1,12 @@
|
||||
/*
|
||||
This is version 4.5 of XVT-Architect.
|
||||
This file was automatically generated by XVT-Architect,
|
||||
Do not modify its contents.
|
||||
*/
|
||||
|
||||
#include "facstr.h"
|
||||
|
||||
|
||||
// Strings for DEFAULT layer
|
||||
string (1016+GUIStringIDBase) "Control Window"
|
||||
|
||||
@@ -0,0 +1,211 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: g4xvtdoc.cxx,v 2.1 1998/07/12 02:39:03 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/*********************************************************************
|
||||
*
|
||||
Copyright (c) 1996
|
||||
|
||||
File Name: G4XvtDoc.cxx
|
||||
|
||||
Implements a document class to manage data
|
||||
*
|
||||
*********************************************************************/
|
||||
|
||||
#include "XVTPwr.h"
|
||||
#include "AppDef.h"
|
||||
|
||||
#include GUI_i
|
||||
#include G4XvtDoc_i
|
||||
|
||||
#include G4XvtWin_i
|
||||
|
||||
#include NScrollText_i
|
||||
#include CStatusBar_i
|
||||
|
||||
// Define the Run-Time Type Identification for this class
|
||||
// PWRRegisterClass1(G4XvtDoc, G4XvtDocID, "G4XvtDoc", CDocument)
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Document class constructor
|
||||
//
|
||||
// Create and Initialize the internal data objects for this class
|
||||
//
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
G4XvtDoc::G4XvtDoc( CApplication * theApplication, PWRID theDocumentId )
|
||||
: CDocument( theApplication, theDocumentId )
|
||||
{
|
||||
// If the internal data object is derived from CModel, you may also
|
||||
// want to instantiate a CController for the data, and take advantage
|
||||
// of the automatic data propagation
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Document class destructor
|
||||
//
|
||||
// Delete the internal data objects for this class
|
||||
//
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
G4XvtDoc::~G4XvtDoc( void )
|
||||
{
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// BuildWindow
|
||||
//
|
||||
// Create the default view(s) of this data
|
||||
//
|
||||
// This method is automatically called by the base class methods
|
||||
// when new document objects are created or opened.
|
||||
//
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
void G4XvtDoc::BuildWindow( void )
|
||||
{
|
||||
// Create all window objects associated with this document
|
||||
// that have the AutoCreate option specified in XVT-Architect.
|
||||
|
||||
GUIFactory.DoCreateWindows( this, G4Doc, FALSE, &itsData );
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// DoCommand
|
||||
//
|
||||
// Handle commands here that have to do with accessing data, or that create,
|
||||
// destroy or otherwise manage the window objects of the application.
|
||||
//
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
void G4XvtDoc::DoCommand( long theCommand, void * theData )
|
||||
{
|
||||
switch( theCommand )
|
||||
{
|
||||
case NULLcmd:
|
||||
// stop propagation of "undefined" commands
|
||||
break;
|
||||
|
||||
default:
|
||||
CDocument::DoCommand( theCommand, theData );
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// DoMenuCommand
|
||||
//
|
||||
// Handle menu items here that have to do with accessing data, or that create,
|
||||
// destroy or otherwise manage the window objects of the application.
|
||||
//
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
void G4XvtDoc::DoMenuCommand(
|
||||
MENU_TAG theMenuItem,
|
||||
BOOLEAN isShiftKey,
|
||||
BOOLEAN isControlKey )
|
||||
{
|
||||
switch( theMenuItem )
|
||||
{
|
||||
case NULLcmd:
|
||||
// stop propagation of "undefined" commands
|
||||
break;
|
||||
|
||||
default:
|
||||
CDocument::DoMenuCommand( theMenuItem, isShiftKey, isControlKey );
|
||||
break;
|
||||
}
|
||||
}
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Save
|
||||
//
|
||||
// Called by DoSave(). Do the actual work of saving the data.
|
||||
//
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
BOOLEAN G4XvtDoc::Save( void )
|
||||
{
|
||||
SetSave( FALSE );
|
||||
return( !NeedsSaving( ) );
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Open
|
||||
//
|
||||
// Called by DoOpen(). Do the actual work of restoring the object from
|
||||
// a data source.
|
||||
//
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
BOOLEAN G4XvtDoc::Open( void )
|
||||
{
|
||||
// Add code here to set internal data members of the class based
|
||||
// on information read from some data source
|
||||
|
||||
SetSave( FALSE );
|
||||
return( !NeedsSaving( ) );
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// DoSave
|
||||
//
|
||||
// This method is automatically called when the File Save menu option is
|
||||
// selected. Write out the contents of this document object to the path
|
||||
// specified in the internal FILE_SPEC data member.
|
||||
//
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
BOOLEAN G4XvtDoc::DoSave( void )
|
||||
{
|
||||
if( itsXVTFilePointer && itsXVTFilePointer -> name[0] )
|
||||
return( Save( ) );
|
||||
else
|
||||
return( DoSaveAs( ) );
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// DoOpen
|
||||
//
|
||||
// This method is automatically called when the File Save menu option is
|
||||
// selected. Initialize the contents of this document object from the file
|
||||
// path in the internal FILE_SPEC data member. Put up the File Open dialog
|
||||
// if no file name has been assigned yet.
|
||||
//
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
BOOLEAN G4XvtDoc::DoOpen( void )
|
||||
{
|
||||
if( !itsXVTFilePointer )
|
||||
{
|
||||
itsXVTFilePointer = new FILE_SPEC;
|
||||
itsXVTFilePointer -> type[0] = 0;
|
||||
itsXVTFilePointer -> name[0] = 0;
|
||||
xvt_fsys_get_default_dir( &itsXVTFilePointer -> dir );
|
||||
}
|
||||
|
||||
switch( xvt_dm_post_file_open( itsXVTFilePointer,
|
||||
"Enter a new file to open:" ) )
|
||||
{
|
||||
case FL_OK:
|
||||
if( Open( ) )
|
||||
{
|
||||
BuildWindow( );
|
||||
return( TRUE );
|
||||
}
|
||||
else
|
||||
{
|
||||
return( FALSE );
|
||||
}
|
||||
|
||||
case FL_BAD:
|
||||
case FL_CANCEL:
|
||||
default:
|
||||
return( FALSE );
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,82 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: g4xvtdoc.h,v 2.1 1998/07/12 02:39:03 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/********************************************************************
|
||||
*
|
||||
Copyright (c) 1996
|
||||
|
||||
File Name: G4XvtDoc.h
|
||||
Author:
|
||||
Date:
|
||||
|
||||
Class: G4XvtDoc
|
||||
Inheritance: CDocument->G4XvtDoc
|
||||
Helper(s):
|
||||
|
||||
Purpose: This is an example of how to override the minimal set of
|
||||
methods of CDocument. It initializes data maintained by
|
||||
the class, creates a window in which to display the data,
|
||||
implements methods for handling requests to access the
|
||||
data, and provides a basic skeleton for persistence.
|
||||
|
||||
Usage: Override or add methods as necessary.
|
||||
|
||||
Modifications:
|
||||
*
|
||||
********************************************************************/
|
||||
|
||||
#ifndef G4XvtDoc_H
|
||||
#define G4XvtDoc_H
|
||||
|
||||
#include "XVTPwr.h"
|
||||
#include "AppDef.h"
|
||||
|
||||
#include GUI_i
|
||||
#include CDocument_i
|
||||
|
||||
#ifdef DSP_RELEASE
|
||||
#include G4XvtDoc_f
|
||||
#endif
|
||||
|
||||
//#include CTypeInfo_i
|
||||
|
||||
class G4XvtDoc : public CDocument
|
||||
{
|
||||
public:
|
||||
G4XvtDoc( CApplication * theApplication = G -> GetApplication( ),
|
||||
PWRID theDocumentId = G -> GetId( ) );
|
||||
virtual ~G4XvtDoc( void );
|
||||
|
||||
virtual void BuildWindow( void );
|
||||
virtual void DoCommand( long theCommand, void * theData = NULL );
|
||||
virtual void DoMenuCommand( MENU_TAG theMenuItem,
|
||||
BOOLEAN isShiftKey, BOOLEAN isControlKey );
|
||||
|
||||
virtual BOOLEAN DoSave( void );
|
||||
virtual BOOLEAN DoOpen( void );
|
||||
|
||||
virtual BOOLEAN Save( void );
|
||||
virtual BOOLEAN Open( void );
|
||||
|
||||
protected:
|
||||
// By default, copy and assignment are disallowed
|
||||
|
||||
G4XvtDoc( const G4XvtDoc& theDocument ) : CDocument( theDocument ) { }
|
||||
G4XvtDoc& operator=( const G4XvtDoc& theDocument ) { return( *this ); }
|
||||
|
||||
private:
|
||||
G4DocData itsData;
|
||||
|
||||
WINDOW theWin;
|
||||
|
||||
// PWRClassInfo
|
||||
};
|
||||
|
||||
#endif // G4XvtDoc_H
|
||||
@@ -0,0 +1,265 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: g4xvtgui.cxx,v 2.1 1998/07/12 02:39:04 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/*********************************************************************
|
||||
*
|
||||
Copyright (c) 1996
|
||||
|
||||
File Name: G4XvtGUI.cxx
|
||||
|
||||
Implements the application class
|
||||
*
|
||||
*********************************************************************/
|
||||
|
||||
#include "XVTPwr.h"
|
||||
#include "AppDef.h"
|
||||
|
||||
#include GUI_i
|
||||
#include G4XvtGUI_i
|
||||
#include CGlobalClassLib_i
|
||||
#include CTaskWin_i
|
||||
#include CDocument_i
|
||||
#include CMenuBar_i
|
||||
#include "rw/ordcltn.h"
|
||||
|
||||
#ifdef DSP_RELEASE
|
||||
#include CTaskWin_f
|
||||
#endif
|
||||
|
||||
// Define the Run-Time Type Identification for this class
|
||||
// PWRRegisterClass1(G4XvtGUI, G4XvtGUIID, "G4XvtGUI", CApplication)
|
||||
|
||||
// --- Include attachment files --- //
|
||||
#include CToolBarAttachment_i
|
||||
#include CAttachmentFrame_i
|
||||
// #include CUserWin_f
|
||||
#include G4XvtWin_f
|
||||
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Application class constructor
|
||||
//
|
||||
// Defines the initial state of the application object.
|
||||
//
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
G4XvtGUI::G4XvtGUI( CApplication::ApplicationByteAware theAppByte ) : CApplication( theAppByte )
|
||||
{
|
||||
// Set any System Attribute Table values that
|
||||
// need to be set before GUI initialization
|
||||
|
||||
#ifdef DSP_RELEASE
|
||||
GUIFactory.ConstructApplication( this, G4XvtGUI1002 );
|
||||
#endif
|
||||
|
||||
// For example...
|
||||
#if 0
|
||||
#if (XVTWS == WINWS || XVTWS == NTWS )
|
||||
|
||||
// Follow the MDI look and feel when running on MS-Windows
|
||||
xvt_vobj_set_attr( NULL_WIN, ATTR_WIN_MDI, TRUE );
|
||||
|
||||
#endif
|
||||
|
||||
#if (XVTWS == WINWS || XVTWS == NTWS || XVTWS == PMWS)
|
||||
|
||||
// Allow drawing in the task window:
|
||||
xvt_vobj_set_attr(NULL_WIN, ATTR_WIN_PM_DRAWABLE_TWIN, TRUE);
|
||||
|
||||
#endif
|
||||
|
||||
#if (XVTWS == MTFWS)
|
||||
|
||||
// When running on Motif, don't display the "ghost" window
|
||||
xvt_vobj_set_attr( NULL_WIN, ATTR_X_DISPLAY_TASK_WIN, FALSE );
|
||||
|
||||
#endif
|
||||
#endif
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Application class destructor
|
||||
//
|
||||
// Delete the internal data objects for this class
|
||||
//
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
G4XvtGUI::~G4XvtGUI( void )
|
||||
{
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Startup
|
||||
//
|
||||
// Defines the startup behavior for the application - whether an
|
||||
// initial about box is created, or a login screen is presented,
|
||||
// or an initial document object and its associated windows are
|
||||
// created, etc. Also, Initialize application level objects here.
|
||||
//
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
void G4XvtGUI::StartUp( void )
|
||||
{
|
||||
// NOTE: The base class method must be called before adding any
|
||||
// of your own code.
|
||||
CApplication::StartUp();
|
||||
|
||||
#ifdef DSP_RELEASE
|
||||
GUIFactory.InitializeApplication( this, G4XvtGUI1002 );
|
||||
#endif
|
||||
|
||||
#if 0
|
||||
#if (XVTWS == WINWS || XVTWS == NTWS || XVTWS == PMWS)
|
||||
// To instantiate the views sketched out in the TaskWindow, use
|
||||
// the following code:
|
||||
CTaskWin* aTaskWindow = G->GetTaskWin();
|
||||
GUIFactory.DoCreateViews( aTaskWindow, CTaskWin1004, TRUE );
|
||||
#endif
|
||||
#endif
|
||||
|
||||
// Create an instance of its documents and display their initial windows
|
||||
DoNew();
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// ShutDown
|
||||
//
|
||||
// Defines the termination behavior for the application - typically
|
||||
// it deletes application level objects that were created in StartUp.
|
||||
//
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
void G4XvtGUI::ShutDown( void )
|
||||
{
|
||||
// Base class method must be called as the last thing this method does
|
||||
CApplication::ShutDown();
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SetUpMenus
|
||||
//
|
||||
// Initialize the application menubar - the one that is
|
||||
// available when there are no windows with menubars available.
|
||||
//
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
void G4XvtGUI::SetUpMenus( CMenuBar* /*theMenuBar*/ )
|
||||
{
|
||||
// Example code to Initialize default menus
|
||||
// theMenuBar->SetEnabled( M_FILE_NEW, TRUE );
|
||||
// theMenuBar->SetEnabled( M_FILE_OPEN, TRUE );
|
||||
// theMenuBar->SetEnabled( M_EDIT, FALSE );
|
||||
// theMenuBar->SetEnabled( M_FONT_POPUP, FALSE );
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// DoCommand
|
||||
//
|
||||
// Handle commands here that have to do with behavior specific
|
||||
// to the application, or that create, destroy or otherwise
|
||||
// manage the data (document) objects of the application.
|
||||
//
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
void G4XvtGUI::DoCommand( long theCommand, void* theData )
|
||||
{
|
||||
switch ( theCommand )
|
||||
{
|
||||
case NULLcmd: // stop propagation of "undefined" commands
|
||||
break;
|
||||
|
||||
#if 0
|
||||
#if (XVTWS == MTFWS)
|
||||
// if the application is running on motif, Terminate the app when the
|
||||
// last window is closed to Follow motif style guidelines
|
||||
case NOWINDOWcmd:
|
||||
DoClose(); // clean up TaskDoc
|
||||
xvt_app_destroy(); // Terminate the application
|
||||
break;
|
||||
#endif
|
||||
#endif
|
||||
default:
|
||||
CApplication::DoCommand( theCommand, theData );
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// DoNew
|
||||
//
|
||||
// This method is automatically called when the New option on the
|
||||
// default File menu is selected. Create all document objects
|
||||
// that had the AutoCreate option specified in XVT-Architect.
|
||||
//
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
BOOLEAN G4XvtGUI::DoNew( void )
|
||||
{
|
||||
RWOrdered anExistingDocList( *itsDocuments );
|
||||
GUIFactory.DoCreateDocuments( this, G4XvtGUI1002, FALSE, &itsData );
|
||||
RWOrderedIterator nextDoc( *itsDocuments );
|
||||
CDocument* aDoc;
|
||||
RWOrdered orphanedDocs;
|
||||
BOOLEAN allDocsCreated = TRUE;
|
||||
while ( (aDoc = (CDocument*)nextDoc()) != NULL )
|
||||
if ( !anExistingDocList.find( aDoc ) && !aDoc->DoNew() )
|
||||
{
|
||||
orphanedDocs.append( aDoc );
|
||||
allDocsCreated = FALSE;
|
||||
}
|
||||
orphanedDocs.clearAndDestroy();
|
||||
return allDocsCreated;
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// DoOpen
|
||||
//
|
||||
// This method is automatically called when the Open option on the
|
||||
// default File menu is selected. Create a new document object,
|
||||
// allow the user to select a file, and Initialize the document
|
||||
// object from the file.
|
||||
//
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
BOOLEAN G4XvtGUI::DoOpen( void )
|
||||
{
|
||||
RWOrdered anExistingDocList( *itsDocuments );
|
||||
GUIFactory.DoCreateDocuments( this, G4XvtGUI1002, FALSE, &itsData );
|
||||
RWOrderedIterator nextDoc( *itsDocuments );
|
||||
CDocument* aDoc;
|
||||
RWOrdered orphanedDocs;
|
||||
BOOLEAN allDocsCreated = TRUE;
|
||||
while ( (aDoc = (CDocument*)nextDoc()) != NULL )
|
||||
if ( !anExistingDocList.find( aDoc ) && !aDoc->DoOpen() )
|
||||
{
|
||||
orphanedDocs.append( aDoc );
|
||||
allDocsCreated = FALSE;
|
||||
}
|
||||
orphanedDocs.clearAndDestroy();
|
||||
return allDocsCreated;
|
||||
}
|
||||
|
||||
|
||||
// --- New code for the attachment stuff --- //
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// GetAttachmentFrame
|
||||
//
|
||||
// Returns a pointer to the attacment frame created for the application's
|
||||
// task window. A return value of NULL indicates that no attachment frame
|
||||
// was created.
|
||||
//
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
CAttachmentFrame* G4XvtGUI::GetAttachmentFrame() const
|
||||
{
|
||||
return itsAttachmentFrame;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,90 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: g4xvtgui.h,v 2.1 1998/07/12 02:39:05 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/********************************************************************
|
||||
*
|
||||
Copyright (c) 1996
|
||||
|
||||
File Name: G4XvtGUI.h
|
||||
Author: Simon Prior
|
||||
Date:
|
||||
|
||||
Class: G4XvtGUI
|
||||
Inheritance: CApplication->G4XvtGUI
|
||||
Helper(s): G4XvtDoc, CShellWin
|
||||
|
||||
Purpose: This is an example of how to override the minimal set of
|
||||
methods of CApplication. It initializes the inherited
|
||||
application, creates a document object to manage the
|
||||
application's data, and implements methods for handling
|
||||
application-level issues.
|
||||
|
||||
Usage: Override or add methods as necessary.
|
||||
|
||||
Modifications:
|
||||
*
|
||||
********************************************************************/
|
||||
|
||||
#ifndef G4XvtGUI_H
|
||||
#define G4XvtGUI_H
|
||||
|
||||
#include "XVTPwr.h"
|
||||
#include "AppDef.h"
|
||||
|
||||
#include GUI_i
|
||||
#include CApplication_i
|
||||
|
||||
#ifdef DSP_RELEASE
|
||||
#include G4XvtGUI_f
|
||||
#endif
|
||||
|
||||
// --- Alert code of the CAttachment frame class use --- //
|
||||
class CAttachmentFrame;
|
||||
|
||||
#include CGlobalClassLib_i
|
||||
#define ATTACHApp ((CAttachApp*) CObjectRWC::G->GetApplication())
|
||||
|
||||
class G4XvtGUI : public CApplication
|
||||
{
|
||||
public:
|
||||
|
||||
G4XvtGUI( CApplication::ApplicationByteAware theAppByte = CApplication::AB_SINGLEBYTE );
|
||||
virtual ~G4XvtGUI( void );
|
||||
|
||||
// --- CAttachApp specific interface --- //
|
||||
|
||||
CAttachmentFrame* GetAttachmentFrame() const;
|
||||
|
||||
virtual void StartUp( void );
|
||||
virtual void ShutDown( void );
|
||||
virtual void SetUpMenus( CMenuBar* theMenuBar );
|
||||
virtual void DoCommand( long theCommand, void* theData = NULL );
|
||||
|
||||
virtual BOOLEAN DoNew( void );
|
||||
virtual BOOLEAN DoOpen( void );
|
||||
|
||||
protected:
|
||||
|
||||
// By default, copy and assignment are disallowed
|
||||
G4XvtGUI( const G4XvtGUI& theApplication ) : CApplication( theApplication ) {}
|
||||
G4XvtGUI& operator=( const G4XvtGUI& theApplication ) { return *this; }
|
||||
|
||||
// --- Class data --- //
|
||||
|
||||
CAttachmentFrame* itsAttachmentFrame;
|
||||
|
||||
private:
|
||||
|
||||
G4XvtGUI1002Data itsData;
|
||||
|
||||
// PWRClassInfo
|
||||
};
|
||||
|
||||
#endif // G4XvtGUI_H
|
||||
@@ -0,0 +1,282 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: g4xvtwin.h,v 2.1 1998/07/12 02:39:07 urbi Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
/********************************************************************
|
||||
*
|
||||
Copyright (c) 1996
|
||||
|
||||
File Name: G4XvtWin.h
|
||||
Author: Simon Prior
|
||||
Date:
|
||||
|
||||
Class: G4XvtWin
|
||||
Inheritance: CWindow->G4XvtWin
|
||||
Helper(s):
|
||||
|
||||
Purpose: This is a window class that has properties that were
|
||||
specified using XVT-Architect. It implements methods
|
||||
to Initialize and manage the state of views nested
|
||||
inside the window.
|
||||
|
||||
Usage: Override or add methods as necessary.
|
||||
|
||||
Modifications:
|
||||
*
|
||||
********************************************************************/
|
||||
|
||||
#ifndef G4XvtWin_H
|
||||
#define G4XvtWin_H
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// Define named pipes //
|
||||
// //
|
||||
// Note - if you wish to change the location of where the pipes are //
|
||||
// created edit the following lines putting in the appropriate //
|
||||
// paths. The default is for the pipes to be created in the //
|
||||
// current directory. //
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#define XvtToGeant "XvtToGeant.tmp"
|
||||
#define GeantToXvt "GeantToXvt.tmp"
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// Define file mode/permissions //
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#define FILE_MODE (0664 | S_IFIFO)
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// Include different files depending on what platform you are //
|
||||
// compiling on. //
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifdef _AIX
|
||||
#include <sys/mode.h> // --- mkfifo utils --- //
|
||||
#endif
|
||||
|
||||
#include <strings.h> // --- bzero function --- //
|
||||
#include <sys/time.h> // --- struct timeval --- //
|
||||
#include <sys/types.h>
|
||||
#include <unistd.h> // --- POSIX standards for stdin, out, err. --- //
|
||||
#include <values.h>
|
||||
#include <sys/stat.h>
|
||||
#include <fcntl.h> // --- Open, Close, Unlink etc --- //
|
||||
#include <sys/ioctl.h>
|
||||
#include <stdio.h> // --- sscanf, sprintf --- //
|
||||
|
||||
#include "XVTPwr.h"
|
||||
#include "AppDef.h"
|
||||
|
||||
#include GUI_i
|
||||
#include CWindow_i
|
||||
|
||||
#ifdef DSP_RELEASE
|
||||
#include G4XvtWin_f
|
||||
#endif
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// New data structures, one to hold the parameter information of a //
|
||||
// command and one to hold information on the command itself. //
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
|
||||
typedef struct G4parameterData
|
||||
{
|
||||
CStringRW name;
|
||||
CStringRW guidance;
|
||||
CStringRW defaultValue;
|
||||
CStringRW range;
|
||||
CStringRW candidate;
|
||||
char type;
|
||||
CStringRW omittable;
|
||||
};
|
||||
|
||||
typedef struct G4commandData
|
||||
{
|
||||
int flag;
|
||||
CStringRW name;
|
||||
CStringRW guidance;
|
||||
int numOfParameters;
|
||||
G4parameterData parameters[10];
|
||||
|
||||
// CStringRW bitmapName;
|
||||
|
||||
int commandNumber;
|
||||
};
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// Variables for the status bar //
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
|
||||
const long NULL_FIELD = 1L;
|
||||
const long STATUS_FIELD = 2L;
|
||||
const long COORDS_FIELD = 3L;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// Make code aware of the attachment and mouse handling classes use //
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
|
||||
class CAttachmentFrame;
|
||||
class CAttachment;
|
||||
class CToolBarAttachment;
|
||||
class CToolPalette;
|
||||
class CViewSinkData;
|
||||
class CDragSource;
|
||||
|
||||
class G4XvtWin : public CWindow
|
||||
{
|
||||
public:
|
||||
G4XvtWin(
|
||||
CDocument * theDocument,
|
||||
const CRect& theRegion,
|
||||
const CStringRW& theTitle = NULLString,
|
||||
long theWindowAttributes = WSF_NONE,
|
||||
WIN_TYPE theWindowType = W_DOC,
|
||||
int theMenuBarId = MENU_BAR_RID,
|
||||
WINDOW theParentWindow = TASK_WIN );
|
||||
|
||||
virtual ~G4XvtWin( void );
|
||||
|
||||
BOOLEAN I4XvtWin( void );
|
||||
|
||||
virtual void DoCommand( long theCommand, void * theData = NULL );
|
||||
|
||||
virtual void DoMenuCommand( MENU_TAG theMenuItem,
|
||||
BOOLEAN isShiftKey, BOOLEAN isControlKey );
|
||||
|
||||
virtual void UpdateMenus( CMenuBar * theMenuBar);
|
||||
|
||||
virtual void DoUpdateModel( long theControllerId,
|
||||
long theCommand, const CModel * theModel );
|
||||
|
||||
////////////////////////////////////////////////////////////////
|
||||
// Overriden timer method //
|
||||
////////////////////////////////////////////////////////////////
|
||||
|
||||
void DoTimer(long theTimerId);
|
||||
|
||||
protected:
|
||||
// By default, copy and assignment are disallowed
|
||||
|
||||
G4XvtWin( const G4XvtWin& theWindow ) : CWindow( theWindow ) { }
|
||||
G4XvtWin& operator=( const G4XvtWin& theWindow ){ return( *this ); }
|
||||
|
||||
private:
|
||||
G4WinData itsData;
|
||||
|
||||
////////////////////////////////////////////////////////////////
|
||||
// IPC Data members //
|
||||
////////////////////////////////////////////////////////////////
|
||||
|
||||
int fd_XvtToGeant, fd_GeantToXvt;
|
||||
long theTimer;
|
||||
long interval;
|
||||
WINDOW theWin;
|
||||
char textDump[100];
|
||||
int number;
|
||||
int G4Running;
|
||||
|
||||
///////////////////////////////////////////////////////////////
|
||||
// IPC methods //
|
||||
///////////////////////////////////////////////////////////////
|
||||
|
||||
void initTimer(void);
|
||||
void initIPC(void);
|
||||
void startSlave(void);
|
||||
void createNamedPipes(void);
|
||||
void destroyNamedPipes(void);
|
||||
void errorHandler(CStringRW theError);
|
||||
void writeData(CStringRW theString);
|
||||
void ExecuteCommand(void);
|
||||
CStringRW getString(void);
|
||||
|
||||
///////////////////////////////////////////////////////////////
|
||||
// Command Base data members //
|
||||
///////////////////////////////////////////////////////////////
|
||||
|
||||
G4commandData commandArray[200];
|
||||
int currentPosition, lastPosition;
|
||||
int reading;
|
||||
|
||||
///////////////////////////////////////////////////////////////
|
||||
// Command Base methods //
|
||||
///////////////////////////////////////////////////////////////
|
||||
|
||||
void initIndex(void);
|
||||
void fillLocalArray(void);
|
||||
void listCommandArray(void); // debugging method
|
||||
|
||||
|
||||
///////////////////////////////////////////////////////////////
|
||||
// Palette and attachment data members //
|
||||
///////////////////////////////////////////////////////////////
|
||||
|
||||
CToolPalette* commandPalette;
|
||||
CDragSource* commandSource;
|
||||
CAttachmentFrame* itsAttachmentFrame;
|
||||
|
||||
///////////////////////////////////////////////////////////////
|
||||
// Palette and attachment methods //
|
||||
///////////////////////////////////////////////////////////////
|
||||
|
||||
void initFrame(void);
|
||||
void initCommandPalette(void);
|
||||
void destroyCommandPalette(void);
|
||||
void destroyDragSource(void);
|
||||
void buildCommandPalettes(void);
|
||||
void regenerateCommandPalette(void);
|
||||
CStringRW retrieveCommand(void);
|
||||
|
||||
|
||||
///////////////////////////////////////////////////////////////
|
||||
// Status bar methods //
|
||||
///////////////////////////////////////////////////////////////
|
||||
|
||||
void initStatusBar(void);
|
||||
void setStatus(CStringRW theText);
|
||||
void resetStatus(void);
|
||||
|
||||
|
||||
///////////////////////////////////////////////////////////////
|
||||
// Text window methods //
|
||||
///////////////////////////////////////////////////////////////
|
||||
|
||||
void initTextWindows(void);
|
||||
|
||||
|
||||
///////////////////////////////////////////////////////////////
|
||||
// Help Method //
|
||||
///////////////////////////////////////////////////////////////
|
||||
|
||||
void showHelp(void);
|
||||
|
||||
|
||||
///////////////////////////////////////////////////////////////
|
||||
// Parameter retrieval methods (pops up dialog) //
|
||||
///////////////////////////////////////////////////////////////
|
||||
|
||||
CStringRW getParameters(void);
|
||||
CStringRW getTextCommand(void);
|
||||
|
||||
///////////////////////////////////////////////////////////////
|
||||
// Toolbar and enclosed view methods //
|
||||
///////////////////////////////////////////////////////////////
|
||||
|
||||
void activateButtons(void);
|
||||
|
||||
// PWRClassInfo
|
||||
};
|
||||
|
||||
#endif // G4XvtWin_H
|
||||
|
||||
@@ -0,0 +1,90 @@
|
||||
#---------------------------------------------------------------------
|
||||
#
|
||||
# file: makefile
|
||||
# author: XVT-Architect, XVT Software
|
||||
#
|
||||
#---------------------------------------------------------------------
|
||||
|
||||
#---------------------------------------------------------------------
|
||||
# System settings
|
||||
|
||||
# Modify the following according to your system setup:
|
||||
#
|
||||
# XVT_DSP_DIR path to the xvt directrorie
|
||||
# CC the name of your C++ compiler
|
||||
# LD linker
|
||||
# UIL uil compiler
|
||||
# SFX suffix of C++ source files
|
||||
|
||||
CC = CC
|
||||
LD = CC
|
||||
UIL = /usr/bin/X11/uil
|
||||
SFX = .cxx
|
||||
|
||||
#---------------------------------------------------------------------
|
||||
# Includes:
|
||||
|
||||
INCLUDE = -I. -I./factory \
|
||||
-I$(XVT_DSP_DIR)/include \
|
||||
-I/usr/include/Motif1.2 \
|
||||
-I/usr/include/X11R5
|
||||
|
||||
#---------------------------------------------------------------------
|
||||
# Libraries:
|
||||
|
||||
PWRLIBS = $(XVT_DSP_DIR)/lib/libxvtxmpwr450.a
|
||||
PTKLIBS = $(XVT_DSP_DIR)/lib/libxvtxmapi457.a -lxvtxmhb457 -lxvtxmba457
|
||||
LIBS = $(PWRLIBS) $(PTKLIBS) -lxvtxmrw -lMrm -lXm -lXt -lX11 -lPW -lm
|
||||
|
||||
#---------------------------------------------------------------------
|
||||
# Flags:
|
||||
|
||||
PWRFLAGS = -DSTDH -D_HPUX_SOURCE -DWSMTF -D__hpux -D__unix -D__STDC__
|
||||
CCFLAGS = -Aa +a1 $(PWRFLAGS) $(INCLUDE)
|
||||
LDFLAGS = -Wl,+s +a1 -L$(XVT_DSP_DIR)/lib -L/usr/lib/Motif1.2 -L/usr/lib/X11R5
|
||||
CURLFLAGS = -r mtf12 -s $(INCLUDE)
|
||||
UILFLAGS = -I/usr/include/Motif1.2
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
# Default make instructions:
|
||||
|
||||
.SUFFIXES: .url .uil .uid .o $(SFX) .h
|
||||
|
||||
.url.uil:
|
||||
$(XVT_DSP_DIR)/bin/curl $(CURLFLAGS) $<
|
||||
|
||||
.uil.uid:
|
||||
$(UIL) $(UILFLAGS) -o $@ $<
|
||||
|
||||
$(SFX).o:
|
||||
$(CC) $(CCFLAGS) -o $@ -c $<
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
# Targets for shell:
|
||||
APPNAME = GUI
|
||||
|
||||
# Shell and factory objects
|
||||
GENERATEDOBJECTS = \
|
||||
g4xvtgui.o \
|
||||
g4xvtdoc.o \
|
||||
XResMgr.o \
|
||||
g4xvtwin.o \
|
||||
cstartup.o \
|
||||
factory/factory.o \
|
||||
factory/faccb0.o \
|
||||
factory/faccb1.o \
|
||||
factory/faccb2.o \
|
||||
factory/faccb3.o \
|
||||
factory/faccb4.o \
|
||||
factory/classes.o
|
||||
|
||||
# other application objects
|
||||
# List all other object files which are needed for your application here
|
||||
APPNAMEOBJECTS =
|
||||
|
||||
OBJECTS = $(GENERATEDOBJECTS) $(APPNAMEOBJECTS)
|
||||
|
||||
$(APPNAME): $(OBJECTS) $(APPNAME).uil $(APPNAME).uid
|
||||
$(LD) $(LDFLAGS) -o $(APPNAME) $(OBJECTS) $(LIBS)
|
||||
|
||||
$(APPNAME).uil: $(APPNAME).url factory/images.url factory/strings.url factory/factory.url
|
||||
|
After Width: | Height: | Size: 1.3 KiB |
@@ -0,0 +1,487 @@
|
||||
Written by: Simon Prior
|
||||
Date: 25/08/97
|
||||
|
||||
GUI
|
||||
----
|
||||
|
||||
The purpose of this program is to be the first XVT/Geant4 GUI prototype.
|
||||
|
||||
Basic idea: Construct a prototype GUI which interacts with Geant 4.
|
||||
|
||||
Future use: After initial investigation into how XVT can interact etc with
|
||||
Geant, seeing what features I can use/exploit, it should be
|
||||
possible for future XVT GUI developers to build on the work
|
||||
done adding functionality and design ideas thus constructing one
|
||||
possible GUI for use with Geant 4. It should be different in
|
||||
design/features offered from other implementations so as to
|
||||
promote the use of XVT with Geant4 which will cost money (as XVT is
|
||||
not free) rather than the use of say TCL which is free.
|
||||
|
||||
Discoveries and implementation specifics :
|
||||
|
||||
For this part I shall go through the files which I have edited and
|
||||
explain each part - the idea as well as implementation details.
|
||||
|
||||
I will give an abstract view to show my overall idea and then a
|
||||
detailed one which will highlight implementation specifics.
|
||||
|
||||
The two files that do all the work regarding connection to Geant
|
||||
and handling of all user input are "g4xvtwin.h" and "g4xvtwin.cxx"
|
||||
- the 'window' files. These are both well commented.
|
||||
|
||||
Some of the other files have been added to (mainly for the floating
|
||||
dockable palettes - see my Geant4 web page or palette documentation
|
||||
in the 'palettes' directory).
|
||||
|
||||
I shall go through both files with a fine toothed comb and explain
|
||||
as much as possible. (each method will be looked at carefully - if
|
||||
need be).
|
||||
|
||||
==============================================================================
|
||||
|
||||
Abstract view of the prototype:
|
||||
-------------------------------
|
||||
|
||||
OK, start the XVT GUI, GUI then spawns the Geant benchmark program. The user
|
||||
interacts with the GUI via appropriate widgets selecting and executing
|
||||
commands, these are sent to Geant which does the processing, Geant then
|
||||
relays any information back to the user via the GUI.
|
||||
|
||||
==============================================================================
|
||||
|
||||
More Detailed view:
|
||||
-------------------
|
||||
|
||||
My main idea(s) for this interface:
|
||||
|
||||
Basically, the application starts (by executing the XVT GUI
|
||||
executable file).
|
||||
|
||||
This handles all the initialisation required for the IPC mechanism,
|
||||
it is in charge of creating the named pipes and opens them at the
|
||||
XVT end with the appropriate permissions on them.
|
||||
|
||||
Then it handles the startup of the Geant 'xvt.benchmark' file.
|
||||
|
||||
It basically forks off a process and execs the xvt.benchmark file.
|
||||
|
||||
See the xvt.benchmark documentation for the ideas behind that and a
|
||||
detailed description of what happens when it is executed.
|
||||
|
||||
==============================================================================
|
||||
|
||||
I will now cover some of the major parts and ideas of the interface before
|
||||
analysing the individual methods:
|
||||
|
||||
==============================================================================
|
||||
|
||||
The named pipes:
|
||||
----------------
|
||||
|
||||
This was the chosen IPC method after reviewing several IPC mechanisms (See
|
||||
the IPC section on my Geant4 web page). It works like the twoWay
|
||||
program - incorporating a timer in the XVT end to read the pipe, a suitable
|
||||
way of testing the pipe before reading it (blocking issues) etc - see the
|
||||
early work in the IPC section or the program code for details.
|
||||
|
||||
The data Structures:
|
||||
--------------------
|
||||
|
||||
Now, this was a new idea. I had to get all the command information from Geant
|
||||
and transfer it via the pipes and then use it to build a suitable dynamic
|
||||
widget at the XVT end. Therefore, the idea behind it all is simple, build a
|
||||
data structure at the Geant end and fill it with command information, then when
|
||||
requested by XVT, send all the information down the pipe. At the XVT end, parse
|
||||
this information into a data structure at this end and then build the widget
|
||||
etc using this data structures contained information.
|
||||
|
||||
The new data structures I defined were G4CommandData and G4ParameterData. (See
|
||||
the header file "g4xvtwin.h" for implementation specifics.
|
||||
|
||||
Some important issues were encountered. It became clear that a certain
|
||||
'protocol' had to be defined so that I could recognise command information etc
|
||||
- this will be explained when documenting the individual method in detail.
|
||||
|
||||
The Palettes:
|
||||
-------------
|
||||
|
||||
These were a new provided widget with XVT version 4.5 and were exactly what I
|
||||
required. (I was working to emulate their behaviour before the release came
|
||||
out). The best feature of them is that they are dynamic and can be created at
|
||||
run time etc - thus giving the flexibility needed for Geant.
|
||||
|
||||
As they are like an artists palette the first point is that you make a
|
||||
selection and it stays selected - this suited my idea well as I had the idea
|
||||
to have all the command information in one palette - i.e. select a command from
|
||||
this palette, then have a button which you press to 'Execute' the selected
|
||||
command. I have since added a 'Help' button which you can also press - this
|
||||
gives a small message about the selected command.
|
||||
|
||||
- This is my idea for command entry to date:
|
||||
|
||||
1.. Select command.
|
||||
2.. If help is required click help button for information.
|
||||
3.. If you are sure, press Execute which will dispatch the command to Geant.
|
||||
|
||||
Thus it gives a level of security so that selecting a command doesn't
|
||||
necessarily mean it gets executed - until you EXPLICITLY say so.
|
||||
|
||||
Command Retrieval:
|
||||
------------------
|
||||
|
||||
The idea behind this is quite clever. OK, firstly, on the geant side of
|
||||
things. This reads all the commands from the Geant command tree using 'get'
|
||||
methods from the Command tree class. All of the commands are read into a type
|
||||
I have defined - called G4CommandData - this basically holds all the
|
||||
information on a command and its parameters. (see data structures section
|
||||
mentioned earlier)
|
||||
|
||||
Now back to the GUI end. After this has initialised itself and listed all the
|
||||
available commands the user can click on a button to retrieve all the available
|
||||
commands from Geant. When this happens a command is sent from the GUI down the
|
||||
named pipes to Geant. When Geant receives this command it parses the command
|
||||
array at that end and writes all the information down the named pipe to XVT.
|
||||
|
||||
XVT also has the same data structure declared and basically reads all the
|
||||
information from the pipe into its own structure.
|
||||
|
||||
After this is done the floating command palette is constructed using the
|
||||
information contained in the data structure at the XVT end.
|
||||
|
||||
I have defined a protocol so that XVT recognises when the commands are coming
|
||||
down the pipe.
|
||||
|
||||
As the timer ticks and calls the DoTimer method this checks to see if there is
|
||||
anything present in the pipe - if so reads it and decides what to do with it.
|
||||
|
||||
When it receives the string "comTree" it knows that the commands are coming.
|
||||
|
||||
I basically bypass the timer for a while and then call some methods to deal
|
||||
with the incoming data. The first string that comes through is an integer
|
||||
which tells me exactly how many command entries there are - then a loop can
|
||||
be entered to fill the array at the XVT end with that number of entries.
|
||||
|
||||
All the appropriate casting and type changes are handled correctly. (i.e.
|
||||
converting from string to integer).
|
||||
|
||||
You have to be careful when reading the pipe that you check there is something
|
||||
present before actually reading it - especially in this case when order of
|
||||
information is critical - thats why I defined a method (getString) to handle
|
||||
correct reading of the named pipe. (it waits until thers is something present
|
||||
before reading and returning the string).
|
||||
|
||||
==============================================================================
|
||||
|
||||
Now I shall look at the header file g4xvtwin.h and then I shall look at
|
||||
the implementation file g4xvtwin.cxx in detail to explain what the methods
|
||||
do etc.
|
||||
|
||||
==============================================================================
|
||||
|
||||
g4xvtwin.h:
|
||||
-----------
|
||||
|
||||
First thing to note in this file is the #defines which define XvtToGeant and
|
||||
GeantToXvt. These are names I will use in my code for the named pipes which
|
||||
I set up for communication between the XVT executable and the Geant4 executable.
|
||||
|
||||
The next #define simply defines the file mode (i.e. appropriate UNIX
|
||||
permissions) to open the named pipes with.
|
||||
|
||||
After this come several #includes which include various functions I will
|
||||
use in the code.
|
||||
|
||||
After this I define 2 new types called 'G4parameterData' and 'G4commandData'.
|
||||
These are structures to hold information about commands.
|
||||
|
||||
After this are the usual method declarations and data member definitions
|
||||
etc. - These are commented.
|
||||
|
||||
******************************************************************************
|
||||
*************************** IMPORTANT ***************************************
|
||||
*** ***
|
||||
*** The declaration of 'G4commandData commandArray[200];' in the header ***
|
||||
*** file basically declares how many commands can be stored in the array ***
|
||||
*** and then used to create the command palette. ***
|
||||
*** IF during future use the GUI coredumps when creating the command ***
|
||||
*** palette it is most likely that there are greater that 200 commands ***
|
||||
*** - especially as commands are being added all the time. All you need ***
|
||||
*** to do is increase this value and everything will work fine again. ***
|
||||
*** ***
|
||||
******************************************************************************
|
||||
|
||||
==============================================================================
|
||||
|
||||
g4xvtwin.cxx:
|
||||
-------------
|
||||
|
||||
I shall cover the methods which I have written or added code to - the ones
|
||||
automatically generated are self explanatory and have good commenting (see
|
||||
file for more details).
|
||||
|
||||
The Constructor:
|
||||
----------------
|
||||
|
||||
Initialisation occurs here by calling several initialiser functions - see their
|
||||
own documentation later on (next).
|
||||
|
||||
initIndex:
|
||||
----------
|
||||
|
||||
This initialises the command base array indexing variables - very simple.
|
||||
|
||||
initStatusBar:
|
||||
--------------
|
||||
|
||||
This sets up the status bars fields with some initial values.
|
||||
|
||||
initTimer:
|
||||
----------
|
||||
|
||||
Starts the XVT timer (on every time interval (which the coder can alter) it
|
||||
activates the DoTimer method).
|
||||
|
||||
initIPC:
|
||||
--------
|
||||
|
||||
This sets the value of the pipe reading variable (i.e. how many bytes are
|
||||
read in a single read operation and then calls createNamedPipes and startSlave.
|
||||
|
||||
initFrame:
|
||||
----------
|
||||
|
||||
Creates an attachment frame and allows attachment to all sides.
|
||||
|
||||
createNamedPipes:
|
||||
-----------------
|
||||
|
||||
This method creates the named pipes required in the application.
|
||||
|
||||
It first creates the pipes and then opens them.
|
||||
|
||||
The XvtToGeant pipe with write permission only,
|
||||
the GeantToXvt with read permission only.
|
||||
|
||||
The program uses the errorHandler method to report errors because the
|
||||
program should terminate if IPC setup fails.
|
||||
|
||||
destroyNamedPipes:
|
||||
------------------
|
||||
|
||||
This method closes and unlinks all the open named pipes.
|
||||
|
||||
startSlave:
|
||||
-----------
|
||||
|
||||
This method forks and exec's the other process (xvt.benchmark - the Geant
|
||||
executable).
|
||||
|
||||
This method also uses the errorHandler to report errors because if the
|
||||
fork or Exec fail the program should terminate.
|
||||
|
||||
The fork and exec are UNIX specific - for more details on their use see a UNIX
|
||||
manual or man pages.
|
||||
|
||||
DoTimer:
|
||||
--------
|
||||
|
||||
Every time the timer ticks this method checks to see if the file descriptor
|
||||
can be read without blocking (i.e. there is something in the pipe), if
|
||||
there is it grabs the data from the pipe, if you are not in the process of
|
||||
reading all the commands from Geant it then checks if the string is equal to
|
||||
"comTree" which indicates all the commands are coming from Geant and
|
||||
different action should be taken. If it isn't comTree then it simply
|
||||
displays the string in the Main log area.
|
||||
|
||||
The different action to take is to call some other methods to do the reading of
|
||||
commands and building of the command palette. (discussed later.)
|
||||
|
||||
Refer to code for the implementation specifics.
|
||||
|
||||
errorHandler:
|
||||
-------------
|
||||
|
||||
A general purpose error handler. It can be called by any method. A string
|
||||
is passed so that this method can post a dialog box to the user stating
|
||||
where the program fault occurs then quit the GUI.
|
||||
|
||||
The key point is that this method should be called when processing should no
|
||||
longer continue i.e. the GUI should be killed.
|
||||
|
||||
writeData:
|
||||
----------
|
||||
|
||||
Writes the passed string to the Command log window and the XvtToGeant
|
||||
pipe - i.e. will send the string to Geant (commands!) for processing.
|
||||
|
||||
initCommandPalette:
|
||||
-------------------
|
||||
|
||||
Allocate storage space for a tool palette.
|
||||
|
||||
destroyCommandPalette:
|
||||
----------------------
|
||||
|
||||
Free up storage space allocated for the command palette.
|
||||
|
||||
buildCommandPalettes:
|
||||
---------------------
|
||||
|
||||
This method builds the palettes of commands available to the user.
|
||||
|
||||
This basically parses the commandArray that was received from Geant and
|
||||
builds up the command palette 'on-the-fly' from this information.
|
||||
|
||||
It checks the flag of the command in the array to see whether it is
|
||||
a 'directory', a command or a cascade. (this is denoted by the flag being a
|
||||
0, 1 or 2 and this is set at the Geant end when it reads in the commands).
|
||||
|
||||
Once it has this information it can decide how to handle it.. If it is a
|
||||
'directory' - i.e. a category of command it must have its own sub-palette
|
||||
so this can be constructed. If it is a command it must be a button in the
|
||||
current sub-palette and if it is a cascade it must be a sub-palette of the
|
||||
current palette - see code for implementation specifics.
|
||||
|
||||
destroyDragSource:
|
||||
------------------
|
||||
|
||||
This method destroys the space allocated for the drag source.
|
||||
|
||||
setStatus:
|
||||
----------
|
||||
|
||||
This method places the passed string into the status field of the status
|
||||
bar.
|
||||
|
||||
resetStatus:
|
||||
------------
|
||||
|
||||
This method completely blanks the status field of the status bar.
|
||||
|
||||
retrieveCommand:
|
||||
----------------
|
||||
|
||||
This method checks the command palette to see which button has been pressed
|
||||
then it will scan the command array to find the command that corresponds to
|
||||
the users selection and returns the command string to be sent to Geant.
|
||||
|
||||
It also tests to see if the command that is selected for execution requires a
|
||||
parameter and if so calls 'getParameters' to obtain this from the user.
|
||||
|
||||
initTextWindows:
|
||||
----------------
|
||||
|
||||
This method simply puts a title in the Text windows to start things off.
|
||||
|
||||
fillLocalArray:
|
||||
---------------
|
||||
|
||||
This method fills the command data structure at the XVT end with data that is
|
||||
being received from the Geant end. It uses the method 'getString' to grab the
|
||||
strings from the pipe without error.
|
||||
|
||||
showHelp:
|
||||
---------
|
||||
|
||||
This method is called when the user clicks on the 'help' button.
|
||||
|
||||
It looks which is the current selected tool and retrieves the guidance for
|
||||
that tool - then puts this in the text widget and a pop up window.
|
||||
|
||||
getParameters:
|
||||
--------------
|
||||
|
||||
This method retrieves parameters from the user via dialog boxes. - called by
|
||||
retrieveCommand.
|
||||
|
||||
getTextCommand:
|
||||
---------------
|
||||
|
||||
This method retrieves parameters from the user via dialog boxes. This method
|
||||
is very similar to 'getParameters' however this one is called if the user
|
||||
wishes to type a command in instead of using the command palette widget.
|
||||
|
||||
executeCommand:
|
||||
---------------
|
||||
|
||||
When the user clicks on the execute button this method is called.
|
||||
|
||||
It retrieves the command (with parameters if necessary) and writes it
|
||||
down the named pipe to Geant to deal with.
|
||||
|
||||
getString:
|
||||
----------
|
||||
|
||||
This method grabs the string that is located in the pipe and returns it
|
||||
to the caller - provided there is something present in the pipe.
|
||||
|
||||
activateButtons:
|
||||
----------------
|
||||
|
||||
This method enables the 'exec' buttons on the toolbar. It is called just
|
||||
after the user has retrieved the commands and built the widget.
|
||||
|
||||
It first enables the buttons and then refreshes the screen by redrawing
|
||||
them.
|
||||
|
||||
I have tried to limit the mistakes a user could make and this is a very good
|
||||
way of doing just that - by disabling buttons/widgets etc that could cause
|
||||
problems if pressed/clicked on at the wrong time.
|
||||
|
||||
==============================================================================
|
||||
|
||||
NOTE: Any code not mentioned here is self explanatory and well commented.
|
||||
|
||||
==============================================================================
|
||||
|
||||
Now I a couple of XVT specific discoveries to mention:
|
||||
|
||||
DISCOVERY 1:
|
||||
|
||||
There is some sort of problem with Dialog boxes and floating dockable palettes.
|
||||
|
||||
I had a palette which contained a button, when this button was pressed it
|
||||
called one of the pre-defined dialogs, this however caused a lock up concerning
|
||||
the mouse - I couldn't get control back, the dialog seemed to keep it.
|
||||
What happened exactly was when you clicked the button down it didn't pop up
|
||||
again thus it wasn't receiving the mouse up event. When you did click the
|
||||
mouse again however it spawned the dialog - again and again, it sort of
|
||||
entered a loop repeatedly spawning the dialog. - Technical support said that
|
||||
the dialog must have been inadvertently destroying the mouse handlers.
|
||||
|
||||
DISCOVERY 2:
|
||||
|
||||
You cannot have a toolbar with buttons in and a CAttachmentFrame which
|
||||
encomapasses the whole window because if you do, the CAttachmentFrame
|
||||
obscures all of the mouse events from reaching the toolbar - thus none
|
||||
of the buttons react.
|
||||
|
||||
A solution to this problem is to have a CAttachmentFrame that doesn't
|
||||
cover the entire window, just a part of it (this can be acheived with
|
||||
a certain constructor - see code) - thus the events can then
|
||||
get to the toolbar.
|
||||
|
||||
DISCOVERY 3:
|
||||
|
||||
For some reason you cannot pass a WINDOW variable between a view and a
|
||||
document - when I tried it the program kept core dumping on this.
|
||||
|
||||
DISCOVERY 4:
|
||||
|
||||
The Select() system call has been dropped. The reason is that it was failing
|
||||
for some reason which I couldn't work out. It kept returning TRUE all the
|
||||
time when I used it to see if the named pipe was ready for reading and this
|
||||
was not always the case.
|
||||
|
||||
The solution I came up with was to use a function from the ioctl library.
|
||||
The function I used is the following:
|
||||
|
||||
int nbytes;
|
||||
ioctl(fd_XvtToGeant, FIONREAD, &nbytes);
|
||||
|
||||
This is much better than select because I only have a single file descriptor
|
||||
to test and using this is far shorter and easier to code/understand than the
|
||||
select stuff.
|
||||
|
||||
==============================================================================
|
||||
S.Prior - August '97
|
||||
|
After Width: | Height: | Size: 1.3 KiB |
|
After Width: | Height: | Size: 1.3 KiB |