ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 TImageEnMView upgrade

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

View 
UserName:
Password:
Format  Bold Italicized Underline  Align Left Centered Align Right  Horizontal Rule  Insert Hyperlink   Browse for an image to attach to your post Browse for a zip to attach to your post Insert Code  Insert Quote Insert List
   
Message 

 

Emoji
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Black Eye [B)]
Frown [:(] Shocked [:0] Angry [:(!] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
AndyColmes Posted - Oct 03 2016 : 21:17:17
I upgraded an old version of ImageEn to the latest but some of the properties are no longer available. What is the best way to modify the following code:

ImageEnMView1.ImageBottomText[ idx ].Background:=clYellow;
ImageEnMView1.ImageBottomText[ idx ].Font.Name := 'Arial Unicode MS';
ImageEnMView1.ImageBottomText[ idx ].Font.Size := 8;
ImageEnMView1.ImageBottomText[ idx ].Font.Style := [];
ImageEnMView1.ImageBottomText[ idx ].Font.Color:=clBlue;

Thanks in advance.

Andy
5   L A T E S T    R E P L I E S    (Newest First)
AndyColmes Posted - Oct 15 2016 : 08:19:25
Thanks Nigel. I will give it a try.

Andy
xequte Posted - Oct 12 2016 : 02:19:23
Hi Andy

You are changing component properties in a paint event, which causes it to repaint, where you set component properties, which causes it to paint...

Instead of ImageEnMView1.TextBackgroundColor use BackgroundColor.
Instead of ImageEnMView1.BottomTextFont use Font.

Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
AndyColmes Posted - Oct 11 2016 : 11:11:49
Hi Nigel,

I must be missing something. I am manually inserting images to a TImageEnMView using SetIEBitmapEx. I am also defining each item by its ImageTag, hoping to have a different text color and background depending on the ImageTag value. But my whole application freezes when I do that. Where did I go wrong with the following OnGetTextEx code?

Thanks Nigel and sorry for being thick.

Andy



procedure TCompareForm.ImageEnMView1GetTextEx(Sender: TObject; Index: Integer;
  Position: TIEMTextPos; var Text: WideString; Font: TFont;
  var BackgroundStyle: TBrushStyle; var BackgroundColor: TColor;
  var TruncSide: TIEMTruncSide);
begin
  ImageEnMView1.BottomTextFont.Name := 'Arial Unicode MS';
  ImageEnMView1.BottomTextFont.Size := 8;
  ImageEnMView1.BottomTextFont.Style := [];

  if (ImageEnMView1.ImageTag[ Index ] = 0) then begin

    ImageEnMView1.TextBackgroundColor := clBtnFace;
    ImageEnMView1.BottomTextFont.Color:=clBlack;

  end else if (ImageEnMView1.ImageTag[ Index ] = 1) then begin

   ImageEnMView1.TextBackgroundColor := clYellow;
   ImageEnMView1.BottomTextFont.Color:=clBlue;

  end else if (ImageEnMView1.ImageTag[ Index ] = 2) then begin

   ImageEnMView1.TextBackgroundColor := clRed;
   ImageEnMView1.BottomTextFont.Color:=clWhite;

  end else if (ImageEnMView1.ImageTag[ Index ] = 3) then begin

   ImageEnMView1.TextBackgroundColor := clBlue;
   ImageEnMView1.BottomTextFont.Color:=clWhite;

  end;
  ImageEnMView1.Update;

end;
xequte Posted - Oct 04 2016 : 02:53:52
Yes, please see the examples at:

http://www.imageen.com/help/TImageEnMView.OnGetTextEx.html

Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
AndyColmes Posted - Oct 04 2016 : 00:57:13
I think I have to use OnGetTextEx event to use TextBackgroundColor and TextBottomFont.