@Override
  public String getLayoutAttribute(String nodeId, String name) {
    final ILayoutAttributeDescriptor layoutAttributeDescriptor =
        this.stylesheetDescriptor.getLayoutAttributeDescriptor(name);
    if (layoutAttributeDescriptor == null) {
      logger.warn(
          "Attempted to get layout attribute {} for ID=\"{}\" but no such stylesheet parameter is defined in stylesheet descriptor {}. Null will be returned",
          new Object[] {name, nodeId, this.stylesheetDescriptor.getName()});
      return null;
    }

    final Scope scope = layoutAttributeDescriptor.getScope();
    final IStylesheetUserPreferences stylesheetUserPreferences =
        this.getStylesheetUserPreferences(scope, false);
    if (stylesheetUserPreferences != null) {
      final String layoutAttribute = stylesheetUserPreferences.getLayoutAttribute(nodeId, name);
      if (layoutAttribute != null) {
        return layoutAttribute;
      }
    }

    if (this.distributedStylesheetUserPreferences != null) {
      final String layoutAttribute =
          this.distributedStylesheetUserPreferences.getLayoutAttribute(nodeId, name);
      if (layoutAttribute != null) {
        return layoutAttribute;
      }
    }

    return layoutAttributeDescriptor.getDefaultValue();
  }