mirror of
https://github.com/servo/servo.git
synced 2025-08-06 06:00:15 +01:00
Default to 1 dppx in headless mode
This commit is contained in:
parent
a76b982ff9
commit
5148b67eac
1 changed files with 5 additions and 1 deletions
|
@ -127,8 +127,12 @@ impl IOCompositor {
|
||||||
|
|
||||||
let hidpi_factor = match opts.device_pixels_per_px {
|
let hidpi_factor = match opts.device_pixels_per_px {
|
||||||
Some(dppx) => dppx,
|
Some(dppx) => dppx,
|
||||||
None => window.hidpi_factor(),
|
None => match opts.output_file {
|
||||||
|
Some(_) => 1.0,
|
||||||
|
None => window.hidpi_factor(),
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
root_layer.common.borrow_mut().set_transform(identity().scale(hidpi_factor, hidpi_factor, 1f32));
|
root_layer.common.borrow_mut().set_transform(identity().scale(hidpi_factor, hidpi_factor, 1f32));
|
||||||
|
|
||||||
IOCompositor {
|
IOCompositor {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue