Return JS placeholder image
@param integer $width
@param integer $height
@param string $text
@param string $backgroundColor
@param string $textColor
@param array $options
@return string
489779
private function jsPlaceholder($width, $height, $text, $backgroundColor, $textColor, $random, array $options)
    {
        $src = 'holder.js/' . $width . 'x' . $height . '?bg=' . $backgroundColor . '&fg=' . $textColor . '&text=' . $text;

        if ($random) {
            $src .= $src . '&random=yes';
        }

        return Html::img('', array_merge($options, ['data-src' => $src]));
    }
1198873
public function image($text, array $options = []) {
		return $this->Html->image($this->uri($text), $options);
	}
1077172
public function process($width = null, $height = null, $options = []) {
        return $this
            ->autoRotate()
            ->trim($options)
            ->resizeAndOrCrop($width, $height, $options)
            ->applyFilters($options)
        ;
    }
874181
public function getImageDataUri($string, $size = 64, $color = null)
	{
		return sprintf('data:image/png;base64,%s', base64_encode($this->getImageData($string, $size, $color)));
	}
479769
static function createImage( $width, $height, &$useTruecolor )
    {
        if ( $useTruecolor === null )
        {
//             print( "has GD2='" . eZImageInterface::hasGD2() . "'<br/>" );
            $useTruecolor = eZImageInterface::hasGD2();
        }
        if ( $useTruecolor and
             !function_exists( 'ImageCreateTrueColor' ) )
        {
            eZDebug::writeWarning( 'Function ImageCreateTrueColor does not exist, cannot create true color images', __METHOD__ );
            $useTruecolor = false;
        }
        if ( $useTruecolor )
            $imageObject = ImageCreateTrueColor( $width, $height );
        else
            $imageObject = ImageCreate( $width, $height );
        return $imageObject;
    }
835993
public function canvas($width, $height = NULL, $rgb = 'transparent', $real = false) : GD
    {   
        if( $this->mime->type($width, 0) === 'image' )
        {
            $this->createImageCanvas($width);
        }
        else
        {
            $this->createEmptyCanvas($width, $height, $rgb, $real, $p1);
        }
        
        $this->defaultRevolvingVariables();

        return $this;
    }
185618
public function resize($image, $width = null, $height = null, $options = [])
    {
        if (!$this->fileExists($image)) {
            return $this->getMediaImageUrl($image);
        }
        
        $resizedImage = 'resized/' . $width . 'x' . $height . '/' . $image;
        if (!$this->fileExists($resizedImage)) {
            $imageResize = $this->setup($image, $width, $height, $options);
            $imageResize->resize($width, $height);
            $imageResize->save($this->getMediaDirectory()->getAbsolutePath($resizedImage));
        }
        
        return $this->getMediaImageUrl($resizedImage);
    }
1305938
public function withDefaultImage(
        $width = null,
        $height = null,
        $options = null)
    {
        $this->withRenamedImage(null, null, $width, $height, $options);

        return $this;
    }
10191
def image(size, options={})
      domain           = options[:domain] || 'http://placehold.it'
      src              = "#{domain}/#{size}"
      hex              = %w(a b c d e f 0 1 2 3 4 5 6 7 8 9)
      background_color = options[:background_color]
      color            = options[:color]

      if options[:random_color]
        background_color = hex.shuffle[0...6].join
        color = hex.shuffle[0...6].join
      end

      src << "/#{background_color.sub(/^#/, '')}" if background_color
      src << '/ccc' if background_color.nil? && color
      src << "/#{color.sub(/^#/, '')}" if color
      src << "&text=#{Rack::Utils.escape(options[:text])}" if options[:text]

      src
    end
925438
public function ThumbnailURL($width, $height)
    {
        $thumbnail = $this->Thumbnail($width, $height);
        if ($thumbnail) {
            return $thumbnail->getURL();
        }
        return $this->getIcon();
    }
1150580
protected function setup($image, $width = null, $height = null, $options = [])
    {
        $imageResize = $this->imageFactory->create();
        $imageResize->open($this->getMediaDirectory()->getAbsolutePath($image));
        if (!empty($options)) {
            foreach ($options as $method => $value) {
                $imageResize->$method($value);
            }
        }
        return $imageResize;
    }
299230
public static function image($url, $name = null, $options = [])
    {
        $options['src'] = $url;

        self::exclure($options);

        return self::input('image', $name, null, $options);
    }
1037624
static function imageCreate( $width, $height, $isTrueColor = true )
    {
        if ( $isTrueColor )
            return ImageCreateTrueColor( $width, $height );
        else
            return ImageCreate( $width, $height );
    }
57648
public function newImage($width, $height, $background = 'white')
    {
        $this->resource->createNew($width, $height, $background);

        return $this;
    }
809645
public function getUrl($width=null, $height=null)
    {

        if ($width || $height) {
            return $this->urlForSize($width, $height);

        }

        if (!$this->url) {
            $this->url = new Url($this->__get('url'));
        }

        return $this->url;

    }
1247714
def image_url(self, width=None, height=None):
        
        width_ = width or self.random_int(max=1024)
        height_ = height or self.random_int(max=1024)
        placeholder_url = self.random_element(self.image_placeholder_services)
        return placeholder_url.format(width=width_, height=height_)
442982
public function ThumbnailURL($width, $height)
    {
        $object = $this->getObjectLatestVersion();
        if ($object instanceof Thumbnail) {
            return $object->ThumbnailURL($width, $height);
        }
        return null;
    }