On 11/09/2018 22:03, Prasanta Sadhukhan wrote:
Why SynthLookAndFeel.updateStyle() which is called in SynthButtonUI.updateStyle(AbstractButton b) did not update the context which is passed to it? Is it possible that SynthButtonUI.installDefaults() was not called before getBaseline()?

SynthButtonUI.updateStyle() called from SynthButtonUI.installDefaults() creates a new context whereas in getBaseline() we again calls getContext() in l207 which creates a new SynthContext, so the style was not updated to the context currently being queried in getBaseline()

SynthButtonUI.updateStyle() creates a new context and at the same time updates the "SynthStyle.style", so the new SynthContext created in getBaseline() should use non-null "SynthStyle.style", no?


--
Best regards, Sergey.

Reply via email to