Ignore:
Timestamp:
Feb 16, 2009, 10:14:30 AM (15 years ago)
Author:
garnier
Message:

en test de gl2ps. Problemes de libraries

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/documents/UserDoc/DocBookUsersGuides/ForApplicationDeveloper/xml/GettingStarted/graphicalUserInterface.xml

    r904 r921  
    2929The "intercoms" category
    3030provides an expandable command interpreter. It is the key mechanism
    31 of Geant4 to realize user interactions of all categories without
     31of Geant4 to realize secure user interactions of all categories without
    3232being annoyed by the dependencies among categories. The direct use
    3333of Geant4 classes in a C++ program offers a first ground level of
     
    3636hard-coded in the program.
    3737</para>
     38
     39
    3840
    3941</sect3>
     
    5254the interfaces category. This interfacing strategy opens an
    5355important door towards various user interface tools and allows
    54 Geant4 to utilize the state-of-the-art GUI tools such as Motif and
    55 Java, etc..The richness of the collaboration has permitted for
    56 different groups to offer various user interfaces to the Geant4
     56Geant4 to utilize the state-of-the-art GUI tools such as Motif, Qt,
     57and Java etc..The richness of the collaboration has permitted for
     58developers to offer various user interfaces to the Geant4
    5759command system. Currently available are the following;
    5860
     
    6769  </para></listitem>
    6870  <listitem><para>
    69   GAG, a fully Graphical User Interface and its extension
     71  GAG, a fully Graphical User Interface and its network extension
    7072  GainServer of the client/server type.
    7173  </para></listitem>
     
    7678Full implementation of the character
    7779terminals (1 and 2) is included in the standard Geant4 distribution
    78 in the <literal>source/interfaces/basic</literal> directory. As for GAG
    79 with rich GUI functionalities, its front-end classes are included
    80 in the Geant4 distribution in the source/interfaces/GAG directory.
    81 The corresponding GUI package is available either from the author's
    82 Web pages (see URL below) or in the distributed package under the
    83 <literal>environments/MOMO</literal> directory.
     80in the <literal>source/interfaces/basic</literal> directory. As for GAG,
     81the front-end class is included
     82in the Geant4 distribution in the source/interfaces/GAG directory,
     83while its partner GUI package MOMO.jar is available in the standard Geant4 distribution
     84under the
     85<literal>environments/MOMO</literal> directory. MOMO.jar, Java archive file, contains
     86not only GAG, but also GGE and other helper packages.
     87Supplementary information is available
     88from the author's Webpage(see URL below).
    8489</para>
    8590
    8691<para>
    8792GAG, GainServer's client GUI Gain:
    88 <ulink url="http://erpc1.naruto-u.ac.jp/~geant4">
    89 http://erpc1.naruto-u.ac.jp/~geant4
     93<ulink url="http://www-geant4.kek.jp/~yoshidah">
     94http://www-geant4.kek.jp/~yoshidah
    9095</ulink>
    9196</para>
     
    238243A command box is at disposal for entering or recalling Geant4 commands.
    239244Command completion by typing &amp;ldquo;TAB&amp;rdquo; key is
    240 available on the command line. The shellcommands "exit, cont,
     245available on the command line. The shell commands "exit, cont,
    241246help, ls, cd..." are also supported. A menu bar could be customized
    242247through the <emphasis>AddMenu</emphasis> and
     
    287292
    288293<para>
    289 They are the front-end classes of Geant4 which interface with their
    290 respective graphical user interfaces, GAG (Geant4 Adaptive GUI) and Gain
    291 (Geant4 adaptive interface for network). While GAG must run on the same
     294They are the front-end classes of Geant4 which make connection with their
     295respective graphical user interfaces, GAG (Geant4 Adaptive GUI) via pipe, and Gain
     296(Geant4 adaptive interface for network) via sockets. While GAG must run on the same
    292297system (Windows or Unixen) as a Geant4 application, Gain can run on a
    293 remote system (Windows, Linux, etc.) to which JVM (Java Virtual
    294 Machine) is installed. A Geant4 application is invoked on a Unix
     298remote system (Windows, Linux, etc.) in which JRE (Java Runtime
     299Environment) is installed. A Geant4 application is invoked on a Unix
    295300(Linux) system and behaves as a network server. It opens a port,
    296301waiting the connection from the Gain. Gain is capable to connect to
     
    300305
    301306<para>
    302 Client GUI, GAG and Gain have almost similar look-and-feel. So,
    303 GAG's functionalities are briefly introduced here. Please refer to
    304 the above URL for details and to download the client GUIs.
    305 </para>
    306 
    307 <para>
    308 GAG is a Graphical User Interface tool with which user
    309 can set parameters and execute commands. It is adaptive, since GAG
    310 reflects the internal states of Geant4 that is a state machine. GAG
    311 is based on the server-client model; GAG is the server, while
    312 Geant4 executables are clients. Hence, GAG does nothing by itself
    313 and it must invoke an executable simulation program. Geant4's
     307Client GUIs, GAG and Gain have almost similar look-and-feel. So,
     308GAG's functionalities are briefly explained here. Please refer to
     309the above URL for details.
     310</para>
     311
     312<para>
     313Using GAG, user
     314can select a command, set its parameters and execute it. It is adaptive, in the sense that it
     315reflects the internal states of Geant4 that is a state machine. So, GAG  always provides users with
     316the Geant4 commands which may be added, deleted, enabled or disabled during a session. GAG does nothing by itself but to play an intermediate between user and
     317 an executable simulation program via pipes. Geant4's
    314318front-end class <emphasis>G4UIGAG</emphasis> must be instantiated to
    315 communicate with GAG. This runs on Linux and Windows 2000.
    316 GAG is written in Java and
    317 its Jar (Java Archive) file is available from the above URL. See
    318 the same pages to know how to install and run Java programs.
    319 </para>
     319communicate with GAG. GAG runs on Linux and Windows. If MOMO.jar is in your
     320CLASSPATH, it can be run by a command;
     321</para>
     322
     323<informalexample>
     324<programlisting>
     325   %java -jar MOMO.jar
     326</programlisting>
     327</informalexample>
    320328
    321329<para>
     
    329337    a GEANT4 process and to exit GAG. Upon the normal exit or an
    330338    unexpected death of the Geant4 process, GAG window are
    331     automatically reset to accept another GEANT4 executable.   
     339    automatically reset to run another GEANT4 executable.   
    332340    </listitem>
    333341  </varlistentry>
     
    335343    <term>GEANT4 Command tree:</term>
    336344    <listitem>
    337     Upon the establishment of the pipe with the GEANT4 process, GAG displays
    338     the command menu tree whose look and feel is quite similar to
    339     Windows' file browser. Disabled commands are shown opaque. GAG
     345    Upon the establishment of the pipe connection with the GEANT4 process, GAG displays
     346    the command menu, using expandable tree browser whose look and feel is similar to
     347    a file browser. Disabled commands are shown in opaque. GAG
    340348    doesn &amp;rsquo;t display commands that are just below the root of
    341349    the command hierarchy. Direct type-in field is available for such
     
    364372    Log can be redirected to the terminal (xterm or cygwin
    365373    window) from which GAG is invoked. It can be interrupted as will,
    366     in the middle of long session of execution. Log can be saved to a
     374    in the middle of a long session of execution. Log can be saved to a
    367375    file independent of the above redirection . GAG displays warning or
    368376    error messages from GEANT4 in a pop-up warning widget.
     
    383391
    384392<para>
    385 The libraries that don't depend on external packages are made by default.
     393The libraries that don't depend on external packages are created by default, using
     394Geant4 configure scripts.
    386395They include <emphasis>G4UIterminal</emphasis>, <emphasis>G4UItcsh</emphasis>
    387396and <emphasis>G4UIGAG</emphasis> in libraries <emphasis>libG4UIbasic.a/so</emphasis> and
     
    396405<emphasis role="bold">G4UI_BUILD_XAW_SESSION</emphasis> or
    397406<emphasis role="bold">G4UI_BUILD_WIN32_SESSION</emphasis> must be set
    398 explicitly.
     407explicitly before creating libraries.
    399408</para>
    400409
     
    405414
    406415<para>
    407 Build scheme of the user interface libraries is
     416The scheme of building the user interface libraries is
    408417specified in "$G4INSTALL/config/G4UI_BUILD.gmk" makefile and the
    409418dependencies on the external packages are specified in
     
    416425<sect2 id="sect.HowToSetUpInter.HowToUseInter">
    417426<title>
    418 How to Use the Interface
     427How to Use the Interface in Your Application
    419428</title>
    420429
     
    422431To use a given interface
    423432(<literal>G4UIxxx</literal> where <literal>xxx = terminal,Xm, Xaw, Win32,
    424 GAG, GainServer</literal>) in a user's program, he has the following
    425 lines in his main program;
     433GAG, GainServer</literal>) in your program, you have following
     434lines in your main program;
    426435
    427436<informalexample>
    428437<programlisting>
    429 // to include the class definition in his main program:
     438// to include the class definition in the main program:
    430439   #include "G4Uixxx.hh"
    431 // to instantiate a session of his choice and start the session
     440// to instantiate a session of your choice and start the session
    432441   G4UIsession* session = new G4UIxxx;
    433442   session-&gt;SessionStart();
    434 // the line next to the "SessionStart" is usually to finish the session
     443// the line next to the "SessionStart" is necessary to finish the session
    435444   delete session;
    436445</programlisting>
     
    466475
    467476<para>
    468 Again, environment variable selects a given interface. But for your
    469 convenience, some of them are set defaults.
     477Again, environment variable must be preset to select a given interface. But for your
     478convenience, some of them are set by defaults.
    470479
    471480<itemizedlist spacing="compact">
     
    473482   <emphasis>G4UIterminal</emphasis>, <emphasis>G4UItcsh</emphasis>,
    474483   <emphasis>G4UIGAG</emphasis> and <emphasis>G4UIGainServer</emphasis>
    475    can be used without any environment
     484   can be used without setting any environment
    476485   variables. Sessions not needing external packages or libraries are
    477486   always built (see "G4UI_BUILD.gmk") and linked, so the user can
     
    497506   <listitem><para>
    498507   If the environment variable <emphasis role="bold">G4UI_NONE</emphasis> is
    499    set, no externa ibraries are selected. Also, for your convenience, if any
     508   set, no external libraries are selected. Also, for your convenience, if any
    500509   <emphasis role="bold">G4UI_USE_XXX</emphasis> environment variable is set,
    501510   then the corresponding C-pre-processor flag is also set. However, if the
Note: See TracChangeset for help on using the changeset viewer.