Commit 22da469b authored by Bill Medland's avatar Bill Medland Committed by Alexandre Julliard

If the buffer is no longer static the names should reflect that.

Also minimise the use of the constant.
parent 418672f2
...@@ -838,7 +838,7 @@ static void TEXT_DrawUnderscore (HDC hdc, int x, int y, const WCHAR *str, int of ...@@ -838,7 +838,7 @@ static void TEXT_DrawUnderscore (HDC hdc, int x, int y, const WCHAR *str, int of
* 3 more than a null-terminated string). If this is not so then increase * 3 more than a null-terminated string). If this is not so then increase
* the allowance in DrawTextExA. * the allowance in DrawTextExA.
*/ */
#define MAX_STATIC_BUFFER 1024 #define MAX_BUFFER 1024
INT WINAPI DrawTextExW( HDC hdc, LPWSTR str, INT i_count, INT WINAPI DrawTextExW( HDC hdc, LPWSTR str, INT i_count,
LPRECT rect, UINT flags, LPDRAWTEXTPARAMS dtp ) LPRECT rect, UINT flags, LPDRAWTEXTPARAMS dtp )
{ {
...@@ -846,7 +846,7 @@ INT WINAPI DrawTextExW( HDC hdc, LPWSTR str, INT i_count, ...@@ -846,7 +846,7 @@ INT WINAPI DrawTextExW( HDC hdc, LPWSTR str, INT i_count,
const WCHAR *strPtr; const WCHAR *strPtr;
WCHAR *retstr, *p_retstr; WCHAR *retstr, *p_retstr;
size_t size_retstr; size_t size_retstr;
WCHAR line[MAX_STATIC_BUFFER]; WCHAR line[MAX_BUFFER];
int len, lh, count=i_count; int len, lh, count=i_count;
TEXTMETRICW tm; TEXTMETRICW tm;
int lmargin = 0, rmargin = 0; int lmargin = 0, rmargin = 0;
...@@ -911,7 +911,7 @@ INT WINAPI DrawTextExW( HDC hdc, LPWSTR str, INT i_count, ...@@ -911,7 +911,7 @@ INT WINAPI DrawTextExW( HDC hdc, LPWSTR str, INT i_count,
do do
{ {
len = MAX_STATIC_BUFFER; len = sizeof(line)/sizeof(line[0]);
last_line = !(flags & DT_NOCLIP) && y + ((flags & DT_EDITCONTROL) ? 2*lh-1 : lh) > rect->bottom; last_line = !(flags & DT_NOCLIP) && y + ((flags & DT_EDITCONTROL) ? 2*lh-1 : lh) > rect->bottom;
strPtr = TEXT_NextLineW(hdc, strPtr, &count, line, &len, width, flags, &size, last_line, &p_retstr, tabwidth, &prefix_offset, &ellip); strPtr = TEXT_NextLineW(hdc, strPtr, &count, line, &len, width, flags, &size, last_line, &p_retstr, tabwidth, &prefix_offset, &ellip);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment