Mercurial > projects > dwt2
comparison org.eclipse.swt.win32.win32.x86/src/org/eclipse/swt/graphics/Path.d @ 39:0ecb2b338560
further work on phobosification
author | Frank Benoit <benoit@tionex.de> |
---|---|
date | Wed, 25 Mar 2009 13:20:43 +0100 |
parents | 6bf2837c50fe |
children |
comparison
equal
deleted
inserted
replaced
38:2e09b0e6857a | 39:0ecb2b338560 |
---|---|
294 */ | 294 */ |
295 public void addString(String string, float x, float y, Font font) { | 295 public void addString(String string, float x, float y, Font font) { |
296 if (isDisposed()) SWT.error(SWT.ERROR_GRAPHIC_DISPOSED); | 296 if (isDisposed()) SWT.error(SWT.ERROR_GRAPHIC_DISPOSED); |
297 if (font is null) SWT.error(SWT.ERROR_NULL_ARGUMENT); | 297 if (font is null) SWT.error(SWT.ERROR_NULL_ARGUMENT); |
298 if (font.isDisposed()) SWT.error(SWT.ERROR_INVALID_ARGUMENT); | 298 if (font.isDisposed()) SWT.error(SWT.ERROR_INVALID_ARGUMENT); |
299 wchar[] wstr = StrToWCHARs( string ); | 299 String16 wstr = StrToWCHARs( string ); |
300 wchar* buffer = wstr.ptr; | 300 LPCWSTR buffer = wstr.ptr; |
301 int length = wstr.length; | 301 int length = wstr.length; |
302 auto hDC = device.internal_new_GC(null); | 302 auto hDC = device.internal_new_GC(null); |
303 auto gdipFont = GC.createGdipFont(hDC, font.handle); | 303 auto gdipFont = GC.createGdipFont(hDC, font.handle); |
304 Gdip.PointF point; | 304 Gdip.PointF point; |
305 point.X = x - (Gdip.Font_GetSize(gdipFont) / 6); | 305 point.X = x - (Gdip.Font_GetSize(gdipFont) / 6); |