This series collects together some new features for expo to make it more
useful for boot menus:

- measurement and display of multi-line text objects
- internal alignment for objects (e.g. centred text)
- editable strings in text fields
- new 'box' object to draw a rectangle
- highlighting of menu items, rather than just relying on a pointer

Expo's boot menu is restructured so that it is possible to iterate
through various bootdevs and update the menu as new ones are found. This
is more in keeping with how bootstd works.

A new textedit object is added, intended to provide a simple text
editor. Future work will complete this.

With this series the boot menu has a better layout and appearance.

Changes in v2:
- Add new patch to pass in the video device for cedit_prepare()
- Add new patch to test rendering a lineedit
- Add new patch to test editing a lineedit
- Handle the case of an initially empty string
- Only check the text objects used by the bootmenu, for now

Simon Glass (60):
  sandbox: Provide an option to skip flattree tests
  sandbox: Provide an option to continue on failure
  video: Make white-on-black a video-device property
  sandbox: Select white-on-black
  abuf: Add a function to copy a buffer
  abuf: Add a way to printf() into a buffer
  video: Add a test for font measurement
  video: Begin support for measuring multiple lines of text
  video: truetype: Fill in the measured line
  video: truetype: Support newlines in the measured string
  video: truetype: Support a limit on the width of a line
  video: Add a way to write a partial string to the console
  console: Support a format string for stderr output
  test: video: Export the video-checking functions
  video: Allow console output to be silenced
  video: Add a function to draw a rectangle
  expo: Add CLI context to the expo
  expo: Add a function to poll for input
  expo: Destroy the cedit expo when done
  vidconsole: Avoid kerning against an unrelated character
  expo: Create a rendering test for cedit
  expo: Move cedit-state fields into expo
  expo: Test some cedit actions
  expo: Pass in the video device for cedit_prepare()
  expo: Test rendering a lineedit
  expo: Provide access to the current menu item
  expo: Adjust how menu items are highlighted
  expo: Test editing a lineedit
  expo: Split bootflow_menu_run() into two pieces
  expo: Split bootflow_menu_new() into two pieces
  expo: Allow adding a single bootflow to a menu
  expo: Rename scene_dim to scene_obj_bbox
  expo: Rename x and y in struct scene_obj_bbox
  expo: Use an abuf to hold strings
  expo: Separate dimensions from the bounding box
  expo: Make bounding-box calculation more flexible
  expo: Support setting the size and bounds of an object
  expo: Line up all menu objects
  expo: Create a struct for generic text attributes
  expo: Move text-rendering into its own function
  expo: Tidy up scene_txt_render()
  expo: Allow strings to be editable
  expo: Check the screen contents after rendering
  expo: Support rendering multiple lines of text
  expo: Support white-on-black in the theme
  expo: Implement a box
  expo: Support object alignment
  expo: Begin implementation of a text editor
  expo: Use a simpler name for USB media
  expo: Drop the gap between groups of menu items
  expo: Add forward declarations to scene_internal.h
  expo: Support highlighting menu items
  expo: Adjust expo_poll() to avoid looping forever
  expo: Drop the render from expo_poll()
  expo: Provide a way to position things relative to display
  expo: Improve the visual appearance of the menu
  expo: Update bootflow_menu_poll() to return a sequence ID
  expo: Split setting up the menu from adding items
  expo: Set up menu fully in bootflow_menu_start()
  expo: Drop the special theme code for bootflow_menu

 arch/sandbox/cpu/start.c          |  19 ++
 arch/sandbox/dts/test.dts         |   1 +
 arch/sandbox/include/asm/state.h  |   2 +
 boot/Makefile                     |   2 +-
 boot/bootflow_internal.h          |  11 +-
 boot/bootflow_menu.c              | 382 +++++++++++++-----------
 boot/cedit.c                      | 160 +++++-----
 boot/expo.c                       |  74 ++++-
 boot/scene.c                      | 478 ++++++++++++++++++++++++------
 boot/scene_internal.h             |  71 ++++-
 boot/scene_menu.c                 | 166 ++++++++---
 boot/scene_textedit.c             |  61 ++++
 boot/scene_textline.c             |  44 +--
 cmd/bootflow.c                    |  43 ++-
 cmd/cedit.c                       |   2 +
 common/console.c                  |  18 ++
 doc/develop/expo.rst              |  34 +++
 drivers/video/console_truetype.c  |  90 +++++-
 drivers/video/vidconsole-uclass.c |  36 ++-
 drivers/video/video-uclass.c      |  52 +++-
 include/abuf.h                    |  32 ++
 include/bootflow.h                |  77 ++++-
 include/cedit.h                   |  17 +-
 include/console.h                 |  15 +
 include/expo.h                    | 293 ++++++++++++++++--
 include/test/test.h               |  24 ++
 include/test/ut.h                 |  57 ++--
 include/test/video.h              |  45 +++
 include/video.h                   |  31 +-
 include/video_console.h           |  83 +++++-
 lib/abuf.c                        |  49 +++
 test/boot/bootflow.c              |   9 +-
 test/boot/cedit.c                 | 217 +++++++++++++-
 test/boot/expo.c                  | 214 ++++++++++---
 test/dm/video.c                   | 352 +++++++++++++++-------
 test/lib/abuf.c                   |  87 +++++-
 test/test-main.c                  |   5 +-
 37 files changed, 2669 insertions(+), 684 deletions(-)
 create mode 100644 boot/scene_textedit.c
 create mode 100644 include/test/video.h

-- 
2.43.0

base-commit: d3446ef55a2a2ae72e6d227ed054af599a397b82
branch: schd2

Reply via email to