49 typedef intptr_t ssize_t;
50 extern ssize_t getline(
char **lineptr,
size_t *n, FILE *stream);
90 for (
c = getc(
cellp);
c != EOF;
c = getc(
cellp))
if (
c ==
'\n') i ++;
91 j = (format == 0 || format == 2) ? 1 : (format == 1) ? 2 : 3;
98 add_cell_info (g_strdup_printf (
"Wrong file format - %d steps found in cell file", k));
109 if (! j || format == 1)
111 getline (& line, & length,
cellp);
112 this_line = g_strdup_printf (
"%s", line);
122 add_cell_info (g_strdup_printf (
"Wrong file format - error at step %d !", i+1));
130 add_cell_info (g_strdup_printf (
"Wrong file format - error at step %d !", i+1));
138 add_cell_info (g_strdup_printf (
"Wrong file format - error at step %d !", i+1));
148 if (! j || format == 3)
150 getline (& line, & length,
cellp);
151 this_line = g_strdup_printf (
"%s", line);
161 add_cell_info (g_strdup_printf (
"Wrong file format - error at step %d !", i+1));
169 add_cell_info (g_strdup_printf (
"Wrong file format - error at step %d !", i+1));
177 add_cell_info (g_strdup_printf (
"Wrong file format - error at step %d !", i+1));
235 cellp = fopen (filename,
"r");
282 g_debug (
"CELL-NPT:: Impossible to retrieve cell parameters !");
Binding to the Fortran90 subroutines.
Function declarations for the crystal builder.
double string_to_double(gpointer string)
convert string to double
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
Functions declaration to read atomic coordinates.