<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body style="overflow-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;">I guess the use-case is the same as for any node property. I want to be able to specify it via CSS instead of code.<div><br></div><div>I could easily implement this for ImageView but I am not familiar with the OpenJFX dev process (e.g. which tests are required), so it would take me a long time to do. Pretty sure that other contributors could do this in a fraction of the time.</div><div><br></div><div>Dirk<br id="lineBreakAtBeginningOfMessage"><div><br><blockquote type="cite"><div>Am 16.11.2023 um 20:57 schrieb Andy Goryachev <andy.goryachev@oracle.com>:</div><br class="Apple-interchange-newline"><div><meta charset="UTF-8"><div class="WordSection1" style="page: WordSection1; caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 14px; font-style: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;"><div style="margin: 0in; font-size: 10pt; font-family: Calibri, sans-serif;"><span style="font-size: 11pt; font-family: "Iosevka Fixed SS16";">Dear Dirk:<o:p></o:p></span></div><div style="margin: 0in; font-size: 10pt; font-family: Calibri, sans-serif;"><span style="font-size: 11pt; font-family: "Iosevka Fixed SS16";"><o:p> </o:p></span></div><div style="margin: 0in; font-size: 10pt; font-family: Calibri, sans-serif;"><span style="font-size: 11pt; font-family: "Iosevka Fixed SS16";">I don’t see any reason why not - we’d need to add entries in<span class="Apple-converted-space"> </span><u>getCssMetaData</u>() and update CSS reference. In fact, there is a TODO item in ImageView:812 along the lines<o:p></o:p></span></div><div style="margin: 0in; font-size: 10pt; font-family: Calibri, sans-serif;"><span style="font-size: 11pt; font-family: "Iosevka Fixed SS16";"><o:p> </o:p></span></div><div style="margin: 0in; font-size: 10pt; font-family: Calibri, sans-serif; background: white;"><span style="font-size: 12pt; font-family: "Iosevka Fixed SS16";"> <span class="Apple-converted-space"> </span></span><span style="font-size: 12pt; font-family: "Iosevka Fixed SS16"; color: rgb(255, 38, 0);">// TODO</span><span style="font-size: 12pt; font-family: "Iosevka Fixed SS16";"><o:p></o:p></span></div><div style="margin: 0in; font-size: 10pt; font-family: Calibri, sans-serif; background: white;"><span style="font-size: 12pt; font-family: "Iosevka Fixed SS16";"> <span class="Apple-converted-space"> </span></span><span style="font-size: 12pt; font-family: "Iosevka Fixed SS16"; color: rgb(255, 38, 0);">// "preserve-ratio","smooth","viewport","fit-width","fit-height"</span><span style="font-size: 12pt; font-family: "Iosevka Fixed SS16";"><o:p></o:p></span></div><div style="margin: 0in; font-size: 10pt; font-family: Calibri, sans-serif;"><span style="font-size: 11pt; font-family: "Iosevka Fixed SS16";"><o:p> </o:p></span></div><div style="margin: 0in; font-size: 10pt; font-family: Calibri, sans-serif;"><span style="font-size: 11pt; font-family: "Iosevka Fixed SS16";">Perhaps it just fell through the cracks.<o:p></o:p></span></div><div style="margin: 0in; font-size: 10pt; font-family: Calibri, sans-serif;"><span style="font-size: 11pt; font-family: "Iosevka Fixed SS16";"><o:p> </o:p></span></div><div style="margin: 0in; font-size: 10pt; font-family: Calibri, sans-serif;"><span style="font-size: 11pt; font-family: "Iosevka Fixed SS16";">Can you describe your use case? Is this something you’d like to impement?<o:p></o:p></span></div><div style="margin: 0in; font-size: 10pt; font-family: Calibri, sans-serif;"><span style="font-size: 11pt; font-family: "Iosevka Fixed SS16";"><o:p> </o:p></span></div><div style="margin: 0in; font-size: 10pt; font-family: Calibri, sans-serif;"><span style="font-size: 11pt; font-family: "Iosevka Fixed SS16";">-andy<o:p></o:p></span></div><div style="margin: 0in; font-size: 10pt; font-family: Calibri, sans-serif;"><span style="font-size: 11pt; font-family: "Iosevka Fixed SS16";"><o:p> </o:p></span></div><div id="mail-editor-reference-message-container"><div><div style="border-width: 1pt medium medium; border-style: solid none none; border-color: rgb(181, 196, 223) currentcolor currentcolor; border-image: none; padding: 3pt 0in 0in;"><p class="MsoNormal" style="margin: 0in 0in 12pt; font-size: 10pt; font-family: Calibri, sans-serif;"><b><span style="font-size: 12pt;">From:<span class="Apple-converted-space"> </span></span></b><span style="font-size: 12pt;">openjfx-dev <openjfx-dev-retn@openjdk.org> on behalf of Dirk Lemmermann <dlemmermann@gmail.com><br><b>Date:<span class="Apple-converted-space"> </span></b>Thursday, November 16, 2023 at 07:12<br><b>To:<span class="Apple-converted-space"> </span></b>openjfx-dev <openjfx-dev@openjdk.org><br><b>Subject:<span class="Apple-converted-space"> </span></b>ImageView.fitWidth()/.fitHeight()/.preserveRatio() styling<o:p></o:p></span></p></div><div><div style="margin: 0in; font-size: 10pt; font-family: Calibri, sans-serif;"><span style="font-size: 11pt;">Hi everyone,<br><br>Is there a particular reason why the fitWidth, fitHeight, and preserveRatio() properties of an ImageView can not be styled via CSS?<br><br>Dirk</span></div></div></div></div></div></div></blockquote></div><br></div></body></html>