displayButton

@param $display
@return bool
180627
private static function displayButton($display): bool
    {
        if (is_bool($display))
            return $display;

        if (!method_exists(self::getButtonReactInterface(), $display))
            trigger_error(sprintf('The manager "%s" must have a method "%s"',get_class(self::getButtonReactInterface()), $display), E_USER_ERROR);

        return self::getButtonReactInterface()->$display();
    }
727114
protected function display(FieldContract $control, array $displayable = array())
    {
        $name              = $control->get('name');
        $shouldBeDisplayed = false;
        if ($control->force_displayable) {
            return true;
        }
        foreach ($displayable as $field) {

            if ($name == $field['name']) {
                $shouldBeDisplayed = true;
                break;
            }
        }
        return $shouldBeDisplayed;
    }
252550
public function display()
    {
        if (!$this->visible) {
            return;
        }

        parent::display();

        $ordered_options = $this->getOrderedOptions();

        $div_tag = new SwatHtmlTag('div');
        $div_tag->id = $this->id;
        $div_tag->class = $this->getCSSClassString();
        $div_tag->open();

        $list_div = new SwatHtmlTag('div');
        $list_div->style = "width: {$this->width}; height: {$this->height};";
        $list_div->id = "{$this->id}_list";
        $list_div->class = 'swat-change-order-list';
        $list_div->open();

        $option_div = new SwatHtmltag('div');
        $option_div->class = 'swat-change-order-item';

        foreach ($ordered_options as $option) {
            $title = $option->title === null ? '' : $option->title;
            $option_div->setContent($title, $option->content_type);
            $option_div->display();
        }

        $list_div->close();

        $this->displayButtons();

        echo '<div class="swat-clear"></div>';

        $values = array();
        foreach ($ordered_options as $option) {
            $values[] = SwatString::signedSerialize(
                $option->value,
                $this->getForm()->getSalt()
            );
        }

        $hidden_tag = new SwatHtmlTag('input');
        $hidden_tag->type = 'hidden';
        $hidden_tag->id = $this->id . '_value';
        $hidden_tag->name = $this->id;
        $hidden_tag->value = implode(',', $values);
        $hidden_tag->display();

        $hidden_items_tag = new SwatHtmlTag('input');
        $hidden_items_tag->type = 'hidden';
        $hidden_items_tag->id = $this->id . '_dynamic_items';
        $hidden_items_tag->value = '';
        $hidden_items_tag->display();

        $div_tag->close();

        Swat::displayInlineJavaScript($this->getInlineJavaScript());
    }
211479
public function display()
    {
        if (!$this->visible) {
            return;
        }

        parent::display();

        $div_tag = new SwatHtmlTag('div');
        $div_tag->id = $this->id;
        $div_tag->class = $this->getCSSClassString();
        $div_tag->open();

        echo '<span class="swat-date-entry-span">';

        foreach ($this->getDatePartOrder() as $datepart) {
            if ($datepart == 'd' && $this->display_parts & self::DAY) {
                $day_flydown = $this->getCompositeWidget('day_flydown');

                if ($day_flydown->value === null && $this->value !== null) {
                    $day_flydown->value = $this->value->getDay();
                }

                $day_flydown->display();
            } elseif ($datepart == 'm' && $this->display_parts & self::MONTH) {
                $month_flydown = $this->getCompositeWidget('month_flydown');

                if ($month_flydown->value === null && $this->value !== null) {
                    $month_flydown->value = $this->value->getMonth();
                }

                $month_flydown->display();
            } elseif ($datepart == 'y' && $this->display_parts & self::YEAR) {
                $year_flydown = $this->getCompositeWidget('year_flydown');

                if ($year_flydown->value === null && $this->value !== null) {
                    $year_flydown->value = $this->value->getYear();
                }

                $year_flydown->display();
            }
        }

        echo '</span>';

        if ($this->display_parts & self::CALENDAR) {
            $calendar = $this->getCompositeWidget('calendar');
            $calendar->display();
        }

        if ($this->display_parts & self::TIME) {
            $time_entry = $this->getCompositeWidget('time_entry');

            // if we aren't using the current date then we won't use the
            // current time
            if (!$this->use_current_date) {
                $time_entry->use_current_time = false;
            }

            echo ' ';
            if ($time_entry->value === null && $this->value !== null) {
                $time_entry->value = $this->value;
            }

            $time_entry->display();
        }

        Swat::displayInlineJavaScript($this->getInlineJavaScript());

        $div_tag->close();
    }
1000117
public function totalRow($display = null)
    {
        $this->grid->addTotalRow($this->name, $display);

        return $this;
    }
629418
protected function findButtonByValue($button)
    {
        foreach ($this->all('input[type=submit]') as $element) {
            if ($element->getAttribute('value') === $button) {
                return $element;
            }
        }
    }
211041
def display(self, display):
        
        if display is None:
            raise ValueError("Invalid value for `display`, must not be `None`")  # noqa: E501
        allowed_values = ["BANNER", "TOASTER"]  # noqa: E501
        if display not in allowed_values:
            raise ValueError(
                "Invalid value for `display` ({0}), must be one of {1}"  # noqa: E501
                .format(display, allowed_values)
            )

        self._display = display
571890
public function setDisplayName($displayName)
    {
        /** @var ActionDescriptor $parent */
        $parent = $this->getParent();
        if ($parent instanceof ActionDescriptor) {
            $parentName = $parent->getName();
            if ($displayName === $parentName) {
                $this->displayName = null;
                return $this;
            }
        }
        $this->displayName = $displayName;

        return $this;
    }
433817
public function DisplayLogic()
    {
        if ($criteria = $this->getDisplayLogicCriteria()) {
            Requirements::javascript('unclecheese/display-logic: client/dist/js/bundle.js');
            Requirements::css('unclecheese/display-logic: client/dist/styles/bundle.css');
            return $criteria->toScript();
        }
        
        return false;
    }
583908
public function display($tpl, $data = array())
    {
        if ($this->isRending) {
            throw new RenderException('Display is called.');
        }

        $this->assign($data);

        echo $this->render($tpl, $data);

        return true;
    }
1181677
public function display()
    {
        if ($this->displayProperty === null) {
            $this->displayProperty = $this->createDisplayProperty();
        }

        return $this->displayProperty;
    }
1341228
public function setDisplayAmount($displayAmount = true)
    {
        $this->isBool($displayAmount, 'displayAmount');
        $this->displayAmount = $displayAmount;

        return $this;
    }
1095708
public function display($return = false)
    {
        if ($this->getStatus()===null) {
            $this->setStatus(self::STATUS_OK);
        }
        if ($this->getMessage()===null) {
            $this->setMessage(
                array_key_exists($this->getStatus(), self::$default_messages) ?
                    self::$default_messages[$this->getStatus()] : ''
            );
        }
        if ($this->getResponse()->getStatus()===null) {
            $this->getResponse()->setStatus(HttpStatus::OK);
        }
        $this->getResponse()->setHeaders($this->headers);
        if ($return) {
            return $this->getResponse();
        } else {
            $this->getResponse()->send();
        }
    }
94907
public function display()
    {
        if (!$this->visible) {
            return;
        }

        parent::display();

        $tr_tag = new SwatHtmlTag('tr');
        $tr_tag->id = $this->id;
        $tr_tag->class = $this->getCSSClassString();

        $colspan = $this->view->getXhtmlColspan();
        $td_tag = new SwatHtmlTag('td');

        $tr_tag->open();

        if ($this->offset > 0 && $this->position === self::POSITION_LEFT) {
            $this->displayOffsetCell($this->offset);
        }

        $this->displayWidgetCell();

        if ($this->offset > 0 && $this->position === self::POSITION_RIGHT) {
            $this->displayOffsetCell($this->offset);
        }

        $tr_tag->close();
    }
1292104
public function getDisplayRoundingFactor( $decimal )
	{
		// Simple chcck
		if ( ! is_numeric( $decimal ) || $decimal == 0 ) return 1;

		// Note: using '==' so the array value is coerced to zero
		if ( ! isset( $this->displayRoundings[ $decimal ] ) || $this->displayRoundings[ $decimal ] == 0 )
		{
			$this->setDisplayRoundingFactor( $decimal, abs( $decimal ) );
		}

		return $this->displayRoundings[ $decimal ];
	}
