*.{h,c}: do not use the C reserved identifiers for tag names

pull/4/head
Koichi Murase 5 months ago
parent a6ca0111de
commit 2e5e0a5b67
  1. 4
      src/bin/colors.h
  2. 18
      src/bin/config.h
  3. 2
      src/bin/controls.c
  4. 2
      src/bin/gravatar.c
  5. 4
      src/bin/ipc.h
  6. 12
      src/bin/keyin.c
  7. 8
      src/bin/keyin.h
  8. 4
      src/bin/media.c
  9. 4
      src/bin/media.h
  10. 4
      src/bin/miniview.c
  11. 4
      src/bin/options.c
  12. 6
      src/bin/options_background.c
  13. 2
      src/bin/options_behavior.c
  14. 4
      src/bin/options_colors.c
  15. 4
      src/bin/options_font.c
  16. 2
      src/bin/options_keys.c
  17. 2
      src/bin/options_mouse.c
  18. 6
      src/bin/options_theme.c
  19. 8
      src/bin/sel.c
  20. 12
      src/bin/term_container.h
  21. 8
      src/bin/termiointernals.h
  22. 40
      src/bin/termpty.h
  23. 4
      src/bin/termptyesc.c
  24. 2
      src/bin/termptyops.h
  25. 4
      src/bin/tyls.c
  26. 2
      src/bin/tytest.c
  27. 32
      src/bin/win.c
  28. 4
      src/bin/win.h

