<div dir="ltr"><p>Hi,</p><p>- Allow global CSS. I might be missing something, but I think there's no easy way to tell JavaFx<br>to use a CSS for the entire application.</p><p>- Font Family Fallback: Add support for font family fallbacks in -fx-font-family, similar to standard CSS.<br> For example: -fx-font-family: "Inter", "Noto Sans", sans-serif;</p><p>- Media Queries for device/screen size: Introduce support for media queries to adapt styles based on screen size, <br>resolution, or other device characteristics. This will help usage of JavaFx outside of "desktop applications" scope,<br>especially on devices where the application takes the entire screen.</p><p>- Image Scaling: Provide a declarative way to scale images relative to their container size (e.g., percentage-based width/height).<br></p><div><br></div><div>I’d be cautious about introducing an entirely new theme, as it could significantly increase the long-term maintenance effort. </div><div>I would instead, improve modena by allowing it to be more customizable.</div><div><br></div><div>-- Thiago.</div><div><br></div><div><br></div></div><br><div class="gmail_quote gmail_quote_container"><div dir="ltr" class="gmail_attr">Em qui., 29 de mai. de 2025 às 15:32, Michael Strauß <<a href="mailto:michaelstrau2@gmail.com">michaelstrau2@gmail.com</a>> escreveu:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Here is how I think we should be evolving JavaFX CSS over the next<br>
period of time:<br>
<br>
1. Media queries<br>
Gist: <a href="https://gist.github.com/mstr2/cbb93bff03e073ec0c32aac317b22de7" rel="noreferrer" target="_blank">https://gist.github.com/mstr2/cbb93bff03e073ec0c32aac317b22de7</a><br>
PR: <a href="https://github.com/openjdk/jfx/pull/1655" rel="noreferrer" target="_blank">https://github.com/openjdk/jfx/pull/1655</a><br>
<br>
This feature is already out for review.<br>
<br>
2. System colors<br>
Gist: <a href="https://gist.github.com/mstr2/afac42ab9587c1040a6cf7b091cee99f" rel="noreferrer" target="_blank">https://gist.github.com/mstr2/afac42ab9587c1040a6cf7b091cee99f</a><br>
<br>
System colors allow stylesheet authors to use colors that are defined<br>
by the scene or the platform. Most notably, this includes the accent<br>
color. We will also add new media queries to help stylesheet authors<br>
deal with contrast modes.<br>
<br>
3. With media queries and system colors in place, we can remove the<br>
built-in high contrast stylesheets that come with Caspian and Modena.<br>
Instead of hard-coding these special cases (and not even in a good<br>
way), we can now use standard APIs to achieve a better result. This<br>
will remove a big chunk of special-casing from the codebase and bring<br>
us closer to an equal playing field of built-in vs. third-party<br>
themes.<br>
<br>
4. Dark Modena / Modena 2025?<br>
<br>
5. Bold new theme?<br>
<br>
<br>
What do you think? Please focus comments on step 1-3, and not on<br>
bikeshedding a new theme.<br>
</blockquote></div>