github.com/256dpi/max-go@v0.7.0/lib/max/ext_preferences.h (about)

     1  #ifndef _EXT_PREFERENCES_H_
     2  #define _EXT_PREFERENCES_H_
     3  
     4  #include "ext_prefix.h"
     5  #include "ext_mess.h"
     6  #include "ext_dictionary.h"
     7  
     8  BEGIN_USING_C_LINKAGE
     9  
    10  t_max_err preferences_getatomforkey(t_symbol *key, t_atom *value);
    11  t_symbol *preferences_getsym(C74_CONST char *name);
    12  void preferences_setsym(C74_CONST char *name, t_symbol *value);
    13  long preferences_getlong(C74_CONST char *name);
    14  void preferences_setlong(C74_CONST char *name, long value);
    15  long preferences_getchar(C74_CONST char *name);
    16  void preferences_setchar(C74_CONST char *name, long value);
    17  t_max_err preferences_getatoms(C74_CONST char *name, long *argc, t_atom **argv);
    18  t_max_err preferences_setatoms(C74_CONST char *name, long argc, t_atom *argv);
    19  void *preferences_define(C74_CONST char *name, C74_CONST char *type, C74_CONST char *label, C74_CONST char *style, C74_CONST char *category, long attrflags, method get, method set, long flags);
    20  void *preferences_class_define(t_class *c, C74_CONST char *name, C74_CONST char *type, C74_CONST char *label, C74_CONST char *style, C74_CONST char *category, long attrflags, method get, method set, long flags);
    21  void *preferences_defineoption(C74_CONST char *name, C74_CONST char *label, C74_CONST char *category, char *ptr, method notify, long flags);
    22  void *preferences_class_defineoption(t_class *c, C74_CONST char *name, C74_CONST char *label, C74_CONST char *category, char *ptr, method notify, long flags);
    23  t_max_err preferences_writedictionary(C74_CONST t_dictionary *d, C74_CONST char *filename);
    24  t_max_err preferences_readdictionary(C74_CONST char *filename, t_dictionary **d);
    25  t_dictionary *simpleprefs_dictionary();
    26  
    27  END_USING_C_LINKAGE
    28  
    29  enum {
    30  	PREFERENCES_FLAGS_INVISIBLE = 1,
    31  	PREFERENCES_FLAGS_DONTSAVE = 2
    32  };
    33  
    34  
    35  #endif // _EXT_PREFERENCES_H_