x11 Posted September 17, 2020 Share Posted September 17, 2020 How to fit an SVG picture proportionally in unimImage? unimImage1.url := 'files/svg/myimg1.svg' unimImage1.Proportional := True; thanx apart6.svg Quote Link to comment Share on other sites More sharing options...
Sherzod Posted September 17, 2020 Share Posted September 17, 2020 I will check. Quote Link to comment Share on other sites More sharing options...
x11 Posted September 17, 2020 Author Share Posted September 17, 2020 preferably with css thank you Quote Link to comment Share on other sites More sharing options...
Sherzod Posted September 17, 2020 Share Posted September 17, 2020 1 hour ago, x11 said: preferably with css For example: 1. procedure TMainForm.UniFormCreate(Sender: TObject); begin with UniImage1 do begin Url := 'files/apart6.svg'; Stretch := True; Proportional := True; end; end; 2. UniImage1.LayoutConfig.Cls = svgclass 3. CustomCSS .svgclass img { height: 100%; } Quote Link to comment Share on other sites More sharing options...
x11 Posted September 17, 2020 Author Share Posted September 17, 2020 5 minutes ago, Sherzod said: height: 100%; it does not affect Quote Link to comment Share on other sites More sharing options...
Sherzod Posted September 17, 2020 Share Posted September 17, 2020 1 minute ago, x11 said: it does not affect Sorry, you are using UnimImage. I will check. Quote Link to comment Share on other sites More sharing options...
x11 Posted September 17, 2020 Author Share Posted September 17, 2020 Yes, for mobile. Quote Link to comment Share on other sites More sharing options...
x11 Posted September 17, 2020 Author Share Posted September 17, 2020 .mainbtnimg { position: initial; } UnimImage3.Stretch := True; UnimImage3.Proportional := True; thank you 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.