riched20: Set the end-of-paragraph run width to that of a space.
Signed-off-by: Huw Davies <huw@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
c8a90e5de9
commit
4c322698da
|
@ -611,17 +611,16 @@ SIZE ME_GetRunSizeCommon(ME_Context *c, const ME_Paragraph *para, ME_Run *run, i
|
||||||
int startx, int *pAscent, int *pDescent)
|
int startx, int *pAscent, int *pDescent)
|
||||||
{
|
{
|
||||||
SIZE size;
|
SIZE size;
|
||||||
int nMaxLen = run->len;
|
WCHAR spaceW[] = {' ',0};
|
||||||
|
|
||||||
if (nLen>nMaxLen)
|
nLen = min( nLen, run->len );
|
||||||
nLen = nMaxLen;
|
|
||||||
|
|
||||||
/* FIXME the following call also ensures that TEXTMETRIC structure is filled
|
if (run->nFlags & MERF_ENDPARA)
|
||||||
* this is wasteful for MERF_NONTEXT runs, but that shouldn't matter
|
{
|
||||||
* in practice
|
nLen = min( nLen, 1 );
|
||||||
*/
|
ME_GetTextExtent(c, spaceW, nLen, run->style, &size);
|
||||||
|
}
|
||||||
if (para->nFlags & MEPF_COMPLEX)
|
else if (para->nFlags & MEPF_COMPLEX)
|
||||||
{
|
{
|
||||||
size.cx = run->nWidth;
|
size.cx = run->nWidth;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue