dear Alexander,
using the last svn I have problems with reticulemode property. If I set it to True every time I click on a chart the reticule is drawn and does not disappear.
To reproduce it just enable reticule mode on a chart with at least one serie and click on the chart.
Andrea
Mailing lists / lazarus / 2010-03
tchart reticule mode
9 messages · 4 people · –
- AAlexander Klenin 4
- GGeoffray 2
- JJoshyFun 2
- AAndrea Mauri 1
Reply by email Subscribe to this list Your subscription
Read-only archive. Use j and k to move between messages.
Le Lundi 01 Mars 2010 15:24:46, Andrea Mauri a ?crit :
Show quoted text 8 lines
I have the same bug. Also when using the mouse to zoom on an area, there's no indicators (i mean no boxes) and the reticule is not following the mouse.
Geoffray wrote 10 lines
Acknowledged, I will work on a fix in a day or two.
Also when using the mouse to zoom on an area, there's no indicators (i mean no boxes)
Do you mean zoom rectangle is not drawn for you?
I can't reproduce that.
and the reticule is not following the mouse.
That's half-intentional, it seems to me that it would be visually confusing to display both reticule and zoom rectangle at the same time. So perhaps correct behaviour would be to hide reticule on mousedown, and show it again on mouseup?
That would also fix the original bug.
Le Mardi 02 Mars 2010 23:06:09, Alexander Klenin a ?crit :
Do you mean zoom rectangle is not drawn for you? I can't reproduce that.
Exactly. I'm using Qt. After some test there's no bug when using GTK widget set. This happen with Qt but I can't test something else than GTK and Qt.
Hello Lazarus-List,
Wednesday, March 3, 2010, 2:31:07 AM, you wrote:
G> Le Mardi 02 Mars 2010 23:06:09, Alexander Klenin a ?crit :
> Do you mean zoom rectangle is not drawn for you? > I can't reproduce that.
G> Exactly. I'm using Qt. After some test there's no bug when using GTK widget G> set. This happen with Qt but I can't test something else than GTK and Qt.
I'm not using TChart but if the TChart is trying to draw a focus rect or similar over a bitmap without using the bitmap itself it is not working in QT. I have the same problem in a program that uses drawfocusrect to paint a box selection over a bitmap, but painting over the control, not inside the bitmap.
JoshyFun wrote 16 lines
Yes, TChart do draw over the control from MouseMove event. However, there is no "bitmap" for TChart, it is a TCustomControl descendant. Does that mean that I have to call Invalidate from inside MouseMove to repaint the chart every time? That would have serious performance impact.
Acknowledged, I will work on a fix in a day or two. Do you mean zoom rectangle is not…
Alexander Klenin wrote 13 lines
Should be fixed in r23833. Please test.
Show quoted text 6 lines
I experimented a bit and decided that it is visually better to display, but _not_ move the reticule during the zoom. If you think some other variant is better or that is should be configurable, please post your arguments -- I might reconsider ;-)
Le Mardi 02 Mars 2010 23:06:09, Alexander Klenin a ?crit : Exactly. I'm using Qt. After…
Geoffray wrote 7 lines
It is strange that you see the reticule, but not the zoom box, since they are both drawn
in the MouseMove event handler.
Unfortunately, I am on Windows, so it will be hard for me to fix this bug. Please file a Mantis bug report and assign it to me, so at least it will not be forgotten.
Yes, TChart do draw over the control from MouseMove event. However, there is no "bitmap"…
Hello Lazarus-List,
Thursday, March 4, 2010, 12:34:56 AM, you wrote:
AK> Yes, TChart do draw over the control from MouseMove event. AK> However, there is no "bitmap" for TChart, it is a TCustomControl descendant. AK> Does that mean that I have to call Invalidate from inside MouseMove AK> to repaint the chart every time? That would have serious performance impact.
No the invalidaterect is not needed in your case (I think). I'll explain my case:
I have a bitmap (TImage) which is strenched and I must paint a selection box over it so I can not paint in the bitmap because the selection box will be also draw strenched too, so I paint over the control:
TImage.Canvas.DrawFocusRect(...);This procedure is not working on QT, I do not know actually if the problem is known by the QT maintainer(s), or maybe it is regression as I do not have experience with the QT widgetset.
In you case as you are already drawing the content, drawing in the same way the selectionbox using a XOR pen should solve the problem at least partially.
