The PNGs used as sources for the different examples are:
All assets are created by Kenney.
Adding a simple 9-Patch UI element by using the NinePatchBundle component bundle.
Changing the size of a 9-Patch UI element by modifying the Style.size component.
To set the content of a 9-Patch UI element, you can specify an Entity when setting the NinePatchData component. This Entity will be set as a children of the 9-Patch UI element.
When more flexibility is needed to set the content, it can be done by creating a system with a query on the NinePatchContent component.
Complete example with:
- a complex 9-Patch UI element with two different content zones and a top bar that has two different parts that can grow
- 9-Patch UI elements inside a 9-Patch UI element inside a 9-Patch UI element
- Some 9-Patch UI elements change size during time






