ans = 




The functionality would allow report generation straight from live scripts that could be shared without exposing the code. This could be useful for cases where the recipient of the report only cares about the results and not the code details, or when the methodology is part of a company know how, e.g. Engineering services companies.
In order for it to be practical for use it would also require that variable values could be inserted into the text blocks, e.g. #var_name# would insert the value of the variable "var_name" and possibly selecting which code blocks to be hidden.
In the latest Graphics and App Building blog article, documentation writer Jasmine Poppick modernized a figure-based bridge analysis app by replacing uicontrol with new UI components and uifigure, resulting in cleaner code, better layouts, and expanded functionality in R2025a.
https://blogs.mathworks.com/graphics-and-apps/2025/08/19/__from-uicontrol-to-ui-components
This article covers the following topics:
Why and when to move from uicontrol and figure to modern UI components and uifigure.
How to replace uicontrol objects with equivalent UI component functions (uicheckbox, uidropdown, uispinner, etc.).
How to update callback code to match new component properties and behaviors.
How to adopt new UI component types (like spinners) to simplify validation and improve usability.
How to configure existing components with modern options (sortable tables, auto-fitting columns, editable data).
How to apply visual styling with uistyle and addStyle to make apps more user-friendly.
How to use uigridlayout to create flexible, adaptive layouts instead of manually managing positions.
The benefits of switching from figure to uifigure for app-building workflows.
A full before-and-after example of modernizing an existing app with incremental, practical updates.