Module org.autogui

Interface GuiSwingLogEntry

All Superinterfaces:
GuiLogEntry
All Known Implementing Classes:
GuiSwingLogEntryException, GuiSwingLogEntryProgress, GuiSwingLogEntryString

public interface GuiSwingLogEntry extends GuiLogEntry
a log-entry supporting GUI rendering, managed by GuiSwingLogManager
  • Method Details

    • getRendererKey

      default Object getRendererKey()
      for each key object (and also a container type), a renderer will be created by getRenderer(GuiSwingLogManager, ContainerType). by default, the key is Object.getClass()
      Returns:
      the key object
    • getRenderer

      Parameters:
      manager - the manager
      type - rendering for a list or a status-bar
      Returns:
      factory method of renderer
    • sizeCache

      default float[] sizeCache(Object renderer, Supplier<float[]> src)
      obtains cached layout-size or computes it by the size. the default impl. is just always computing as no caching. available by
            SizeCache c = new SizeCache(2);
            float[] sizeCache(Object k, Supplier src) {
                return c.computeIfAbsent(k, _k -> src.get());
            }
        
      Parameters:
      renderer - the key for the size
      src - the task for computing the size
      Returns:
      the layout-size, {w,h}
      Since:
      1.5
    • clearSelection

      default void clearSelection()
    • setSelected

      void setSelected(boolean selected)
    • isSelected

      boolean isSelected()