ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/group/trunk/OOPSE-4/src/applications/staticProps/StaticPropsCmd.c
(Generate patch)

Comparing trunk/OOPSE-4/src/applications/staticProps/StaticPropsCmd.c (file contents):
Revision 2782 by xsun, Mon May 22 15:30:42 2006 UTC vs.
Revision 2783 by xsun, Thu Jun 1 18:06:33 2006 UTC

# Line 62 | Line 62 | void clear_given (struct gengetopt_args_info *args_inf
62    args_info->theta_omega_given = 0 ;
63    args_info->gxyz_given = 0 ;
64    args_info->p2_given = 0 ;
65 +  args_info->rp2_given = 0 ;
66    args_info->scd_given = 0 ;
67    args_info->density_given = 0 ;
68    args_info->slab_density_given = 0 ;
# Line 140 | Line 141 | cmdline_parser_print_help (void)
141    printf("%s\n","      --theta_omega             g(cos(theta), cos(omega))");
142    printf("%s\n","      --gxyz                    g(x, y, z)");
143    printf("%s\n","      --p2                      p2 order parameter (--sele1 and --sele2 must be \n                                  specified)");
144 +  printf("%s\n","      --rp2                     rp2 order parameter (--sele1 and --sele2 must \n                                  be specified)");
145    printf("%s\n","      --scd                     scd order parameter(either --sele1, --sele2, \n                                  --sele3 are specified or --molname, --begin, \n                                  --end are specified)");
146    printf("%s\n","      --density                 density plot (--sele1 must be specified)");
147    printf("%s\n","      --slab_density            slab density (--sele1 must be specified)");
# Line 426 | Line 428 | cmdline_parser_file_save(const char *filename, struct
428    }
429    if (args_info->p2_given) {
430      fprintf(outfile, "%s\n", "p2");
431 +  }
432 +  if (args_info->rp2_given) {
433 +    fprintf(outfile, "%s\n", "rp2");
434    }
435    if (args_info->scd_given) {
436      fprintf(outfile, "%s\n", "scd");
# Line 484 | Line 489 | reset_group_staticProps(struct gengetopt_args_info *ar
489    args_info->theta_omega_given = 0 ;
490    args_info->gxyz_given = 0 ;
491    args_info->p2_given = 0 ;
492 +  args_info->rp2_given = 0 ;
493    args_info->scd_given = 0 ;
494    args_info->density_given = 0 ;
495    args_info->slab_density_given = 0 ;
# Line 599 | Line 605 | cmdline_parser_internal (int argc, char * const *argv,
605          { "theta_omega",        0, NULL, 0 },
606          { "gxyz",       0, NULL, 0 },
607          { "p2", 0, NULL, 0 },
608 +        { "rp2",        0, NULL, 0 },
609          { "scd",        0, NULL, 0 },
610          { "density",    0, NULL, 0 },
611          { "slab_density",       0, NULL, 0 },
# Line 1035 | Line 1042 | cmdline_parser_internal (int argc, char * const *argv,
1042                continue;
1043              local_args_info.p2_given = 1;
1044              args_info->p2_given = 1;
1045 +            if (args_info->staticProps_group_counter && override)
1046 +              reset_group_staticProps (args_info);
1047 +            args_info->staticProps_group_counter += 1;
1048 +            break;
1049 +          }
1050 +          /* rp2 order parameter (--sele1 and --sele2 must be specified).  */
1051 +          else if (strcmp (long_options[option_index].name, "rp2") == 0)
1052 +          {
1053 +            if (local_args_info.rp2_given)
1054 +              {
1055 +                fprintf (stderr, "%s: `--rp2' option given more than once%s\n", argv[0], (additional_error ? additional_error : ""));
1056 +                goto failure;
1057 +              }
1058 +            if (args_info->rp2_given && ! override)
1059 +              continue;
1060 +            local_args_info.rp2_given = 1;
1061 +            args_info->rp2_given = 1;
1062              if (args_info->staticProps_group_counter && override)
1063                reset_group_staticProps (args_info);
1064              args_info->staticProps_group_counter += 1;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines