private void setupModuleListeners() {
    module.addListener(observable -> {
      WorkbenchModule current = getModule();
      // Replace any occurence of \n with space
      name.setValue(current.getName().replace("\n", " "));
      icon.setValue(current.getIcon());

      // Sets the id with toString of module.
      // Adds 'tab-', replaces spaces with hyphens and sets letters to lowercase.
      // eg. Customer Management converts to tab-customer-management
      String tabId = WorkbenchUtils.convertToId("tab-" + current.getName());
      LOGGER.debug("Set Tab-ID of '" + getModule() + "' to: '" + tabId + "'");
      setId(tabId);
    });
  }
Constructs a new {@link Tab}.

@param workbench which created this {@link Tab}
workbenchfx-core/src/main/java/com/dlsc/workbenchfx/view/controls/module/Tab.java