Ansel 0.0
A darktable fork - bloat + design vision
Loading...
Searching...
No Matches
screen_metrics.c
Go to the documentation of this file.
1/*
2 This file is part of Ansel,
3 Copyright (C) 2026 Aurélien PIERRE.
4
5 Ansel is free software: you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation, either version 3 of the License, or
8 (at your option) any later version.
9
10 Ansel is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
14
15 You should have received a copy of the GNU General Public License
16 along with Ansel. If not, see <http://www.gnu.org/licenses/>.
17*/
18
19#include "gui/screen_metrics.h"
21
22/* Written once at startup by whoever can interrogate the display, read everywhere after.
23 * The defaults are the neutral ones, so a reader that runs before the push -- or in a
24 * headless process where the push never happens -- gets unscaled geometry rather than
25 * zeroes. Setters reject non-positive values for the same reason: a bad probe must not be
26 * able to collapse every length in the application to 0. */
27/* Forwarders. The store lives in widgets/widget_settings.c -- see the comment there for why
28 * the toolkit owns it rather than the GUI. These names exist for the readers below layer 4
29 * (the crash reporter, the telemetry payload) and for the cairo helpers in the header. */
30
31double dt_screen_dpi(void) { return dt_widget_dpi(); }
32void dt_screen_set_dpi(double dpi) { dt_widget_set_dpi(dpi); }
33
36
37double dt_screen_ppd(void) { return dt_widget_ppd(); }
38void dt_screen_set_ppd(double ppd) { dt_widget_set_ppd(ppd); }
39
41
42double dt_screen_em_size(void) { return dt_widget_em_size(); }
44
45// clang-format off
46// modelines: These editor modelines have been set for all relevant files by tools/update_modelines.py
47// vim: shiftwidth=2 expandtab tabstop=2 cindent
48// kate: tab-indents: off; indent-width 2; replace-tabs on; indent-mode cstyle; remove-trailing-spaces modified;
49// clang-format on
const float factor
Definition pdf.h:91
void dt_screen_set_ppd(double ppd)
void dt_screen_set_dpi_factor(double factor)
double dt_screen_dpi(void)
void dt_screen_set_dpi(double dpi)
void dt_screen_set_em_size(double em)
double dt_screen_em_size(void)
double dt_screen_dpi_factor(void)
gboolean dt_screen_metrics_probed(void)
double dt_screen_ppd(void)
void dt_widget_set_ppd(double ppd)
double dt_widget_ppd(void)
void dt_widget_set_dpi_factor(double factor)
gboolean dt_widget_metrics_probed(void)
void dt_widget_set_em_size(double em)
void dt_widget_set_dpi(double dpi)
double dt_widget_dpi_factor(void)
double dt_widget_dpi(void)
double dt_widget_em_size(void)