home *** CD-ROM | disk | FTP | other *** search
/ FM Towns: Free Software Collection 5 / FREESOFT.BIN / mopterm / fapx405b / fapxschg.plp < prev    next >
Text File  |  1992-08-19  |  3KB  |  126 lines

  1. /************************************************************************
  2. *    設定情報の変更処理                        *
  3. *************************************************************************/
  4. /*    ファイルからユーザー設定情報を読み込む    */
  5. %LOADset{
  6.     var    newfile    [64];
  7.     SNDMSG({erande_f.snd});
  8.     footnote({ユーザー設定情報を読み込むファイルを指定して下さい});
  9.     newfile:=@filesel({USR});
  10.     case    (newfile<>{},
  11.         {Yes},
  12.         {
  13.         %newdir    @getcdir;
  14.         case    (@nochar(newdir)==3,
  15.             {Yes},{newfile:=newdir|newfile},
  16.             {No},{newfile:=newdir|{\}|newfile});
  17.         case    (@filechk(newfile),
  18.             {Yes},
  19.             {
  20.             %ExcPilot {#}|newfile;
  21.             ExcPilot;
  22.             init;
  23.             SETFILE1:=@tail(newfile,{\});
  24.             }
  25.             );
  26.         }
  27.         );
  28.     setcdir(CDIR);
  29.     };
  30.  
  31. /*    ファイルからNIFTY設定情報を読み込む    */
  32. %LOADnif{
  33.     var    newfile    [64];
  34.     SNDMSG({erande_f.snd});
  35.     footnote({NIFTYでの処理の設定を読み込むファイルを指定して下さい});
  36.     newfile:=@filesel({NIF});
  37.     case    (newfile<>{},
  38.         {Yes},
  39.         {
  40.         %newdir    @getcdir;
  41.         case    (@nochar(newdir)==3,
  42.             {Yes},{newfile:=newdir|newfile},
  43.             {No},{newfile:=newdir|{\}|newfile});
  44.         case    (@filechk(newfile),
  45.             {Yes},
  46.             {
  47.             %ExcPilot {#}|newfile;
  48.             ExcPilot;
  49.             setcdir(CDIR);
  50.             SETFILE2:=@tail(newfile,{\});
  51.             }
  52.             );
  53.         }
  54.         );
  55.     setcdir(CDIR);
  56.     };
  57.  
  58. /*    ファイルからユーザー設定情報とNIFTY設定情報を読み込む    */
  59. %LOADall{
  60.     var    newfile1[64];
  61.     var    newfile2[64];
  62.     SNDMSG({erande_f.snd});
  63.     footnote({設定を読み込むファイル名を指定して下さい});
  64.     newfile1:=@filesel({USR});
  65.     case    (newfile1<>{},
  66.         {Yes},
  67.         {
  68.         %newdir    @getcdir;
  69.         case    (@nochar(newdir)==3,
  70.             {Yes},{newfile1:=newdir|newfile1},
  71.             {No},{newfile1:=newdir|{\}|newfile1});
  72.         newfile2:=@body(newfile1,,{.})|{.NIF};
  73.         case    (@filechk(newfile1) && @filechk(newfile2),
  74.             {Yes},
  75.             {
  76.             %ExcPilot {#}|newfile1|{;#}|newfile2;
  77.             ExcPilot;
  78.             init;
  79.             setcdir(CDIR);
  80.             SETFILE1:=@tail(newfile1,{\});
  81.             SETFILE2:=@tail(newfile2,{\});
  82.             },
  83.             {No},
  84.             {
  85.             SNDMSG({okasi_f.snd});
  86.             display({ユーザー設定ファイル(*.USR)とNIFTY設定ファイル(*.NIF)}|
  87.                 {の両方が同一ディレクトリに必要です\n});
  88.             wait(2);
  89.             }
  90.             );
  91.         }
  92.         );
  93.     setcdir(CDIR);
  94.     };
  95.  
  96. /*    設定を元に戻す    */
  97. %CANCEL    {
  98.     setcdir(CDIR);
  99.     #FAPXSET.SET;
  100.     #FAPXNIF.SET;
  101.     init;
  102.     setcdir(CDIR);
  103.     SETFILE1:={標準設定};
  104.     SETFILE2:={標準設定};
  105.     };
  106.  
  107. %SETCHNG{
  108.     loop    ({
  109.         SNDMSG({erande_f.snd});
  110.         footnote({現在のユーザー設定ファイル=}|SETFILE1|
  111.                 {  NIFTY設定ファイル=}|SETFILE2);
  112.         select    ({どの設定情報をファイルから読み込みますか?},
  113.             Wtime4,{im({No})},
  114.             {      ユーザー設定情報      },{LOADset;im({Yes})},
  115.             { NIFTYでの処理設定情報 },{LOADnif;im({Yes})},
  116.             {         両方の設定         },{LOADall;im({Yes})},
  117.             {    両方の設定を元に戻す    },{CANCEL;im({Yes})},
  118.             {         終      了         },{im({No})}
  119.             );
  120.         });
  121.     display({\n現在のユーザー設定ファイル=}|SETFILE1|
  122.         {  NIFTY設定ファイル=}|SETFILE2|{\n});
  123.     };
  124.  
  125. SETCHNG;
  126.