Answers the icon size class for the receiver.

@return string
511253
public function getIconSizeClass()
    {
        $size = $this->config()->default_icon_size;
        
        if (($parent = $this->getParent()) && $parent->IconSize) {
            $size = $parent->IconSize;
        }
        
        return sprintf('size-%d', $size);
    }
446238
public function getCSSClassString()
    {
        $classes = array('swat-message');

        // legacy style for backwards compatibility
        if ($this->type === 'notice') {
            $classes[] = 'swat-message-notification';
        }

        // type-specific style
        if ($this->type != '') {
            $classes[] = 'swat-message-' . $this->type;
        }

        if ($this->secondary_content !== null) {
            $classes[] = 'swat-message-with-secondary';
        }

        return implode(' ', $classes);
    }
371890
public function getPaginationSizeClass()
    {
        switch ($this->owner->PaginationSize) {
            case self::SIZE_SMALL:
                return $this->style('pagination.small');
            case self::SIZE_LARGE:
                return $this->style('pagination.large');
        }
    }
1021046
protected function _getAvailableIcons()
    {
        $dir = GEMS_WEB_DIR . '/gems-responsive/images/icons';
        if (!file_exists($dir)) {
            $dir = GEMS_WEB_DIR . '/gems/icons';
        }

        $icons = array();

        if (file_exists($dir)) {
            $iterator = new DirectoryIterator($dir);

            foreach ($iterator as $fileinfo) {
                if ($fileinfo->isFile()) {
                    // $icons[$fileinfo->getFilename()] = $fileinfo->getFilename();
                    $filename = $fileinfo->getFilename();
                    $url = $this->view->baseUrl() . \MUtil_Html_ImgElement::getImageDir($filename);
                    $icons[$fileinfo->getFilename()] = \MUtil_Html::create('span', $filename, array('style' => 'background: transparent url(' . $url . $filename . ') center right no-repeat; padding-right: 20px;'));
                }
            }
        }

        ksort($icons);  // Sort by key

        return $icons;
    }
353288
public function current()
    {
        $icon = current($this->icon);

        $fa = clone $this;

        return $fa->addClass($icon);
    }
394365
private function getImageRtfWidth()
    {
        if ($this->_width > 0) {
            return PHPRtfLite_Unit::getUnitInTwips($this->_width);
        }

        $imageWidth = $this->_imageWidth ? $this->_imageWidth : 100;
        if ($this->_height > 0) {
            $imageHeight = $this->_imageHeight ? $this->_imageHeight : 100;
            $width = ($imageWidth / $imageHeight) * $this->_height;
            return PHPRtfLite_Unit::getUnitInTwips($width);
        }

        return PHPRtfLite_Unit::getPointsInTwips($imageWidth);
    }
1122775
private function classes() : string
    {
        $classes = '';

        if ($this->xl_size !== null) {
            $classes .= ' col-xl-' . $this->xl_size;
        }

        if ($this->lg_size !== null) {
            $classes .= ' col-lg-' . $this->lg_size;
        }

        if ($this->md_size !== null) {
            $classes .= ' col-md-' . $this->md_size;
        }

        if ($this->sm_size !== null) {
            $classes .= ' col-sm-' . $this->sm_size;
        }

        if ($this->xs_size !== null) {
            $classes .= ' col-' . $this->xs_size;
        }

        if ($this->bg_color !== null) {
            $classes .= ' bg-' . $this->bg_color;
        }

        if ($this->text_color !== null) {
            $classes .= ' text-' . $this->text_color;
        }

        return trim($classes);
    }
1031734
public function getIcon($default = null)
    {
        if ($this->icon !== null && $this->icon !== '') {
            return '<i class="' . $this->icon . '"></i>';
        }
        if ($default === null) {
            return $default;
        }

        return '<i class="' . $default . '"></i>';
    }
