*"表題 編集記述を作成 GTOOL3(GUEAXN)
*
*"履歴 90/09/20 沼口  敦
*
*
*********************************************************************
*"         << 編集記述を作成  >>
*********************************************************************
      SUBROUTINE GUEAXN
     I         ( HAXIS , HED   , HET   ,
     I           ISTR  , IEND  ,
     O           HEDIT , HETTL           )
*
      CHARACTER  HAXIS         *(*)          !" 軸名称
      CHARACTER  HED           *(*)          !" 編集記述子接頭
      CHARACTER  HET           *(*)          !" 編集タイトル接尾
      INTEGER    ISTR                        !" 格子番号始め
      INTEGER    IEND                        !" 格子番号終り
      CHARACTER  HEDIT         *(*)          !" 編集記述子
      CHARACTER  HETTL         *(*)          !" 編集タイトル
*
#ifdef SYS_IBMS
      INCLUDE    (GZSIZE)                    !" NCC, NDC
#else
#include         "gzsize.F"                  !" NCC, NDC
#endif
      CHARACTER  HNUM1         *(NCC)
      CHARACTER  HNUM2         *(NCC)
#ifdef SYS_IBMS
      INCLUDE   (GZIWRK)                     !" NW: 軸ワークの大きさ
#else
#include        "gziwrk.F"                   !" NW: 軸ワークの大きさ
#endif
      CHARACTER  HHEADZ ( NDC )*(NCC)
      CHARACTER  HHEADA ( NDC )*(NCC)
      REAL       AXISZ  ( NW )
      LOGICAL    OSUBCK
*
*"         < 1. 編集略記号 >
*
      NHE  = LENC ( HED   )
      WRITE ( HNUM1, '(I5)' ) ISTR
      CALL CLADJ  ( HNUM1 )
      NH1  = LENC ( HNUM1 )
      IF ( ISTR .NE. IEND ) THEN
         WRITE ( HNUM2, '(I5)' ) IEND
         CALL CLADJ  ( HNUM2 )
         HEDIT = HED(1:NHE)//HNUM1(1:NH1)//'-'//HNUM2
      ELSE
         HEDIT = HED(1:NHE)//HNUM1
      ENDIF
*
*"         < 2. 編集タイトル >
*
      CALL GHPSET ( HHEADZ, 'IDFM' , 0     )
      CALL GHCSET ( HHEADZ, 'AITM1', HAXIS )
      CALL GHPSET ( HHEADZ, 'ASTR1', ISTR  )
      CALL GHPSET ( HHEADZ, 'AEND1', IEND  )
      CALL GTPGET ( 'SUBCHK', OSUBCK )
      CALL GTSIZE ( HHEADA  ,  NW     )
      CALL GUQAXV
     I            ( HHEADZ, 1     , 'LOC' ,
     O              HHEADA, AXISZ , IEOD  )
      CALL GTPSET ( 'SUBCHK', OSUBCK )
*
      NHA    = LENC( HAXIS )
*
      IF ( IEOD .EQ. 0 ) THEN
*
         CALL CHVAL  ( 'D', AXISZ(1), HNUM1 )
         NH1 = LENC( HNUM1 )
*
         IF ( ISTR .NE. IEND ) THEN
            CALL CHVAL  ( 'D', AXISZ(IEND-ISTR+1), HNUM2 )
            HETTL = HAXIS(1:NHA)//'='//HNUM1(1:NH1)//'-'//HNUM2
         ELSE
            HETTL = HAXIS(1:NHA)//'='//HNUM1
         ENDIF
*
      ELSE
         HETTL = HAXIS(1:NHA)//' '//HET
      ENDIF
*
      RETURN
      END
