On 12/27/2014 06:45 PM, Giuliano Colla wrote:

Il 27/12/2014 17:35, Juha Manninen ha scritto:
On Sat, Dec 27, 2014 at 4:56 PM, Giuliano Colla
<giuliano.co...@fastwebnet.it> wrote:
However I've found a simple workaround: with Qt ws, to remove the old
tab
before calling InsertVisiblePage. That way PageComponent is always
nil, and
everything works just fine.

If you agree, I can commit my change (it's really minimal) and you
may check it.
Yes, that workaround would prevent moving tabs and it could be added
with IFDEF LCLQt.

Committed with rev 47255.
You'll find the workaround (surrounded by the IFDEF LCLQt) + some added
Debugln + a minor fix (a ShowHint := true was missing) + an attempt to
use a different code for moving tabs (surrounded by an IFDEF
USE_PageIndex). It doesn't make any difference but it saves a number of
tests, because they're done in LCL. You may keep it or throw it away
following your taste.

I'm against such workarounds since it can hide bug. Is it enough to comment code LCLQt to completely disable LCLQt ifdef ? I'll try to debug and see what exactly happens, since it's impossible to reproduce it with simple example project.

zeljko


The bug is most likely a regression in recent QT versions. I applied
the change from Zeljko. It uses QTabBar_moveTab and is an improvement
but still does not solve the problem.
I see if I can reproduce it in a small test application.

I hope you'll have better chance than me. I tried with a small test
application, but no way to reproduce the bug. Tabs were always
inserted/moved properly.
True, I did use just standard components i.e. a standard NoteBook with
standart TabSheet, and my tabs didn't come from a StringList, but I
don't see how this should make a difference. The Qt code involved was
exactly the same, as far as I can tell, and my debugln's tell.

Giuliano



--
_______________________________________________
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply via email to