Commit graph

6139 commits

Author SHA1 Message Date
Michael Davidson
d7b512fc93
Fix clang-tidy issues 2024-01-03 23:36:18 +11:00
Michael Davidson
2b76450163
clang-format fixes 2024-01-03 17:08:35 +11:00
Michael Davidson
4dce318e6d
Merge branch 'add-graphical-layout-system' of github.com:MrMDavidson/esphome into add-graphical-layout-system 2024-01-03 17:01:58 +11:00
Michael Davidson
4d6ff150a9
Merge branch 'dev' into add-graphical-layout-system 2024-01-03 17:01:15 +11:00
Michael Davidson
a083240e12
Apply clang-tidy fixes 2024-01-03 17:01:02 +11:00
Clyde Stubbs
a2e152ad12
clang-format and clang-tidy scripts: More robust algorithm to find correct executable (#6041)
* More robust algorithm to find correct executable

* Revise message wording

* Add clang-tidy and clang-format to requirements.txt.
Add to message explaining install process.

* Extracted get_binary to helpers.py. Use execptions for clean exit.

* Add parameter types

* clang-{tidy,format} in requirements_test.txt
clean up script exit

* Kill processes on ^C

* Move clang-tidy and clang-format into requirements_dev.txt
2024-01-02 23:00:52 -06:00
Michael Davidson
a6f77271a4
Clang-format fixes 2024-01-03 12:51:37 +11:00
Michael Davidson
130ce44c51
Apply build fixes, black, flake8, pylint, and ci-custom recommendation 2024-01-03 12:48:28 +11:00
Michael Davidson
0403562e3a
Merge branch 'add-graphical-layout-system' of github.com:MrMDavidson/esphome into add-graphical-layout-system 2024-01-02 17:41:08 +11:00
Michael Davidson
4c1f4bbf78
Merge branch 'dev' into add-graphical-layout-system 2024-01-02 17:40:48 +11:00
Michael Davidson
395d1d10a4
Merge branch 'add-graphical-layout-system' of github.com:MrMDavidson/esphome into add-graphical-layout-system 2024-01-02 17:38:02 +11:00
Michael Davidson
c5ed675be5
Add support for Text Run Panel grabbing run text from a Sensor or Text Sensor 2024-01-02 17:37:36 +11:00
Michael Davidson
4e37a09310
Add support for TextPanels grabbing their content from Sensors and TextSensors 2024-01-02 17:32:41 +11:00
Clyde Stubbs
ae52164d9c
Display: Introduce draw_pixels_at() method for fast block display rendering (#6034)
* Introduce `draw_pixels_at()` method for fast block display rendering

* Add check for 18 vs 16 bit display.
2024-01-01 17:34:40 -06:00
Michael Davidson
29ebc9dc18
Merge branch 'dev' into add-graphical-layout-system 2024-01-01 16:12:36 +11:00
Michael Davidson
c018ba2ac3
Change to less-than-or-equal checks when laying out items
Previously this would cause the actual rendering of item to want different bounds as the longest line would reflow as it was equal to the bounds
2024-01-01 12:35:21 +11:00
Michael Davidson
c72e789be9
Additional clang-format fixes 2024-01-01 10:37:55 +11:00
Michael Davidson
5f5c35e779
ci-custom and clang-format fixes 2024-01-01 10:34:30 +11:00
Michael Davidson
b18e217313
Make margin, borders, and padding individually settable (top vs left vs bottom vs right)
Can still take an int to set all the properties equally
2024-01-01 10:23:17 +11:00
Clyde Stubbs
773cd0f414
GT911 touchscreen: Fix bug causing touch button release to fail (#6042)
* Fix bug causing gt911 touch button release to fail

* Cache button state and report changes only
2023-12-31 04:01:16 -06:00
Michael Davidson
feef234ddd
Add can_wrap_at_character - allows for overriding how lines are wrapped
This can be used if the default characters do not work for a user or to support languages other than English
2023-12-31 13:03:26 +11:00
Michael Davidson
046065b307
Use local defintions of COLOR_ON / COLOR_OFF 2023-12-31 12:41:37 +11:00
Michael Davidson
cf559ead56
More ci-custom + clang-format fixes 2023-12-31 12:05:51 +11:00
Michael Davidson
9e7ccebaa1
ci-custom and clang-format fixes 2023-12-31 11:50:18 +11:00
Michael Davidson
cbd4515900
Add ability for FixedDimensionPanel to operate in one of three modes; display dimension, child dimension, or fixed.
- Display dimensions use the width/height of the display (minus margin, border, and padding) for the dimension
- Child dimensions fix the dimension to that of the child
- Fixed dimension uses a specified pixel value (or lambda returning pixel value)
2023-12-31 09:54:07 +11:00
Michael Davidson
fed36a0af5
Add dump_config_base_properties to LayoutItem - displays the basic properties of the item (Margin, Border, Padding) 2023-12-31 09:31:51 +11:00
Michael Davidson
b1b85cdada
clang-format fixes 2023-12-30 13:48:37 +11:00
Michael Davidson
e40277aa56
clang-tidy fixes 2023-12-30 12:40:19 +11:00
Michael Davidson
62b7c05cd7
Merge branch 'dev' into add-graphical-layout-system 2023-12-30 11:59:04 +11:00
Michael Davidson
b2e949c6e9
Apply clang-tidy recommendation 2023-12-30 11:35:42 +11:00
Michael Davidson
5f47c6e255
Test, clang-format, and ci-custom fixes 2023-12-30 11:07:47 +11:00
Michael Davidson
38ac72c912
Apply clang-tidy recommendations 2023-12-30 10:53:31 +11:00
Michael Davidson
2f3b4a25b2
Add simple test layout 2023-12-30 10:49:02 +11:00
Michael Davidson
eb00e8982d
Build fixes 2023-12-30 10:35:50 +11:00
Michael Davidson
409ba147a3
clang-format, ci-custom, and build fixes 2023-12-30 10:24:38 +11:00
Pavlo Dudnytskyi
2a43e55452
HaierProtocol library updated to 0.9.25 to fix the answer_timeout bug (#6015) 2023-12-29 13:08:26 -08:00
Michael Davidson
4046d9e074
Apply flake8. pylint, ci-custom, and clang-format fixes 2023-12-29 20:30:24 +11:00
Michael Davidson
93d2e4e8ff
Add text_run_panel
Unlike text_panel (to be renamed) the text_run_panel supports multiple runs of different fonts (and thus sizes, weights, and colours) and will lay them out to the best of its ability - respecting desired alignment - as it can.
2023-12-29 20:11:30 +11:00
Michael Davidson
92f5f03bfe
Merge branch 'add-graphical-layout-system' of github.com:MrMDavidson/esphome into add-graphical-layout-system 2023-12-29 18:41:36 +11:00
Michael Davidson
b721262759
Switch to using display's definition of COLOR_ON/COLOR_OFF + improve ESP_LOGCONFIG() output 2023-12-29 18:39:38 +11:00
Michael Davidson
6e51b4f479
Ensure child items have their measure_item() called so they can perform layout, if necessary 2023-12-29 18:38:37 +11:00
Michael Davidson
9b658980b2
Add [horizontal|vertical]_child_align_to_string methods
Used as part of ESP_LOGCONFIG() to aide in human readability
2023-12-29 18:37:36 +11:00
Michael Davidson
9cb8410266
Merge branch 'dev' into add-graphical-layout-system 2023-12-29 18:36:18 +11:00
Michael Davidson
f061ff4ee4
Add setup_complete hook
Called at the end of setup() of the underlying Component. Last chance to do pre-run-time initialisation in LayoutItems
2023-12-29 18:35:55 +11:00
Clyde Stubbs
5ebb68f4ff
Ble client additions and fixes (#5277)
* Add config to disable auto-connect of BLE client.
Correct initialise MAC address of BLE client.

* Checkpont

* Fixes for automation progress.

* Fixes for automation progress.

* Checkpoint;
fix notify for ble_client

* Fix BLE client binary_output

* Various fixes

* Consider notifications on when receiving REG_FOR event.

* Add testing branch to workflow

* Add workflow

* CI changes

* CI changes

* CI clang

* CI changes

* CI changes

* Add comment about logging macros

* Add test, sanitise comment

* Revert testing change to ci config

* Update codeowners

* Revert ci config change

* Fix some state changes

* Add default case.

* Minor fixes

* Add auto-connect to logconfig
2023-12-29 01:35:44 -06:00
Michael Davidson
982942a512
Add text_align_to_string
Used for debugging ESP_LOGCONFIG purposes
2023-12-29 18:31:01 +11:00
Edward Firmo
d3567f9ac6
Nextion queue size (#6029)
* Nextion `queue_size` function

Returns the size of Nextion queue.
For troubleshooting only.

* Move `queue_size` to `nextion.h`

This is where the queue is

* Inline doc

* clang-format
2023-12-28 23:15:06 -06:00
Clyde Stubbs
21ec42f495
Add constants used by multiple display drivers to global const.py (#6033)
* Add constants used by multiple display drivers to global const.py

* Add further constants

* Refactor st7789v and st7735v
2023-12-29 02:00:19 +00:00
J. Nick Koston
d4d49e38fc
Fix device not requesting Home Assistant time at the update interval (#6022) 2023-12-28 14:51:00 +11:00
Anton Viktorov
3be97868fc
Support for ST7567 display 128x64 (I2C, SPI) (#5952) 2023-12-27 12:01:15 +11:00