cleanup: convert tab to spaces and trim tail spaces

This commit is contained in:
Vincent Wei
2020-02-02 10:53:31 +08:00
parent 8dbe2c63f1
commit 14d020cccf
831 changed files with 468564 additions and 468554 deletions

View File

@@ -1,5 +1,13 @@
#!/bin/bash
tab2space() {
sed -i 's/\t/ /g' `find . -name '*.c'`
sed -i 's/\t/ /g' `find . -name '*.h'`
sed -i 's/\s\+$//g' `find . -name '*.c'`
sed -i 's/\s\+$//g' `find . -name '*.h'`
}
# templates
# sed -i 's/\<AAA\>/__AAA/g' `grep AAA -rl include/ src/`
# sed -i 's/\<AAA\>/__mgAAA/g' `grep AAA -rl include/ src/`
@@ -41,4 +49,6 @@
# sed -i 's/\<sysres_init_inner_resource\>/__sysres_init_inner_resource/g' `grep sysres_init_inner_resource -rl include/ src/`
# sed -i 's/\<sysres_get_system_res_path\>/__sysres_get_system_res_path/g' `grep sysres_get_system_res_path -rl include/ src/`
tab2space
exit 0

View File

@@ -284,7 +284,7 @@ void miFillSppPoly (PDC pdc, int count, SppPointPtr ptsIn, int xTrans, int yTran
DEALLOCATE_LOCAL(FirstPoint);
}
/* Find the index of the point with the smallest y.also return the
* smallest and largest y */
static int GetFPolyYBounds(register SppPointPtr pts, int n, double yFtrans, int* by, int* ty)

View File

@@ -266,14 +266,14 @@ static void _parallelogram_map(HDC hdc, const BITMAP *bmp, fixed sx[4],
if (index < 2)
corner_bmp_y[i] = 0;
else
/* Need `- 1' since otherwise it would be outside bitmap. */
else /* Need `- 1' since otherwise it would be outside bitmap. */
corner_bmp_y[i] = (bmp_h << 16) - 1;
if ((index == 0) || (index == 3))
corner_bmp_x[i] = 0;
else
corner_bmp_x[i] = (bmp_w << 16) - 1;
index = (index + right_index) & 3;
}