diff --git a/new/init_windows.c b/new/init_windows.c
index 5620f76..e2cc1f2 100644
--- a/new/init_windows.c
+++ b/new/init_windows.c
@@ -84,7 +84,7 @@ uiInitError *uiInit(uiInitOptions *o)
 	// give each control a reasonable initial parent
 	// don't free the initial parent!
 	// TODO tune this better; it shouldn't be closed, for instance
-	initialParent = uiWindowHandle(uiNewWindow("", 0, 0));
+	initialParent = (HWND) uiWindowHandle(uiNewWindow("", 0, 0));
 
 	uiFree(err);
 	return NULL;
diff --git a/new/newcontrol_windows.c b/new/newcontrol_windows.c
index 61f802a..f301a54 100644
--- a/new/newcontrol_windows.c
+++ b/new/newcontrol_windows.c
@@ -100,7 +100,7 @@ uiControl *uiWindowsNewControl(uiWindowsNewControlParams *p)
 	c->onCommandNotifyData = p->onCommandNotifyData;
 	c->preferredSize = p->preferredSize;
 
-	if ((*fv_SetWindowSubclass)(c->hwnd, singleSubclassProc, 0, c) == FALSE)
+	if ((*fv_SetWindowSubclass)(c->hwnd, singleSubclassProc, 0, (DWORD_PTR) c) == FALSE)
 		logLastError("error subclassing Windows control in uiWindowsNewControl()");
 
 	return (uiControl *) c;
diff --git a/new/ui.h b/new/ui.h
index 11f3615..ce0a44b 100644
--- a/new/ui.h
+++ b/new/ui.h
@@ -24,4 +24,6 @@ void uiWindowShow(uiWindow *);
 void uiWindowHide(uiWindow *);
 void uiWindowOnClosing(uiWindow *, int (*)(uiWindow *, void *), void *);
 
+typedef struct uiControl uiControl;
+
 #endif
diff --git a/new/uipriv_windows.h b/new/uipriv_windows.h
index a17fbfe..c7527c0 100644
--- a/new/uipriv_windows.h
+++ b/new/uipriv_windows.h
@@ -36,6 +36,13 @@ enum {
 	msgNOTIFY,
 };
 
+// TODO move this to the right place
+struct uiSizing {
+	int baseX;
+	int baseY;
+	LONG internalLeading;
+};
+
 // alloc_windows.c
 extern void *uiAlloc(size_t);
 // TODO use this in existing files
diff --git a/new/window_windows.c b/new/window_windows.c
index aac61db..c0ca6c3 100644
--- a/new/window_windows.c
+++ b/new/window_windows.c
@@ -14,7 +14,7 @@ static LRESULT CALLBACK uiWindowWndProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPA
 {
 	uiWindow *w;
 	CREATESTRUCTW *cs = (CREATESTRUCTW *) lParam;
-	LRESULT lr;
+	LRESULT lResult;
 
 	w = (uiWindow *) GetWindowLongPtrW(hwnd, GWLP_USERDATA);
 	if (w == NULL) {
@@ -23,7 +23,7 @@ static LRESULT CALLBACK uiWindowWndProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPA
 		// fall through to DefWindowProc() anyway
 		return DefWindowProcW(hwnd, uMsg, wParam, lParam);
 	}
-	if (sharedWindowProc(hwnd, uMsg, wParam, lParam, &lResult) != FALSE)
+	if (sharedWndProc(hwnd, uMsg, wParam, lParam, &lResult) != FALSE)
 		return lResult;
 	switch (uMsg) {
 	case WM_CLOSE: