Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions internal/renderers/femtovg/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ impl<B: GraphicsBackend> FemtoVGRenderer<B> {
// We pass an integer that is greater than or equal to the scale factor as
// dpi / device pixel ratio as the anti-alias of femtovg needs that to draw text clearly.
// We need to care about that `ceil()` when calculating metrics.
femtovg_canvas.set_size(surface_size.width, surface_size.height, scale);
femtovg_canvas.set_size(surface_size.width, surface_size.height, 1.0);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This reverts #2618 more or less. I was under the impression that it looked better, but from the amount of reports and your testing it looks like that isn't universally the case. I'm okay with reverting back to what you're proposing, but I think the comment before this function call needs adjusting.


// Clear with window background if it is a solid color otherwise it will drawn as gradient
if let Some(Brush::SolidColor(clear_color)) = window_background_brush {
Expand Down Expand Up @@ -184,7 +184,7 @@ impl<B: GraphicsBackend> FemtoVGRenderer<B> {
let commands = femtovg_canvas.flush_to_surface(surface.render_surface());
self.graphics_backend.submit_commands(commands);

femtovg_canvas.set_size(width.get(), height.get(), scale);
femtovg_canvas.set_size(width.get(), height.get(), 1.0);
drop(femtovg_canvas);

self.with_graphics_api(|api| {
Expand Down
Loading