/* common.h original code: SASANO Takayoshi --- public domain, no warranty. */ #include #include #include #include #include #include #include /* エンディアン変換が必要になった時のための、拡張用 */ #define XeH(x) (x) #define XeW(x) (x) /* 保存対象となるトレーレコードの指定 */ #define ENABLE_VOBJ (1 << 0) // 仮身レコード保存許可 #define ENABLE_TEXT (1 << 1) // 文章レコード保存許可 #define ENABLE_FIG (1 << 2) // 図形レコード保存許可 #define ENABLE_FUSEN (1 << 3) // 付箋レコード保存許可 #define ENABLE_ALL (ENABLE_VOBJ | ENABLE_TEXT | ENABLE_FIG | ENABLE_FUSEN) /* デバッグ用 */ #ifdef DEBUG #define DP(x) printf x #else #define DP(x) /* */ #endif #define P(x) printf x IMPORT ERR tray2file_backend(W fd, TRAYREC *rec, W record);