4 * Copyright 1999 Patrik Stridvall
13 #include "debugtools.h"
17 DEFAULT_DEBUG_CHANNEL(ttydrv
);
19 /***********************************************************************
20 * TTYDRV_DC_ExtTextOut
22 BOOL
TTYDRV_DC_ExtTextOut(DC
*dc
, INT x
, INT y
, UINT flags
,
23 const RECT
*lpRect
, LPCWSTR str
, UINT count
,
27 TTYDRV_PDEVICE
*physDev
= (TTYDRV_PDEVICE
*) dc
->physDev
;
31 TRACE("(%p, %d, %d, 0x%08x, %p, %s, %d, %p)\n",
32 dc
, x
, y
, flags
, lpRect
, debugstr_wn(str
, count
), count
, lpDx
);
37 /* FIXME: Is this really correct? */
38 if(dc
->w
.textAlign
& TA_UPDATECP
) {
46 row
= (dc
->w
.DCOrgY
+ y
) / physDev
->cellHeight
;
47 col
= (dc
->w
.DCOrgX
+ x
) / physDev
->cellWidth
;
48 ascii
= HeapAlloc( GetProcessHeap(), 0, count
+1 );
49 lstrcpynWtoA(ascii
, str
, count
+1);
50 mvwaddnstr(physDev
->window
, row
, col
, ascii
, count
);
51 HeapFree( GetProcessHeap(), 0, ascii
);
52 wrefresh(physDev
->window
);
54 if(dc
->w
.textAlign
& TA_UPDATECP
) {
55 dc
->w
.CursPosX
+= count
* physDev
->cellWidth
;
56 dc
->w
.CursPosY
+= physDev
->cellHeight
;
60 #else /* defined(WINE_CURSES) */
61 FIXME("(%p, %d, %d, 0x%08x, %p, %s, %d, %p): stub\n",
62 dc
, x
, y
, flags
, lpRect
, debugstr_wn(str
,count
), count
, lpDx
);
65 #endif /* defined(WINE_CURSES) */