Skip to content

Commit

Permalink
Remove all trailing whitespace
Browse files Browse the repository at this point in the history
  • Loading branch information
SimonN authored and SiegeLord committed Jun 20, 2023
1 parent 38a0732 commit 147ca7f
Show file tree
Hide file tree
Showing 23 changed files with 72 additions and 72 deletions.
2 changes: 1 addition & 1 deletion allegro5/allegro_android.d
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@ nothrow @nogc extern(C)
void al_android_set_apk_file_interface();
const(char)* al_android_get_os_version();
void al_android_set_apk_fs_interface();
void _al_android_set_capture_volume_keys(ALLEGRO_DISPLAY* display, bool onoff);
void _al_android_set_capture_volume_keys(ALLEGRO_DISPLAY* display, bool onoff);
}
8 changes: 4 additions & 4 deletions allegro5/allegro_audio.d
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ nothrow @nogc extern (C)
ALLEGRO_CHANNEL_CONF_6_1 = 0x61,
ALLEGRO_CHANNEL_CONF_7_1 = 0x71
}

const ALLEGRO_MAX_CHANNELS = 8;

enum ALLEGRO_PLAYMODE
Expand All @@ -75,7 +75,7 @@ nothrow @nogc extern (C)
}

const float ALLEGRO_AUDIO_PAN_NONE = -1000.0f;

enum ALLEGRO_AUDIO_EVENT_TYPE
{
ALLEGRO_EVENT_AUDIO_ROUTE_CHANGE = 520,
Expand All @@ -92,9 +92,9 @@ nothrow @nogc extern (C)
}

struct ALLEGRO_SAMPLE_INSTANCE {};

struct ALLEGRO_AUDIO_STREAM {};

struct ALLEGRO_MIXER {};

struct ALLEGRO_VOICE {};
Expand Down
16 changes: 8 additions & 8 deletions allegro5/allegro_native_dialog.d
Original file line number Diff line number Diff line change
Expand Up @@ -36,12 +36,12 @@ nothrow @nogc extern (C)
{
const ALLEGRO_MENU_SEPARATOR = ALLEGRO_MENU_INFO(null, -1, 0, null);
}

template ALLEGRO_START_OF_MENU(const(char)[] caption, int id)
{
const ALLEGRO_START_OF_MENU = ALLEGRO_MENU_INFO(mixin(`"` ~ caption ~ `->\0"`), id, 0, NULL);
}

template ALLEGRO_END_OF_MENU()
{
const ALLEGRO_END_OF_MENU = ALLEGRO_MENU_INFO(null, 0, 0, null);
Expand All @@ -54,14 +54,14 @@ nothrow @nogc extern (C)
int al_get_native_file_dialog_count(in ALLEGRO_FILECHOOSER* dialog);
ALLEGRO_PATH* al_get_native_file_dialog_path(in ALLEGRO_FILECHOOSER* dialog, size_t index);
void al_destroy_native_file_dialog(ALLEGRO_FILECHOOSER* dialog);

int al_show_native_message_box(ALLEGRO_DISPLAY* display, in char* title, in char* heading, in char* text, in char* buttons, int flags);

ALLEGRO_TEXTLOG* al_open_native_text_log(in char* title, int flags);
void al_close_native_text_log(ALLEGRO_TEXTLOG* textlog);
void al_append_native_text_log(ALLEGRO_TEXTLOG* textlog, in char* format, ...);
ALLEGRO_EVENT_SOURCE* al_get_native_text_log_event_source(ALLEGRO_TEXTLOG* textlog);

/* creating/modifying menus */
ALLEGRO_MENU* al_create_menu();;
ALLEGRO_MENU* al_create_popup_menu();;
Expand All @@ -84,16 +84,16 @@ nothrow @nogc extern (C)
}
ALLEGRO_BITMAP* al_get_menu_item_icon(ALLEGRO_MENU* menu, int pos);
void al_set_menu_item_icon(ALLEGRO_MENU* menu, int pos, ALLEGRO_BITMAP* icon);

/* querying menus */
ALLEGRO_MENU* al_find_menu(ALLEGRO_MENU* haystack, ushort id);
bool al_find_menu_item(ALLEGRO_MENU* haystack, ushort id, ALLEGRO_MENU** menu, int* index);

/* menu events */
ALLEGRO_EVENT_SOURCE* al_get_default_menu_event_source();;
ALLEGRO_EVENT_SOURCE* al_enable_menu_event_source(ALLEGRO_MENU* menu);
void al_disable_menu_event_source(ALLEGRO_MENU* menu);

/* displaying menus */
ALLEGRO_MENU* al_get_display_menu(ALLEGRO_DISPLAY* display);
bool al_set_display_menu(ALLEGRO_DISPLAY* display, ALLEGRO_MENU* menu);
Expand All @@ -120,7 +120,7 @@ nothrow @nogc extern (C)
ALLEGRO_MESSAGEBOX_YES_NO = 1<<3,
ALLEGRO_MESSAGEBOX_QUESTION = 1<<4
}

enum
{
ALLEGRO_TEXTLOG_NO_CLOSE = 1<<0,
Expand Down
18 changes: 9 additions & 9 deletions allegro5/allegro_primitives.d
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ nothrow @nogc extern (C)
ALLEGRO_PRIM_HALF_FLOAT_2,
ALLEGRO_PRIM_HALF_FLOAT_4
}

enum ALLEGRO_LINE_JOIN
{
ALLEGRO_LINE_JOIN_NONE,
Expand Down Expand Up @@ -92,7 +92,7 @@ nothrow @nogc extern (C)

const int ALLEGRO_PRIM_QUALITY = 10;

struct ALLEGRO_VERTEX_ELEMENT
struct ALLEGRO_VERTEX_ELEMENT
{
int attribute;
int storage;
Expand All @@ -109,7 +109,7 @@ nothrow @nogc extern (C)
}

struct ALLEGRO_VERTEX_BUFFER {};

struct ALLEGRO_INDEX_BUFFER {};

uint al_get_allegro_primitives_version();
Expand All @@ -123,10 +123,10 @@ nothrow @nogc extern (C)
int al_draw_indexed_prim(in void* vtxs, in ALLEGRO_VERTEX_DECL* decl, ALLEGRO_BITMAP* texture, in int* indices, int num_vtx, int type);
int al_draw_vertex_buffer(ALLEGRO_VERTEX_BUFFER* vertex_buffer, ALLEGRO_BITMAP* texture, int start, int end, int type);
int al_draw_indexed_buffer(ALLEGRO_VERTEX_BUFFER* vertex_buffer, ALLEGRO_BITMAP* texture, ALLEGRO_INDEX_BUFFER* index_buffer, int start, int end, int type);

ALLEGRO_VERTEX_DECL* al_create_vertex_decl(in ALLEGRO_VERTEX_ELEMENT* elements, int stride);
void al_destroy_vertex_decl(ALLEGRO_VERTEX_DECL* decl);

/*
* Vertex buffers
*/
Expand All @@ -135,7 +135,7 @@ nothrow @nogc extern (C)
void* al_lock_vertex_buffer(ALLEGRO_VERTEX_BUFFER* buffer, int offset, int length, int flags);
void al_unlock_vertex_buffer(ALLEGRO_VERTEX_BUFFER* buffer);
int al_get_vertex_buffer_size(ALLEGRO_VERTEX_BUFFER* buffer);

/*
* Index buffers
*/
Expand All @@ -156,11 +156,11 @@ nothrow @nogc extern (C)
void al_draw_soft_triangle(ALLEGRO_VERTEX* v1, ALLEGRO_VERTEX* v2, ALLEGRO_VERTEX* v3, uintptr_t state,
void function(uintptr_t, ALLEGRO_VERTEX*, ALLEGRO_VERTEX*, ALLEGRO_VERTEX*) init,
void function(uintptr_t, int, int, int, int) first,
void function(uintptr_t, int) step,
void function(uintptr_t, int) step,
void function(uintptr_t, int, int, int) draw);
void al_draw_soft_line(ALLEGRO_VERTEX* v1, ALLEGRO_VERTEX* v2, uintptr_t state,
void function(uintptr_t, int, int, ALLEGRO_VERTEX*, ALLEGRO_VERTEX*) first,
void function(uintptr_t, int) step,
void function(uintptr_t, int) step,
void function(uintptr_t, int, int) draw);

/*
Expand Down Expand Up @@ -190,7 +190,7 @@ nothrow @nogc extern (C)
void al_draw_filled_circle(float cx, float cy, float r, ALLEGRO_COLOR color);
void al_draw_filled_pieslice(float cx, float cy, float r, float start_theta, float delta_theta, ALLEGRO_COLOR color);
void al_draw_filled_rounded_rectangle(float x1, float y1, float x2, float y2, float rx, float ry, ALLEGRO_COLOR color);

void al_draw_polyline(in float* vertices, int vertex_stride, int vertex_count, ALLEGRO_LINE_JOIN join_style, ALLEGRO_LINE_CAP cap_style, ALLEGRO_COLOR color, float thickness, float miter_limit);

void al_draw_polygon(in float* vertices, int vertex_count, ALLEGRO_LINE_JOIN join_style, ALLEGRO_COLOR color, float thickness, float miter_limit);
Expand Down
2 changes: 1 addition & 1 deletion allegro5/bitmap_draw.d
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ nothrow @nogc extern(C)
ALLEGRO_FLIP_HORIZONTAL = 0x00001,
ALLEGRO_FLIP_VERTICAL = 0x00002
}

/* Blitting */
void al_draw_bitmap(ALLEGRO_BITMAP* bitmap, float dx, float dy, int flags);
void al_draw_bitmap_region(ALLEGRO_BITMAP* bitmap, float sx, float sy, float sw, float sh, float dx, float dy, int flags);
Expand Down
2 changes: 1 addition & 1 deletion allegro5/bitmap_io.d
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ nothrow @nogc extern(C)
ALLEGRO_NO_PREMULTIPLIED_ALPHA = 0x0200, /* was a bitmap flag in 5.0 */
ALLEGRO_KEEP_INDEX = 0x0800
}

alias ALLEGRO_BITMAP* function(in char* filename) ALLEGRO_IIO_LOADER_FUNCTION;
alias ALLEGRO_BITMAP* function(ALLEGRO_FILE* fp) ALLEGRO_IIO_FS_LOADER_FUNCTION;
alias bool function(in char* filename, ALLEGRO_BITMAP* bitmap) ALLEGRO_IIO_SAVER_FUNCTION;
Expand Down
2 changes: 1 addition & 1 deletion allegro5/bitmap_lock.d
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ nothrow @nogc extern(C)
ALLEGRO_LOCK_WRITEONLY = 2
}

struct ALLEGRO_LOCKED_REGION
struct ALLEGRO_LOCKED_REGION
{
void* data;
int format;
Expand Down
2 changes: 1 addition & 1 deletion allegro5/config.d
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ nothrow @nogc extern (C)
struct ALLEGRO_CONFIG {};
struct ALLEGRO_CONFIG_SECTION {};
struct ALLEGRO_CONFIG_ENTRY {};

ALLEGRO_CONFIG* al_create_config();
void al_add_config_section(ALLEGRO_CONFIG* config, in char* name);
void al_set_config_value(ALLEGRO_CONFIG* config, in char* section, in char* key, in char* value);
Expand Down
6 changes: 3 additions & 3 deletions allegro5/display.d
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ nothrow @nogc extern (C)
ALLEGRO_REQUIRE,
ALLEGRO_SUGGEST
}

enum ALLEGRO_DISPLAY_ORIENTATION
{
ALLEGRO_DISPLAY_ORIENTATION_UNKNOWN = 0,
Expand Down Expand Up @@ -152,11 +152,11 @@ nothrow @nogc extern (C)
void al_reset_new_display_options();
void al_set_display_option(ALLEGRO_DISPLAY* display, int option, int value);
int al_get_display_option(ALLEGRO_DISPLAY* display, int option);

/*Deferred drawing*/
void al_hold_bitmap_drawing(bool hold);
bool al_is_bitmap_drawing_held();

void al_acknowledge_drawing_halt(ALLEGRO_DISPLAY* display);
void al_acknowledge_drawing_resume(ALLEGRO_DISPLAY *display);
}
14 changes: 7 additions & 7 deletions allegro5/events.d
Original file line number Diff line number Diff line change
Expand Up @@ -82,12 +82,12 @@ nothrow @nogc extern (C)
{
int[32] __pad = void;
}

struct ALLEGRO_ANY_EVENT
{
mixin(_AL_EVENT_HEADER!("ALLEGRO_EVENT_SOURCE"));
}

struct ALLEGRO_DISPLAY_EVENT
{
mixin(_AL_EVENT_HEADER!("ALLEGRO_DISPLAY"));
Expand Down Expand Up @@ -136,7 +136,7 @@ nothrow @nogc extern (C)
long count;
double error;
}

struct ALLEGRO_TOUCH_EVENT
{
mixin(_AL_EVENT_HEADER!("ALLEGRO_TOUCH_INPUT"));
Expand All @@ -151,7 +151,7 @@ nothrow @nogc extern (C)
float dx, dy;
bool primary;
}

struct ALLEGRO_USER_EVENT_DESCRIPTOR;

struct ALLEGRO_USER_EVENT
Expand All @@ -163,12 +163,12 @@ nothrow @nogc extern (C)
intptr_t data3;
intptr_t data4;
}

union ALLEGRO_EVENT
{
/* This must be the same as the first field of _AL_EVENT_HEADER. */
ALLEGRO_EVENT_TYPE type;

ALLEGRO_ANY_EVENT any;
ALLEGRO_DISPLAY_EVENT display;
ALLEGRO_JOYSTICK_EVENT joystick;
Expand All @@ -178,7 +178,7 @@ nothrow @nogc extern (C)
ALLEGRO_TOUCH_EVENT touch;
ALLEGRO_USER_EVENT user;
}

/* Event sources */
void al_init_user_event_source(ALLEGRO_EVENT_SOURCE* src);
void al_destroy_user_event_source(ALLEGRO_EVENT_SOURCE* src);
Expand Down
6 changes: 3 additions & 3 deletions allegro5/file.d
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,11 @@ nothrow @nogc extern (C)
int function(ALLEGRO_FILE* f, int c) fi_fungetc;
off_t function(ALLEGRO_FILE* f) fi_fsize;
}

struct ALLEGRO_FILE
{
}

enum ALLEGRO_SEEK
{
ALLEGRO_SEEK_SET = 0,
Expand Down Expand Up @@ -83,7 +83,7 @@ nothrow @nogc extern (C)
/* Specific to stdio backend. */
ALLEGRO_FILE* al_fopen_fd(int fd, in char* mode);
ALLEGRO_FILE* al_make_temp_file(in char* tmpl, ALLEGRO_PATH **ret_path);

/* Specific to slices. */
ALLEGRO_FILE* al_fopen_slice(ALLEGRO_FILE* fp, size_t initial_size, in char *mode);

Expand Down
16 changes: 8 additions & 8 deletions allegro5/fixed.d
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ import core.stdc.errno;
nothrow @nogc extern (C)
{
alias int al_fixed;

const al_fixed al_fixtorad_r = cast(al_fixed)1608;
const al_fixed al_radtofix_r = cast(al_fixed)2670177;

al_fixed al_fixsqrt(al_fixed x);
al_fixed al_fixhypot(al_fixed x, al_fixed y);
al_fixed al_fixatan(al_fixed x);
Expand All @@ -32,12 +32,12 @@ nothrow @nogc extern (C)

return cast(al_fixed)(x * 65536.0 + (x < 0 ? -0.5 : 0.5));
}

double al_fixtof(al_fixed x)
{
return cast(double)x / 65536.0;
}

al_fixed al_fixadd(al_fixed x, al_fixed y)
{
al_fixed result = x + y;
Expand Down Expand Up @@ -78,9 +78,9 @@ nothrow @nogc extern (C)
else
return result;
}
else
else
{
if ((x > 0) && (y < 0))
if ((x > 0) && (y < 0))
{
al_set_errno(ERANGE);
return 0x7FFFFFFF;
Expand All @@ -96,7 +96,7 @@ nothrow @nogc extern (C)
long ly = y;
long lres = (lx*ly);

if (lres > 0x7FFFFFFF0000L)
if (lres > 0x7FFFFFFF0000L)
{
al_set_errno(ERANGE);
return 0x7FFFFFFF;
Expand Down Expand Up @@ -133,7 +133,7 @@ nothrow @nogc extern (C)
al_set_errno(ERANGE);
return 0x80000000;
}
else
else
{
return cast(al_fixed)(lres);
}
Expand Down
Loading

0 comments on commit 147ca7f

Please sign in to comment.