NAME
App::MathImage::Glib::Ex::EnumBits -- misc enum helpers
SYNOPSIS
use App::MathImage::Glib::Ex::EnumBits;
FUNCTIONS
$str = App::MathImage::Glib::Ex::EnumBits::to_text ($enum_class, $nick)
-
Return a text form for value
$nick
from$enum_class
. This is meant to be suitable for display in a menu, label, etc.$enum_class
is a string class name such as"Glib::UserDirectory"
. If that class has a$enum_class->EnumBits_to_text ($nick)
method then it's called, otherwiseto_text_default
below. $str = App::MathImage::Glib::Ex::EnumBits::to_text_default ($enum_class, $nick)
-
Return a text form for value
$nick
from$enum_class
. This function is the default forto_text
above and can be used as a fallback in ato_text
method.The nick is split into words and numbers, and
ucfirst
applied to each word. So for example "some-val1" gives "Some Val 1".