@private
decorateLabelStub :: LabelDecorator -> String -> String -> <Proc> ()
decorateLabelStub decorator key value = do
- fontti = match decorateFont decorator (Just getDefaultFontDescriptor) key 0 with
+ fontti = match decorateFont decorator (Just defaultFontDescriptor) key 0 with
Nothing -> ""
Just font -> ""
fontti = decorateBackground decorator Nothing key 0
importJava "org.simantics.browsing.ui.content.ImageDecorator" where
data ImageDecorator
-importJava "org.eclipse.jface.resource.JFaceResources" where
- getDefaultFontDescriptor :: FontDescriptor
-
importJava "org.eclipse.jface.resource.DeviceResourceDescriptor" where
data FontDescriptor
data ColorDescriptor
+importJava "org.eclipse.jface.resource.FontDescriptor" where
+ @private
+ @JavaName createFrom
+ createFontDescriptorFrom :: String -> Integer -> Integer -> FontDescriptor
+
+defaultFontDescriptor = createFontDescriptorFrom "Arial" 12 0
+
importJava "org.simantics.browsing.ui.content.LabelDecorator" where
"""
An interface for decorating aesthetic properties of an UI item, including the label text, font, background color and foreground color.