color = new Color(Color::COLOR_BLACK); } /** * Get Visible. */ public function isVisible(): bool { return $this->visible; } /** * Set Visible. */ public function setVisible(bool $pValue = false): self { $this->visible = $pValue; return $this; } /** * Get Blur radius. */ public function getBlurRadius(): int { return $this->blurRadius; } /** * Set Blur radius. */ public function setBlurRadius(int $pValue = 6): self { $this->blurRadius = $pValue; return $this; } /** * Get Shadow distance. */ public function getDistance(): int { return $this->distance; } /** * Set Shadow distance. * * @return $this */ public function setDistance(int $pValue = 2): self { $this->distance = $pValue; return $this; } /** * Get Shadow direction (in degrees). */ public function getDirection(): int { return $this->direction; } /** * Set Shadow direction (in degrees). */ public function setDirection(int $pValue = 0): self { $this->direction = $pValue; return $this; } /** * Get Shadow alignment. */ public function getAlignment(): string { return $this->alignment; } /** * Set Shadow alignment. */ public function setAlignment(string $pValue = self::SHADOW_BOTTOM_RIGHT): self { $this->alignment = $pValue; return $this; } /** * Get Color. */ public function getColor(): ?Color { return $this->color; } /** * Set Color. */ public function setColor(Color $pValue = null): self { $this->color = $pValue; return $this; } /** * Get Alpha. */ public function getAlpha(): int { return $this->alpha; } /** * Set Alpha. */ public function setAlpha(int $pValue = 0): self { $this->alpha = $pValue; return $this; } /** * Get hash code. * * @return string Hash code */ public function getHashCode(): string { return \md5(($this->visible ? 't' : 'f') . $this->blurRadius . $this->distance . $this->direction . $this->alignment . $this->color->getHashCode() . $this->alpha . __CLASS__); } /** * Get hash index. * * Note that this index may vary during script execution! Only reliable moment is * while doing a write of a workbook and when changes are not allowed. * * @return int|null Hash index */ public function getHashIndex(): ?int { return $this->hashIndex; } /** * Set hash index. * * Note that this index may vary during script execution! Only reliable moment is * while doing a write of a workbook and when changes are not allowed. * * @param int $value Hash index * * @return $this */ public function setHashIndex(int $value) { $this->hashIndex = $value; return $this; } }