Skip to content

Commit

Permalink
Revert "SetSize should use 96 dpi for now"
Browse files Browse the repository at this point in the history
This reverts commit 9cbdc83.
  • Loading branch information
dimensionscape committed Oct 30, 2024
1 parent e65e863 commit e6fa4e7
Showing 1 changed file with 7 additions and 15 deletions.
22 changes: 7 additions & 15 deletions project/src/text/Font.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1041,22 +1041,14 @@ namespace lime {
}


void Font::SetSize(size_t size)
{
//We changed this from 72? I think in the next version of lime we should probably
//change the function signature from both the native and haxe side to expect an optional
//dpi argument
size_t hdpi = 96;
size_t vdpi = 96;

FT_Set_Char_Size(
(FT_Face)face, //Handle to the target face object
0, //Char width in 1/64th of points (0 means same as height)
static_cast<int>(size * 64), //Char height in 1/64th of points
hdpi, //Horizontal DPI
vdpi //Vertical DPI
);
void Font::SetSize (size_t size) {

size_t hdpi = 72;
size_t vdpi = 72;

FT_Set_Char_Size ((FT_Face)face, (int)(size*64), (int)(size*64), hdpi, vdpi);
mSize = size;

}


Expand Down

0 comments on commit e6fa4e7

Please sign in to comment.