Project JEDI - Issue Tracker
Mantis Bugtracker

Viewing Issue Simple Details Jump to Notes ] View Advanced ] Issue History ] Print ]
ID Category Severity Reproducibility Date Submitted Last Update
0002940 [JEDI VCL] 00 JVCL Components minor always 2005-05-08 09:51 2005-05-09 03:08
Reporter messenjah View Status public  
Assigned To AHUser
Priority normal Resolution fixed  
Status resolved   Product Version 3.00
Summary 0002940: HTMLDrawTextEx in jvJVCLUTILS does not always render hyperlink red.
Description Sometimes when I go over a hyperlink in jvHTLabel, it does not turn red.
the problem is in HTMLDrawTextEx in jvJVCLUTILS

Around line 7222 there is a statement like:
if (MouseY in [])

The problem is that [R.Top..R.Top+height] (and [R.lef..R.Left.Width]) never return true is the range starts > 255.
This is a compiler bug (I am using D7). It should either work, Or give a warning.

In the mean time i fixed it by replacing it with this:

      Height := CanvasMaxTextHeight(Canvas);
      if IsLink and not MouseOnLink then
        if (MouseY>=R.Top) and (MouseY <= R.Top + Height) then
        if (mouseX >= R.Left) and (MouseX <=R.Left + Width) then
          MouseOnLink := True;
Additional Information To see the problem, use this simple program:

procedure TForm1.Button1Click(Sender: TObject);
  X, Y, Z : Integer;
  z := 255;
  if Z in [x..y] then memo1.Lines.Add('true 1');

  z := 256;
  if Z in [x..y] then memo1.Lines.Add('true 2')

This should output:"
true 1
true 2

but it only outputs:"
true 1

Well atleast in my Delphi 7.
Tags No tags attached.
Attached Files

- Relationships

-  Notes
AHUser (developer)
2005-05-09 03:08

Thanks for reporting this.
Fixed in CVS.

- Issue History
Date Modified Username Field Change
2005-05-08 09:51 messenjah New Issue
2005-05-09 03:08 AHUser Status new => resolved
2005-05-09 03:08 AHUser Resolution open => fixed
2005-05-09 03:08 AHUser Assigned To => AHUser
2005-05-09 03:08 AHUser Note Added: 0007118

Mantis 1.1.6[^]
Copyright © 2000 - 2008 Mantis Group
Powered by Mantis Bugtracker