Text Size Fix

master
Wizard Atman 11 years ago
parent 3b6376dd1c
commit 14f2876819

@ -245,15 +245,32 @@ public class TitanEditor {
{
AttributeSetConfigured asc = cluster.get((String) at.getAttribute(const_DisplayName));
if (asc != null)
{
if (!at.getAttribute(const_DisplayName).equals("Default"))
{
res.add(apply_colors(asc, at, annotation));
}
else
{
res.add(apply_text_size_fix(apply_colors(asc, at, annotation)));
}
}
}
}
return res;
}
private static AttributeSet apply_colors (AttributeSetConfigured asc, AttributeSet at, boolean annotation) throws IllegalAccessException, IllegalArgumentException, InvocationTargetException
private static SimpleAttributeSet apply_text_size_fix (SimpleAttributeSet old)
{
if (old.isDefined(StyleConstants.FontSize))
{
old.removeAttribute(StyleConstants.FontSize);
}
old.addAttribute(StyleConstants.FontSize, 18);
return old;
}
private static SimpleAttributeSet apply_colors (AttributeSetConfigured asc, AttributeSet at, boolean annotation) throws IllegalAccessException, IllegalArgumentException, InvocationTargetException
{
SimpleAttributeSet sas = new SimpleAttributeSet(at);

Loading…
Cancel
Save