So, I just tried to render a string that contains both english and japanese characters, and used "Courier New" font for that. Both were displayed correctly. And I'm pretty sure that Courier New doesn't have any japanese support in it. Which font was used for japanese?
res = pdds->GetDC(&dc);
if (res!= DD_OK) FUCK();
//TEXT("Courier New") //TEXT("Impact") //TEXT("MS PGothic") //msgothic.ttc
HFONThFont = CreateFont(24,0,0,0,FW_DONTCARE,FALSE,FALSE,FALSE,DEFAULT_CHARSET,OUT_OUTLINE_PRECIS, CLIP_DEFAULT_PRECIS,CLEARTYPE_QUALITY, FIXED_PITCH,TEXT("Courier New"));
rect.top = 0;
rect.left = 0;
rect.right = 64;
rect.bottom = 64;
//DrawTextW(dc, L"hello!", -1, &rect, DT_NOCLIP);
DrawTextW(dc, L"はっはっは！suckers!lWlW", -1, &rect, DT_NOCLIP);
pdds->ReleaseDC(dc); //it's just a number
Last edited by vivik on 07 Jun 2018, 17:05; edited 2 times in total
MS windows has font linking feature, some font with chinese characters is linked to the courier, and if courier font does not contain certain character the system searches linked fonts for such character.
Linking of fonts is set up in windows registry (I do not remember exact place)
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum