Recent

Author Topic: Flickering TScrollbox  (Read 3787 times)

kupferstecher

  • Hero Member
  • *****
  • Posts: 583
Flickering TScrollbox
« on: May 11, 2017, 09:15:02 pm »
Hi,

there is flickering inside a TScrollbox when I set a quantity of controls to visible:= false. Its reproducable, see the attached example project. The flickering occurs on and near to the border of the scrollbox.
DoubleBuffered:= true also doesn't help.

It seems to be fine for BorderStyle:= bsNone. But in the standard configuration (bsSingle) there is this annoying flickering.

Does anyone know how to solve that?

Regards

PS: Same behaviour on Win Vista 32bit, Lazarus 1.6.4
and on Win7 64bit, Lazarus 1.6.

Thaddy

  • Hero Member
  • *****
  • Posts: 14197
  • Probably until I exterminate Putin.
Re: Flickering TScrollbox
« Reply #1 on: May 11, 2017, 09:38:00 pm »
Seems to be an off-by-one bug in the case of a border.
Specialize a type, not a var.

kupferstecher

  • Hero Member
  • *****
  • Posts: 583
Re: Flickering TScrollbox
« Reply #2 on: May 11, 2017, 10:00:22 pm »
Hm, could be.
Now I also testet on Linux with qt, there the flickering doesn't occur.

ASerge

  • Hero Member
  • *****
  • Posts: 2222
Re: Flickering TScrollbox
« Reply #3 on: May 19, 2017, 11:35:14 pm »
there is flickering inside a TScrollbox when I set a quantity of controls to visible:= false.
Framing with ScrollBox1.DisableAutoSizing and ScrollBox1.EnableAutoSizing will help.

kupferstecher

  • Hero Member
  • *****
  • Posts: 583
Re: Flickering TScrollbox
« Reply #4 on: May 23, 2017, 12:52:15 pm »
Hello ASerge,

now I tried that, for hiding the controls your solution works. But for enabling the visibility there still is flicker.

For now I just use the scrollbox without frame.

Regards

Framing with ScrollBox1.DisableAutoSizing and ScrollBox1.EnableAutoSizing will help.

airpas

  • Full Member
  • ***
  • Posts: 179
Re: Flickering TScrollbox
« Reply #5 on: May 23, 2017, 02:11:18 pm »
i got lot of flickering too with Splitters when it's linked with many controls . i think the procedure TCustomSplitter.MoveSplitter is unoptimized , there is alot of code inside this procedure .

Handoko

  • Hero Member
  • *****
  • Posts: 5129
  • My goal: build my own game engine using Lazarus
Re: Flickering TScrollbox
« Reply #6 on: June 08, 2017, 07:43:49 am »
I cannot reproduce the issue on Linux Gtk2.

 

TinyPortal © 2005-2018