On 4/2/20 8:59 pm, Prasanta Sadhukhan wrote:
If we GC is correct in reset/pack step, but the View calculate wrong size(and update it
only after "graphicsConfiguration" property change) means that we calculate the
size of the View using wrong GC, why?
It's not the size of View, it's the preferredSize that is wrong. This is because tip's GC
is null before the tip is shown, so View's span is calculated accordingly. Only when View
isupdated when "graphicsConfiguration" is fired, then Tooltip GC is updated and
preferredSpan is calculated correctly.
It's to be remembered that the issue happens only when html text is shown in
ToolTip. If normal text is shown , there is no issue. I guess if it's a
question of wrong GC during popup reset/pack, then it will cause problem during
normal text rendering also, no?
If GC of the tip is null before showing then can we use default screen GC by
default? Same as in the java.awt.Window.initGC().
--
Best regards, Sergey.