@ -5,7 +5,7 @@
#include "config.h"
struct _Color_Block
struct tag_Color_Block
{
Color def;
Color black;
@ -21,7 +21,7 @@ struct _Color_Block
uint32_t _padding;
};
struct _Color_Scheme
struct tag_Color_Scheme
{
int version;
struct {

@ -3,12 +3,12 @@
#include <Evas.h>
typedef struct _Config Config;
typedef struct _Color Color;
typedef struct _Color_Scheme Color_Scheme;
typedef struct _Color_Block Color_Block;
typedef struct _Config_Keys Config_Keys;
struct _Color
typedef struct tag_Config Config;
typedef struct tag_Color Color;
typedef struct tag_Color_Scheme Color_Scheme;
typedef struct tag_Color_Block Color_Block;
typedef struct tag_Config_Keys Config_Keys;
struct tag_Color
{
unsigned char r, g, b, a;
};
@ -16,7 +16,7 @@ struct _Color
#include "colors.h"
struct _Config_Keys
struct tag_Config_Keys
{
const char *keyname;
Eina_Bool ctrl;
@ -29,14 +29,14 @@ struct _Config_Keys
};
/* TODO: separate config per terminal (tab, window) and global. */
typedef enum _Cursor_Shape
typedef enum tag_Cursor_Shape
{
CURSOR_SHAPE_BLOCK = 0,
CURSOR_SHAPE_UNDERLINE = 1,
CURSOR_SHAPE_BAR = 2
} Cursor_Shape;
struct _Config
struct tag_Config
{
int version;
int scrollback;

@ -10,7 +10,7 @@
static Eina_Hash *controls = NULL;
typedef struct _Controls_Ctx {
typedef struct tag_Controls_Ctx {
Evas_Object *frame;
Evas_Object *group_input_cx;
Evas_Object *over;

@ -27,7 +27,7 @@ int _gravatar_log_dom = -1;
#define GRAVATAR_URL_START "https://www.gravatar.com/avatar/"
#define GRAVATAR_URL_END ""
typedef struct _Gravatar {
typedef struct tag_Gravatar {
const char *url;
const Config *config;
} Gravatar;

@ -3,9 +3,9 @@
#include "config.h"
typedef struct _Ipc_Instance Ipc_Instance;
typedef struct tag_Ipc_Instance Ipc_Instance;
struct _Ipc_Instance
struct tag_Ipc_Instance
{
char *cmd;
char *cd;

@ -10,15 +10,15 @@
#include "keyin.h"
#include "win.h"
typedef struct _Tty_Key Tty_Key;
typedef struct _Key_Values Key_Values;
typedef struct tag_Tty_Key Tty_Key;
typedef struct tag_Key_Values Key_Values;
struct _s {
char *s;
ssize_t len;
};
struct _Key_Values {
struct tag_Key_Values {
struct _s plain;
struct _s alt;
struct _s ctrl;
@ -28,7 +28,7 @@ struct _Key_Values {
struct _s shift_ctrl;
struct _s shift_ctrl_alt;
};
struct _Tty_Key
struct tag_Tty_Key
{
char *key;
int key_len;
@ -36,9 +36,9 @@ struct _Tty_Key
Key_Values cursor;
};
typedef struct _Key_Binding Key_Binding;
typedef struct tag_Key_Binding Key_Binding;
struct _Key_Binding
struct tag_Key_Binding
{
uint16_t ctrl : 1;
uint16_t alt : 1;

@ -1,9 +1,9 @@
#ifndef TERMINOLOGY_KEYIN_H_
#define TERMINOLOGY_KEYIN_H_ 1
typedef struct _Keys_Handler Keys_Handler;
typedef struct tag_Keys_Handler Keys_Handler;
struct _Keys_Handler
struct tag_Keys_Handler
{
Ecore_IMF_Context *imf;
unsigned int last_keyup;
@ -29,9 +29,9 @@ void keyin_handle_up(Keys_Handler *khdl, Evas_Event_Key_Up *ev);
typedef Eina_Bool (*Key_Binding_Cb)(Evas_Object *term);
typedef struct _Shortcut_Action Shortcut_Action;
typedef struct tag_Shortcut_Action Shortcut_Action;
struct _Shortcut_Action
struct tag_Shortcut_Action
{
const char *action;
const char *description;

@ -11,9 +11,9 @@
#include "theme.h"
#include "termiolink.h"
typedef struct _Media Media;
typedef struct tag_Media Media;
struct _Media
struct tag_Media
{
Evas_Object_Smart_Clipped_Data __clipped_data;
Evas_Object *clip, *o_img, *o_tmp, *o_ctrl, *o_busy, *o_event;

@ -14,9 +14,9 @@
#define MEDIA_SAVE 0x0020
typedef enum _Media_Type Media_Type;
typedef enum tag_Media_Type Media_Type;
enum _Media_Type {
enum tag_Media_Type {
MEDIA_TYPE_UNKNOWN,
MEDIA_TYPE_IMG,
MEDIA_TYPE_SCALE,

@ -49,9 +49,9 @@ miniview_shutdown(void)
_miniview_log_dom = -1;
}
typedef struct _Miniview Miniview;
typedef struct tag_Miniview Miniview;
struct _Miniview
struct tag_Miniview
{
Evas_Object *self;
Evas_Object *base;

@ -29,7 +29,7 @@ enum option_mode {
OPTIONS_MODE_NB
};
typedef struct _Options_Ctx {
typedef struct tag_Options_Ctx {
enum option_mode mode;
Evas_Object *frame;
Evas_Object *toolbar;
@ -42,7 +42,7 @@ typedef struct _Options_Ctx {
Config *config;
void (*donecb) (void *data);
void *donedata;
struct _Options_Ctx *modes[OPTIONS_MODE_NB];
struct tag_Options_Ctx *modes[OPTIONS_MODE_NB];
} Options_Ctx;
static void

@ -12,7 +12,7 @@
#include "main.h"
#include <sys/stat.h>
typedef struct _Background_Ctx {
typedef struct tag_Background_Ctx {
Config *config;
Evas_Object *frame;
Evas_Object *flip;
@ -30,14 +30,14 @@ typedef struct _Background_Ctx {
Ecore_Timer *bubble_disappear;
} Background_Ctx;
typedef struct _Background_Item
typedef struct tag_Background_Item
{
const char *path;
Eina_Bool selected;
Elm_Object_Item *item;
} Background_Item;
typedef struct _Insert_Gen_Grid_Item_Notify
typedef struct tag_Insert_Gen_Grid_Item_Notify
{
Elm_Gengrid_Item_Class *class;
Background_Item *item;

@ -13,7 +13,7 @@
#include "main.h"
#include "theme.h"
typedef struct _Behavior_Ctx {
typedef struct tag_Behavior_Ctx {
Config *config;
Evas_Object *term;
Evas_Object *op_w;

@ -10,7 +10,7 @@
#include "options_themepv.h"
#include "utils.h"
typedef struct _Color_Scheme_Ctx
typedef struct tag_Color_Scheme_Ctx
{
Evas_Object *term;
Config *config;
@ -21,7 +21,7 @@ typedef struct _Color_Scheme_Ctx
Evas_Object *ctxpopup;
} Color_Scheme_Ctx;
typedef struct _Color_Scheme_Info
typedef struct tag_Color_Scheme_Info
{
Color_Scheme_Ctx *ctx;
Elm_Object_Item *item;

@ -14,7 +14,7 @@
#define FONT_STEP (1.0 / (FONT_MAX - FONT_MIN))
typedef struct _Font_Ctx
typedef struct tag_Font_Ctx
{
Evas_Object *fr;
Evas_Object *opbox;
@ -35,7 +35,7 @@ typedef struct _Font_Ctx
int expecting_resize;
} Font_Ctx;
typedef struct _Font
typedef struct tag_Font
{
Elm_Object_Item *item;
const char *pretty_name;

@ -9,7 +9,7 @@
#include "keyin.h"
#include "theme.h"
typedef struct _Keys_Ctx {
typedef struct tag_Keys_Ctx {
Config *config;
Evas_Object *frame;
Evas_Object *gl;

@ -8,7 +8,7 @@
#include "options_mouse.h"
#include "main.h"
typedef struct _Mouse_Ctx {
typedef struct tag_Mouse_Ctx {
Config *config;
Evas_Object *term;
Evas_Object *sld_hide_cursor;

@ -12,7 +12,7 @@
#include "theme.h"
#include "main.h"
typedef struct _Theme_Ctx
typedef struct tag_Theme_Ctx
{
Evas_Object *term;
Config *config;
@ -21,8 +21,8 @@ typedef struct _Theme_Ctx
Ecore_Timer *seltimer;
} Theme_Ctx;
typedef struct _Theme Theme;
struct _Theme
typedef struct tag_Theme Theme;
struct tag_Theme
{
Elm_Object_Item *item;
const char *name;

@ -9,10 +9,10 @@
#include "win.h"
#include "term_container.h"
typedef struct _Sel Sel;
typedef struct _Entry Entry;
typedef struct tag_Sel Sel;
typedef struct tag_Entry Entry;
struct _Sel
struct tag_Sel
{
Evas_Object_Smart_Clipped_Data __clipped_data;
Evas_Object *self;
@ -41,7 +41,7 @@ struct _Sel
unsigned char use_px : 1;
};
struct _Entry
struct tag_Entry
{
Evas_Object *obj, *bg;
Term_Container *tc;

@ -2,10 +2,10 @@
#define TERMINOLOGY_TERM_CONTAINER_H_ 1
typedef struct _Term_Container Term_Container;
typedef struct _Sizeinfo Sizeinfo;
typedef struct tag_Term_Container Term_Container;
typedef struct tag_Sizeinfo Sizeinfo;
struct _Sizeinfo
struct tag_Sizeinfo
{
int min_w;
int min_h;
@ -18,7 +18,7 @@ struct _Sizeinfo
int req;
};
typedef enum _Term_Container_Type
typedef enum tag_Term_Container_Type
{
TERM_CONTAINER_TYPE_UNKNOWN = 0,
TERM_CONTAINER_TYPE_SOLO,
@ -27,7 +27,7 @@ typedef enum _Term_Container_Type
TERM_CONTAINER_TYPE_WIN
} Term_Container_Type;
typedef enum _Split_Direction {
typedef enum tag_Split_Direction {
SPLIT_DIRECTION_NONE,
SPLIT_DIRECTION_LEFT,
SPLIT_DIRECTION_RIGHT,
@ -36,7 +36,7 @@ typedef enum _Split_Direction {
SPLIT_DIRECTION_TABS,
} Split_Direction;
struct _Term_Container {
struct tag_Term_Container {
Term_Container_Type type;
Term_Container *parent;
Win *wn;

@ -5,9 +5,9 @@
typedef void Term;
#endif
typedef struct _Termio Termio;
typedef struct tag_Termio Termio;
struct _Termio
struct tag_Termio
{
Evas_Object_Smart_Clipped_Data __clipped_data;
struct {
@ -100,8 +100,8 @@ struct _Termio
double gesture_zoom_start_size;
};
typedef struct _Termio_Modifiers Termio_Modifiers;
struct _Termio_Modifiers
typedef struct tag_Termio_Modifiers Termio_Modifiers;
struct tag_Termio_Modifiers
{
unsigned char alt : 1;
unsigned char shift : 1;

@ -5,15 +5,15 @@
#include "media.h"
#include "sb.h"
typedef struct _Termcell Termcell;
typedef struct _Termatt Termatt;
typedef struct _Termsave Termsave;
typedef struct _Termsavecomp Termsavecomp;
typedef struct _Termblock Termblock;
typedef struct _Termexp Termexp;
typedef struct _Termpty Termpty;
typedef struct _Termlink Term_Link;
typedef struct _TitleIconElem TitleIconElem;
typedef struct tag_Termcell Termcell;
typedef struct tag_Termatt Termatt;
typedef struct tag_Termsave Termsave;
typedef struct tag_Termsavecomp Termsavecomp;
typedef struct tag_Termblock Termblock;
typedef struct tag_Termexp Termexp;
typedef struct tag_Termpty Termpty;
typedef struct tag_Termlink Term_Link;
typedef struct tag_TitleIconElem TitleIconElem;
#define COL_DEF 0
#define COL_BLACK 1
@ -49,7 +49,7 @@ typedef struct _TitleIconElem TitleIconElem;
#define HL_LINKS_MAX (1 << 16)
struct _Termlink
struct tag_Termlink
{
const char *key;
const char *url;
@ -59,7 +59,7 @@ struct _Termlink
struct _Termatt
struct tag_Termatt
{
uint8_t fg, bg;
unsigned short bold : 1;
@ -94,12 +94,12 @@ struct _Termatt
uint16_t link_id;
};
typedef struct _Backlog_Beacon{
typedef struct tag_Backlog_Beacon{
int screen_y;
int backlog_y;
} Backlog_Beacon;
typedef struct _Term_State {
typedef struct tag_Term_State {
Termatt att;
unsigned char charset;
unsigned char charsetch;
@ -125,13 +125,13 @@ typedef struct _Term_State {
unsigned int sace_rectangular : 1;
} Term_State;
typedef struct _Term_Cursor {
typedef struct tag_Term_Cursor {
int cx;
int cy;
unsigned char wrapnext : 1;
} Term_Cursor;
struct _Termpty
struct tag_Termpty
{
Evas_Object *obj;
Config *config;
@ -212,13 +212,13 @@ struct _Termpty
TitleIconElem *title_icon_stack;
};
struct _Termcell
struct tag_Termcell
{
Eina_Unicode codepoint;
Termatt att;
};
struct _Termsave
struct tag_Termsave
{
unsigned int gen : 8;
unsigned int comp : 1;
@ -229,7 +229,7 @@ struct _Termsave
};
/* TODO: RESIZE rewrite Termsavecomp */
struct _Termsavecomp
struct tag_Termsavecomp
{
unsigned int gen : 8;
unsigned int comp : 1;
@ -238,7 +238,7 @@ struct _Termsavecomp
unsigned int wout; // output width in Termcells
};
struct _Termblock
struct tag_Termblock
{
Termpty *pty;
const char *path, *link, *chid;
@ -262,7 +262,7 @@ struct _Termblock
unsigned char mov_state : 2; // movie state marker
};
struct _Termexp
struct tag_Termexp
{
Eina_Unicode ch;
int left, id;

@ -3188,10 +3188,10 @@ _handle_resize_by_chars(Termpty *ty, Eina_Unicode **ptr)
#endif
}
struct _TitleIconElem {
struct tag_TitleIconElem {
const char *title;
const char *icon;
struct _TitleIconElem *next;
struct tag_TitleIconElem *next;
};
static void

@ -1,7 +1,7 @@
#ifndef TERMINOLOGY_TERMPTY_OPS_H_
#define TERMINOLOGY_TERMPTY_OPS_H_ 1
typedef enum _Termpty_Clear
typedef enum tag_Termpty_Clear
{
TERMPTY_CLR_END = 0,
TERMPTY_CLR_BEGIN = 1,

@ -140,14 +140,14 @@ sizeprint(char *sz, char szch)
colorprint(RESET, 0, 0, 0, 0);
}
typedef struct _Cmatch
typedef struct tag_Cmatch
{
short fr, fg, fb;
short br, bg, bb;
const char *match, *icon;
} Cmatch;
typedef struct _Tyls_Options
typedef struct tag_Tyls_Options
{
int mode;
Eina_Bool hidden;

@ -104,7 +104,7 @@ _run_tytests(int argc, char **argv)
/* }}} */
typedef struct _Termpty_Tests
typedef struct tag_Termpty_Tests
{
size_t backsize, backpos;
Backlog_Beacon backlog_beacon;

@ -67,15 +67,15 @@ int _win_log_dom = -1;
/* {{{ Structs */
typedef struct _Split Split;
typedef struct _Tabbar Tabbar;
typedef struct _Solo Solo;
typedef struct _Tabs Tabs;
typedef struct _Tab_Item Tab_Item;
typedef struct _Tab_Drag Tab_Drag;
typedef struct tag_Split Split;
typedef struct tag_Tabbar Tabbar;
typedef struct tag_Solo Solo;
typedef struct tag_Tabs Tabs;
typedef struct tag_Tab_Item Tab_Item;
typedef struct tag_Tab_Drag Tab_Drag;
struct _Tab_Drag
struct tag_Tab_Drag
{
Evas_Coord mdx; /* Mouse-down x */
Evas_Coord mdy; /* Mouse-down y */
@ -101,14 +101,14 @@ struct _Tab_Drag
}; };
};
struct _Tabbar
struct tag_Tabbar
{
struct {
Evas_Object *box;
} l, r;
};
struct _Term
struct tag_Term
{
Win *wn;
Config *config;
@ -153,18 +153,18 @@ struct _Term
Eina_Bool sendfile_progress_enabled : 1;
};
struct _Solo {
struct tag_Solo {
Term_Container tc;
Term *term;
};
struct _Tab_Item {
struct tag_Tab_Item {
Term_Container *tc;
Evas_Object *obj;
void *selector_entry;
};
struct _Tabs {
struct tag_Tabs {
Term_Container tc;
Evas_Object *selector;
Evas_Object *selector_bg;
@ -174,7 +174,7 @@ struct _Tabs {
double v2_orig;
};
struct _Split
struct tag_Split
{
Term_Container tc;
Term_Container *tc1, *tc2; // left/right or top/bottom child splits, null if leaf
@ -187,7 +187,7 @@ struct _Split
struct _Win
struct tag_Win
{
Term_Container tc; /* has to be first field */
@ -329,7 +329,7 @@ _scale_change(void *data EINA_UNUSED,
elm_config_all_flush();
}
typedef struct _Scale_Ctx
typedef struct tag_Scale_Ctx
{
Evas_Object *hv;
Term *term;
@ -5631,7 +5631,7 @@ _popmedia_show(Term *term, const char *src, Media_Type type)
}
#ifdef HAVE_ECORE_CON_URL_HEAD
typedef struct _Ty_Http_Head {
typedef struct tag_Ty_Http_Head {
const char *handler;
const char *src;
Ecore_Con_Url *url;

@ -3,8 +3,8 @@
#include "config.h"
typedef struct _Win Win;
typedef struct _Term Term;
typedef struct tag_Win Win;
typedef struct tag_Term Term;

Loading…
Cancel
Save