Go to the documentation of this file.
17 $def =
$config->getCSSDefinition();
18 $this->info[
'list-style-type'] = $def->info[
'list-style-type'];
19 $this->info[
'list-style-position'] = $def->info[
'list-style-position'];
20 $this->info[
'list-style-image'] = $def->info[
'list-style-image'];
27 if ($string ===
'')
return false;
30 $bits = explode(
' ', strtolower($string));
33 $caught[
'type'] =
false;
34 $caught[
'position'] =
false;
35 $caught[
'image'] =
false;
40 foreach ($bits as $bit) {
42 if ($bit ===
'')
continue;
43 foreach ($caught as $key =>
$status) {
44 if (
$status !==
false)
continue;
45 $r = $this->info[
'list-style-' . $key]->validate($bit,
$config, $context);
46 if ($r ===
false)
continue;
50 if ($key ==
'image')
continue;
58 if (!
$i)
return false;
63 if ($caught[
'type'])
$ret[] = $caught[
'type'];
66 if ($caught[
'image'])
$ret[] = $caught[
'image'];
69 if ($caught[
'position'])
$ret[] = $caught[
'position'];
71 if (empty(
$ret))
return false;
72 return implode(
' ',
$ret);