omit unit, when no size is given; display unit to the user, so he knows what he is selecting

This commit is contained in:
Klaus Leithoff 2013-02-22 09:45:47 +00:00
parent 2315944590
commit 98120c44b3

View File

@ -72,7 +72,7 @@ class egw_ckeditor_config
$unit = 'px';
$size = (string)(int)$size;
}
return $size.$unit;
return $size.($size?$unit:'');
}
/**
@ -228,7 +228,7 @@ class egw_ckeditor_config
if (empty($unit)) $unit = 'px';
foreach(self::$font_size_options as $k => $v)
{
$config['fontSize_sizes'] .= $v.'/'.$k.$unit.';';
$config['fontSize_sizes'] .= $v.$unit.'/'.$k.$unit.';';
}
}