Autor Beitrag
Nerzhul
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 20



BeitragVerfasst: So 23.01.05 16:33 
Hallo zusammen,

Vielleicht bin ich einfach zu blöd und/oder blind, aber ich kann im Web keine gute Dokumentation oder Community (Forum) zur Jedi VCL finden :-(

Mein Problem ist eigentlich simpel - ich möchte dynamisch erstellte JvImages verwenden. Das Erzeugen funktioniert prima, keinerlei Laufzeitfehler oder sonstige Probleme, bis auf eine kleine Sache: die Bilder werden erst angezeigt, wenn ich einmal mit der Maus drüber gefahren bin :roll: Ich hab jetzt alle Funktionen durchprobiert, von Invalidate, Update über Refresh bis Repaint [direkt nach dem Erzeugen aufgerufen] und konnte das Problem nicht lösen.

Kann mir jemand helfen?

-M
herzi
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 168

WINXP pro, SUSE Linux 9.0
D7 Pers.
BeitragVerfasst: Mo 24.01.05 21:24 
1. Quellcode wäre nett :)

2. Du hast nicht zufällig Picdown anstatt Picture genommen ?
Nerzhul Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 20



BeitragVerfasst: Mo 24.01.05 22:35 
Hallo,

Naja, ich habe exakt den gleichen Code schonmal verwendet, nämlich mit einer TImage Kompo und alles lief bestens. Ich hätte halt nur einige der neuen Features des JvImages gebrauchen können...

Hier der Code:

ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
tmpimg := TJvImage.Create(Form1);
  tmpimg.Parent := Form1.ScrollBox22;
  tmpimg.Name := 'HitBrowserValImg' + IntToStr(hitlist[i]);
  tmpimg.Left := 63;
  tmpimg.Top := (i * 23) + 24;
  tmpimg.Tag := hitlist[i];
  tmpimg.Cursor := crHandPoint;
  tmpimg.OnClick := Form1.HitbrowserOnClick;
  tmpimg.Height := 10;
  tmpimg.Width := 15;
  Form1.ImgValues.GetBitmap(1, tmpimg.Picture.Bitmap);
  tmpimg.Visible := TRUE;


Die Bilder werden aus einer ImgList geladen (statt der 1 steht dort ein wesentlich komplexerer Ausdruck der hier nichts zur Sache tut). Mit TImages funktioniert der Code bestens, mit TJvImages eigentlich auch, nur dass sie erst angezeigt werden, wenn ich mit der Maus drüber fahre.

Ideen?

-M
herzi
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 168

WINXP pro, SUSE Linux 9.0
D7 Pers.
BeitragVerfasst: Di 25.01.05 13:59 
Versuchs mal so...
ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
var 
  a:TBitmap;
begin 
  a:=TBitmap.Create;
tmpimg := TJvImage.Create(Form1);
  tmpimg.Parent := Form1.ScrollBox22;
  tmpimg.Name := 'HitBrowserValImg' + IntToStr(hitlist[i]);
  tmpimg.Left := 63;
  tmpimg.Top := (i * 23) + 24;
  tmpimg.Tag := hitlist[i];
  tmpimg.Cursor := crHandPoint;
  tmpimg.OnClick := Form1.HitbrowserOnClick;
  tmpimg.Height := 10;
  tmpimg.Width := 15;
  Form1.ImgValues.GetBitmap(1, a);
  tmpimg.Picture.Bitmap:=a;
  tmpimg.Visible := TRUE;