What actions should be taken to address the issue of excessive memory consumption by the UI

edited November 2024 in Elecrow HMI Display

Widgets and Screens:
1.Try to minimize the number of widgets and screens used in your project.

Fonts:
1. Try to minimize the number of different font types used
2. Minimize the generated font characters to only those you'll actually use - avoid unnecessarily generated characters. Use the Range and Symbols sections in the Font Manager.
https://docs.squareline.io/docs/dev_env/fontmanager#create-new-font

Images:
1. Try to minimize the number of images used
2. Avoid using images with alpha channels when possible
3. Where applicable, tile images that can be repeated. For example, instead of saving a divider line as a full image, save just a small section and adjust the widget size in the editor to determine the image size.
4. Try to use style effects rather than images wherever possible.

Memory Optimization:
1. Use the Temporary option in screen settings. When enabled, this loads the screen into memory only when it appears. It's recommended to enable this for all screens so only one screen loads into memory at a time, rather than the entire project.
https://docs.squareline.io/docs/widgets#screen

Tagged:

Comments

  • To address excessive memory consumption by the UI, minimize widget and screen usage, reduce font types and characters, limit image use and avoid alpha channels, tile images where possible, and prioritize style effects. Enable the "Temporary" option for screens to load them only when needed, optimizing memory usage.

  • @talharizwaann said:
    To address excessive memory consumption by the UI, minimize widget and screen usage, reduce font types and characters, limit image use and avoid alpha channels, tile images where possible, and prioritize style effects. Enable the "Temporary" option for screens to load them only when needed, optimizing memory usage.

    >
    To optimize memory usage, focus on simplifying UI elements: use fewer widgets/screens, limit fonts and images, avoid alpha channels, tile images, prioritize styles, and enable "Temporary" screens for efficient loading.

  • edited January 30

    Excessive UI memory consumption can be tackled by first profiling to pinpoint the problematic areas. Next, optimize UI elements by using smaller, compressed images, simplifying complex layouts, and ensuring animations are hardware-accelerated and efficient. Implement memory management techniques like caching, object pooling, and diligently fixing memory leaks. Code optimization is crucial, focusing on efficient data structures, minimizing unnecessary object creation, and employing lazy loading. Finally, regular testing and monitoring of memory usage across different devices are essential to catch issues early and maintain a smooth user experience. Check nulls brawl apk that has well designed UI without consuming excessive memory.

  • edited January 30

    @talharizwaann said:
    To address excessive memory consumption by the UI, minimize widget and screen usage, reduce font types and characters, limit image use and avoid alpha channels, tile images where possible, and prioritize style effects. Enable the "Temporary" option for screens to load them only when needed, optimizing memory usage.

    To optimize memory, streamline widgets, screens, and fonts while minimizing images and alpha channels.Use tiling, prioritize styles efficiently, and enable "Temporary" screens for better memory management and performance.

  • edited January 30

    @talharizwaann said:
    To address excessive memory consumption by the UI, minimize widget and screen usage, reduce font types and characters, limit image use and avoid alpha channels, tile images where possible, and prioritize style effects. Enable the "Temporary" option for screens to load them only when needed, optimizing memory usage.

    Minimizing widgets, screens, and font variations while optimizing images and effects is a great approach to reducing memory usage. Enabling the "Temporary" option further enhances efficiency by loading screens only when necessaryThese steps collectively ensure a smoother UI experience with lower resource consumption.

Sign In or Register to comment.