Set cell alignment.

@access public
@param string $location alignment for the cell ('left', 'right', etc...).
979846
function setAlign($location)
    {
        if (preg_match("/\d/",$location)) {
            return;                      // Ignore numbers
        }

        $location = strtolower($location);

        if ($location == 'left') {
            $this->_text_h_align = 1;
        }
        if ($location == 'centre') {
            $this->_text_h_align = 2;
        }
        if ($location == 'center') {
            $this->_text_h_align = 2;
        }
        if ($location == 'right') {
            $this->_text_h_align = 3;
        }
        if ($location == 'fill') {
            $this->_text_h_align = 4;
        }
        if ($location == 'justify') {
            $this->_text_h_align = 5;
        }
        if ($location == 'merge') {
            $this->_text_h_align = 6;
        }
        if ($location == 'equal_space') { // For T.K.
            $this->_text_h_align = 7;
        }
        if ($location == 'top') {
            $this->_text_v_align = 0;
        }
        if ($location == 'vcentre') {
            $this->_text_v_align = 1;
        }
        if ($location == 'vcenter') {
            $this->_text_v_align = 1;
        }
        if ($location == 'bottom') {
            $this->_text_v_align = 2;
        }
        if ($location == 'vjustify') {
            $this->_text_v_align = 3;
        }
        if ($location == 'vequal_space') { // For T.K.
            $this->_text_v_align = 4;
        }
    }
531021
public function matchLocation(Location $location)
    {
        $contentType = $this->repository
            ->getContentTypeService()
            ->loadContentType($location->getContentInfo()->contentTypeId);

        return isset($this->values[$contentType->identifier]);
    }
819785
public function setPositionXL($positionXL = self::xlLegendPositionRight)
    {
        if (!array_key_exists($positionXL, self::$positionXLref)) {
            return false;
        }

        $this->position = self::$positionXLref[$positionXL];
        return true;
    }
185094
public void setPosition(final Object targetObj, final CellPosition position) {
        
        ArgUtils.notNull(targetObj, "targetObj");
        ArgUtils.notNull(position, "position");
        
        positionSetter.ifPresent(setter -> setter.set(targetObj, position));
    }
318346
public function setPosition( $pos )
	{
		if ( $pos == $this->getPosition() ) { return; }

		$this->_values['pos'] = (int) $pos;
		$this->setModified();
	}
439733
protected function setOrderByDirection($direction)
    {
        $direction = strtolower($direction);

        if ($direction == 'desc' || $direction == 'asc') {
            $this->orderByDirection = $direction;
        }
    }
212172
public function setLocation($location)
    {
        if (! is_int($location)) {
            throw new \InvalidArgumentException(
                'Argument 1 must be an int value. Valued passed is of type ' . gettype($location));
        }
        
        $this->location = $location;
    }
346737
public function setLocation(string $location)
    {
        $dir = Directory::make($location, Directory::MAKE_DIRECTORY_EXISTS_OPEN);

        $old = $this->getPath();
        $new = $dir->getPath();

        if(rename($old, $new)) {
            $this->_location = $dir->getPath();
        }
    }
961543
public function setAlign($align)
    {
        foreach ($this->results as $name) {
            $this->columns->offsetGet($name)->setAlign($align);
        }
    }
632274
public function setCellno($cellno)
    {
        if (!is_string($cellno)) {
            $cellno = strval($cellno);
        }

        $this->cellno = $cellno;
    }
1042825
public function seek($position)
    {
        if ($position < 0) {
            $position = 0;
        } elseif ($position > $this->count()) {
            $position = $this->count();
        }

        if (isset($this->rows[ $position ])) {
            $this->position = $position;
        }
    }
1314623
public function setLocation( Location $location )
    {
        foreach ( $this->handlers as $handler )
        {
            if ( $handler instanceof LocationAwareHandlerInterface )
            {
                $handler->setLocation( $location );
            }
        }
    }
982882
public void setupCellPositoin(final CellPosition address) {
        ArgUtils.notNull(address, "address");
        setupCellPositoin(address.getRow(), address.getColumn());
    }
80827
public function setColumnAlignments(array $alignments)
    {
        $this->columnAlignments = array();

        foreach ($alignments as $column => $alignment) {
            $this->setColumnAlignment($column, $alignment);
        }

        return $this;
    }
1189150
private function createRestLocation(Location $location): RestLocation
    {
        return new RestLocation(
            $location,
            $this->locationService->getLocationChildCount($location)
        );
    }
1324019
public function addLocation($location, $data = null)
  {
    if(InUseLocation::isValid($location))
    {
      $this->locations[] = [$location, $data];
    }
    return $this;
  }
458009
public function setPositionXL($positionXL = self::xlLegendPositionRight) {
		if (!array_key_exists($positionXL,self::$_positionXLref)) {
			return false;
		}

		$this->_position = self::$_positionXLref[$positionXL];
		return true;
	}