* Contributors: Details at https://graphviz.org
*************************************************************************/
-#ifndef BinaryHeap_H
-#define BinaryHeap_H
+#pragma once
#include <sparse/general.h>
#include <sparse/IntStack.h>
void BinaryHeap_print(BinaryHeap h, void (*pnt)(void*));
void BinaryHeap_sanity_check(BinaryHeap h);
-
-#endif
* Contributors: Details at https://graphviz.org
*************************************************************************/
-#ifndef DOTIO_H
-#define DOTIO_H
+#pragma once
#include <cgraph.h>
#include <sparse/SparseMatrix.h>
void attached_clustering(Agraph_t* g, int maxcluster, int clustering_scheme);
int Import_dot_splines(Agraph_t* g, int *ne, char ***xsplines);
-#endif
* Contributors: Details at https://graphviz.org
*************************************************************************/
-#ifndef IntStack_H
-#define IntStack_H
+#pragma once
#include <stddef.h>
int IntStack_pop(IntStack s, int *flag);/* remove the last item. If none exist, flag = -1, and return -1. */
void IntStack_print(IntStack s);
-
-#endif
* Contributors: Details at https://graphviz.org
*************************************************************************/
-#ifndef LINKED_LIST_H
-#define LINKED_LIST_H
+#pragma once
typedef struct SingleLinkedList_struct* SingleLinkedList;
DoubleLinkedList DoubleLinkedList_get_next(DoubleLinkedList l);
void DoubleLinkedList_delete_element(DoubleLinkedList l, void (*linklist_deallocator)(void*), DoubleLinkedList *head);
-#endif
* Contributors: Details at https://graphviz.org
*************************************************************************/
-#ifndef QUAD_TREE_H
-#define QUAD_TREE_H
+#pragma once
#include <sparse/LinkedList.h>
#include <stdio.h>
void QuadTree_get_nearest(QuadTree qt, real *x, real *ymin, int *imin, real *min, int *flag);
QuadTree QuadTree_new_in_quadrant(int dim, real *center, real width, int max_level, int i);
-
-#endif
*
* Contributors: Details at https://graphviz.org
*************************************************************************/
-#ifndef SPARSEMATRIX_H
-#define SPARSEMATRIX_H
+
+#pragma once
#include <sparse/general.h>
#include <stdio.h>
#define SparseMatrix_known_undirected(A) test_flag((A)->property, MATRIX_UNDIRECTED)
#define SparseMatrix_known_symmetric(A) test_flag((A)->property, MATRIX_SYMMETRIC)
#define SparseMatrix_known_strucural_symmetric(A) test_flag((A)->property, MATRIX_PATTERN_SYMMETRIC)
-
-#endif
* Contributors: Details at https://graphviz.org
*************************************************************************/
-#ifndef CLUSTERING_H
-#define CLUSTERING_H
+#pragma once
typedef struct Multilevel_Modularity_Clustering_struct *Multilevel_Modularity_Clustering;
*/
void modularity_clustering(SparseMatrix A, int inplace, int maxcluster, int use_value,
int *nclusters, int **assignment, real *modularity, int *flag);
-
-#endif
* Contributors: Details at https://graphviz.org
*************************************************************************/
-#ifndef COLOR_PALLETE_H
-#define COLOR_PALLETE_H
+#pragma once
+
#include "stdio.h"
enum {MAX_COLOR = 1001};
extern float palette_sequential_singlehue_red_lighter[1001][3];
extern float palette_adam_blend[1001][3];
extern float palette_adam[11][3];
-
-#endif
-
-
* Contributors: Details at https://graphviz.org
*************************************************************************/
-#ifndef COLORUTIL_H
-#define COLORUTIL_H
+#pragma once
#include <color.h>
/* dimension of cstring must be >=7 */
char* hue2rgb(real hue, char *color);
-
-#endif
* Contributors: Details at https://graphviz.org
*************************************************************************/
-#ifndef GENERAL_H
-#define GENERAL_H
+#pragma once
#include <stdlib.h>
#include <stdio.h>
char *strip_dir(char *s);
void scale_to_box(real xmin, real ymin, real xmax, real ymax, int n, int dim, real *x);
-
-#endif
-
-
-
* Contributors: Details at https://graphviz.org
*************************************************************************/
-#ifndef MG_H
-#define MG_H
+#pragma once
typedef struct Multilevel_MQ_Clustering_struct *Multilevel_MQ_Clustering;
*/
void mq_clustering(SparseMatrix A, int inplace, int maxcluster, int use_value,
int *nclusters, int **assignment, real *mq, int *flag);
-
-#endif
* Contributors: Details at https://graphviz.org
*************************************************************************/
-#ifndef VECTOR_H
-#define VECTOR_H
+#pragma once
+
#include <stdlib.h>
struct vector_struct {
int maxlen;
int Vector_get_length(Vector v);
Vector Vector_reset(Vector v, void *stuff, int i);
-
-#endif