Terminal.Gui icon indicating copy to clipboard operation
Terminal.Gui copied to clipboard

Latest version of all 3 drivers call refresh constantly

Open tznind opened this issue 1 year ago • 3 comments

Describe the bug

refresh-bug Clicking the mouse causes about 68 screen refreshes (it does eventually stop)

To Reproduce This changed recently.

  1. Add a debug counter to UpdateScreen
  2. Click mouse

Expected behavior Only redraw when something has changed.

Screenshots If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: [e.g. iOS]
  • Browser [e.g. chrome, safari]
  • Version [e.g. 22]

Smartphone (please complete the following information):

  • Device: [e.g. iPhone6]
  • OS: [e.g. iOS8.1]
  • Browser [e.g. stock browser, safari]
  • Version [e.g. 22]

Additional context Add any other context about the problem here.

tznind avatar Sep 26 '24 19:09 tznind

I probably did this when I fixed a bunch of repaint logic last week. I focused on WindowsDriver.

tig avatar Sep 26 '24 23:09 tig

@tznind I think you should change the title to reflect that this affect all drivers.

BDisp avatar Oct 15 '24 20:10 BDisp

I finally got frustrated with all this enough today. I have started a branch where I finally make

  • layout decoupled from draw
  • enforce that Clear rarely happens
  • ensure drivers minimize full repaints
  • minimize when Draw/OnDrawContent are called

More soon.

tig avatar Oct 15 '24 22:10 tig