View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0005174 | JEDI VCL | 00 JVCL Components | public | 2010-02-20 09:57 | 2011-06-10 16:09 |
Reporter | tetardd | Assigned To | AHUser | ||
Priority | normal | Severity | tweak | Reproducibility | always |
Status | resolved | Resolution | fixed | ||
Product Version | 3.39 | ||||
Target Version | Fixed in Version | 3.40 | |||
Summary | 0005174: JvArrowButton: arrwo draw one pixel too much on the right | ||||
Description | In themed app in Windows XP (not tried on other config.), the arrow is drawn one pixel too much on the right. Reproduce: Place JvArrowButton on form. Make sure it's themed. Set ArrwoWidth to 15 or 16. Do a screen capture and zoom arrow part of control. The arrow touched the button border on the left but is 2 pixels away from right border. Should have 1 pixel gap on both side. Proposed fix: Add +1 to the drawline's coordinated: procedure TJvArrowButton.Paint; ... { Draw arrow } while PaintRect.Left < PaintRect.Right + 1 do begin DrawLine(Canvas, PaintRect.Left + 1, PaintRect.Bottom, PaintRect.Right + 1, PaintRect.Bottom); InflateRect(PaintRect, -1, 1); end; | ||||
Tags | No tags attached. | ||||
|
Please provide the zipped sources of a sample application showing this. Your proposed fix does not take into account the presence or absence of themes |
|
I will but you can try for yourself in double quick time. Create a VCL form, add a JvArrowButton button and look at the screen. Switch Theming on. Note: if it's theme dependant, have a test for theme being enabled for the control and draw as you currently do without theming and as I suggest when themed. |
2010-03-13 13:56
|
|
2010-03-13 13:58
|
|
|
Attached are two screen captures (one zoomed for clarity). From top to bottom: 1- Current jvArrowButton (themed) showing the arrow being drawn one pixel too much to the left. 2- My proposed fix (themed) showing the arrow now being perfectly centered. 3- My porposed fix (not themed) showing that my fix works from non-themed controls too. |
|
Fixed in SVN. |
Date Modified | Username | Field | Change |
---|---|---|---|
2010-02-20 09:57 | tetardd | New Issue | |
2010-03-09 11:05 | obones | Note Added: 0017272 | |
2010-03-09 11:05 | obones | Status | new => feedback |
2010-03-09 13:52 | tetardd | Note Added: 0017293 | |
2010-03-13 13:56 | tetardd | File Added: jvArrowButton.bmp | |
2010-03-13 13:58 | tetardd | File Added: jvArrowButton (Zoomed).bmp | |
2010-03-13 14:01 | tetardd | Note Added: 0017301 | |
2010-03-16 22:16 | AHUser | Note Added: 0017305 | |
2010-03-16 22:16 | AHUser | Status | feedback => resolved |
2010-03-16 22:16 | AHUser | Fixed in Version | => Daily / SVN |
2010-03-16 22:16 | AHUser | Resolution | open => fixed |
2010-03-16 22:16 | AHUser | Assigned To | => AHUser |
2011-06-10 16:09 | obones | Fixed in Version | Daily / SVN => 3.40 |