Home » Developing U++ » U++ Developers corner » Will UPP support full UNICODE (21bits long codepoint)?
Re: Will UPP support full UNICODE (21bits long codepoint)? [message #54623 is a reply to message #54611] |
Sat, 22 August 2020 18:01   |
 |
mirek
Messages: 14257 Registered: November 2005
|
Ultimate Member |
|
|
I am now investigating the whole thing in Win32. Let us say we would want just to support 32-bit codepoints as the first step.
Now current model needs following info: a) that the font has glyph for required, b) at least advance width for the glyph.
If we do not want to use Uniscribe, just good old GDI, so far I have only found solution to b), but unfortunately it returns just dimensions of that "box" character that is used in case glyph is missing instead of indicating anyhow that it is actually missing....
void Test(int ch, Font fnt)
{
TIMING("Glyph");
HFONT hfont = GetWin32Font(fnt, 0);
VERIFY(hfont);
if(hfont) {
HDC hdc = CreateIC("DISPLAY", NULL, NULL, NULL);
HFONT ohfont = (HFONT) ::SelectObject(hdc, hfont);
GLYPHMETRICS gm;
memset(&gm, 0, sizeof(gm));
MAT2 m_matrix;
memset8(&m_matrix, 0, sizeof(m_matrix));
m_matrix.eM11.value = 1;
m_matrix.eM22.value = 1;
int gsz = GetGlyphOutlineW(hdc, ch, GGO_NATIVE|GGO_UNHINTED|GGO_METRICS, &gm, 0, NULL, &m_matrix);
if(gsz == GDI_ERROR)
DLOG("Failed " << ch);
if(gm.gmCellIncX != 75)
DLOG(ch << " " << gm.gmCellIncX << ", " << gm.gmCellIncY << ", " << gm.gmptGlyphOrigin.x);
::SelectObject(hdc, ohfont);
::DeleteDC(hdc);
}
}
GUI_APP_MAIN
{
for(int i = 32; i < 100000; i++)
Test(i, Font().Height(100).FaceName("MingLiU-ExtB"));
}
|
|
|
 |
|
Will UPP support full UNICODE (21bits long codepoint)?
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: mirek on Tue, 11 August 2020 17:22
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: Oblivion on Sat, 15 August 2020 01:02
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: mirek on Sat, 15 August 2020 01:39
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: Oblivion on Sat, 15 August 2020 11:12
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: mirek on Sat, 15 August 2020 11:33
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: Oblivion on Sat, 15 August 2020 12:15
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: mirek on Sat, 15 August 2020 12:44
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: Oblivion on Sat, 15 August 2020 13:15
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: mirek on Sat, 15 August 2020 14:07
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: Oblivion on Sat, 15 August 2020 15:11
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: mirek on Mon, 17 August 2020 10:17
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: mirek on Mon, 17 August 2020 11:01
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: Oblivion on Mon, 17 August 2020 11:50
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: mirek on Mon, 17 August 2020 14:04
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: Oblivion on Mon, 17 August 2020 15:17
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: mirek on Tue, 18 August 2020 16:55
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: deep on Thu, 20 August 2020 07:10
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: mirek on Sat, 22 August 2020 18:01
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: Oblivion on Sat, 22 August 2020 19:29
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: mirek on Sun, 23 August 2020 10:06
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: Oblivion on Sun, 23 August 2020 10:52
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: mirek on Sun, 23 August 2020 13:15
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: mirek on Mon, 24 August 2020 11:31
|
 |
|
Re: Will UPP support full UNICODE (21bits long codepoint)?
By: Oblivion on Sat, 15 August 2020 01:02
|
Goto Forum:
Current Time: Sun May 11 09:24:44 CEST 2025
Total time taken to generate the page: 0.01342 seconds
|