ILIAS
release_8 Revision v8.23
◀ ilDoc Overview
Letter.php
Go to the documentation of this file.
1
<?php
2
3
declare(strict_types=1);
4
21
namespace
ILIAS\UI\Implementation\Component\Symbol\Avatar
;
22
23
use
ILIAS\UI\Component
as
C
;
24
25
class
Letter
extends
Avatar
implements C\Symbol\Avatar\Letter
26
{
27
public
function
getAbbreviation
(): string
28
{
29
return
(substr($this->
getUsername
(), 0, 2));
30
}
31
32
public
function
getBackgroundColorVariant
():
int
33
{
34
return
((crc32($this->
getAbbreviation
()) % 26) + 1);
35
}
36
}
ILIAS\UI\Implementation\Component\Symbol\Avatar\Letter\getAbbreviation
getAbbreviation()
Definition:
Letter.php:27
ILIAS\UI\Component
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
ILIAS\UI\Component\Symbol\Avatar\Avatar\getUsername
getUsername()
ILIAS\UI\Implementation\Component\Symbol\Avatar\Letter\getBackgroundColorVariant
getBackgroundColorVariant()
Definition:
Letter.php:32
ILIAS\UI\Component\Symbol\Avatar\Letter
Definition:
Letter.php:23
ILIAS\UI\Implementation\Component\Symbol\Avatar\Avatar
Definition:
Avatar.php:27
ILIAS\UI\Component\Symbol\Avatar\Letter\getAbbreviation
getAbbreviation()
ILIAS\Repository\int
int(string $key)
Definition:
trait.BaseGUIRequest.php:61
ILIAS\UI\Implementation\Component\Symbol\Avatar
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
Definition:
Avatar.php:21
src
UI
Implementation
Component
Symbol
Avatar
Letter.php
Generated on Wed Sep 3 2025 22:02:58 for ILIAS by
1.8.13 (using
Doxyfile
)