Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHarley Acheson <harley.acheson@gmail.com>2022-09-24 03:36:49 +0300
committerHarley Acheson <harley.acheson@gmail.com>2022-09-24 03:36:49 +0300
commitcd1631b17dd0e25a8a398fb00a982ca5f0633558 (patch)
treeee8d9cdb560c815ea86d952ef2f053c6435865c1 /source/blender/editors/space_clip
parent88a602bc64fc2a86411d67881439a04486f95030 (diff)
BLF: Refactor of DPI
Correction of U.dpi to hold actual monitor DPI. Simplify font sizing by omitting DPI as API argument, always using 72 internally. See D15961 for more details. Differential Revision: https://developer.blender.org/D15961 Reviewed by Campbell Barton
Diffstat (limited to 'source/blender/editors/space_clip')
-rw-r--r--source/blender/editors/space_clip/clip_dopesheet_draw.c2
-rw-r--r--source/blender/editors/space_clip/clip_draw.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/editors/space_clip/clip_dopesheet_draw.c b/source/blender/editors/space_clip/clip_dopesheet_draw.c
index 8f876f6a8a3..b7ca6334e35 100644
--- a/source/blender/editors/space_clip/clip_dopesheet_draw.c
+++ b/source/blender/editors/space_clip/clip_dopesheet_draw.c
@@ -343,7 +343,7 @@ void clip_draw_dopesheet_channels(const bContext *C, ARegion *region)
/* second pass: text */
y = (float)CHANNEL_FIRST;
- BLF_size(fontid, 11.0f * U.pixelsize, U.dpi);
+ BLF_size(fontid, 11.0f * U.dpi_fac);
for (channel = dopesheet->channels.first; channel; channel = channel->next) {
float yminc = (float)(y - CHANNEL_HEIGHT_HALF);
diff --git a/source/blender/editors/space_clip/clip_draw.c b/source/blender/editors/space_clip/clip_draw.c
index b9bd97260ef..ea286fd2c2d 100644
--- a/source/blender/editors/space_clip/clip_draw.c
+++ b/source/blender/editors/space_clip/clip_draw.c
@@ -1034,7 +1034,7 @@ static void draw_marker_texts(SpaceClip *sc,
return;
}
- BLF_size(fontid, 11.0f * U.pixelsize, U.dpi);
+ BLF_size(fontid, 11.0f * U.dpi_fac);
fontsize = BLF_height_max(fontid);
if (marker->flag & MARKER_DISABLED) {