diff --git a/src/base/assets_manager.c b/src/base/assets_manager.c index 99449f44a..54de43778 100644 --- a/src/base/assets_manager.c +++ b/src/base/assets_manager.c @@ -146,7 +146,9 @@ static asset_info_t* try_load_image(assets_manager_t* am, const char* name, subpath = "assets/raw/images/svg"; break; } - default: { return NULL; } + default: { + return NULL; + } } return_value_if_fail(build_path(am, path, MAX_PATH, ratio, subpath, name, extname) == RET_OK, @@ -195,7 +197,9 @@ static asset_info_t* try_load_assets(assets_manager_t* am, const char* name, con subpath = "assets/raw/data"; break; } - default: { return NULL; } + default: { + return NULL; + } } return_value_if_fail(build_path(am, path, MAX_PATH, FALSE, subpath, name, extname) == RET_OK, diff --git a/src/base/line_break.c b/src/base/line_break.c index 6a083cbab..f773c284b 100644 --- a/src/base/line_break.c +++ b/src/base/line_break.c @@ -50,7 +50,9 @@ break_type_t line_break_check(wchar_t c1, wchar_t c2) { case LINEBREAK_NOBREAK: { return LINE_BREAK_NO; } - default: { return LINE_BREAK_ALLOW; } + default: { + return LINE_BREAK_ALLOW; + } } } diff --git a/src/base/text_edit.c b/src/base/text_edit.c index 314fc09a5..2ce12205c 100644 --- a/src/base/text_edit.c +++ b/src/base/text_edit.c @@ -464,7 +464,9 @@ static int32_t text_edit_calc_x(text_edit_t* text_edit, row_info_t* iter) { case ALIGN_H_RIGHT: { return (layout_info->w - row_width); } - default: { break; } + default: { + break; + } } } diff --git a/src/ext_widgets/mledit/mledit.c b/src/ext_widgets/mledit/mledit.c index ec57cd7ea..4a7bd517a 100644 --- a/src/ext_widgets/mledit/mledit.c +++ b/src/ext_widgets/mledit/mledit.c @@ -182,7 +182,7 @@ static ret_t mledit_on_destroy(widget_t* widget) { mledit_t* mledit = MLEDIT(widget); return_value_if_fail(widget != NULL && mledit != NULL, RET_BAD_PARAMS); - if(mledit->timer_id != TK_INVALID_ID) { + if (mledit->timer_id != TK_INVALID_ID) { timer_remove(mledit->timer_id); } diff --git a/src/ext_widgets/scroll_view/children_layouter_list_view.c b/src/ext_widgets/scroll_view/children_layouter_list_view.c index ad74d4ab9..841e34cc7 100644 --- a/src/ext_widgets/scroll_view/children_layouter_list_view.c +++ b/src/ext_widgets/scroll_view/children_layouter_list_view.c @@ -182,8 +182,7 @@ static ret_t children_layouter_list_view_layout(children_layouter_t* layouter, w widget_t* scroll_bar = NULL; scroll_view_t* scroll_view = SCROLL_VIEW(widget); children_layouter_list_view_t* l = (children_layouter_list_view_t*)layouter; - return_value_if_fail(l != NULL && widget != NULL && scroll_view != NULL && l != NULL, - RET_BAD_PARAMS); + return_value_if_fail(widget != NULL && scroll_view != NULL && l != NULL, RET_BAD_PARAMS); virtual_h = widget->h; list_view = LIST_VIEW(widget->parent); diff --git a/src/svg/bsvg_draw.c b/src/svg/bsvg_draw.c index 7f0272099..c7fb7011e 100644 --- a/src/svg/bsvg_draw.c +++ b/src/svg/bsvg_draw.c @@ -229,7 +229,9 @@ ret_t bsvg_draw_path(draw_ctx_t* ctx, const svg_path_t* path) { break; } case SVG_PATH_NULL: - default: { break; } + default: { + break; + } } return RET_OK; diff --git a/src/svg/bsvg_to_svg.c b/src/svg/bsvg_to_svg.c index 7a1593f9e..5e90f5a1e 100644 --- a/src/svg/bsvg_to_svg.c +++ b/src/svg/bsvg_to_svg.c @@ -132,7 +132,9 @@ ret_t bsvg_to_svg_path(str_t* str, const svg_path_t* path) { break; } case SVG_PATH_NULL: - default: { break; } + default: { + break; + } } return str_append(str, buff); diff --git a/src/svg/svg_path_parser.c b/src/svg/svg_path_parser.c index fcaa5a7f1..716140ebb 100644 --- a/src/svg/svg_path_parser.c +++ b/src/svg/svg_path_parser.c @@ -248,7 +248,9 @@ static ret_t svg_path_parser_parse_cmd(svg_path_parser_t* parser, char c) { } break; } - default: { assert(!"not supported path!"); } break; + default: { + assert(!"not supported path!"); + } break; } return RET_OK; diff --git a/src/tkc/path.c b/src/tkc/path.c index 745fcde0d..9547114ce 100644 --- a/src/tkc/path.c +++ b/src/tkc/path.c @@ -163,7 +163,9 @@ ret_t path_normalize(const char* path, char* result, int32_t size) { } break; } - default: { *d++ = *s++; } + default: { + *d++ = *s++; + } } } diff --git a/src/tkc/value.c b/src/tkc/value.c index 1de588e7c..d9d38b97d 100644 --- a/src/tkc/value.c +++ b/src/tkc/value.c @@ -37,7 +37,9 @@ bool_t value_bool(const value_t* v) { case VALUE_TYPE_WSTRING: { return tk_watob(v->value.wstr); } - default: { return value_int(v) ? TRUE : FALSE; } + default: { + return value_int(v) ? TRUE : FALSE; + } } } @@ -448,7 +450,9 @@ int value_int(const value_t* v) { case VALUE_TYPE_WSTRING: { return tk_watoi(v->value.wstr); } - default: { assert(!"not supported type"); } + default: { + assert(!"not supported type"); + } } return 0; diff --git a/src/vgcanvas/vgcanvas_cairo.c b/src/vgcanvas/vgcanvas_cairo.c index 139d0006e..bf9fac3ec 100644 --- a/src/vgcanvas/vgcanvas_cairo.c +++ b/src/vgcanvas/vgcanvas_cairo.c @@ -414,7 +414,9 @@ static cairo_surface_t* create_surface(uint32_t w, uint32_t h, bitmap_format_t f cairo_format = CAIRO_FORMAT_RGB16_565; break; } - default: { return NULL; } + default: { + return NULL; + } } return cairo_image_surface_create_for_data(fbuff, cairo_format, w, h, w * bpp); diff --git a/src/vgcanvas/vgcanvas_nanovg_soft.inc b/src/vgcanvas/vgcanvas_nanovg_soft.inc index 30ee80d7e..947388c8c 100644 --- a/src/vgcanvas/vgcanvas_nanovg_soft.inc +++ b/src/vgcanvas/vgcanvas_nanovg_soft.inc @@ -111,7 +111,9 @@ static int vgcanvas_nanovg_ensure_image(vgcanvas_nanovg_t* canvas, bitmap_t* img f = NVG_TEXTURE_RGB; break; } - default: { assert(!"not supported format"); } + default: { + assert(!"not supported format"); + } } i = nvgCreateImageRaw(canvas->vg, img->w, img->h, f, NVG_IMAGE_NEAREST, img->data);