make width method protected

This commit is contained in:
yggverse 2024-07-29 18:43:40 +03:00
parent 53626a602a
commit 016a81ecfa
2 changed files with 2 additions and 6 deletions

View file

@ -139,7 +139,7 @@ class Markup implements \Yggverse\Yoda\Interface\Model\Gtk\Pango\Markup
throw new Exception; throw new Exception;
} }
public static function width( protected static function _width(
string $markup string $markup
): ?int ): ?int
{ {
@ -173,7 +173,7 @@ class Markup implements \Yggverse\Yoda\Interface\Model\Gtk\Pango\Markup
foreach (explode(' ', $string) as $word) foreach (explode(' ', $string) as $word)
{ {
if (isset($words[$line]) && Markup::width(implode(' ', $words[$line])) > $width) if (isset($words[$line]) && self::_width(implode(' ', $words[$line])) > $width)
{ {
$line++; $line++;
} }

View file

@ -56,8 +56,4 @@ interface Markup
string $const, string $const,
bool $close bool $close
): string; ): string;
public static function width(
string $markup
): ?int;
} }