1028678
public function display()
    {
        if (!$this->visible) {
            return;
        }

        parent::display();

        $wrapper_classes = array_merge(
            array_diff($this->getCSSClassNames(), array('swat-flydown')),
            array('swat-flydown-wrapper')
        );
        $wrapper = new SwatHtmlTag('span');
        $wrapper->class = implode(' ', $wrapper_classes);
        $wrapper->open();

        $options = $this->getOptions();
        $selected = false;

        if ($this->show_blank) {
            $options = array_merge(array($this->getBlankOption()), $options);
        }

        // only show a select if there is more than one option
        if (count($options) > 1) {
            $flydown_value = $this->serialize_values
                ? $this->value
                : (string) $this->value;

            if ($this->serialize_values) {
                $salt = $this->getForm()->getSalt();
            }

            $select_tag = new SwatHtmlTag('select');
            $select_tag->name = $this->id;
            $select_tag->id = $this->id;
            $select_tag->class = $this->getCSSClassString();

            if (!$this->isSensitive()) {
                $select_tag->disabled = 'disabled';
            }

            $option_tag = new SwatHtmlTag('option');

            $select_tag->open();

            foreach ($options as $flydown_option) {
                if ($this->serialize_values) {
                    $option_tag->value = SwatString::signedSerialize(
                        $flydown_option->value,
                        $salt
                    );
                } else {
                    $option_tag->value = (string) $flydown_option->value;
                }

                if ($flydown_option instanceof SwatFlydownDivider) {
                    $option_tag->disabled = 'disabled';
                    $option_tag->class = 'swat-flydown-option-divider';
                } elseif ($flydown_option instanceof SwatFlydownBlankOption) {
                    $option_tag->removeAttribute('disabled');
                    $option_tag->class = 'swat-blank-option';
                } else {
                    $option_tag->removeAttribute('disabled');
                    $option_tag->removeAttribute('class');

                    // add option-specific CSS classes from option metadata
                    $classes = $this->getOptionMetadata(
                        $flydown_option,
                        'classes'
                    );

                    if (is_array($classes)) {
                        $option_tag->class = implode(' ', $classes);
                    } elseif ($classes) {
                        $option_tag->class = strval($classes);
                    }
                }

                $value = $this->serialize_values
                    ? $flydown_option->value
                    : (string) $flydown_option->value;

                if (
                    $flydown_value === $value &&
                    !$selected &&
                    !($flydown_option instanceof SwatFlydownDivider)
                ) {
                    $option_tag->selected = 'selected';
                    $selected = true;
                } else {
                    $option_tag->removeAttribute('selected');
                }

                $option_tag->setContent(
                    $flydown_option->title,
                    $flydown_option->content_type
                );

                $option_tag->display();
            }

            $select_tag->close();
        } elseif (count($options) === 1) {
            // get first and only element
            $this->displaySingle(current($options));
        }

        $wrapper->close();
    }
392066
public function display()
    {
        if (!$this->visible) {
            return;
        }

        SwatWidget::display();

        $this->getForm()->addHiddenField($this->id . '_submitted', 1);

        $div_tag = new SwatHtmlTag('div');
        $div_tag->id = $this->id;
        $div_tag->class = $this->getCSSClassString();
        $div_tag->open();

        $this->label_tag = new SwatHtmlTag('label');
        $this->label_tag->class = 'swat-control';

        $this->input_tag = new SwatHtmlTag('input');
        $this->input_tag->type = 'checkbox';
        $this->input_tag->name = $this->id . '[]';

        if ($this->tree !== null) {
            $num_nodes = $this->displayNode($this->tree);
        } else {
            $num_nodes = 0;
        }

        // Only display the check-all widget if more than one checkable item is
        // displayed.
        $check_all = $this->getCompositeWidget('check_all');
        $check_all->visible = $num_nodes > 1 && $this->show_check_all;
        $check_all->display();

        $div_tag->close();

        Swat::displayInlineJavaScript($this->getInlineJavaScript());
    }