Skip to content

Commit 06fe06f

Browse files
committed
Add N&N for SVG support
This contributes an N&N informing about the support of SVGs for loading images in Eclipse. See eclipse-platform/eclipse.platform.swt#1638.
1 parent aa79b70 commit 06fe06f

File tree

4 files changed

+70
-1
lines changed

4 files changed

+70
-1
lines changed
Loading
Loading

news/4.36/platform.html

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,44 @@ <h2>General Updates </h2>
145145
<img src="images/rescaling-enabled.png" alt="Monitor-Specific UI Rescaling Enabled" />
146146
</td>
147147
</tr>
148+
<tr id="supportSVGForIcons"> <!-- https://github.com/eclipse-platform/eclipse.platform.swt/pull/1638 -->
149+
<td class="title">Support for Scalable SVG Icons in Eclipse</td>
150+
<td class="content">
151+
Until now, only raster graphics could be used for loading icons in Eclipse.
152+
This limited the ability to scale icons without quality loss and required manual rasterization of SVG files outside
153+
of Eclipse to generate icons in different sizes, leading to additional effort and many separate icon files.
154+
<p>
155+
Support for vector graphics (SVG) has now been added. Instead of providing multiple rasterized images for different
156+
sizes and resolutions, a single SVG file can be referenced. The SVG is rasterized on-the-fly at the required size
157+
when the icon is rendered at runtime. This ensures optimal image quality for arbitrary scaling factors
158+
without manual preprocessing.
159+
</p>
160+
<p>
161+
This approach reduces maintenance overhead, as only one source file per icon needs to be managed.
162+
As part of this change, most icons across all bundles have been added as SVGs, and the corresponding paths
163+
(e.g., in <code>plugin.xml</code> files) have been updated accordingly.
164+
</p>
165+
<p>
166+
In a future release, bundle sizes will be further reduced by removing the existing redundant raster images.
167+
Support for raster graphics remains available, as SVG handling has been seamlessly integrated into the existing
168+
image loading infrastructure without requiring changes to existing code.
169+
</p>
170+
<p>
171+
This improvement is especially beneficial for High-DPI displays, where crisp, scalable icons greatly enhance the
172+
visual appearance and usability of the user interface. It also ensures better adaptation to different display
173+
settings and dynamic scaling scenarios.
174+
</p>
175+
<p>
176+
The following screenshots compare the use of raster graphics and vector graphics when loading icons with 125% monitor scaling:
177+
</p>
178+
<p>
179+
<img src="images/icon_rendering_using_vector-graphics.png" alt="Icons rendered using raster graphics" /> &nbsp<code>Icons rendered using raster graphics</code>
180+
</p>
181+
<p>
182+
<img src="images/icon_rendering_using_raster-graphics.png" alt="Icons rendered using vector graphics" /> &nbsp<code>Icons rendered using vector graphics</code>
183+
</p>
184+
</td>
185+
</tr>
148186
<!-- ******************* End of General Updates ************************************* -->
149187
<tr>
150188
<td colspan="2" />

news/4.36/platform.md

Lines changed: 32 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,4 +60,35 @@ On a 200% monitor with the feature being **disabled**:
6060

6161
On a 200% monitor with the feature being **enabled**:
6262

63-
![Monitor-Specific UI Rescaling Enabled](images/rescaling-enabled.png)
63+
![Monitor-Specific UI Rescaling Enabled](images/rescaling-enabled.png)
64+
65+
### Support for Scalable SVG Icons in Eclipse
66+
67+
Until now, only raster graphics could be used for loading icons in Eclipse.
68+
This limited the ability to scale icons without quality loss and required manual rasterization of SVG files outside
69+
of Eclipse to generate icons in different sizes, leading to additional effort and many separate icon files.
70+
71+
Support for vector graphics (SVG) has now been added. Instead of providing multiple rasterized images for different
72+
sizes and resolutions, a single SVG file can be referenced. The SVG is rasterized on-the-fly at the required size
73+
when the icon is rendered at runtime. This ensures optimal image quality for arbitrary scaling factors
74+
without manual preprocessing.
75+
76+
This approach reduces maintenance overhead, as only one source file per icon needs to be managed.
77+
As part of this change, most icons across all bundles have been added as SVGs, and the corresponding paths
78+
(e.g., in `plugin.xml` files) have been updated accordingly.
79+
80+
In a future release, bundle sizes will be further reduced by removing the existing redundant raster images.
81+
Support for raster graphics remains available, as SVG handling has been seamlessly integrated into the existing
82+
image loading infrastructure without requiring changes to existing code.
83+
84+
This improvement is especially beneficial for High-DPI displays, where crisp, scalable icons greatly enhance the
85+
visual appearance and usability of the user interface. It also ensures better adaptation to different display
86+
settings and dynamic scaling scenarios.
87+
88+
The following screenshots compare the use of raster graphics and vector graphics when loading icons with 125% monitor scaling:
89+
90+
![Icons rendered using raster graphics](images/icon_rendering_using_vector-graphics.png)
91+
`Icons rendered using raster graphics`
92+
93+
![Icons rendered using vector graphics](images/icon_rendering_using_raster-graphics.png)
94+
`Icons rendered using vector graphics`

0 commit comments

Comments
 (0)