summaryrefslogtreecommitdiffstats
path: root/libass/ass_types.h
diff options
context:
space:
mode:
authorgreg <greg@blackbox>2009-06-18 17:54:08 +0200
committergreg <greg@blackbox>2009-06-20 03:38:00 +0200
commit2303b5430337da60f582613f95e605f08606759f (patch)
tree7ab52c9de634da3dfe55e1f36e87030beff2a3fe /libass/ass_types.h
parent9c7521c0224f16880870839f7492e50b1c8602f7 (diff)
downloadlibass-2303b5430337da60f582613f95e605f08606759f.tar.bz2
libass-2303b5430337da60f582613f95e605f08606759f.tar.xz
Reindent all source code.
Reindent complete source code (*.c, *.h) with indent, the exact command line being: indent -kr -i4 -bap -nut -l76 *.c *.h From now on, new code should use (more or less) K&R style, only spaces and no tabs, 4 spaces indent width. Avoid long lines. Fix function declaration pointer spacing. Remove spaces that were added to many function declarations by indent, like some_func(foo_t * bar). Fix indenting of macros in ass.c
Diffstat (limited to 'libass/ass_types.h')
-rw-r--r--libass/ass_types.h119
1 files changed, 59 insertions, 60 deletions
diff --git a/libass/ass_types.h b/libass/ass_types.h
index d43fef31..cdea14ef 100644
--- a/libass/ass_types.h
+++ b/libass/ass_types.h
@@ -1,5 +1,3 @@
-// -*- c-basic-offset: 8; indent-tabs-mode: t -*-
-// vim:ts=8:sw=8:noet:ai:
/*
* Copyright (C) 2006 Evgeniy Stepanov <eugeni.stepanov@gmail.com>
*
@@ -34,31 +32,31 @@
/// ass Style: line
typedef struct ass_style_s {
- char* Name;
- char* FontName;
- double FontSize;
- uint32_t PrimaryColour;
- uint32_t SecondaryColour;
- uint32_t OutlineColour;
- uint32_t BackColour;
- int Bold;
- int Italic;
- int Underline;
- int StrikeOut;
- double ScaleX;
- double ScaleY;
- double Spacing;
- int Angle;
- int BorderStyle;
- double Outline;
- double Shadow;
- int Alignment;
- int MarginL;
- int MarginR;
- int MarginV;
+ char *Name;
+ char *FontName;
+ double FontSize;
+ uint32_t PrimaryColour;
+ uint32_t SecondaryColour;
+ uint32_t OutlineColour;
+ uint32_t BackColour;
+ int Bold;
+ int Italic;
+ int Underline;
+ int StrikeOut;
+ double ScaleX;
+ double ScaleY;
+ double Spacing;
+ int Angle;
+ int BorderStyle;
+ double Outline;
+ double Shadow;
+ int Alignment;
+ int MarginL;
+ int MarginR;
+ int MarginV;
// int AlphaLevel;
- int Encoding;
- int treat_fontname_as_pattern;
+ int Encoding;
+ int treat_fontname_as_pattern;
} ass_style_t;
typedef struct render_priv_s render_priv_t;
@@ -66,20 +64,20 @@ typedef struct render_priv_s render_priv_t;
/// ass_event_t corresponds to a single Dialogue line
/// Text is stored as-is, style overrides will be parsed later
typedef struct ass_event_s {
- long long Start; // ms
- long long Duration; // ms
-
- int ReadOrder;
- int Layer;
- int Style;
- char* Name;
- int MarginL;
- int MarginR;
- int MarginV;
- char* Effect;
- char* Text;
-
- render_priv_t* render_priv;
+ long long Start; // ms
+ long long Duration; // ms
+
+ int ReadOrder;
+ int Layer;
+ int Style;
+ char *Name;
+ int MarginL;
+ int MarginR;
+ int MarginV;
+ char *Effect;
+ char *Text;
+
+ render_priv_t *render_priv;
} ass_event_t;
typedef struct parser_priv_s parser_priv_t;
@@ -89,31 +87,32 @@ typedef struct ass_library_s ass_library_t;
/// ass track represent either an external script or a matroska subtitle stream (no real difference between them)
/// it can be used in rendering after the headers are parsed (i.e. events format line read)
typedef struct ass_track_s {
- int n_styles; // amount used
- int max_styles; // amount allocated
- int n_events;
- int max_events;
- ass_style_t* styles; // array of styles, max_styles length, n_styles used
- ass_event_t* events; // the same as styles
+ int n_styles; // amount used
+ int max_styles; // amount allocated
+ int n_events;
+ int max_events;
+ ass_style_t *styles; // array of styles, max_styles length, n_styles used
+ ass_event_t *events; // the same as styles
- char* style_format; // style format line (everything after "Format: ")
- char* event_format; // event format line
+ char *style_format; // style format line (everything after "Format: ")
+ char *event_format; // event format line
- enum {TRACK_TYPE_UNKNOWN = 0, TRACK_TYPE_ASS, TRACK_TYPE_SSA} track_type;
+ enum { TRACK_TYPE_UNKNOWN =
+ 0, TRACK_TYPE_ASS, TRACK_TYPE_SSA } track_type;
- // script header fields
- int PlayResX;
- int PlayResY;
- double Timer;
- int WrapStyle;
- char ScaledBorderAndShadow;
+ // script header fields
+ int PlayResX;
+ int PlayResY;
+ double Timer;
+ int WrapStyle;
+ char ScaledBorderAndShadow;
- int default_style; // index of default style
- char* name; // file name in case of external subs, 0 for streams
+ int default_style; // index of default style
+ char *name; // file name in case of external subs, 0 for streams
- ass_library_t* library;
- parser_priv_t* parser_priv;
+ ass_library_t *library;
+ parser_priv_t *parser_priv;
} ass_track_t;
-#endif /* LIBASS_TYPES_H */
+#endif /* LIBASS_TYPES_H */