> ## Documentation Index
> Fetch the complete documentation index at: https://fdm.furkankursav.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Slot Widget

A **Slot Widget** is the visual representation of an Entry. It must implement the `WBPI_FDM_EntrySlot` interface. When an entry is added to the menu, the corresponding widget class (`WidgetSlotClass` from Metadata) is created and added to the menu, then the **InitializeSlot** interface function is called.

<img src="https://mintcdn.com/furkankursav/Tk-ROR47VDMDTlEi/images/image79.png?fit=max&auto=format&n=Tk-ROR47VDMDTlEi&q=85&s=6c8297e2fab4463e45321c24592a815f" alt="image79" width="1713" height="353" data-path="images/image79.png" />

and that’s how you can customize your widget by accessing Metadata.

<img src="https://mintcdn.com/furkankursav/Tk-ROR47VDMDTlEi/images/image80.png?fit=max&auto=format&n=Tk-ROR47VDMDTlEi&q=85&s=a162e38a882d1ceacd35642bb58c21a0" alt="image80" width="2048" height="455" data-path="images/image80.png" />

Additionally, you can keep the UI up-to-date by casting the Source Object given as a parameter to your own class and binding events.

And the other `WBPI_FDM_EntrySlot` interface function is **Set Widget Slot State**.

<img src="https://mintcdn.com/furkankursav/Tk-ROR47VDMDTlEi/images/image81.png?fit=max&auto=format&n=Tk-ROR47VDMDTlEi&q=85&s=f7f87c2843c01468b34be8897982882f" alt="image81" width="900" height="384" data-path="images/image81.png" />

This function is called to determine the visibility of the slot widget. You can use different techniques for hiding/showing your widget. I believe that the Selected, Visible, and Hidden states explain themselves; I will explain the Expanding and Collapsing states later.