1282080
public function getIcon()
    {
        $classNamespaces = explode("\\", static::class);
        $shortClass = end($classNamespaces);

        $resource = ModuleLoader::getModule('silverstripe/userforms')
            ->getResource('images/' . strtolower($shortClass) . '.png');

        if (!$resource->exists()) {
            return '';
        }

        return $resource->getURL();
    }
995675
public function getSizes(\ElggEntity $entity, array $icon_sizes = array()) {

		$defaults = ($entity && $entity->getSubtype() == 'file') ? $this->config->getFileIconSizes() : $this->config->getGlobalIconSizes();
		$sizes = array_merge($defaults, $icon_sizes);

		return elgg_trigger_plugin_hook('entity:icon:sizes', $entity->getType(), array(
			'entity' => $entity,
			'subtype' => $entity->getSubtype(),
				), $sizes);
	}
1168756
public function getIconUrl()
    {
        if (($sIcon = $this->oxcategories__oxicon->value)) {
            $oConfig = \OxidEsales\Eshop\Core\Registry::getConfig();
            $sSize = $oConfig->getConfigParam('sCatIconsize');
            if (!isset($sSize)) {
                $sSize = $oConfig->getConfigParam('sIconsize');
            }

            return \OxidEsales\Eshop\Core\Registry::getPictureHandler()->getPicUrl("category/icon/", $sIcon, $sSize);
        }
    }
483016
public function getButtonSizeOptions()
    {
        return [
            self::SIZE_SMALL  => _t(__CLASS__ . '.SMALL', 'Small'),
            self::SIZE_MEDIUM => _t(__CLASS__ . '.MEDIUM', 'Medium'),
            self::SIZE_LARGE  => _t(__CLASS__ . '.LARGE', 'Large')
        ];
    }
403767
public function getSize()
    {
        if (! $this->size) {
            $this->size = strlen($this->getContents());
        }
        return $this->size;
    }
717525
public function size(){
        if(empty($this->img)) $this->throwError('没有指定图像资源');
        return array($this->info['width'], $this->info['height']);
    }
775137
public function icon()
	{
		$input = [
			[icon('plane'),                  "icon('plane');",               ],
			[icon('bolt'),                   "icon('bolt');",                ],
			[icon('bolt', '#FF00FF'),        "icon('bolt', '#FF00FF');",     ],
			[icon('info', 'info'),           "icon('info', 'info');",        ],
			[icon(true),                     "icon(true);",                  ],
			[icon(false),                    "icon(false);",                 ],
		];
		$data = array_reduce($input, function ($output, $arr)
		{
			$output[] = (object) ['code' => $arr[1], 'icon' => $arr[0]];
			return $output;
		}, []);
		return view('sketchpad::help/helpers/icon', compact('data'));
	}
879952
public function get_image_sizes_for_ui() {
		// We start from scratch and build our own sizes array
		$sizes = array();

		// Build up new array of image sizes
		foreach ( Helper::get_image_sizes() as $key => $size ) {
			// Do not add our own size if it is set to false in the image config
			if ( isset( $size['show_in_ui'] ) && false === $size['show_in_ui'] ) {
				continue;
			}

			$name = $key;

			if ( isset( $size['name'] ) ) {
				$name = $size['name'] . ' (' . $key . ')';
			}

			$sizes[ $key ] = $name;
		}

		/**
		 * Re-add full size so it can still be selected.
		 *
		 * The full size is needed, if a e.g. a logo has to be displayed in the page content and no
		 * predefined size fits.
		 */
		$sizes['full'] = __( 'Full Size' );

		return $sizes;
	}
367290
public function getFormattedSize(): string
    {
        $kiloBytes = $this->getSize() / 1024;
        if ($kiloBytes < 1024) {
            return round($kiloBytes, 2).' KB';
        }
        $megaBytes = $kiloBytes / 1024;
        if ($megaBytes < 1024) {
            return round($megaBytes, 1).' MB';
        }

        return round($megaBytes / 1024, 1).' GB';
    }