48 typedef intptr_t ssize_t;
49 extern ssize_t getline(
char **lineptr,
size_t *n, FILE *stream);
91 for (
c = getc(
cellp);
c != EOF;
c = getc(
cellp))
if (
c ==
'\n') i ++;
92 j = (format == 0 || format == 2) ? 1 : (format == 1) ? 2 : 3;
99 add_cell_info (g_strdup_printf (
"Wrong file format - %d steps found in cell file", k));
110 if (! j || format == 1)
112 getline (& line, & length,
cellp);
113 this_line = g_strdup_printf (
"%s", line);
123 add_cell_info (g_strdup_printf (
"Wrong file format - error at step %d !", i+1));
131 add_cell_info (g_strdup_printf (
"Wrong file format - error at step %d !", i+1));
139 add_cell_info (g_strdup_printf (
"Wrong file format - error at step %d !", i+1));
149 if (! j || format == 3)
151 getline (& line, & length,
cellp);
152 this_line = g_strdup_printf (
"%s", line);
162 add_cell_info (g_strdup_printf (
"Wrong file format - error at step %d !", i+1));
170 add_cell_info (g_strdup_printf (
"Wrong file format - error at step %d !", i+1));
178 add_cell_info (g_strdup_printf (
"Wrong file format - error at step %d !", i+1));
236 cellp = fopen (filename,
"r");
283 g_debug (
"CELL-NPT:: Impossible to retrieve cell parameters !");
Binding to the Fortran90 subroutines.
Function declarations for the crystal builder.
Global variable declarations Global convenience function declarations Global data structure defin...
void show_error(char *error, int val, GtkWidget *win)
show error message
Messaging function declarations.
integer(kind=c_int) function lattice(totl, lid, vectors, vmod, angles, lat, cfrac, apbc)
Function declarations for reading atomes project file Function declarations for saving atomes proje...
int cell_get_lattice(int format)
get the lattice parameters format from the file
void add_cell_info(gchar *info)
append information message to the cell information
int open_cell_file(int format, gchar *filename)
open the file that contains the cell parameters