You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-13 13:31:48 +00:00
clang-format: Enable BreakBeforeTernaryOperators
clang-format keeps breaking the way it handles break *after* ternary operators, so I give up and go with the only style they seem to actually test.
This commit is contained in:
@@ -2983,16 +2983,16 @@ void CanvasItemEditor::_draw_ruler_tool() {
|
||||
|
||||
const Vector2 end_to_begin = (end - begin);
|
||||
|
||||
real_t arc_1_start_angle = end_to_begin.x < 0 ?
|
||||
(end_to_begin.y < 0 ? 3.0 * Math_PI / 2.0 - vertical_angle_rad : Math_PI / 2.0) :
|
||||
(end_to_begin.y < 0 ? 3.0 * Math_PI / 2.0 : Math_PI / 2.0 - vertical_angle_rad);
|
||||
real_t arc_1_start_angle = end_to_begin.x < 0
|
||||
? (end_to_begin.y < 0 ? 3.0 * Math_PI / 2.0 - vertical_angle_rad : Math_PI / 2.0)
|
||||
: (end_to_begin.y < 0 ? 3.0 * Math_PI / 2.0 : Math_PI / 2.0 - vertical_angle_rad);
|
||||
real_t arc_1_end_angle = arc_1_start_angle + vertical_angle_rad;
|
||||
// Constrain arc to triangle height & max size
|
||||
real_t arc_1_radius = MIN(MIN(arc_radius_max_length_percent * ruler_length, ABS(end_to_begin.y)), arc_max_radius);
|
||||
|
||||
real_t arc_2_start_angle = end_to_begin.x < 0 ?
|
||||
(end_to_begin.y < 0 ? 0.0 : -horizontal_angle_rad) :
|
||||
(end_to_begin.y < 0 ? Math_PI - horizontal_angle_rad : Math_PI);
|
||||
real_t arc_2_start_angle = end_to_begin.x < 0
|
||||
? (end_to_begin.y < 0 ? 0.0 : -horizontal_angle_rad)
|
||||
: (end_to_begin.y < 0 ? Math_PI - horizontal_angle_rad : Math_PI);
|
||||
real_t arc_2_end_angle = arc_2_start_angle + horizontal_angle_rad;
|
||||
// Constrain arc to triangle width & max size
|
||||
real_t arc_2_radius = MIN(MIN(arc_radius_max_length_percent * ruler_length, ABS(end_to_begin.x)), arc_max_radius);
|
||||
|
||||
Reference in New Issue
Block a user