mirror of
https://github.com/esphome/esphome.git
synced 2024-12-12 08:24:55 +01:00
Apply ci-custom and clang-format fixes
This commit is contained in:
parent
b49453ef7e
commit
65825516d4
1 changed files with 9 additions and 6 deletions
|
@ -94,7 +94,8 @@ std::vector<std::shared_ptr<CalculatedTextRun>> TextRunPanel::split_runs_into_wo
|
|||
return runs;
|
||||
}
|
||||
|
||||
std::vector<std::shared_ptr<LineInfo>> TextRunPanel::fit_words_to_bounds(const std::vector<std::shared_ptr<CalculatedTextRun>> &runs, display::Rect bounds) {
|
||||
std::vector<std::shared_ptr<LineInfo>> TextRunPanel::fit_words_to_bounds(
|
||||
const std::vector<std::shared_ptr<CalculatedTextRun>> &runs, display::Rect bounds) {
|
||||
int x_offset = 0;
|
||||
int y_offset = 0;
|
||||
int current_line_number = 0;
|
||||
|
@ -128,7 +129,8 @@ std::vector<std::shared_ptr<LineInfo>> TextRunPanel::fit_words_to_bounds(const s
|
|||
return lines;
|
||||
}
|
||||
|
||||
void TextRunPanel::apply_alignment_to_lines(std::vector<std::shared_ptr<LineInfo>> &lines, display::TextAlign alignment) {
|
||||
void TextRunPanel::apply_alignment_to_lines(std::vector<std::shared_ptr<LineInfo>> &lines,
|
||||
display::TextAlign alignment) {
|
||||
const auto x_align = display::TextAlign(int(this->text_align_) & TEXT_ALIGN_X_MASK);
|
||||
const auto y_align = display::TextAlign(int(this->text_align_) & TEXT_ALIGN_Y_MASK);
|
||||
|
||||
|
@ -208,7 +210,8 @@ CalculatedLayout TextRunPanel::determine_layout(display::Display *display, displ
|
|||
}
|
||||
layout.bounds.h = y_offset;
|
||||
|
||||
ESP_LOGD(TAG, "Text fits on %i lines and its bounds are (%i, %i)", layout.line_count, layout.bounds.w, layout.bounds.h);
|
||||
ESP_LOGD(TAG, "Text fits on %i lines and its bounds are (%i, %i)", layout.line_count, layout.bounds.w,
|
||||
layout.bounds.h);
|
||||
|
||||
return layout;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue