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

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
Forum membership is Free!  Click Join to sign-up
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 IElayerMview size
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

pierrotsc

USA
497 Posts

Posted - May 29 2019 :  13:11:04  Show Profile  Reply
I am trying to show the pixels dimensions of the image not the layer dimensions. When i switch the option to imagedimension in the component, i still get the layer dimension.
Advice

w2m

USA
1990 Posts

Posted - May 30 2019 :  15:56:39  Show Profile  Reply
procedure TForm1.ImageEnLayerMView1GetTextEx(Sender: TObject; Index: Integer;
  Position: TIEMTextPos; var Text: WideString; Font: TFont;
  var BackgroundStyle: TBrushStyle; var BackgroundColor: TColor;
  var TruncSide: TIEMTruncSide);
begin
  if (Index <> -1) and (Index < ImageEnLayerMView1.ImageCount) then
  begin
    if Assigned(cxPageControl1.ActivePage) then
    begin
      ImageEnView := TImageEnView(cxPageControl1.ActivePage.Controls[0]);
      if Assigned(ImageEnView) and (Index <> -1) and
        (ImageEnLayerMView1.ImageCount = ImageEnView.LayersCount) then
      begin
        if Position = iemtpTop then
        begin
          Font.Style := [fsBold];
          Text := 'Kind: ' + GetLayerKindStr(ImageEnView) + '     ';
          Text := Text + 'Name: ' + ImageEnView.Layers[index].Name;
        end
        else
        begin
          Font.Style := [];
          Text := 'Layer Width: ' + IntegerToString
            (ImageEnView.Layers[index].Width) + '     ';
          Text := Text + ' Layer Height: ' + IntegerToString
            (ImageEnView.Layers[index].Height) + '     ';
          Text := Text + ' Width: ' + IntegerToString
            (ImageEnView.Layers[index].Bitmap.Width) + '     ';
          Text := Text + ' Height: ' + IntegerToString
            (ImageEnView.Layers[index].Bitmap.Height);
        end;
      end;
    end;
  end;
end;

Bill Miller
Adirondack Software & Graphics
Email: w2m@hughes.net
EBook: http://www.imageen.com/ebook/
Custom Commercial ImageEn Development
Go to Top of Page

pierrotsc

USA
497 Posts

Posted - May 30 2019 :  16:05:09  Show Profile  Reply
No , what i am saying is that changing the properties to iedtnone for example in all 3 fields does not modify anything. the size and layername always show. it looks like if i set the autoadaptstyle to false, it is now working. Something weird was happening in the ielayermview component.
Go to Top of Page

xequte

38180 Posts

Posted - Jun 04 2019 :  17:30:24  Show Profile  Reply
Hi

Did you call Update after changing the text properties?

Can you give me the steps to reproduce?


Nigel
Xequte Software
www.imageen.com
Go to Top of Page

pierrotsc

USA
497 Posts

Posted - Jun 04 2019 :  20:42:55  Show Profile  Reply
i think it is working now. not sure what i did but i got what i wanted. thanks for checking.
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: